diff options
author | Tristan Gingold <tgingold@free.fr> | 2019-09-26 07:44:53 +0200 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2019-09-26 07:44:53 +0200 |
commit | d07137710b5a1ff9a0d50341c2fa0432f9c7d4b0 (patch) | |
tree | 1b8288f49830cf6a71922f5dcac0ac526568252c /src/synth/synth-expr.adb | |
parent | decc588e1858cca6f6447a11c7669ac697964805 (diff) | |
download | ghdl-d07137710b5a1ff9a0d50341c2fa0432f9c7d4b0.tar.gz ghdl-d07137710b5a1ff9a0d50341c2fa0432f9c7d4b0.tar.bz2 ghdl-d07137710b5a1ff9a0d50341c2fa0432f9c7d4b0.zip |
synth: fix handling of single-bit memories.
Diffstat (limited to 'src/synth/synth-expr.adb')
-rw-r--r-- | src/synth/synth-expr.adb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/synth/synth-expr.adb b/src/synth/synth-expr.adb index fa2ddc925..9cb1e0bcc 100644 --- a/src/synth/synth-expr.adb +++ b/src/synth/synth-expr.adb @@ -910,13 +910,14 @@ package body Synth.Expr is if Pfx_Type.Kind = Type_Vector then W := 1; - Mul := 0; if Idx_Val.Kind = Value_Discrete then Voff := No_Net; + Mul := 0; Off := Index_To_Offset (Pfx_Type.Vbound, Idx_Val.Scal, Name); else Voff := Dyn_Index_To_Offset (Pfx_Type.Vbound, Idx_Val, Name); Off := 0; + Mul := 1; end if; elsif Pfx_Type.Kind = Type_Array then W := Get_Type_Width (Pfx_Type.Arr_El); |