Question

I know MSVC can do this via a pragma message -> http://support.microsoft.com/kb/155196
Does gcc have a way to print user created warnings or messages? (I couldn't find a solution with google :( )

Was it helpful?

Solution

#warning "This will only hurt a little bit."
#error "Or maybe a lot!"
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top