-
Notifications
You must be signed in to change notification settings - Fork 13.5k
Tweak some warnings around #[target_feature] #50096
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
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
When compiling crates we'll be calculating and parsing `#[target_feature]` for upstream crates. We'll also be checking the stability of listed features, but we only want to check the listed stability during the actual crate that wrote the relevant code. This commit updates the `target_feature` process to ignore foreign `DefId` instances and only check the feature whitelist for local functions. Closes rust-lang#50094
This commit transitions the `target_feature` attribute from `Normal` to `Whitelisted`. Discovered in rust-lang#50095 the fact of whether this attribute is used or not is dependent on typechecking running and executing `check_name`, but incremental compilation doesn't currently account for this, meaning that the attribute ends up being flagged as unused when it shouldn't be. I was a little too ambitious it seems hoping that `Normal` could be used, so instead this transitions to `Whitelisted` to be the same as other codegen attributes like `#[inline]` Closes rust-lang#50095
r? @eddyb |
cc @gnzlbg |
aha, this explains it 😆 |
@bors r+ |
📌 Commit 81a6437 has been approved by |
bors
added a commit
that referenced
this pull request
Apr 24, 2018
…ister Tweak some warnings around #[target_feature] This commit fixes up some issues discovered when getting the `stdsimd` crate's CI compiling again.
☀️ Test successful - status-appveyor, status-travis |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This commit fixes up some issues discovered when getting the
stdsimd
crate's CI compiling again.