diff options
-rw-r--r-- | src/synth/synth-static_oper.adb | 6 | ||||
-rw-r--r-- | src/synth/synth-values.adb | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/synth/synth-static_oper.adb b/src/synth/synth-static_oper.adb index 349117d87..1b0cf1cdc 100644 --- a/src/synth/synth-static_oper.adb +++ b/src/synth/synth-static_oper.adb @@ -536,6 +536,8 @@ package body Synth.Static_Oper is Iir_Index32 (Get_Bound_Length (Left.Typ, 1)); R_Len : constant Iir_Index32 := Iir_Index32 (Get_Bound_Length (Right.Typ, 1)); + L : constant Value_Acc := Strip_Alias_Const (Left); + R : constant Value_Acc := Strip_Alias_Const (Right); Bnd : Bound_Type; Res_Typ : Type_Acc; Arr : Value_Array_Acc; @@ -547,10 +549,10 @@ package body Synth.Static_Oper is (Ret_Typ, Bnd); Arr := Create_Value_Array (L_Len + R_Len); for I in 1 .. L_Len loop - Arr.V (I) := Left.Arr.V (I); + Arr.V (I) := L.Arr.V (I); end loop; for I in 1 .. R_Len loop - Arr.V (L_Len + I) := Right.Arr.V (I); + Arr.V (L_Len + I) := R.Arr.V (I); end loop; return Create_Value_Const_Array (Res_Typ, Arr); end; diff --git a/src/synth/synth-values.adb b/src/synth/synth-values.adb index f2a9d7033..0d10a94da 100644 --- a/src/synth/synth-values.adb +++ b/src/synth/synth-values.adb @@ -90,7 +90,7 @@ package body Synth.Values is when Value_Const => return True; when Value_Alias => - return False; + return Is_Static_Val (Val.A_Obj); when Value_Instance | Value_Subtype => -- Not really a value. |