Skip to content

Commit

Permalink
Rename rootnames to root.names to ensure naming conflicts with user-s…
Browse files Browse the repository at this point in the history
…pace variables do not happen.
  • Loading branch information
EpsilonPrime committed Jun 24, 2023
1 parent d732de6 commit 6756799
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ namespace io::substrait::textplan {

namespace {

const std::string kRootNames{"rootnames"};
const std::string kRootNames{"root.names"};

std::string shortName(std::string str) {
auto loc = str.find(':');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ std::vector<TestCase> getTestCases() {
}
})",
AllOf(
HasSymbols({"rootnames", "local", "read", "root"}),
HasSymbols({"root.names", "local", "read", "root"}),
WhenSerialized(EqSquashingWhitespace(
R"(pipelines {
read -> root;
Expand Down Expand Up @@ -190,7 +190,7 @@ std::vector<TestCase> getTestCases() {
})",
AllOf(
HasSymbols(
{"rootnames",
{"root.names",
"schema",
"cost",
"count",
Expand Down Expand Up @@ -408,7 +408,7 @@ std::vector<TestCase> getTestCases() {
}
})",
AllOf(
HasSymbols({"rootnames", "filter", "root"}),
HasSymbols({"root.names", "filter", "root"}),
WhenSerialized(EqSquashingWhitespace(
R"(pipelines {
filter -> root;
Expand Down Expand Up @@ -461,7 +461,7 @@ std::vector<TestCase> getTestCases() {
}
})",
AllOf(
HasSymbols({"rootnames", "filter", "root"}),
HasSymbols({"root.names", "filter", "root"}),
WhenSerialized(EqSquashingWhitespace(
R"(pipelines {
filter -> root;
Expand Down Expand Up @@ -533,7 +533,7 @@ std::vector<TestCase> getTestCases() {
}
})",
AllOf(
HasSymbols({"rootnames", "filter", "root"}),
HasSymbols({"root.names", "filter", "root"}),
WhenSerialized(EqSquashingWhitespace(
R"(pipelines {
filter -> root;
Expand All @@ -546,20 +546,20 @@ std::vector<TestCase> getTestCases() {
{
"single three node pipeline",
"relations: { root: { input: { project: { input { read: { local_files {} } } } } } }",
HasSymbols({"rootnames", "local", "read", "project", "root"}),
HasSymbols({"root.names", "local", "read", "project", "root"}),
},
{
"two identical three node pipelines",
"relations: { root: { input: { project: { input { read: { local_files {} } } } } } }"
"relations: { root: { input: { project: { input { read: { local_files {} } } } } } }",
AllOf(
HasSymbols(
{"rootnames",
{"root.names",
"local",
"read",
"project",
"root",
"rootnames2",
"root.names2",
"local2",
"read2",
"project2",
Expand All @@ -575,7 +575,7 @@ std::vector<TestCase> getTestCases() {
"relations: { root: { input: { hash_join: { left { read: { local_files {} } } right { read: { local_files {} } } } } } }",
AllOf(
HasSymbols(
{"rootnames",
{"root.names",
"local",
"read",
"local2",
Expand Down

0 comments on commit 6756799

Please sign in to comment.