Skip to content

[4.2][Parser] Detect non-breaking space (U+00A0) and offer a fix-it #16306

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 6 commits into from
May 3, 2018

Conversation

rintaro
Copy link
Member

@rintaro rintaro commented May 2, 2018

Cherry-pick of #16090 and #16280
rdar://problem/20982969

#16090 authored by @hashemi, reviewed by me.

Detect Unicode non-breaking space character (U+00A0) in the lexer, diagnose it, and offer a fix-it turning it into a regular space. Also treat the non-breaking space as whitespace when considering whether an operator is left/right bound.

#16280 authored by me, reviewed by @jrose-apple

Diagnose and fix-it consecutive 'U+00A0's at once

@rintaro
Copy link
Member Author

rintaro commented May 2, 2018

@swift-ci Please test

@rintaro rintaro merged commit fcc7434 into swiftlang:swift-4.2-branch May 3, 2018
@rintaro rintaro deleted the 4.2-lexer-nbsp branch May 3, 2018 13:18
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