about summary refs log tree commit diff
path: root/compiler/rustc_interface/src/interface.rs
diff options
context:
space:
mode:
authorbjorn3 <17426603+bjorn3@users.noreply.github.com>2024-12-12 11:45:10 +0000
committerbjorn3 <17426603+bjorn3@users.noreply.github.com>2024-12-13 10:46:53 +0000
commit981f625ba7c8e8ddcf6e470eb54d822eaf9fb300 (patch)
tree9ef00cff5eff1816f31b505b6bd3ad6bf3a13f46 /compiler/rustc_interface/src/interface.rs
parentead78fdfdf6692b2ecef7f47dfc934011c51fe4c (diff)
downloadrust-981f625ba7c8e8ddcf6e470eb54d822eaf9fb300.tar.gz
rust-981f625ba7c8e8ddcf6e470eb54d822eaf9fb300.zip
Remove registered_lints field from Session
It only exists to pass some information from one part of the driver to
another part. We can directly pass this information to the function that
needs it to reduce the amount of mutation of the Session.
Diffstat (limited to 'compiler/rustc_interface/src/interface.rs')
-rw-r--r--compiler/rustc_interface/src/interface.rs1
1 files changed, 0 insertions, 1 deletions
diff --git a/compiler/rustc_interface/src/interface.rs b/compiler/rustc_interface/src/interface.rs
index 07ae24ee6d3..7ad893f61ab 100644
--- a/compiler/rustc_interface/src/interface.rs
+++ b/compiler/rustc_interface/src/interface.rs
@@ -479,7 +479,6 @@ pub fn run_compiler<R: Send>(config: Config, f: impl FnOnce(&Compiler) -> R + Se
             let mut lint_store = rustc_lint::new_lint_store(sess.enable_internal_lints());
             if let Some(register_lints) = config.register_lints.as_deref() {
                 register_lints(&sess, &mut lint_store);
-                sess.registered_lints = true;
             }
             sess.lint_store = Some(Lrc::new(lint_store));