Skip to content

Allow node children to override whether a token needs a leading/trailing space #1298

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 1 commit into from
Feb 6, 2023

Conversation

ahoppen
Copy link
Member

@ahoppen ahoppen commented Jan 31, 2023

The motivating example was that we should not add a space after for in @_dynamicReplacement(for:…).

IMO, this also cleans up a few rules in BasicFormat.

Copy link
Contributor

@bnbarham bnbarham left a comment

Choose a reason for hiding this comment

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

Shouldn't this need a fix in Tests/SwiftParserTest/AttributeTests.swift?

@ahoppen
Copy link
Member Author

ahoppen commented Jan 31, 2023

That test will only be broken by #1180

@ahoppen ahoppen changed the title Allow node children to override whether a token needs a leading/trailing space 🚥 #1289 Allow node children to override whether a token needs a leading/trailing space Feb 2, 2023
@ahoppen ahoppen force-pushed the ahoppen/space-by-keypath branch from f0eb715 to 6ee5d3b Compare February 2, 2023 07:40
@ahoppen
Copy link
Member Author

ahoppen commented Feb 2, 2023

@swift-ci Please test

…ing space

The motivating example was that we should not add a space after `for` in `@_dynamicReplacement(for:…)`.

IMO, this also cleans up a few rules in BasicFormat.
@ahoppen ahoppen force-pushed the ahoppen/space-by-keypath branch from 6ee5d3b to 8781308 Compare February 2, 2023 14:58
@ahoppen
Copy link
Member Author

ahoppen commented Feb 2, 2023

@swift-ci Please test

@ahoppen ahoppen merged commit cec9680 into swiftlang:main Feb 6, 2023
@ahoppen ahoppen deleted the ahoppen/space-by-keypath branch February 6, 2023 13:39
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.

3 participants