Skip to content

Commit

Permalink
stop requiring the feature-gate to use dyn_trait
Browse files Browse the repository at this point in the history
  • Loading branch information
pvdrz committed Apr 27, 2018
1 parent 2a6200a commit 199ee32
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 18 deletions.
9 changes: 2 additions & 7 deletions src/libsyntax/feature_gate.rs
Original file line number Diff line number Diff line change
Expand Up @@ -375,9 +375,6 @@ declare_features! (
// Future-proofing enums/structs with #[non_exhaustive] attribute (RFC 2008)
(active, non_exhaustive, "1.22.0", Some(44109), None),

// Trait object syntax with `dyn` prefix
(active, dyn_trait, "1.22.0", Some(44662), Some(Edition::Edition2018)),

// `crate` as visibility modifier, synonymous to `pub(crate)`
(active, crate_visibility_modifier, "1.23.0", Some(45388), Some(Edition::Edition2018)),

Expand Down Expand Up @@ -592,6 +589,8 @@ declare_features! (
(accepted, cfg_target_feature, "1.27.0", Some(29717), None),
// Allows #[target_feature(...)]
(accepted, target_feature, "1.27.0", None, None),
// Trait object syntax with `dyn` prefix
(accepted, dyn_trait, "1.22.0", Some(44662), None),
);

// If you change this, please modify src/doc/unstable-book as well. You must
Expand Down Expand Up @@ -1657,10 +1656,6 @@ impl<'a> Visitor<'a> for PostExpansionVisitor<'a> {
gate_feature_post!(&self, never_type, ty.span,
"The `!` type is experimental");
}
ast::TyKind::TraitObject(_, ast::TraitObjectSyntax::Dyn) => {
gate_feature_post!(&self, dyn_trait, ty.span,
"`dyn Trait` syntax is unstable");
}
_ => {}
}
visit::walk_ty(self, ty)
Expand Down
11 changes: 0 additions & 11 deletions src/test/ui/feature-gate-dyn-trait.stderr

This file was deleted.

0 comments on commit 199ee32

Please sign in to comment.