Skip to content

bpo-38096: Clean up the "struct sequence" / "named tuple" docs #15895

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

Merged
merged 3 commits into from
Sep 11, 2019

Conversation

rhettinger
Copy link
Contributor

@rhettinger rhettinger commented Sep 11, 2019

Copy link
Member

@pganssle pganssle left a comment

Choose a reason for hiding this comment

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

LGTM.

@pganssle pganssle merged commit 7117074 into python:master Sep 11, 2019
@miss-islington
Copy link
Contributor

Thanks @rhettinger for the PR, and @pganssle for merging it 🌮🎉.. I'm working now to backport this PR to: 3.7, 3.8.
🐍🍒⛏🤖

@miss-islington
Copy link
Contributor

Sorry, @rhettinger and @pganssle, I could not cleanly backport this to 3.8 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker 7117074410118086938044c7a4ef6846ec1662b2 3.8

@miss-islington
Copy link
Contributor

Sorry @rhettinger and @pganssle, I had trouble checking out the 3.7 backport branch.
Please backport using cherry_picker on command line.
cherry_picker 7117074410118086938044c7a4ef6846ec1662b2 3.7

pganssle pushed a commit to pganssle/cpython that referenced this pull request Sep 11, 2019
…nGH-15895)

* bpo-38096: Clean up the "struct sequence" / "named tuple" docs

* Fix remaining occurrences of "struct sequence"

* Repair a user visible docstring

(cherry picked from commit 7117074)
@bedevere-bot
Copy link

GH-15961 is a backport of this pull request to the 3.8 branch.

@bedevere-bot
Copy link

GH-15962 is a backport of this pull request to the 3.7 branch.

Copy link
Member

@tim-one tim-one left a comment

Choose a reason for hiding this comment

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

Looks great! Thank you. Some comments:

  • Left a comment pointing out a typo.

  • Would have liked to see a blurb added to structseq.c pointing out that structseq is an internal CPython implementation detail, and that docs for modules using structseqs should call them "named tuples".

Some named tuples are built-in types (such as the above examples).
Alternatively, a named tuple can be created from a regular class
definition that inherits from :class:`tuple` and that defines named
fields. Such as class can be written by hand or it can be created with
Copy link
Member

Choose a reason for hiding this comment

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

Typo: "as" in "Such as class" should be "a".

DinoV pushed a commit to DinoV/cpython that referenced this pull request Sep 12, 2019
…nGH-15895)

* bpo-38096: Clean up the "struct sequence" / "named tuple" docs

* Fix remaining occurrences of "struct sequence"

* Repair a user visible docstring
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir skip news
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants