From 992a52089e39c5975748ca364971ed61d974a168 Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Fri, 9 Aug 2019 05:51:14 +0200 Subject: vhdl: handle subtype indication (with range) in discrete_range. For #877 --- src/vhdl/vhdl-parse.adb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/vhdl/vhdl-parse.adb') diff --git a/src/vhdl/vhdl-parse.adb b/src/vhdl/vhdl-parse.adb index 491d14b85..7e15589df 100644 --- a/src/vhdl/vhdl-parse.adb +++ b/src/vhdl/vhdl-parse.adb @@ -5152,6 +5152,9 @@ package body Vhdl.Parse is elsif Current_Token = Tok_To or else Current_Token = Tok_Downto then A_Choice := Create_Iir (Iir_Kind_Choice_By_Range); Set_Choice_Range (A_Choice, Parse_Range_Expression (Expr1)); + elsif Current_Token = Tok_Range then + A_Choice := Create_Iir (Iir_Kind_Choice_By_Range); + Set_Choice_Range (A_Choice, Parse_Subtype_Indication (Expr1)); else A_Choice := Create_Iir (Iir_Kind_Choice_By_Expression); Set_Choice_Expression (A_Choice, Expr1); -- cgit v1.2.3