This is the mail archive of the
gdb@sourceware.cygnus.com
mailing list for the GDB project.
Re: wrong htons() used?
>>>>> "Grant" == Grant Edwards <Grant.Edwards@comtrol.com> writes:
Grant> OK, this is wierd. Running gcc -E -O2 produces source with an
Grant> external declaration for htons() but no calls. Running gcc -E
Grant> without -O2 generates source with calls to htons().
Grant> I didn't know that -O altered the pre-processor's behavior.
Grant> That doesn't sound too kosher.
I think that with -O, gcc passes -D__OPTIMIZE__ to the preprocessor.
So preprocessing can be effected by optimization if __OPTIMIZE__ is
used.
--jtc
--
J.T. Conklin
RedBack Networks