diff options
Diffstat (limited to 'compiler/rustc_driver/src')
| -rw-r--r-- | compiler/rustc_driver/src/lib.rs | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/compiler/rustc_driver/src/lib.rs b/compiler/rustc_driver/src/lib.rs index e49e456792b..014007fc13b 100644 --- a/compiler/rustc_driver/src/lib.rs +++ b/compiler/rustc_driver/src/lib.rs @@ -248,11 +248,18 @@ fn run_compiler( interface::run_compiler(config, |compiler| { let sopts = &compiler.session().opts; if sopts.describe_lints { - let lint_store = rustc_lint::new_lint_store( + let mut lint_store = rustc_lint::new_lint_store( sopts.debugging_opts.no_interleave_lints, compiler.session().unstable_options(), ); - describe_lints(compiler.session(), &lint_store, false); + let registered_lints = + if let Some(register_lints) = compiler.register_lints() { + register_lints(compiler.session(), &mut lint_store); + true + } else { + false + }; + describe_lints(compiler.session(), &lint_store, registered_lints); return; } let should_stop = RustcDefaultCalls::print_crate_info( |
