syntaxonly (C Only)

Option Type Default Value #pragma options C C++
-qoption - - x  

Syntax

    -qSYNTAXonly

Purpose
Causes the compiler to perform syntax checking without generating an object file..

Notes
The -P, -E, and -C options override the -qsyntaxonly option, which in turn overrides the -c and -o options.

The -qsyntaxonly option suppresses only the generation of an object file. All other files (listings, precompiled header files, etc) are still produced if their corresponding options are set.

Example
To check the syntax of myprogram.c without generating an object file, enter:

xlC myprogram.c -qsyntaxonly

or

xlC myprogram.c -o testing -qsyntaxonly

Note that in the second example, the -qsyntaxonly option overrides the -o option so no object file is produced.



List of Batch Compiler Options and Their Defaults
Options that Specify Debugging Features
Equivalent Batch Compile-Link and Incremental Build Options