New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ORC-1314: [C++] Remove macros defined before C++11 #1317
Conversation
static_cast<int64_t>(data[rowId])); | ||
writeString(buffer, numBuffer); | ||
const auto numBuffer = std::to_string(static_cast<int64_t>(data[rowId])); | ||
writeString(buffer, numBuffer.c_str()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 LGTM. And I suggest that writeString(std::string& file, const char* ptr) function can be optimized as writeString(std::string& file, const std::string& str).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this pass our Docker tests?
$ cd docker
$ ./run-all.sh apache main
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1, LGTM (if this passes Docker tests), @wgtmac .
Also, cc @williamhyun
Thanks for the review! @dongjoon-hyun I found that the centos7 docker image is failing with an old gcc version:
We may need fix the docker images before proceeding. |
Thank you for checking. It means the CentOS users need extra steps to upgrade it, right? Is it easy, @wgtmac ? Could you file a JIRA issue for CentOS?
|
Some other images fail as well due to different reasons. I will look into it when I have time. Will update when I have made progress. |
Thank you! |
57108b5
to
6ca98b4
Compare
Update:
Outstanding issues:
|
After I digging into fedora37 a little bit more, it seems that I am hitting a gcc bug:
The gcc version is not that old, though
|
I have moved the fix of testing failures on debian docker images to a separate PR: #1324 I can confirm that centos7 (w/ gcc-9) is running into the same issue of fedora37 when building test with google test. This failure exists in main, branch-1.8 and branch-1.7 branches. Therefore, it does not relate to the current patch (as well as the recent C++17 upgrade & google test upgrade). A separate JIRA has been filed to follow up the remaining issues: https://issues.apache.org/jira/browse/ORC-1320 |
I just committed this. Thanks @dongjoon-hyun and @coderex2522! |
Okay. Thank you. Let me double-check the main branch. |
Hi, @wgtmac and all.
Let me add my analysis.
It was my bad to land #1298 to branch-1.8. I'll revert it to recover Also, cc @williamhyun . |
What changes were proposed in this pull request?
Remove any unnecessary macros defined in the old days to work around missing support of C++11.
Why are the changes needed?
We have officially supported C++ 17, which means these macros are useless.
How was this patch tested?