jamesdbrock / hffix

Financial Information Exchange Protocol C++ Library
http://jamesdbrock.github.io/hffix
Other
276 stars 89 forks source link

use std::reverse #2

Closed arvidn closed 7 years ago

arvidn commented 7 years ago

I think this is a slight simplification of the code

jamesdbrock commented 7 years ago

I like this idea but it has a bug. This should be

std::reverse(buffer, b);

And if we do this then we can eliminate the e variable. Also then buffer can be a char const*.

Note to self: Is this faster? Slower? Time to make a real automated benchmark test.

arvidn commented 7 years ago

good point. I amended the patch. it would be nice to have tests that would cover this :)