diff options
| -rw-r--r-- | src/synth/synth-expr.adb | 6 | 
1 files changed, 6 insertions, 0 deletions
| diff --git a/src/synth/synth-expr.adb b/src/synth/synth-expr.adb index 4fb5d1136..a2ceb6e15 100644 --- a/src/synth/synth-expr.adb +++ b/src/synth/synth-expr.adb @@ -2183,6 +2183,12 @@ package body Synth.Expr is        end if;        Strip_Const (Right); +      if Is_Static_Val (Right.Val) +        and then Get_Static_Discrete (Right) = Val +      then +         return Create_Value_Discrete (Val, Boolean_Type); +      end if; +        --  Return a static value if both operands are static.        --  Note: we know the value of left if it is not constant.        if Is_Static_Val (Left.Val) and then Is_Static_Val (Right.Val) then | 
