-+ (plus sign) (C++ only)
In IBM® XL C/C++ for AIX® 16.1.0 or earlier releases, you could use the -+ option to compile any file as a C++ language file. The -x c++ option, which is supported by IBM Open XL C/C++ for AIX 17.1.2, has an equivalent function that treats input files as C++ source files regardless of their file suffixes.
Note the following differences between new -x c++ and classic
-+ options:
- The -+ option is not sensitive to position on the command line. You can specify the input files and the -+ option in any order on the command line. However, the -x c++ option affects only the files that are specified following the option on the command line, but not those that precede the option.
- The -+ option does not accept files that have the
.a,.o,.so,.S, or.ssuffixes. However, the -x option accepts all such files. For example, if you specify thea.ofile after -x c++ on the command line, the compiler treatsa.oas ac++file, which might result in errors.
Related information
- The "Clang command line argument reference" section in the Clang documentation