aboutsummaryrefslogtreecommitdiffstats
path: root/src/synth
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2019-10-01 20:03:11 +0200
committerTristan Gingold <tgingold@free.fr>2019-10-01 20:03:11 +0200
commit808bc3fc0865eb9174f9ad35fe2f96de953c2522 (patch)
treeddff32e35cbfe4cdcc476fc8d26006e708f119ab /src/synth
parent2388da390b41e5fe3aef8c7b7e7a2a610944f362 (diff)
downloadghdl-808bc3fc0865eb9174f9ad35fe2f96de953c2522.tar.gz
ghdl-808bc3fc0865eb9174f9ad35fe2f96de953c2522.tar.bz2
ghdl-808bc3fc0865eb9174f9ad35fe2f96de953c2522.zip
synth: fix a crash on choice by range for aggregate.
Diffstat (limited to 'src/synth')
-rw-r--r--src/synth/synth-expr.adb3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/synth/synth-expr.adb b/src/synth/synth-expr.adb
index 12579b1eb..886b2c46b 100644
--- a/src/synth/synth-expr.adb
+++ b/src/synth/synth-expr.adb
@@ -321,7 +321,8 @@ package body Synth.Expr is
Rng := Synth_Discrete_Range_Expression (Syn_Inst, Ch);
Val := Create_Value_Discrete
(Rng.Left,
- Get_Value_Type (Syn_Inst, Get_Type (Ch)));
+ Get_Value_Type (Syn_Inst,
+ Get_Base_Type (Get_Type (Ch))));
while In_Range (Rng, Val.Scal) loop
Set_Elem (Get_Index_Offset (Val, Bound, Ch));
Update_Index (Rng, Val.Scal);