mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-28 22:34:45 +00:00
Second pass
This commit is contained in:
parent
5e0d90ac53
commit
8dc92ccd97
15 changed files with 651 additions and 275 deletions
|
@ -66,6 +66,7 @@ impl<'a> RawFunctionLayout<'a> {
|
|||
Self::new_help(env, structure, structure_content.clone())
|
||||
}
|
||||
Structure(flat_type) => Self::layout_from_flat_type(env, flat_type),
|
||||
RangedNumber(typ, _) => Self::from_var(env, typ),
|
||||
|
||||
// Ints
|
||||
Alias(Symbol::NUM_I128, args, _) => {
|
||||
|
@ -902,6 +903,8 @@ impl<'a> Layout<'a> {
|
|||
}
|
||||
}
|
||||
|
||||
RangedNumber(typ, _) => Self::from_var(env, typ),
|
||||
|
||||
Error => Err(LayoutProblem::Erroneous),
|
||||
}
|
||||
}
|
||||
|
@ -2562,7 +2565,7 @@ fn layout_from_num_content<'a>(
|
|||
Alias(_, _, _) => {
|
||||
todo!("TODO recursively resolve type aliases in num_from_content");
|
||||
}
|
||||
Structure(_) => {
|
||||
Structure(_) | RangedNumber(..) => {
|
||||
panic!("Invalid Num.Num type application: {:?}", content);
|
||||
}
|
||||
Error => Err(LayoutProblem::Erroneous),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue