Skip to content
Snippets Groups Projects
Commit 6558af9d authored by Emma Söderberg's avatar Emma Söderberg
Browse files

Fix inc param debug mode for circular attributes

parent 5c148260
Branches
No related tags found
No related merge requests found
......@@ -122,6 +122,7 @@ aspect IncrementalDebug {
TemplateContext tt = templateContext();
for (AttrDecl attr : listOfCachedAttributes()) {
tt.bind("IsParameterized", attr.getNumParameter() > 0);
tt.bind("IsCircular", attr.isCircular());
tt.bind("PrintAsObject", attr.isPrimitive() || attr.getType().equals("String"));
tt.bind("AttrSign", attr.signature());
res.append(tt.expand("ASTDecl.dumpCachedAttributeValue"));
......
......@@ -139,7 +139,11 @@ if ($(AttrSign)_values != null) {
}
}
$else
$if (IsCircular)
if ($(AttrSign)_computed == $StateClass.NON_CYCLE || $(AttrSign)_computed == state().cycle()) {
$else
if ($(AttrSign)_computed) {
$endif
$if (PrintAsObject)
System.out.println("value(" + relativeNodeID() + ":$(AttrSign), " + $(AttrSign)_value + ")");
$else
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment