Skip to content

Commit 26d9568

Browse files
committed
[DF][NFC] Fix warnings on Ubuntu 16
Should fix the warnings visible e.g. [here](root-project#6770 (comment)) and [here](root-project#8070 (comment)).
1 parent 59e4b3b commit 26d9568

File tree

2 files changed

+9
-11
lines changed

2 files changed

+9
-11
lines changed

tree/dataframe/src/RDFGraphUtils.cxx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -140,8 +140,7 @@ std::shared_ptr<GraphNode> CreateRangeNode(const ROOT::Detail::RDF::RRangeBase *
140140
return node;
141141
}
142142

143-
std::shared_ptr<GraphNode> AddDefinesToGraph(std::shared_ptr<GraphNode> node,
144-
const RDFInternal::RBookedDefines &defines,
143+
std::shared_ptr<GraphNode> AddDefinesToGraph(std::shared_ptr<GraphNode> node, const RBookedDefines &defines,
145144
const std::vector<std::string> &prevNodeDefines)
146145
{
147146
auto upmostNode = node;
@@ -150,7 +149,7 @@ std::shared_ptr<GraphNode> AddDefinesToGraph(std::shared_ptr<GraphNode> node,
150149
for (auto i = int(defineNames.size()) - 1; i >= 0; --i) { // walk backwards through the names of defined columns
151150
const auto colName = defineNames[i];
152151
const bool isAlias = defineMap.find(colName) == defineMap.end();
153-
if (isAlias || RDFInternal::IsInternalColumn(colName))
152+
if (isAlias || IsInternalColumn(colName))
154153
continue; // aliases appear in the list of defineNames but we don't support them yet
155154
const bool isANewDefine =
156155
std::find(prevNodeDefines.begin(), prevNodeDefines.end(), colName) == prevNodeDefines.end();

tree/dataframe/src/RDFInterfaceUtils.cxx

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@ ConvertRegexToColumns(const ColumnNames_t &colNames, std::string_view columnName
411411
// we need to use TPRegexp
412412
TPRegexp regexp(theRegex);
413413
for (auto &&colName : colNames) {
414-
if ((isEmptyRegex || regexp.MatchB(colName.c_str())) && !RDFInternal::IsInternalColumn(colName)) {
414+
if ((isEmptyRegex || regexp.MatchB(colName.c_str())) && !IsInternalColumn(colName)) {
415415
selectedColumns.emplace_back(colName);
416416
}
417417
}
@@ -584,8 +584,7 @@ std::string PrettyPrintAddr(const void *const addr)
584584
void BookFilterJit(const std::shared_ptr<RJittedFilter> &jittedFilter,
585585
std::shared_ptr<RDFDetail::RNodeBase> *prevNodeOnHeap, std::string_view name,
586586
std::string_view expression, const std::map<std::string, std::string> &aliasMap,
587-
const ColumnNames_t &branches, const RDFInternal::RBookedDefines &customCols, TTree *tree,
588-
RDataSource *ds)
587+
const ColumnNames_t &branches, const RBookedDefines &customCols, TTree *tree, RDataSource *ds)
589588
{
590589
const auto &dsColumns = ds ? ds->GetColumnNames() : ColumnNames_t{};
591590

@@ -629,7 +628,7 @@ void BookFilterJit(const std::shared_ptr<RJittedFilter> &jittedFilter,
629628

630629
// Jit a Define call
631630
std::shared_ptr<RJittedDefine> BookDefineJit(std::string_view name, std::string_view expression, RLoopManager &lm,
632-
RDataSource *ds, const RDFInternal::RBookedDefines &customCols,
631+
RDataSource *ds, const RBookedDefines &customCols,
633632
const ColumnNames_t &branches,
634633
std::shared_ptr<RNodeBase> *upcastNodeOnHeap)
635634
{
@@ -644,7 +643,7 @@ std::shared_ptr<RJittedDefine> BookDefineJit(std::string_view name, std::string_
644643
const auto lambdaName = DeclareLambda(parsedExpr.fExpr, parsedExpr.fVarNames, exprVarTypes);
645644
const auto type = RetTypeOfLambda(lambdaName);
646645

647-
auto definesCopy = new RDFInternal::RBookedDefines(customCols);
646+
auto definesCopy = new RBookedDefines(customCols);
648647
auto definesAddr = PrettyPrintAddr(definesCopy);
649648
auto jittedDefine = std::make_shared<RDFDetail::RJittedDefine>(name, type, lm.GetNSlots(), lm.GetDSValuePtrs());
650649

@@ -676,8 +675,8 @@ std::shared_ptr<RJittedDefine> BookDefineJit(std::string_view name, std::string_
676675
// (see comments in the body for actual jitted code)
677676
std::string JitBuildAction(const ColumnNames_t &cols, std::shared_ptr<RDFDetail::RNodeBase> *prevNode,
678677
const std::type_info &helperArgType, const std::type_info &at, void *helperArgOnHeap,
679-
TTree *tree, const unsigned int nSlots, const RDFInternal::RBookedDefines &customCols,
680-
RDataSource *ds, std::weak_ptr<RJittedAction> *jittedActionOnHeap)
678+
TTree *tree, const unsigned int nSlots, const RBookedDefines &customCols, RDataSource *ds,
679+
std::weak_ptr<RJittedAction> *jittedActionOnHeap)
681680
{
682681
// retrieve type of result of the action as a string
683682
auto helperArgClass = TClass::GetClass(helperArgType);
@@ -696,7 +695,7 @@ std::string JitBuildAction(const ColumnNames_t &cols, std::shared_ptr<RDFDetail:
696695
const std::string actionTypeName = actionTypeClass->GetName();
697696
const std::string actionTypeNameBase = actionTypeName.substr(actionTypeName.rfind(':') + 1);
698697

699-
auto definesCopy = new RDFInternal::RBookedDefines(customCols); // deleted in jitted CallBuildAction
698+
auto definesCopy = new RBookedDefines(customCols); // deleted in jitted CallBuildAction
700699
auto definesAddr = PrettyPrintAddr(definesCopy);
701700

702701
// Build a call to CallBuildAction with the appropriate argument. When run through the interpreter, this code will

0 commit comments

Comments
 (0)