Open3DMotionGroup / Open3DMotion

Other
5 stars 2 forks source link

Adding the -Wcast-align flag to Clang warns about pointer casts that inc... #13

Closed Alzathar closed 10 years ago

Alzathar commented 10 years ago

...rease alignment.

For example: cast from 'value_type ' (aka 'unsigned char ') to 'const Int16 ' (aka 'const short ') increases required alignment from 1 to 2 [-Wcast-align]

The use of the “reinterpret_cast” function fixes that.

I added the flag -Wcast-align, because I wanted to remove the C casting methods from the project Biomechanical-ToolKit and replace them by the adapted C++ code.