[ClangAstParser] Adds exception for InitListExpr in TU normalization
@@ -27,6 +27,7 @@ import org.suikasoft.jOptions.Datakey.DataKey;
import pt.up.fe.specs.clang.parsers.ClangParserData;
import pt.up.fe.specs.clava.ClavaLog;
import pt.up.fe.specs.clava.ClavaNode;
+import pt.up.fe.specs.clava.ast.expr.InitListExpr;
import pt.up.fe.specs.clava.ast.extra.TranslationUnit;
public class TUnitProcessor {
@@ -223,6 +224,11 @@ public class TUnitProcessor {
return Optional.empty();
}
+ // Do not normalize InitListExpr, to avoid conflicts with semantic/syntactic forms
+ if (node instanceof InitListExpr) {
+ return Optional.empty();
+ }
+
String signature = node.getNodeSignature();
// If signature is ambiguous, cannot normalize node
