From 3439e17389eeedf793cf930b642c539b73766a10 Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Sun, 12 Jan 2020 21:28:17 +0100 Subject: synth-decls: do subtype conversion for signal default value. --- src/synth/synth-decls.adb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/synth/synth-decls.adb b/src/synth/synth-decls.adb index 5644d220f..26d6f164b 100644 --- a/src/synth/synth-decls.adb +++ b/src/synth/synth-decls.adb @@ -640,6 +640,8 @@ package body Synth.Decls is if Is_Valid (Def) then Obj_Type := Get_Value_Type (Syn_Inst, Get_Type (Decl)); Init := Synth_Expression_With_Type (Syn_Inst, Def, Obj_Type); + Init := Synth_Subtype_Conversion + (Init, Obj_Type, False, Decl); else Init := null; end if; -- cgit v1.2.3