-
Notifications
You must be signed in to change notification settings - Fork 82
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
Using vector<unsigned char> instead of vector<bool> #827
Conversation
I haven't come up with a cleaner way to fix this yet, please comment if you have any other suggestions! Thanks. |
Please, push "Ready for review" button if you want this PR to be reviewed. |
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.
This looks correct but there is a lot of code duplication.
I was thinking about introducing a generic container type that would select either a std::vector
or a std::array
according to the value type, but thinking again, why not just using always a std::array
?
This is to avoid using too much stack memory, you can see more information in #823. |
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.
Thanks! I love shorter code for maintenance. :-)
Co-authored-by: Ronan Keryell <[email protected]>
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.
Thanks!
Since the std::vector<bool> type does not have a data() member function,
Using vector instead of vector.