diff options
author | Tristan Gingold <tgingold@free.fr> | 2019-06-04 18:26:18 +0200 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2019-06-04 18:26:18 +0200 |
commit | ce47f31048c5f6565f55a84bbb0283b573b87c74 (patch) | |
tree | 1e8ad3f074f1156523b0919ffaf9d21e9090e44d | |
parent | 3b5c385fbb252fc2a5a6c939ed5087bd36b1d6eb (diff) | |
download | ghdl-ce47f31048c5f6565f55a84bbb0283b573b87c74.tar.gz ghdl-ce47f31048c5f6565f55a84bbb0283b573b87c74.tar.bz2 ghdl-ce47f31048c5f6565f55a84bbb0283b573b87c74.zip |
vhdl-sem_expr: do not try to report empty error message.
-rw-r--r-- | src/vhdl/vhdl-sem_expr.adb | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/vhdl/vhdl-sem_expr.adb b/src/vhdl/vhdl-sem_expr.adb index 1c15236f1..31c105c19 100644 --- a/src/vhdl/vhdl-sem_expr.adb +++ b/src/vhdl/vhdl-sem_expr.adb @@ -4968,12 +4968,14 @@ package body Vhdl.Sem_Expr is if Res /= Null_Iir and then Is_Overloaded (Res) then -- FIXME: clarify between overload and not determinable from the -- context. - Report_Start_Group; - Error_Overload (Expr); - if Get_Type (Res) /= Null_Iir then - Disp_Overload_List (Get_Overload_List (Get_Type (Res)), Expr); + if not Is_Error (Expr) then + Report_Start_Group; + Error_Overload (Expr); + if Get_Type (Res) /= Null_Iir then + Disp_Overload_List (Get_Overload_List (Get_Type (Res)), Expr); + end if; + Report_End_Group; end if; - Report_End_Group; return Null_Iir; end if; return Res; |