Github user DaveBirdsall commented on a diff in the pull request:

    https://github.com/apache/trafodion/pull/1585#discussion_r191857408
  
    --- Diff: core/sql/optimizer/ItemExpr.cpp ---
    @@ -3886,23 +3886,7 @@ ItemExpr * Parameter::copyTopNode(ItemExpr 
*derivedNode, CollHeap* outHeap)
     
     ItemExpr * DynamicParam::copyTopNode(ItemExpr *derivedNode, CollHeap* 
outHeap)
     {
    -  ItemExpr *result;
    -
    -  if (derivedNode == NULL) {
    -    result = new (outHeap) DynamicParam(paramName_, indicatorName_, 
outHeap);
    -    ((DynamicParam *) result)->setRowsetSize(rowsetSize_);
    -    ((DynamicParam *) result)->setRowsetInfo(rowsetInfo_);
    -    ((DynamicParam *) result)->setParamHeading(heading_);
    -    ((DynamicParam *) result)->setParamTablename(tablename_);
    -    // we remember our original dynamic parameter because we
    -    // must use their valueid at dynamicparam::codegen time
    -    ((DynamicParam *) result)->setOriginal(this);
    -  }
    -
    -  else
    -    result = derivedNode;
    -
    -  return Parameter::copyTopNode(result, outHeap);
    +  return this;
    --- End diff --
    
    @zellerh, can you comment on copyTopNode? Is my understanding correct?


---

Reply via email to