remove empty layout types (list,str,dict,set)

This commit is contained in:
Folkert 2021-11-27 14:05:16 +01:00
parent 8d668514e4
commit a1fd34feef
11 changed files with 94 additions and 296 deletions

View file

@ -3562,7 +3562,12 @@ pub fn with_hole<'a>(
}
Err(LayoutProblem::UnresolvedTypeVar(_)) => {
let expr = Expr::EmptyArray;
Stmt::Let(assigned, expr, Layout::Builtin(Builtin::EmptyList), hole)
Stmt::Let(
assigned,
expr,
Layout::Builtin(Builtin::List(&Layout::VOID)),
hole,
)
}
Err(LayoutProblem::Erroneous) => panic!("list element is error type"),
}