fix: aliased import of single type throws compiler error closes #707

This commit is contained in:
rvcas 2023-08-16 23:15:51 -04:00
parent 6d90c27587
commit f5a49c4df4
No known key found for this signature in database
GPG Key ID: C09B64E263F7D68C
1 changed files with 2 additions and 5 deletions

View File

@ -877,8 +877,7 @@ impl<'a> CodeGenerator<'a> {
}
Pattern::Constructor {
arguments,
constructor,
name,
constructor: PatternConstructor::Record { name, field_map },
tipo: constr_tipo,
..
} => {
@ -931,9 +930,7 @@ impl<'a> CodeGenerator<'a> {
}
}
let field_map = match constructor {
PatternConstructor::Record { field_map, .. } => field_map.clone(),
};
let field_map = field_map.clone();
let mut type_map: IndexMap<usize, Arc<Type>> = IndexMap::new();