-
-
Notifications
You must be signed in to change notification settings - Fork 32.6k
gh-125897: Use positional-only parameter indicators for range()
#125945
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||
---|---|---|---|---|---|---|---|---|
|
@@ -1713,8 +1713,8 @@ are always available. They are listed here in alphabetical order. | |||||||
|
||||||||
|
||||||||
.. _func-range: | ||||||||
.. class:: range(stop) | ||||||||
range(start, stop, step=1) | ||||||||
.. class:: range(stop, /) | ||||||||
range(start, stop, step=1, /) | ||||||||
kbaikov marked this conversation as resolved.
Show resolved
Hide resolved
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think enumerating all three cases is slightly nicer. The
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I generally prefer fewer lines, partly from experience with IDLE call tips (which would be similar in other IDEs). Serhiy generally went with fewer in his PR, as he did here, except where really needed. Two are really needed here, since the true Python-implementaton signature Given your approval, I will merge this and backport (as Serhiy plans to backport his changes). |
||||||||
:noindex: | ||||||||
|
||||||||
Rather than being a function, :class:`range` is actually an immutable | ||||||||
|
Uh oh!
There was an error while loading. Please reload this page.