mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-10 23:24:24 +00:00
Stop telling people to submit bugs for internal feature ICEs
This keeps track of usage of internal features, and changes the message to instead tell them that using internal features is not supported. See MCP 620.
This commit is contained in:
parent
1ffd09af29
commit
ebe63cde53
1 changed files with 5 additions and 3 deletions
|
@ -178,7 +178,7 @@ pub fn main() {
|
|||
|
||||
rustc_driver::init_rustc_env_logger(&handler);
|
||||
|
||||
rustc_driver::install_ice_hook(BUG_REPORT_URL, |handler| {
|
||||
let using_internal_features = rustc_driver::install_ice_hook(BUG_REPORT_URL, |handler| {
|
||||
// FIXME: this macro calls unwrap internally but is called in a panicking context! It's not
|
||||
// as simple as moving the call from the hook to main, because `install_ice_hook` doesn't
|
||||
// accept a generic closure.
|
||||
|
@ -265,9 +265,11 @@ pub fn main() {
|
|||
let clippy_enabled = !cap_lints_allow && (!no_deps || in_primary_package);
|
||||
if clippy_enabled {
|
||||
args.extend(clippy_args);
|
||||
rustc_driver::RunCompiler::new(&args, &mut ClippyCallbacks { clippy_args_var }).run()
|
||||
rustc_driver::RunCompiler::new(&args, &mut ClippyCallbacks { clippy_args_var })
|
||||
.set_using_internal_features(using_internal_features).run()
|
||||
} else {
|
||||
rustc_driver::RunCompiler::new(&args, &mut RustcCallbacks { clippy_args_var }).run()
|
||||
rustc_driver::RunCompiler::new(&args, &mut RustcCallbacks { clippy_args_var })
|
||||
.set_using_internal_features(using_internal_features).run()
|
||||
}
|
||||
}))
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue