llohse / libnpy

C++ library for reading and writing of numpy's .npy files
MIT License
361 stars 72 forks source link

Change unsigned long and short to int16/int64/etc, #39

Closed phoenixfury closed 1 day ago

phoenixfury commented 5 months ago

ament_cpplint is complaining about the C type long & short, can you please use int16/int64/etc, instead? Thanks for your awesome work!

llohse commented 1 day ago

Different linters complain about different coding styles - there is no way around that. I would not consider long and short to be C style, since they are also the fundamental types in C++. In fact the fixed-width types require to include <cstdint>.

I have been using the fundamental types because that is what the numpy folks are doing. If there is a good argument against this, I would reconsider my decision.