aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2019-08-30 04:04:39 +0200
committerTristan Gingold <tgingold@free.fr>2019-08-30 04:04:39 +0200
commita4d58954c0b541150166b26fadb159bbdd338337 (patch)
treec538e57a798159df22bb159d5790dc58a402a947
parentf430db3560f470a115b608f7714839dd47647cc5 (diff)
downloadghdl-a4d58954c0b541150166b26fadb159bbdd338337.tar.gz
ghdl-a4d58954c0b541150166b26fadb159bbdd338337.tar.bz2
ghdl-a4d58954c0b541150166b26fadb159bbdd338337.zip
vhdl-annotate: handle shared anonymous subtype in interfaces.
-rw-r--r--src/vhdl/vhdl-annotations.adb5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/vhdl/vhdl-annotations.adb b/src/vhdl/vhdl-annotations.adb
index d81e70adf..18640794a 100644
--- a/src/vhdl/vhdl-annotations.adb
+++ b/src/vhdl/vhdl-annotations.adb
@@ -487,7 +487,10 @@ package body Vhdl.Annotations is
| Iir_Kind_Interface_Variable_Declaration
| Iir_Kind_Interface_Constant_Declaration
| Iir_Kind_Interface_File_Declaration =>
- Annotate_Anonymous_Type_Definition (Block_Info, Get_Type (El));
+ if Get_Subtype_Indication (El) /= Null_Iir then
+ Annotate_Anonymous_Type_Definition
+ (Block_Info, Get_Type (El));
+ end if;
when others =>
Error_Kind ("annotate_interface_list_subtype", El);
end case;