Skip to content

Allow adding multiple traits at once#27

Merged
minrk merged 1 commit intoipython:masterfrom
SylvainCorlay:add_traits
Jun 5, 2015
Merged

Allow adding multiple traits at once#27
minrk merged 1 commit intoipython:masterfrom
SylvainCorlay:add_traits

Conversation

@SylvainCorlay
Copy link
Member

As suggested by @sccolbert, allow adding multiple traits at once. This avoids creating too many new types when adding multiple decorators, since every call to add_trait was creating a new one.

@SylvainCorlay SylvainCorlay force-pushed the add_traits branch 2 times, most recently from 4050fb9 to e0a8821 Compare June 5, 2015 02:52
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need to iterate over traits.values() here.

@minrk
Copy link
Member

minrk commented Jun 5, 2015

Other than a missing iteration now that it's a container instead of a single trait, this makes sense to me.

minrk added a commit that referenced this pull request Jun 5, 2015
Allow adding multiple traits at once
@minrk minrk merged commit fac92d6 into ipython:master Jun 5, 2015
@SylvainCorlay SylvainCorlay deleted the add_traits branch June 5, 2015 03:06
@SylvainCorlay
Copy link
Member Author

Thanks,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants