Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-ty/src/mir/lower/tests.rs')
-rw-r--r--crates/hir-ty/src/mir/lower/tests.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/hir-ty/src/mir/lower/tests.rs b/crates/hir-ty/src/mir/lower/tests.rs
index d42072afa4..8eb0a02694 100644
--- a/crates/hir-ty/src/mir/lower/tests.rs
+++ b/crates/hir-ty/src/mir/lower/tests.rs
@@ -6,7 +6,7 @@ use crate::{InferBodyId, db::HirDatabase, setup_tracing, test_db::TestDB};
fn lower_mir(#[rust_analyzer::rust_fixture] ra_fixture: &str) {
let _tracing = setup_tracing();
let (db, file_ids) = TestDB::with_many_files(ra_fixture);
- crate::attach_db(&db, || {
+ crate::attach_db(db.as_dyn(), || {
let file_id = *file_ids.last().unwrap();
let module_id = db.module_for_file(file_id.file_id(&db));
let def_map = module_id.def_map(&db);
@@ -54,7 +54,7 @@ fn foo() {
fn check_borrowck(#[rust_analyzer::rust_fixture] ra_fixture: &str) {
let _tracing = setup_tracing();
let (db, file_ids) = TestDB::with_many_files(ra_fixture);
- crate::attach_db(&db, || {
+ crate::attach_db(db.as_dyn(), || {
let file_id = *file_ids.last().unwrap();
let module_id = db.module_for_file(file_id.file_id(&db));
let def_map = module_id.def_map(&db);
@@ -78,7 +78,7 @@ fn check_borrowck(#[rust_analyzer::rust_fixture] ra_fixture: &str) {
}
for body in bodies {
- let _ = InferBodyId::from(body).borrowck(&db);
+ let _ = InferBodyId::from(body).borrowck(db.as_dyn());
}
})
}