The #INFO compiler command causes the compiler to report or suppress conditions encountered by the compiler that may require attention.
The PSL compiler distinguishes three levels of messages: information, warning, and error. Error messages are always reported by the compiler, but the reporting of warning messages and informational messages is controlled by the environment, the process, or the source unit.
Every message is linked to a group. The #INFO compiler command can be used to show or suppress all warning messages and information messages for a particular group.
Refer to the Troubleshooting Compiler Warnings section for details on each of the compiler warnings.
The compiler warnings and informational messages do not impact the generated code. However, you should use them to check or modify the source code appropriately. Do not use this compiler command unless there is an explicit need to override the environment default.
Syntax
#INFO grouplist ON|OFF
Parameters
grouplist |
One or more groups of messages to show (ON) or suppress (OFF) from the following list:
Recommended settings: - Development environments for Version 6.4 and lower: OFF - Development environments for Version 7.0 and higher: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for Version 6.4 and lower: OFF - Development environments for Version 7.0 and higher: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: OFF - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: OFF - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for Version 6.4 and lower: OFF - Development environments for Version 7.0 and higher: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF
Recommended settings: - Development environments for all versions: ON - Production environments for all versions: OFF |
ON|OFF |
An indication of whether the compiler should show (ON) or suppress (OFF) messages from the selected groups. The default is ON. |
When Became Available
Profile v7.0
Example
#INFO // Test of scope warnings. Do not use this in your code.
new abc // Local Scope
type Number n // Local scope
set zzz=n // zzz not declared...
quit
This produces the following warnings when compiled:
%PSL-W-SCOPE: Unscoped variable: zzz
At source code line: 7 in subroutine:
%PSL-W-SCOPE: Undefined variable: n
At source code line: 7 in subroutine:
%PSL-W-SCOPE: Unreferenced variable: abc
At source code line: 8 in subroutine: