-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CorpusObject: add parameters to init #516
Conversation
Is there anything that speaks against making this a |
That's also a good idea :) the only thing I'm worried about is inheriting from a non- |
The inheritance can be removed, it plays no role at all as far as I can see. At least in i6_experiments there is not a single check for |
Thanks for the feedback. I'll change it and leave it throughout the weekend, and if nobody complains we could merge this next week. |
Also remove inheritance from tk.Object
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was worried this might change hashes, but apparently it does not.
I find it much better to provide the parameters to an object via
__init__
than to provide them by creating the object and explicitly setting the actual attribute. This helps for instance when I have to create a bunch ofCorpusObject
s in a list comprehension, which is similar to my use case.If there was any explicit reason why these were not in the
__init__
function please let me know.