diff options
| author | Tristan Gingold <tgingold@free.fr> | 2019-11-04 18:54:26 +0100 |
|---|---|---|
| committer | Tristan Gingold <tgingold@free.fr> | 2019-11-04 18:54:26 +0100 |
| commit | 6a76011ecd33a45c4ba8b7dd24d0618b9fc85fb1 (patch) | |
| tree | 6f98dcf338f4265dec64538f26c74181c30c8244 | |
| parent | 89c685deca6ba27f85332afef7f08b62fb029a58 (diff) | |
| download | ghdl-6a76011ecd33a45c4ba8b7dd24d0618b9fc85fb1.tar.gz ghdl-6a76011ecd33a45c4ba8b7dd24d0618b9fc85fb1.tar.bz2 ghdl-6a76011ecd33a45c4ba8b7dd24d0618b9fc85fb1.zip | |
synth-expr: allow constants in discrete range
| -rw-r--r-- | src/synth/synth-expr.adb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/synth/synth-expr.adb b/src/synth/synth-expr.adb index f6660db8b..c34616d14 100644 --- a/src/synth/synth-expr.adb +++ b/src/synth/synth-expr.adb @@ -532,6 +532,8 @@ package body Synth.Expr is begin L := Synth_Expression_With_Basetype (Syn_Inst, Get_Left_Limit (Rng)); R := Synth_Expression_With_Basetype (Syn_Inst, Get_Right_Limit (Rng)); + Strip_Const (L); + Strip_Const (R); if not (Is_Const (L) and Is_Const (R)) then Error_Msg_Synth (+Rng, "limits of range are not constant"); |
