From 0832b4aba24d9a1a3753852d58c23d066ce4b1fe Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Sat, 16 Nov 2019 13:40:10 +0100 Subject: synth: adjust static integer division. --- src/synth/synth-static_oper.adb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/synth') diff --git a/src/synth/synth-static_oper.adb b/src/synth/synth-static_oper.adb index 668b7b431..81e5171c0 100644 --- a/src/synth/synth-static_oper.adb +++ b/src/synth/synth-static_oper.adb @@ -206,7 +206,8 @@ package body Synth.Static_Oper is (Left.Scal / Right.Scal, Res_Typ); when Iir_Predefined_Integer_Mod => return Create_Value_Discrete - (Left.Scal mod Right.Scal, Res_Typ); + (Get_Static_Discrete (Left) mod Get_Static_Discrete (Right), + Res_Typ); when Iir_Predefined_Integer_Rem => return Create_Value_Discrete (Left.Scal rem Right.Scal, Res_Typ); -- cgit v1.2.3