enforce name style consistency
move byteswap functions to header files

- this makes clang not complain about them being missing due to being declared inline