mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-03 08:34:33 +00:00
Fix compile errors
This commit is contained in:
parent
b87f09115c
commit
46b4a97104
2 changed files with 10 additions and 2 deletions
|
@ -21,6 +21,7 @@ use roc_parse::pattern::PatternType;
|
|||
use roc_problem::can::{Problem, RuntimeError, ShadowKind};
|
||||
use roc_region::all::{Loc, Region};
|
||||
use roc_types::subs::{VarStore, Variable};
|
||||
use roc_types::types::AliasKind;
|
||||
use std::collections::HashMap;
|
||||
use std::fmt::Debug;
|
||||
use ven_graph::{strongly_connected_components, topological_sort_into_groups};
|
||||
|
@ -341,6 +342,7 @@ fn from_pending_alias<'a>(
|
|||
typ: symbol,
|
||||
variable_region: loc_lowercase.region,
|
||||
variable_name: loc_lowercase.value.clone(),
|
||||
alias_kind: AliasKind::Structural,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@ -373,7 +375,12 @@ fn from_pending_alias<'a>(
|
|||
|
||||
scope.add_alias(env.pool, symbol, named, annotation_id);
|
||||
} else {
|
||||
env.problem(Problem::CyclicAlias(symbol, name.region, vec![]));
|
||||
env.problem(Problem::CyclicAlias(
|
||||
symbol,
|
||||
name.region,
|
||||
vec![],
|
||||
AliasKind::Structural,
|
||||
));
|
||||
return output;
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -7,7 +7,7 @@ use roc_error_macros::todo_abilities;
|
|||
use roc_module::ident::{Ident, Lowercase, TagName, Uppercase};
|
||||
use roc_module::symbol::Symbol;
|
||||
use roc_region::all::{Loc, Region};
|
||||
use roc_types::types::{Problem, RecordField};
|
||||
use roc_types::types::{AliasKind, Problem, RecordField};
|
||||
use roc_types::{subs::Variable, types::ErrorType};
|
||||
|
||||
use crate::lang::env::Env;
|
||||
|
@ -793,6 +793,7 @@ fn to_type_apply<'a>(
|
|||
region,
|
||||
alias_needs: alias.targs.len() as u8,
|
||||
type_got: args.len() as u8,
|
||||
alias_kind: AliasKind::Structural,
|
||||
});
|
||||
return error;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue