clarify variable name

This commit is contained in:
Folkert 2022-03-13 17:59:44 +01:00
parent d31ea3e71f
commit 97742b3238
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
2 changed files with 5 additions and 5 deletions

View file

@ -53,7 +53,7 @@ impl ExposedByModule {
#[derive(Clone, Debug, Default)] #[derive(Clone, Debug, Default)]
pub struct ExposedForModule { pub struct ExposedForModule {
pub exposed_by_module: ExposedByModule, pub exposed_by_module: ExposedByModule,
pub imported_symbols: Vec<Symbol>, pub imported_values: Vec<Symbol>,
} }
impl ExposedForModule { impl ExposedForModule {
@ -61,7 +61,7 @@ impl ExposedForModule {
it: impl Iterator<Item = &'a Symbol>, it: impl Iterator<Item = &'a Symbol>,
exposed_by_module: ExposedByModule, exposed_by_module: ExposedByModule,
) -> Self { ) -> Self {
let mut imported_symbols = Vec::new(); let mut imported_values = Vec::new();
for symbol in it { for symbol in it {
// Today, builtins are not actually imported, // Today, builtins are not actually imported,
@ -75,14 +75,14 @@ impl ExposedForModule {
if let Some(ExposedModuleTypes::Valid { .. }) = if let Some(ExposedModuleTypes::Valid { .. }) =
exposed_by_module.exposed.get(&symbol.module_id()) exposed_by_module.exposed.get(&symbol.module_id())
{ {
imported_symbols.push(*symbol); imported_values.push(*symbol);
} else { } else {
continue; continue;
} }
} }
Self { Self {
imported_symbols, imported_values,
exposed_by_module, exposed_by_module,
} }
} }

View file

@ -3108,7 +3108,7 @@ fn run_solve<'a>(
let mut import_variables = Vec::new(); let mut import_variables = Vec::new();
for symbol in exposed_for_module.imported_symbols { for symbol in exposed_for_module.imported_values {
let module_id = symbol.module_id(); let module_id = symbol.module_id();
match exposed_for_module.exposed_by_module.get_mut(&module_id) { match exposed_for_module.exposed_by_module.get_mut(&module_id) {
Some(t) => match t { Some(t) => match t {