Skip to content

Commit

Permalink
cleanup dead code warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
sbillig committed Jan 13, 2025
1 parent dd02706 commit 3ca832f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
8 changes: 4 additions & 4 deletions crates/hir-analysis/tests/test_db.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ impl_db_traits!(
DriverDb,
);

// https://github.com/rust-lang/rust/issues/46379
#[allow(dead_code)]
impl HirAnalysisTestDb {
pub fn new_stand_alone(&mut self, file_name: &str, text: &str) -> InputFile {
let kind = IngotKind::StandAlone;
Expand Down Expand Up @@ -120,18 +122,16 @@ pub struct HirPropertyFormatter<'db> {
code_span_files: SimpleFiles<String, String>,
}

// https://github.com/rust-lang/rust/issues/46379
#[allow(dead_code)]
impl<'db> HirPropertyFormatter<'db> {
// https://github.com/rust-lang/rust/issues/46379
#[allow(dead_code)]
pub fn push_prop(&mut self, top_mod: TopLevelMod<'db>, span: DynLazySpan<'db>, prop: String) {
self.properties
.entry(top_mod)
.or_default()
.push((prop, span));
}

// https://github.com/rust-lang/rust/issues/46379
#[allow(dead_code)]
pub fn finish(&mut self, db: &'db dyn SpannedHirDb) -> String {
let writer = BufferWriter::stderr(ColorChoice::Never);
let mut buffer = writer.buffer();
Expand Down
1 change: 1 addition & 0 deletions crates/language-server/src/backend/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ pub struct Backend {
pub(super) client: ClientSocket,
pub(super) db: LanguageServerDatabase,
pub(super) workspace: Workspace,
#[allow(dead_code)] // TODO: salsa3-compatible parallelism
pub(super) workers: tokio::runtime::Runtime,
}

Expand Down
2 changes: 0 additions & 2 deletions crates/language-server/src/functionality/handlers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ use async_lsp::{
use common::InputDb;
use fxhash::FxHashSet;
use salsa::Setter;
use tracing::dispatcher::with_default;
use tracing::Dispatch;

use super::{capabilities::server_capabilities, hover::hover_helper};

Expand Down

0 comments on commit 3ca832f

Please sign in to comment.