C and C++ compatibility considerations

C provides the #pragma runopts directive for you to specify runtime options in your source code. When #pragma runopts(execops) is in effect (the default), you can pass runtime options from the command line. Runtime options must be followed by a slash (/).

If the main routine is C and #pragma runopts(noexecops) is specified in the source, you cannot enter runtime options on the command line. Language Environment interprets the entire string on the command line including runtime options, if present, as program arguments to the main routine.

For a C++ application, the following values are not allowed for compilation:
  • PLIST(xxx)
  • ENV(xxx)
  • NOEXECOPS
  • NOREDIR
  • NOARGPARSE

You must use z/OS® XL C++ compiler options to achieve the same effect that was achieved using C runtime options.

See z/OS Language Environment Programming Reference for a description of the EXECOPS runtime option.