Skip to content

[5.7]Preparation for location aware diagnostics in the compiler. #343

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

Conversation

rintaro
Copy link
Member

@rintaro rintaro commented Apr 25, 2022

(Cherry-pick #321 into swift/release/5.7)

Corresponds to swift change swiftlang/swift#58390

Moving libswiftLexRegexLiteral() and libswiftParseRegexLiteral() to
the compiler repository because these functions are basically just
briding the compiler to the actual lexing/parsing function.

  • Make some Lexing error APIs public.
  • Make LocatedErrorProtocol public and expose the location property
  • Shift the location of LocatedError in parseWithDelimiters so the
    client can get the valid string indices of the passed-in literal string.

Moving `libswiftLexRegexLiteral()` and `libswiftParseRegexLiteral()` to
the compiler repository because these functions are basically just
briding the compiler to the actual lexing/parsing function.

 * Make some Lexing error APIs public.
 * Make LocatedErrorProtocol public and expose the `location` property
 * Shift the location of `LocatedError` in `parseWithDelimiters` so the
   client can get the valid string indices of the passed-in literal string.

(cherry picked from commit 89b80bf)
@rintaro
Copy link
Member Author

rintaro commented Apr 25, 2022

@swift-ci Please test

@rintaro rintaro changed the title [5.7 ]Preparation for location aware diagnostics in the compiler. [5.7]Preparation for location aware diagnostics in the compiler. Apr 25, 2022
@rintaro
Copy link
Member Author

rintaro commented Apr 25, 2022

@rintaro
Copy link
Member Author

rintaro commented Apr 25, 2022

@rintaro rintaro merged commit 8decae2 into swiftlang:swift/release/5.7 Apr 25, 2022
@rintaro rintaro deleted the 5.7-diagnostic-swiftcompiler branch April 25, 2022 20:24
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