Anything like #pragma warn "my message" in GCC?

Eljay Love-Jensen eljay@adobe.com
Fri Jun 18 16:34:00 GMT 2004


For GCC (at least, GCC 3.3.1):

#warning "This is a warning"

#error "This is an error"

I'm not 100% sure, but I think #warning is an extension.  And #error is in 
the standard.

For an "info" you may want to use this convention:

#warning "INFO: this is informative"

HTH,
--Eljay



More information about the Gcc-help mailing list