]> git.lizzy.rs Git - rust.git/commitdiff
Remove feature-gate code
authorflip1995 <hello@philkrones.com>
Tue, 2 Oct 2018 08:59:41 +0000 (10:59 +0200)
committerManish Goregaokar <manishsmail@gmail.com>
Tue, 9 Oct 2018 23:38:38 +0000 (16:38 -0700)
src/librustc/lint/levels.rs

index 87d33e473e7f6cd97bc392e3f6bf926518744264..bcba5c97e3317054f80a02e9b89050cc3280f85f 100644 (file)
@@ -22,7 +22,6 @@
 use syntax::ast;
 use syntax::attr;
 use syntax::source_map::MultiSpan;
-use syntax::feature_gate;
 use syntax::symbol::Symbol;
 use util::nodemap::FxHashMap;
 
@@ -228,18 +227,7 @@ pub fn push(&mut self, attrs: &[ast::Attribute]) -> BuilderPush {
                     }
                 };
                 let tool_name = if let Some(lint_tool) = word.is_scoped() {
-                    let gate_feature = !self.sess.features_untracked().tool_lints;
-                    let known_tool = attr::is_known_lint_tool(lint_tool);
-                    if gate_feature {
-                        feature_gate::emit_feature_err(
-                            &sess.parse_sess,
-                            "tool_lints",
-                            word.span,
-                            feature_gate::GateIssue::Language,
-                            &format!("scoped lint `{}` is experimental", word.ident),
-                        );
-                    }
-                    if !known_tool {
+                    if !attr::is_known_lint_tool(lint_tool) {
                         span_err!(
                             sess,
                             lint_tool.span,
@@ -247,9 +235,6 @@ pub fn push(&mut self, attrs: &[ast::Attribute]) -> BuilderPush {
                             "an unknown tool name found in scoped lint: `{}`",
                             word.ident
                         );
-                    }
-
-                    if gate_feature || !known_tool {
                         continue;
                     }