aboutsummaryrefslogtreecommitdiffstats
path: root/src/vhdl/sem_types.adb
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2017-01-15 18:13:07 +0100
committerTristan Gingold <tgingold@free.fr>2017-01-15 18:13:07 +0100
commit4c61775cde12ee8169af73b6d023e02c948b0239 (patch)
treeb56b6451df3b3d82ff2812040a4379677adaaa06 /src/vhdl/sem_types.adb
parentf6c9bc0e66602c86003f118d8d8e35693d4abcaf (diff)
downloadghdl-4c61775cde12ee8169af73b6d023e02c948b0239.tar.gz
ghdl-4c61775cde12ee8169af73b6d023e02c948b0239.tar.bz2
ghdl-4c61775cde12ee8169af73b6d023e02c948b0239.zip
vhdl2008: handle 'Subtype as a type name and in disp_vhdl
Diffstat (limited to 'src/vhdl/sem_types.adb')
-rw-r--r--src/vhdl/sem_types.adb12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/vhdl/sem_types.adb b/src/vhdl/sem_types.adb
index e6f242c1e..09806ad05 100644
--- a/src/vhdl/sem_types.adb
+++ b/src/vhdl/sem_types.adb
@@ -2219,10 +2219,14 @@ package body Sem_Types is
--
-- If the subtype indication does not include a constraint, the subtype
-- is the same as that denoted by the type mark.
- if Get_Kind (Def) in Iir_Kinds_Denoting_Name then
- Type_Mark := Sem_Type_Mark (Def, Incomplete);
- return Type_Mark;
- end if;
+ case Get_Kind (Def) is
+ when Iir_Kinds_Denoting_Name
+ | Iir_Kind_Attribute_Name =>
+ Type_Mark := Sem_Type_Mark (Def, Incomplete);
+ return Type_Mark;
+ when others =>
+ null;
+ end case;
-- Analyze the type mark.
Type_Mark_Name := Get_Subtype_Type_Mark (Def);