Skip to content

Stop using TokenList and NonEmptyTokenList #1177

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
Jan 14, 2023

Conversation

ahoppen
Copy link
Member

@ahoppen ahoppen commented Jan 3, 2023

TokenList and NonEmptyTokenList are anti-patterns for SwiftSyntax parsing because they provide no structure. Stop using them.

@ahoppen ahoppen force-pushed the ahoppen/no-tokenlist branch from 5cd3e3f to 75e6341 Compare January 13, 2023 07:47
@ahoppen ahoppen changed the title Stop using TokenList and NonEmptyTokenList 🚥 #1176 Stop using TokenList and NonEmptyTokenList Jan 13, 2023
@ahoppen ahoppen requested a review from bnbarham January 13, 2023 07:48
@ahoppen ahoppen force-pushed the ahoppen/no-tokenlist branch from 75e6341 to 0d1f936 Compare January 13, 2023 08:20
@ahoppen
Copy link
Member Author

ahoppen commented Jan 13, 2023

@swift-ci Please test

@ahoppen ahoppen force-pushed the ahoppen/no-tokenlist branch from 0d1f936 to 795620a Compare January 13, 2023 08:56
@ahoppen ahoppen changed the title Stop using TokenList and NonEmptyTokenList Stop using TokenList and NonEmptyTokenList 🚥 #1226 Jan 13, 2023
@ahoppen ahoppen force-pushed the ahoppen/no-tokenlist branch from 795620a to 0f9e424 Compare January 13, 2023 15:03
@ahoppen ahoppen changed the title Stop using TokenList and NonEmptyTokenList 🚥 #1226 Stop using TokenList and NonEmptyTokenList Jan 13, 2023
@ahoppen
Copy link
Member Author

ahoppen commented Jan 13, 2023

@swift-ci Please test

@ahoppen
Copy link
Member Author

ahoppen commented Jan 13, 2023

swiftlang/swift-format#476

@swift-ci Please test

@ahoppen ahoppen force-pushed the ahoppen/no-tokenlist branch from 2bcaa31 to a85535b Compare January 13, 2023 20:18
@ahoppen
Copy link
Member Author

ahoppen commented Jan 13, 2023

swiftlang/swift-format#476

@swift-ci Please test

@@ -374,13 +374,19 @@
Child('Type', kind='Type'),
]),

Node('ClosureCaptureItemSpecifier', name_for_diagnostics='closure capture specifier', kind='Syntax',
Copy link
Contributor

Choose a reason for hiding this comment

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

Are there existing tests for this? If not it would be good to add a few.

Copy link
Member Author

Choose a reason for hiding this comment

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

@ahoppen ahoppen force-pushed the ahoppen/no-tokenlist branch from a85535b to ffefcda Compare January 14, 2023 07:35
@ahoppen
Copy link
Member Author

ahoppen commented Jan 14, 2023

@swift-ci Please test

@ahoppen
Copy link
Member Author

ahoppen commented Jan 14, 2023

@swift-ci Please test macOS

@ahoppen
Copy link
Member Author

ahoppen commented Jan 14, 2023

swiftlang/swift-format#476

@swift-ci Please test

1 similar comment
@ahoppen
Copy link
Member Author

ahoppen commented Jan 14, 2023

swiftlang/swift-format#476

@swift-ci Please test

@ahoppen ahoppen force-pushed the ahoppen/no-tokenlist branch from ffefcda to 267a56c Compare January 14, 2023 11:58
@ahoppen
Copy link
Member Author

ahoppen commented Jan 14, 2023

swiftlang/swift-format#476

@swift-ci Please test

@ahoppen
Copy link
Member Author

ahoppen commented Jan 14, 2023

@ahoppen ahoppen merged commit 3916bdb into swiftlang:main Jan 14, 2023
@ahoppen ahoppen deleted the ahoppen/no-tokenlist branch January 14, 2023 18:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants