mirror of
https://github.com/slint-ui/slint.git
synced 2025-10-01 22:31:14 +00:00
Compiler: avoid two error message when trying to call a non-existing function
This commit is contained in:
parent
93142bf417
commit
2564eede9f
2 changed files with 15 additions and 0 deletions
|
@ -891,6 +891,10 @@ impl Expression {
|
|||
.collect()
|
||||
}
|
||||
}
|
||||
Type::Invalid => {
|
||||
debug_assert!(ctx.diag.has_error());
|
||||
arguments.into_iter().map(|x| x.0).collect()
|
||||
}
|
||||
_ => {
|
||||
ctx.diag.push_error("The expression is not a function".into(), &node);
|
||||
arguments.into_iter().map(|x| x.0).collect()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue