Skip to content

[line-directive] Escape literal '[' #31010

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
Apr 14, 2020
Merged

Conversation

davezarzycki
Copy link
Contributor

New versions of Python warn if the literal is not escaped. Specifically:

Support for nested sets and set operations in regular expressions as in Unicode Technical Standard #18 might be added in the future. This would change the syntax. To facilitate this future change a FutureWarning will be raised in ambiguous cases for the time being. That include sets starting with a literal '[' or containing literal character sequences '--', '&&', '~~', and '||'. To avoid a warning, escape them with a backslash. (Contributed by Serhiy Storchaka in bpo-30349.)"

https://docs.python.org/dev/whatsnew/3.7.html

New versions of Python warn if the literal is not escaped. Specifically:

    "Support for nested sets and set operations in regular expressions as in
    Unicode Technical Standard swiftlang#18 might be added in the future. This would
    change the syntax. To facilitate this future change a FutureWarning will
    be raised in ambiguous cases for the time being. That include sets
    starting with a literal '[' or containing literal character sequences
    '--', '&&', '~~', and '||'. To avoid a warning, escape them with a
    backslash. (Contributed by Serhiy Storchaka in bpo-30349.)"

https://docs.python.org/dev/whatsnew/3.7.html
@davezarzycki
Copy link
Contributor Author

@swift-ci please smoke test and merge

@swift-ci swift-ci merged commit 6f01826 into swiftlang:master Apr 14, 2020
@davezarzycki davezarzycki deleted the pr31010 branch April 14, 2020 13:00
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