aboutsummaryrefslogtreecommitdiffstats
path: root/src/synth/synth-stmts.adb
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2019-07-26 04:32:07 +0200
committerTristan Gingold <tgingold@free.fr>2019-07-26 04:32:07 +0200
commit2075f8cf5995bc83a8edc07456331b5b0f5b6be1 (patch)
tree114477245057faf8957c9790b18c61d78f62605e /src/synth/synth-stmts.adb
parent1aa373bd730caa2a558cc02f3f6a0fb269316a16 (diff)
downloadghdl-2075f8cf5995bc83a8edc07456331b5b0f5b6be1.tar.gz
ghdl-2075f8cf5995bc83a8edc07456331b5b0f5b6be1.tar.bz2
ghdl-2075f8cf5995bc83a8edc07456331b5b0f5b6be1.zip
synth: preliminary support of integer subtypes.
Diffstat (limited to 'src/synth/synth-stmts.adb')
-rw-r--r--src/synth/synth-stmts.adb4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/synth/synth-stmts.adb b/src/synth/synth-stmts.adb
index 5aad73c76..158fd60df 100644
--- a/src/synth/synth-stmts.adb
+++ b/src/synth/synth-stmts.adb
@@ -84,13 +84,15 @@ package body Synth.Stmts is
Val : Value_Acc)
is
Targ_Type : constant Node := Get_Type (Target);
+ Bnd : Value_Bound_Acc;
Choice : Node;
Assoc : Node;
Pos : Uns32;
begin
if Is_Vector_Type (Targ_Type) then
+ Bnd := Expr.Synth_Array_Bounds (Syn_Inst, Targ_Type, 0);
Choice := Get_Association_Choices_Chain (Target);
- Pos := Get_Width (Syn_Inst, Targ_Type);
+ Pos := Bnd.Len;
while Is_Valid (Choice) loop
Assoc := Get_Associated_Expr (Choice);
case Get_Kind (Choice) is