mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-29 06:44:46 +00:00
cleanup
This commit is contained in:
parent
229d98483c
commit
55e1e86dc2
3 changed files with 17 additions and 10 deletions
|
@ -67,10 +67,10 @@ macro_rules! mismatch {
|
|||
type Pool = Vec<Variable>;
|
||||
|
||||
pub struct Context {
|
||||
pub first: Variable,
|
||||
pub first_desc: Descriptor,
|
||||
pub second: Variable,
|
||||
pub second_desc: Descriptor,
|
||||
first: Variable,
|
||||
first_desc: Descriptor,
|
||||
second: Variable,
|
||||
second_desc: Descriptor,
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
|
@ -668,8 +668,10 @@ fn unify_flat_type(
|
|||
outcome
|
||||
}
|
||||
(Container(cvar1, mvars1), Container(cvar2, mvars2)) => {
|
||||
let mut outcome = vec![];
|
||||
|
||||
// unify cvar1 and cvar2?
|
||||
unify_pool(subs, pool, *cvar1, *cvar2);
|
||||
outcome.extend(unify_pool(subs, pool, *cvar1, *cvar2));
|
||||
|
||||
let mvars: SendSet<Variable> = mvars1
|
||||
.into_iter()
|
||||
|
@ -689,7 +691,9 @@ fn unify_flat_type(
|
|||
let content =
|
||||
Content::Structure(FlatType::Boolean(Bool::Container(*cvar1, mvars)));
|
||||
|
||||
merge(subs, ctx, content)
|
||||
outcome.extend(merge(subs, ctx, content));
|
||||
|
||||
outcome
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue