Skip to content

Restify PEP 303 - #142

Merged
berkerpeksag merged 5 commits into
python:masterfrom
Mariatta:restify-pep303
Nov 28, 2016
Merged

berkerpeksag merged 5 commits into
python:masterfrom
Mariatta:restify-pep303

Conversation

@Mariatta

Copy link
Copy Markdown
Member

Mostly converted via a script but there were manual adjustments :)

Let me know what you think about this.

Prep the file for conversion by restify script
Add colon where necessary
Output from restify script
Some manual adjustments
Comment thread pep-0303.txt Outdated

The built-in ``divmod()`` function would be changed to accept multiple
divisors, changing its signature from ``divmod(dividend, divisor)`` to
divmod(dividend, \*divisors). The dividend is divided by the last

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

``divmod(dividend, *divisors)``

Comment thread pep-0303.txt Outdated
check its second argument for being a sequence is deemed to be too
ugly to contemplate. And in the case where one *does* have a
sequence that is computed other-where, it is easy enough to write
divmod(x, \*divs) instead.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

``divmod(x, *divs)``

Comment thread pep-0303.txt Outdated
new implementation of the function builtin_divmod() in
Python/bltinmodule.c
Not finished yet, but it seems a rather straightforward
new implementation of the function builtin_divmod() in

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

``builtin_divmod()``

Comment thread pep-0303.txt Outdated
Python/bltinmodule.c
Not finished yet, but it seems a rather straightforward
new implementation of the function builtin_divmod() in
Python/bltinmodule.c

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

``Python/bltinmodule.c``. (notice the missing full stop)

@Mariatta

Copy link
Copy Markdown
Member Author

Thanks, @berkerpeksag :) I addressed your comments.

Comment thread pep-0303.txt Outdated
that the target tuple is of the right length. Users from other
languages are more likely to understand the standard two argument
form without having to re-read the documentation. See python-dev
discussion on 17 June 2005.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Is this the correct discussion thread? https://mail.python.org/pipermail/python-dev/2005-June/054283.html
Should it be linked from here?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks like it is, nice detective work :) Yes, it would be nice to add a link.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Thanks :) I added the link to it.

@berkerpeksag
berkerpeksag merged commit 84de20b into python:master Nov 28, 2016
@berkerpeksag

Copy link
Copy Markdown
Member

Thanks!

@Mariatta
Mariatta deleted the restify-pep303 branch March 2, 2017 04:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants