4 ms·
If you are using macros in C++, you are doing it wrong. They are a relic of a bygone age.
by alexchamberlain 14y ago
If you are using macros in C++, you are doing it wrong. They are a relic of a bygone age.
- dakimov 14y agoThanks for letting me know, I try to use the macros as little as possible, but there are such things as platform-specific code, compiler differences, third-party libraries, standard libraries such as WinAPI and legacy code.
- alexchamberlain 14y agoPlatform-specific code is a very good use that precluded me at 1 o'clock this morning. I tend to wrap legacy code in a C++ wrapper if I can; allowing me to code to a C++ idiomed API, rather than the choice of that particular developer. More often than not, it adds no overhead through the use of inlined functions...