openvms

How to silence the OpenVMS Fortan compiler error messages?


I am using OpenVMS V9.2.2. At the DCL prompt, I define the logical SYS$ERROR to the null device, NL: then I invoke the Fortran compiler. The error messages are displayed on the terminal.

SYS$ERROR set to NL:

How I silence the OpenVMS Fortan compiler error messages?

See also, VMS Wiki - SYS$ERROR


Solution

  • Per @k314159 comment.

    $ define/user_mode sys$error nl:
    $ define/user_mode sys$output nl:
    $ fortran x.for
    $ fortran x.for
    %F90-E-ERROR, Illegal character in statement label field  [/]
    %F90-E-ERROR, Illegal character in statement label field  [*]
    %F90-E-ERROR, Illegal character in statement label field  [-]
    %F90-E-ERROR, Illegal character in statement label field  [H]
    %F90-E-ERROR, Illegal character in statement label field  [H]
    %F90-E-ERROR, Illegal character in statement label field  [H]
    %F90-E-ERROR, Illegal character in statement label field  [x]
    %F90-E-ERROR, Illegal character in statement label field  [x]
    %F90-E-ERROR, Illegal character in statement label field  [H]
    %F90-E-ERROR, Illegal character in statement label field  [H]
    %F90-E-ERROR, Illegal character in statement label field  [x]
    
    
    ^
    %F90-E-ERROR, Syntax error, found END-OF-FILE when expecting one of: <LABEL> <EN
    D-OF-STATEMENT> ; BLOCK BLOCKDATA PROGRAM TYPE COMPLEX BYTE CHARACTER ...
    at line number 12 in file DISK$V922:[CWHII]X.FOR;4
    

    Additionally, to only apply the logical definitions to the next application invoked, use /USER_MODE.