parse multi-backtracking

This commit is contained in:
Folkert 2021-03-19 00:10:02 +01:00
parent 85309444e1
commit 73e6128ce3
6 changed files with 250 additions and 90 deletions

View file

@ -72,7 +72,14 @@ pub fn helper<'a>(
test_builtin_defs,
);
let mut loaded = loaded.expect("failed to load module");
let mut loaded = match loaded {
Ok(x) => x,
Err(roc_load::file::LoadingProblem::ParsingFailedReport(report)) => {
println!("{}", report);
panic!();
}
Err(e) => panic!("{:?}", e),
};
use roc_load::file::MonomorphizedModule;
let MonomorphizedModule {