Skip to content
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

Remove leftover of type ascription feature gating #111350

Merged
merged 3 commits into from
Jun 3, 2023

Conversation

chenyukang
Copy link
Member

Fixes #111325

r? @Nilstrieb

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels May 8, 2023
@@ -532,8 +532,6 @@ declare_features! (
(active, try_blocks, "1.29.0", Some(31436), None),
/// Allows `impl Trait` to be used inside type aliases (RFC 2515).
(active, type_alias_impl_trait, "1.38.0", Some(63063), None),
/// Allows the use of type ascription in expressions.
(active, type_ascription, "1.6.0", Some(23416), None),
Copy link
Member

Choose a reason for hiding this comment

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

Note: this removed the language feature gate, but the built-in macro creates a library feature gate of the same name, which doesn't conflict.

Copy link
Contributor

Choose a reason for hiding this comment

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

Should the feature be declared in rustc_feature::removed?

Copy link
Member

@Noratrieb Noratrieb May 8, 2023

Choose a reason for hiding this comment

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

I wonder how well that interacts with the library feature. Maybe we should just keep the feature, but you can try moving it to removed.

Copy link
Member Author

Choose a reason for hiding this comment

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

we also didn't remove it from AST right now, there are multiple test case is changed to use type_ascribe!, maybe we should keep it at this moment.

compiler/rustc_ast_passes/src/feature_gate.rs Outdated Show resolved Hide resolved
@@ -532,8 +532,6 @@ declare_features! (
(active, try_blocks, "1.29.0", Some(31436), None),
/// Allows `impl Trait` to be used inside type aliases (RFC 2515).
(active, type_alias_impl_trait, "1.38.0", Some(63063), None),
/// Allows the use of type ascription in expressions.
(active, type_ascription, "1.6.0", Some(23416), None),
Copy link
Contributor

Choose a reason for hiding this comment

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

Should the feature be declared in rustc_feature::removed?

@Noratrieb
Copy link
Member

Let's keep the feature definition, but the removal of the gating code looks good.
r=me after reading the definition

@Noratrieb Noratrieb added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 25, 2023
@chenyukang
Copy link
Member Author

@bors r=Nilstrieb

@bors
Copy link
Contributor

bors commented Jun 3, 2023

📌 Commit 8baa32f has been approved by Nilstrieb

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jun 3, 2023
@chenyukang chenyukang changed the title Remove type ascription feature gate Remove leftover of type ascription feature gating Jun 3, 2023
@bors
Copy link
Contributor

bors commented Jun 3, 2023

⌛ Testing commit 8baa32f with merge 7d5b746...

@bors
Copy link
Contributor

bors commented Jun 3, 2023

☀️ Test successful - checks-actions
Approved by: Nilstrieb
Pushing 7d5b746 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jun 3, 2023
@bors bors merged commit 7d5b746 into rust-lang:master Jun 3, 2023
@rustbot rustbot added this to the 1.72.0 milestone Jun 3, 2023
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (7d5b746): comparison URL.

Overall result: no relevant changes - no action needed

@rustbot label: -perf-regression

Instruction count

This benchmark run did not return any relevant results for this metric.

Max RSS (memory usage)

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-2.6% [-2.6%, -2.6%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -2.6% [-2.6%, -2.6%] 1

Cycles

Results

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-1.2% [-1.2%, -1.2%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -1.2% [-1.2%, -1.2%] 1

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 648.734s -> 647.604s (-0.17%)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

remove leftover type_ascription remains in feature gating
6 participants