Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-126085: Addtp_iter to TypeAliasType to allow star unpacking#127981

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
JelleZijlstra merged 13 commits intopython:mainfromtomasr8:type-alias-iter
Mar 4, 2025

Conversation

@tomasr8
Copy link
Member

@tomasr8tomasr8 commentedDec 16, 2024
edited by ZeroIntensity
Loading

As@JelleZijlstra suggested, this simply adds atp_iter slot that returnsUnpack[self], same as we do for TypeVarTuple.

Feedback welcome!


📚 Documentation preview 📚:https://cpython-previews--127981.org.readthedocs.build/en/127981/library/typing.html#typing.TypeAliasType

alwaysmpe reacted with thumbs up emoji
tomasr8and others added2 commitsDecember 16, 2024 21:29
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Copy link
Member

@ZeroIntensityZeroIntensity left a comment

Choose a reason for hiding this comment

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

Mostly LGTM, with two comments.

tomasr8 reacted with thumbs up emoji
Copy link
Member

@ZeroIntensityZeroIntensity left a comment

Choose a reason for hiding this comment

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

Thanks!

tomasr8 reacted with rocket emoji
Copy link
Member

@Eclips4Eclips4 left a comment

Choose a reason for hiding this comment

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

Thank you!

tomasr8 reacted with heart emoji
Copy link
Member

@JelleZijlstraJelleZijlstra left a comment

Choose a reason for hiding this comment

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

Thanks, some nits.


#include"clinic/typevarobject.c.h"

#definetypevartuple_iter unpack_iter

Choose a reason for hiding this comment

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

I don't think we need these defines, just useunpack_iter directly.

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

This was a suggestion from@ZeroIntensity to keep the naming more consistent. I can remove them though

Copy link
Member

Choose a reason for hiding this comment

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

Could you remove them?

ZeroIntensity reacted with thumbs up emoji
Copy link
Member

Choose a reason for hiding this comment

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

I was complaining originally about the naming inconsistency, but in hindsight, it's probably better than the extra#define.

tomasr8 reacted with thumbs up emoji
Copy link
MemberAuthor

Choose a reason for hiding this comment

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

I'll remove them (and fix the conflict) later today :)

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

Removed!

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
@JelleZijlstraJelleZijlstra merged commite091520 intopython:mainMar 4, 2025
42 checks passed
@tomasr8tomasr8 deleted the type-alias-iter branchMarch 5, 2025 06:45
seehwan pushed a commit to seehwan/cpython that referenced this pull requestApr 16, 2025
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@ZeroIntensityZeroIntensityZeroIntensity approved these changes

@JelleZijlstraJelleZijlstraJelleZijlstra approved these changes

@picnixzpicnixzpicnixz approved these changes

@Eclips4Eclips4Eclips4 approved these changes

@markshannonmarkshannonAwaiting requested review from markshannon

@AlexWaygoodAlexWaygoodAwaiting requested review from AlexWaygoodAlexWaygood is a code owner

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

5 participants

@tomasr8@JelleZijlstra@picnixz@ZeroIntensity@Eclips4

[8]ページ先頭

©2009-2025 Movatter.jp