Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.lang.c++.moderated    |    Moderated discussion of C++ superhackery    |    33,346 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 31,752 of 33,346    |
|    David Lowndes to All    |
|    Re: Are MACROS good and can the compiler    |
|    20 Dec 11 12:05:00    |
      From: DavidL@example.invalid              >My question is; if NDEBUG is set, is it common behavior that the       >compiler will see that debugPrint() is empty and then remove the       >function call completely so I get the same removal behavior as a macro?              If the function is in a header file (i.e. the compiler can "see" it       properly), I think it's likely that an optimizer will remove it - but       the only way to be sure is to test it on the compilers you'll use.              Dave                     --        [ See http://www.gotw.ca/resources/clcm.htm for info about ]        [ comp.lang.c++.moderated. First time posters: Do this! ]              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca