-
Notifications
You must be signed in to change notification settings - Fork 60
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Sort the branches alphabetically when writing Frames #421
Conversation
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.
Looks good, for consistency a similar thing should be done for the RNTuples
src/ROOTFrameWriter.cc
Outdated
std::vector<std::string> sortAlphabeticaly(const std::vector<std::string>& input) { | ||
auto output = input; |
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.
std::vector<std::string> sortAlphabeticaly(const std::vector<std::string>& input) { | |
auto output = input; | |
std::vector<std::string> sortAlphabeticaly(std::vector<std::string> vec) { |
Alternatively, since it's making a copy anyway make it explicit by not passing by reference and changing the name to something else
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.
Ah, yes. Excellent proposal. I always forget that this is a possibility for some reason.
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.
For the name change it's only to make it clear that it's not modifying the input although that can be seen in the argument; I don't have a strong opinion
src/ROOTFrameWriter.cc
Outdated
// where we convert the strings to lower case char-by-char. The alternative is | ||
// to make string copies inside the first lambda, transform them to lowercase | ||
// and then use operator< of std::string, which would be effectively | ||
// hand-writing what is happening below. |
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.
Probably worse since in the current way you only tolower
the characters that you need to check
I agree on the RNTuple. Would it help to move the |
Yes, already done I see :) |
Waiting for #423 to be merged first, just to make sure that this doesn't break things accidentally. |
5a3be2c
to
2360607
Compare
BEGINRELEASENOTES
ENDRELEASENOTES
As "requested" in AIDASoft/DD4hep#1108 (comment)