From fbbee537228538f448a335bb0b2dabec2b3d443e Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Wed, 31 Oct 2018 02:08:54 +0300 Subject: Add ModuleScope as a query This is a first step towards queryifing completion and resolve. Some code currently duplicates ra_editor: the plan is to move all completion from ra_editor, but it'll take more than one commit. --- crates/ra_analysis/src/db.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'crates/ra_analysis/src/db.rs') diff --git a/crates/ra_analysis/src/db.rs b/crates/ra_analysis/src/db.rs index 3ca14af79..e7a5d5e2f 100644 --- a/crates/ra_analysis/src/db.rs +++ b/crates/ra_analysis/src/db.rs @@ -9,8 +9,9 @@ use salsa; use crate::{ db, Cancelable, Canceled, - descriptors::module::{SubmodulesQuery, ModuleTreeQuery, ModulesDatabase}, + descriptors::module::{SubmodulesQuery, ModuleTreeQuery, ModulesDatabase, ModuleScopeQuery}, symbol_index::SymbolIndex, + syntax_ptr::{SyntaxPtrDatabase, ResolveSyntaxPtrQuery}, FileId, }; @@ -65,6 +66,10 @@ salsa::database_storage! { impl ModulesDatabase { fn module_tree() for ModuleTreeQuery; fn module_descriptor() for SubmodulesQuery; + fn module_scope() for ModuleScopeQuery; + } + impl SyntaxPtrDatabase { + fn resolve_syntax_ptr() for ResolveSyntaxPtrQuery; } } } -- cgit v1.2.3