diff options
author | Tristan Gingold <tgingold@free.fr> | 2020-04-16 17:51:24 +0200 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2020-04-16 17:51:24 +0200 |
commit | a60a736bfd35ee19a90f4a69e299706079ac76a8 (patch) | |
tree | 45809f15be70cd50c6aa7ea2cd7f1c1bb6871ec9 /src | |
parent | 2d9e127f4c20928a9f5c24e00b7c2d38248897d5 (diff) | |
download | ghdl-a60a736bfd35ee19a90f4a69e299706079ac76a8.tar.gz ghdl-a60a736bfd35ee19a90f4a69e299706079ac76a8.tar.bz2 ghdl-a60a736bfd35ee19a90f4a69e299706079ac76a8.zip |
synth-stmts: handle null assignments. Fix #1230
Diffstat (limited to 'src')
-rw-r--r-- | src/synth/synth-stmts.adb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/synth/synth-stmts.adb b/src/synth/synth-stmts.adb index d994bc0ff..d9b81188d 100644 --- a/src/synth/synth-stmts.adb +++ b/src/synth/synth-stmts.adb @@ -434,6 +434,12 @@ package body Synth.Stmts is Synth_Assignment_Aggregate (Syn_Inst, Target.Aggr, Target.Targ_Type, V, Loc); when Target_Simple => + if V.Typ.Sz = 0 then + -- If there is nothing to assign (like a null slice), + -- return now. + return; + end if; + if Target.Obj.Val.Kind = Value_Wire then if Is_Static (V.Val) and then V.Typ.W = Target.Obj.Typ.W |