I am usng AIX xlc and attempting to use the -qhaltonmsg=... switch to make certain detected messages fatal. It's not working and I can't figure out why. Here is a sample program:
int main()
{
foo();
}
Here is an invocation that does not go as expected:
> xlc test.c -c -qinfo=pro -qhaltonmsg=1506-304; echo $?
"test.c", line 3.9: 1506-304 (I) No function prototype given for "foo".
0
The -qinfo=pro switch enables the "No function prototype" message, that much works. The -qhaltonmsg=1506-304 switch is supposed to elevate the given message to (S) severe, and stop compilation with a nonzero exit code. That does not appear to happen. Why not?
I am using AIX 7.1, if that matters.