mirror of
https://github.com/rust-lang/rust.git
synced 2025-06-06 04:08:40 +00:00
Remove feature-gate code
This commit is contained in:
parent
a249981a43
commit
ac231d40a3
@ -22,7 +22,6 @@ use session::{config::nightly_options, Session};
|
|||||||
use syntax::ast;
|
use syntax::ast;
|
||||||
use syntax::attr;
|
use syntax::attr;
|
||||||
use syntax::source_map::MultiSpan;
|
use syntax::source_map::MultiSpan;
|
||||||
use syntax::feature_gate;
|
|
||||||
use syntax::symbol::Symbol;
|
use syntax::symbol::Symbol;
|
||||||
use util::nodemap::FxHashMap;
|
use util::nodemap::FxHashMap;
|
||||||
|
|
||||||
@ -228,18 +227,7 @@ impl<'a> LintLevelsBuilder<'a> {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
let tool_name = if let Some(lint_tool) = word.is_scoped() {
|
let tool_name = if let Some(lint_tool) = word.is_scoped() {
|
||||||
let gate_feature = !self.sess.features_untracked().tool_lints;
|
if !attr::is_known_lint_tool(lint_tool) {
|
||||||
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 {
|
|
||||||
span_err!(
|
span_err!(
|
||||||
sess,
|
sess,
|
||||||
lint_tool.span,
|
lint_tool.span,
|
||||||
@ -247,9 +235,6 @@ impl<'a> LintLevelsBuilder<'a> {
|
|||||||
"an unknown tool name found in scoped lint: `{}`",
|
"an unknown tool name found in scoped lint: `{}`",
|
||||||
word.ident
|
word.ident
|
||||||
);
|
);
|
||||||
}
|
|
||||||
|
|
||||||
if gate_feature || !known_tool {
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user