aboutsummaryrefslogtreecommitdiffstats
path: root/src/synth/synth-vhdl_decls.adb
diff options
context:
space:
mode:
Diffstat (limited to 'src/synth/synth-vhdl_decls.adb')
-rw-r--r--src/synth/synth-vhdl_decls.adb6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/synth/synth-vhdl_decls.adb b/src/synth/synth-vhdl_decls.adb
index ca1414c84..7bccf96cf 100644
--- a/src/synth/synth-vhdl_decls.adb
+++ b/src/synth/synth-vhdl_decls.adb
@@ -271,10 +271,12 @@ package body Synth.Vhdl_Decls is
is
Attr_Decl : constant Node :=
Get_Named_Entity (Get_Attribute_Designator (Spec));
+ Marker : Mark_Type;
Value : Node;
Val : Valtyp;
Val_Type : Type_Acc;
begin
+ Mark_Expr_Pool (Marker);
Val_Type := Get_Subtype_Object (Syn_Inst, Get_Type (Attr_Decl));
Value := Get_Attribute_Value_Spec_Chain (Spec);
while Value /= Null_Iir loop
@@ -295,8 +297,10 @@ package body Synth.Vhdl_Decls is
--
-- 4. Each new attribute instance is assigned the value of
-- the expression.
+ Val := Unshare (Val, Instance_Pool);
Create_Object (Syn_Inst, Value, Val);
- -- Unshare (Val, Instance_Pool);
+
+ Release_Expr_Pool (Marker);
Value := Get_Spec_Chain (Value);
end loop;