If you forget to declare a variable in PL/I, by default it will be created anyway. This is a very annoying habit. Sometimes you discover it quite fast, because the variable is used as a numeric variable, but declared as a character variable or vice versa. Sometimes you do not notice anything because you use the variable in the same context as it is declared.
I have always hated these implicit declarations, especially because they are only reported as informative messages not even as a warning. Fortunately the users of PL/I finally has been able to convince IBM about this discrepancy (or IBM realised the problem themselves). Now you are able to configure PL/I to report lacking declarations as errors just like any other reasonable programming language.
In Enterprise PL/I for z/OS (also known as PL/I version 3) IBM has introduced a compiler option called RULES, which you can set up in different ways to make the compiler report or ignore different language rules. Fortunately implicit declarations can be controlled using RULES. You can specify RULES(NOLAXDCL), if you want PL/I to report an error for undeclared variables. After specifying this compiler option the presence of an undeclared variable will result in a return code of 8 from the compiler. Remember you can active this compiler option by using *PROCESS RULES(NOLAXDCL); in the program source.