MADEAPPS / newton-dynamics

Newton Dynamics is an integrated solution for real time simulation of physics environments.
http://www.newtondynamics.com
Other
952 stars 182 forks source link

Symbols with two contiguous underscores must only be used by the compiler or standard library #256

Open jonesmz opened 3 years ago

jonesmz commented 3 years ago

See here: https://stackoverflow.com/questions/224397/why-do-people-use-double-underscore-so-much-in-c

I notice that preprocessor symbols with two leading underscores are used in header files. This is forbidden by the C++ and C language standards.

For example:

__D_VECTOR_X86_SIMD_H__

I also notice preprocessor defines with a single underscore followed by a capital letter, e.g.

    add_definitions(-D_D_CORE_EXPORT_DLL)

Symbols of this pattern are reserved for the standard library only.

Newton Dynamics should change these symbols to not use names in the reserved namespace.