-
Notifications
You must be signed in to change notification settings - Fork 3
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
UDict + cmp_generator #3
Conversation
…s to `protocols.py`
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.
lgtm
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'd change some things honestly:
- Make indices start at 0 instead of 1
- Getting the
default
attribute in theUDict.get(default=0)
function, not when the UDict is initialised (eg.UDict(default=0)
)
|
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'd remove the default
kw arg from the UDict.__init__()
, since if you want to pass in a key named default
, you'll need to do that using a dict instead of keyword args, which can lead to bad code readability.
And I'd really change the indices to start from 0 for convenience.
Other than that everything looks good.
No, i don't want change this things |
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.
You do you then
Thanks for approval! |
Checklist:
closes #1
closes #2
closes #7
closes #8