mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-02 08:11:12 +00:00
tell me what function has no implementation
This commit is contained in:
parent
f3e327cfee
commit
b8c0c85395
3 changed files with 8 additions and 3 deletions
|
@ -789,8 +789,13 @@ fn canonicalize_pending_def<'a>(
|
|||
|
||||
let arity = typ.arity();
|
||||
|
||||
let def_symbol = match &loc_can_pattern.value {
|
||||
Pattern::Identifier(symbol) => *symbol,
|
||||
_ => panic!("standalone annotations must be on identifiers"),
|
||||
};
|
||||
|
||||
// Fabricate a body for this annotation, that will error at runtime
|
||||
let value = Expr::RuntimeError(RuntimeError::NoImplementation);
|
||||
let value = Expr::RuntimeError(RuntimeError::NoImplementation(def_symbol));
|
||||
let is_closure = arity > 0;
|
||||
let loc_can_expr = if !is_closure {
|
||||
Located {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue