about summary refs log tree commit diff
diff options
context:
space:
mode:
authorTamir Duberstein <tamird@gmail.com>2023-11-17 15:21:00 -0500
committerTamir Duberstein <tamird@gmail.com>2023-11-22 14:25:22 -0500
commit45bad64ab43bd5af4ef6d540294c81e6bb4f89be (patch)
treef30b1d235430a5ee142cef6ae1b3b0988becfe50
parent6d2b84b3ed7848fd91b8d6151d4451b3103ed816 (diff)
downloadrust-45bad64ab43bd5af4ef6d540294c81e6bb4f89be.tar.gz
rust-45bad64ab43bd5af4ef6d540294c81e6bb4f89be.zip
rustc_lint: remove superfluous assertion
`Option::unwrap` is called on the next line.
-rw-r--r--compiler/rustc_lint/src/late.rs1
1 files changed, 0 insertions, 1 deletions
diff --git a/compiler/rustc_lint/src/late.rs b/compiler/rustc_lint/src/late.rs
index 551fe23f9f1..b47b3d41b12 100644
--- a/compiler/rustc_lint/src/late.rs
+++ b/compiler/rustc_lint/src/late.rs
@@ -33,7 +33,6 @@ use std::cell::Cell;
 /// Extract the `LintStore` from the query context.
 /// This function exists because we've erased `LintStore` as `dyn Any` in the session.
 pub fn unerased_lint_store(sess: &Session) -> &LintStore {
-    assert!(sess.lint_store.is_some());
     let store: &Lrc<_> = sess.lint_store.as_ref().unwrap();
     let store: &dyn Any = &**store;
     store.downcast_ref().unwrap()