From 9272b09a4fdac810bdd1a1aedb4d7fcc2604c9e1 Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Thu, 28 Nov 2019 18:38:42 +0100 Subject: synth-expr: strip const for synth_type_conversion. Fix #1043 --- src/synth/synth-expr.adb | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/synth/synth-expr.adb b/src/synth/synth-expr.adb index 8724afdc0..763e6379c 100644 --- a/src/synth/synth-expr.adb +++ b/src/synth/synth-expr.adb @@ -1588,6 +1588,7 @@ package body Synth.Expr is Val : Value_Acc; begin Val := Synth_Expression_With_Basetype (Syn_Inst, Expr); + Strip_Const (Val); case Get_Kind (Conv_Type) is when Iir_Kind_Integer_Subtype_Definition => if Val.Typ.Kind = Type_Discrete then -- cgit v1.2.3