-
Notifications
You must be signed in to change notification settings - Fork 397
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
Adding SwiftSyntaxBuilder to the build process #379
Conversation
This script does not build SwiftSyntaxBuilder by default. This change has to be followed by an update in `.gyb` files.
|
Thanks for your PR 👍. Building As for your other changes: Those issues are because we are still using Python 2 for all sorts of Python scripts in the swift project. There’s another PR up at #378 that fixes this. I think for this PR we should either
|
|
No worries. Would you mind squashing your changes into one commit and force pushing. Having five commits do and undo some changes just looks noisy in the git history. |
|
This have been fixed in #381 🎉 |
|
@ahoppen think we just can close this one. |
|
Yes, you’re right 👍 |
The build process of SwiftSyntax, should build three shared objects:
The SwiftSyntaxBuilder one has not been called to be built, then this pull request adds such build call to the
build-script.pyfile. Also, there are two points in the build process that was producing erros during the SwiftSyntaxBuilder build.string_escapeencode. However, python2 strings supports encoding forutf-8and decoding asunicode_escape.I'm not sure about differences between
string.encode('utf-8').decode('unicode_escape')andstring.decode('string_escape')in Python2, but looking for the data that will be used to fillTokens.swift.gybwe only have UTF-8 characters, and for that case these approaches are equivalent. See the values in the file swift/utils/gyb_syntax_support/Token.py.