mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-29 06:44:46 +00:00
report a Foo.Bar
malformed identifier
This commit is contained in:
parent
10255a90b1
commit
c05ec12be0
3 changed files with 35 additions and 6 deletions
|
@ -725,10 +725,11 @@ pub fn canonicalize_expr<'a>(
|
|||
}
|
||||
ast::Expr::MalformedIdent(name) => {
|
||||
use roc_problem::can::RuntimeError::*;
|
||||
(
|
||||
RuntimeError(MalformedIdentifier((*name).into(), region)),
|
||||
Output::default(),
|
||||
)
|
||||
|
||||
let problem = MalformedIdentifier((*name).into(), region);
|
||||
env.problem(Problem::RuntimeError(problem.clone()));
|
||||
|
||||
(RuntimeError(problem), Output::default())
|
||||
}
|
||||
ast::Expr::Nested(sub_expr) => {
|
||||
let (answer, output) = canonicalize_expr(env, var_store, scope, region, sub_expr);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue