diff options
-rw-r--r-- | evaluation.adb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/evaluation.adb b/evaluation.adb index 4fd522c..eb0231e 100644 --- a/evaluation.adb +++ b/evaluation.adb @@ -1525,8 +1525,9 @@ package body Evaluation is else return Build_Enumeration (Iir_Index32 (P), Expr); end if; - when Iir_Kind_Physical_Int_Literal => - return Build_Physical (Get_Value (Expr) + N, Expr); + when Iir_Kind_Physical_Int_Literal + | Iir_Kind_Unit_Declaration => + return Build_Physical (Get_Physical_Value (Expr) + N, Expr); when others => Error_Kind ("eval_incdec", Expr); end case; |