Skip to content

[Frontend/AST] Add -interface-compiler-version option to frontend/modules #77216

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
Oct 29, 2024

Conversation

xedin
Copy link
Contributor

@xedin xedin commented Oct 25, 2024

This option is going to be used to indicate what compiler was used
to build swift interface/module which is required for SE-0438.

xedin added 2 commits October 24, 2024 17:06
…nterfaces

This option is going to be used to indicate what compiler was used
to build swift interface/module which is required for SE-0438.
@xedin
Copy link
Contributor Author

xedin commented Oct 25, 2024

@swift-ci please test

@xedin xedin changed the title [Frontend/AST] Add -swift-compiler-version option to frontend [Frontend/AST] Add -swift-compiler-version option to frontend/modules Oct 25, 2024
xedin added 2 commits October 25, 2024 09:53
Swiftinterface files are always built with "current" compiler version,
which means that `-swift-compiler-version` has no effect in this context.
@xedin xedin force-pushed the add-swift-compiler-version branch from b696f5a to 2d8751b Compare October 25, 2024 16:53
@xedin
Copy link
Contributor Author

xedin commented Oct 25, 2024

@swift-ci please test

@xedin
Copy link
Contributor Author

xedin commented Oct 25, 2024

@swift-ci please test Linux platform

@xedin
Copy link
Contributor Author

xedin commented Oct 25, 2024

@swift-ci please test Windows platform

…m swiftinterface

If swiftinterface doesn't have `-swift-compiler-version` flag
it means that it was generated with an older version of the
Swift compiler. In such cases it would be incorrect to use
"current" compiler version because the field is intended to
indicate the compiler the swiftinterface was built with.
@xedin
Copy link
Contributor Author

xedin commented Oct 26, 2024

@swift-ci please test

…ace-compiler-version`

It might be unexpected to future users that `-swift-compiler-version`
would produce a version aligned to .swiftinterface instead of one used
to build the .swiftmodule file. To avoid this possible confusion, let's
scope down the version to `-interface-compiler-version` flag and
`SWIFT_INTERFACE_COMPILER_VERSION` option in the module.
@xedin
Copy link
Contributor Author

xedin commented Oct 28, 2024

@swift-ci please test

Copy link
Contributor

@artemcm artemcm left a comment

Choose a reason for hiding this comment

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

LGTM!

@xedin xedin changed the title [Frontend/AST] Add -swift-compiler-version option to frontend/modules [Frontend/AST] Add -interface-compiler-version option to frontend/modules Oct 28, 2024
@xedin xedin merged commit 6cb4b59 into swiftlang:main Oct 29, 2024
5 checks passed
xedin added a commit to swiftlang/swift-driver that referenced this pull request Oct 30, 2024
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