mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-30 23:31:12 +00:00
add import dependencies to module cache
This commit is contained in:
parent
c24d51e69d
commit
092db87474
1 changed files with 13 additions and 0 deletions
|
@ -358,6 +358,7 @@ struct ModuleCache<'a> {
|
|||
external_specializations_requested: MutMap<ModuleId, ExternalSpecializations>,
|
||||
|
||||
/// Various information
|
||||
imports: MutMap<ModuleId, MutSet<ModuleId>>,
|
||||
documentation: MutMap<ModuleId, ModuleDocumentation>,
|
||||
can_problems: MutMap<ModuleId, Vec<roc_problem::can::Problem>>,
|
||||
type_problems: MutMap<ModuleId, Vec<solve::TypeError>>,
|
||||
|
@ -1641,6 +1642,18 @@ fn update<'a>(
|
|||
.exposed_symbols_by_module
|
||||
.insert(home, exposed_symbols);
|
||||
|
||||
state
|
||||
.module_cache
|
||||
.imports
|
||||
.entry(header.module_id)
|
||||
.or_default()
|
||||
.extend(
|
||||
header
|
||||
.package_qualified_imported_modules
|
||||
.iter()
|
||||
.map(|x| *x.as_inner()),
|
||||
);
|
||||
|
||||
work.extend(state.dependencies.add_module(
|
||||
header.module_id,
|
||||
&header.package_qualified_imported_modules,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue