diff options
author | Tristan Gingold <tgingold@free.fr> | 2017-10-15 07:33:32 +0200 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2017-10-15 07:33:32 +0200 |
commit | 4d12a44e443fbe3285a968e217cde3d27339bb3f (patch) | |
tree | b8b13b510fd44f33953a8a865d4698db204c77e8 | |
parent | cbf6d4d125e7fbf0842dce4089083d0851adfb28 (diff) | |
download | ghdl-4d12a44e443fbe3285a968e217cde3d27339bb3f.tar.gz ghdl-4d12a44e443fbe3285a968e217cde3d27339bb3f.tar.bz2 ghdl-4d12a44e443fbe3285a968e217cde3d27339bb3f.zip |
Reduce cascaded error messages.
-rw-r--r-- | src/vhdl/errorout.adb | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/vhdl/errorout.adb b/src/vhdl/errorout.adb index 2120332ba..9de1aff56 100644 --- a/src/vhdl/errorout.adb +++ b/src/vhdl/errorout.adb @@ -1559,9 +1559,12 @@ package body Errorout is "(" & Disp_Node (Callee) & " is defined here)", Callee); end Error_Pure; - procedure Error_Not_Match (Expr: Iir; A_Type: Iir) - is + procedure Error_Not_Match (Expr: Iir; A_Type: Iir) is begin + if Get_Kind (A_Type) = Iir_Kind_Error then + -- Cascade error message. + return; + end if; Error_Msg_Sem ("can't match " & Disp_Node (Expr) & " with type " & Disp_Node (A_Type), Expr); end Error_Not_Match; |