瀏覽代碼

HPCC-21272 Preserve the case of identifiers in the graph

Signed-off-by: Gavin Halliday <gavin.halliday@lexisnexis.com>
Gavin Halliday 6 年之前
父節點
當前提交
61bbd723bc
共有 2 個文件被更改,包括 6 次插入8 次删除
  1. 5 7
      ecl/hqlcpp/hqlhtcpp.cpp
  2. 1 1
      ecl/hqlcpp/hqlhtcpp.ipp

+ 5 - 7
ecl/hqlcpp/hqlhtcpp.cpp

@@ -1944,16 +1944,14 @@ void ActivityInstance::addNameAttribute(IHqlExpression * symbol)
     //We should probably perform some deduping instead.
     addLocationAttribute(symbol);
 
-    IAtom * name = symbol->queryName();
+    IIdAtom * name = symbol->queryId();
     if (!name)
         return;
 
-    ForEachItemIn(i, names)
-    {
-        if (names.item(i).queryName() == name)
-            return;
-    }
-    names.append(*symbol);
+    if (names.contains(*name))
+        return;
+
+    names.append(*name);
     addAttribute(WaEclName, str(name));
 }
 

+ 1 - 1
ecl/hqlcpp/hqlhtcpp.ipp

@@ -222,7 +222,7 @@ public:
     IHqlStmt * classGroup;
     unsigned    initialGroupMarker;
     HqlExprArray constructorArgs;
-    HqlExprCopyArray names;
+    ICopyArrayOf<IIdAtom> names;
     LocationArray locations;
 
     Linked<IPropertyTree> graphNode;