summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/vhdl/sem_names.adb6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/vhdl/sem_names.adb b/src/vhdl/sem_names.adb
index e74a0f3..fe2b0e0 100644
--- a/src/vhdl/sem_names.adb
+++ b/src/vhdl/sem_names.adb
@@ -3584,9 +3584,7 @@ package body Sem_Names is
when Iir_Kind_Function_Declaration =>
if Maybe_Function_Call (Expr) then
Expr := Sem_As_Function_Call (Res, Expr, Null_Iir);
- if Get_Kind (Expr) /= Iir_Kind_Function_Call then
- raise Internal_Error;
- end if;
+ pragma Assert (Get_Kind (Expr) = Iir_Kind_Function_Call);
Finish_Sem_Function_Call (Expr, Res);
return Expr;
else
@@ -3594,6 +3592,8 @@ package body Sem_Names is
(Disp_Node (Expr) & " requires parameters", Res);
Set_Type (Res, Get_Type (Expr));
Set_Expr_Staticness (Res, None);
+ Set_Named_Entity
+ (Res, Create_Error_Expr (Expr, Get_Type (Expr)));
return Res;
end if;
when others =>