aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2019-11-28 18:38:42 +0100
committerTristan Gingold <tgingold@free.fr>2019-11-28 18:40:28 +0100
commit9272b09a4fdac810bdd1a1aedb4d7fcc2604c9e1 (patch)
treec122fd5df31939cf00ad0fff8df602bf8cd5bd82
parent6a8be8e0ace3040689d849990114415ead81879d (diff)
downloadghdl-9272b09a4fdac810bdd1a1aedb4d7fcc2604c9e1.tar.gz
ghdl-9272b09a4fdac810bdd1a1aedb4d7fcc2604c9e1.tar.bz2
ghdl-9272b09a4fdac810bdd1a1aedb4d7fcc2604c9e1.zip
synth-expr: strip const for synth_type_conversion. Fix #1043
-rw-r--r--src/synth/synth-expr.adb1
1 files changed, 1 insertions, 0 deletions
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