[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: gnubol: IBM flags nested conditionals as error (RC=8) but recovers OK



In a message dated 12/6/99 8:34:17 PM EST, mck@tivoli.mv.com writes:

<< 
 I think we're close enough.  I'm tired of it.  Generating code or not
 is just a matter of assigning a severity level, so let's decide that
 when we have a code generator.
 
 Mike
  >>

That idea is worth amplifying.  If you go back to the mainframe example you 
can see an error message that starts with some letters then some numbers.  It 
is followed by a dash-E. For example, something like 

    IGYAA2012-E an implied mystery was assumed, hope you like it, Line # nn.

That -E is distinct from the error number (which is just something like 
2012). We can build 
a system where the only thing syntax know is the detected situation is a 
diagnostic #2012 that has to be handed to the error processor. When the error 
processor looks it up, it not only discovers the text, it also finds the -E. 
Both syntax and semantics can respond to the -E, if needed.

The -E can be for Error, we could have a -W for Warning, S for show-stopper. 
The matter can actually be determined by what diagnostic database is attached 
to the compile, if we choose to design that way.  For the extension 
contemplated, we can address the divergent code base issue by allowing 
different compiler behavior through different error/diagnostic libraries. 
(This works for 'recoverable' situations, not for unrecognizable source code).

I think that keeping this idea open is useful as a first pass at the 
convergence issue. We face a different situation than any vendor who can 
prefer and may have to prefer prior product behaviors.  It may be our lot 
that we should not choose in some cases, but should provide an alternate.

So I would encourage externalizing severity level in many cases, and keeping 
in mind a possibility that skilled users of this tool might want to customize 
that external mechanism. For completeness then let me say that it would be 
possible to distinguish by error number, an implied end to an arithmetic 
conditional, from an implied end to a SEARCH conditional.
One of these might be a -W with code gen, the other an -E. 

Bob Rayhawk

--
This message was sent through the gnu-cobol mailing list.  To remove yourself
from this mailing list, send a message to majordomo@lusars.net with the
words "unsubscribe gnu-cobol" in the message body.  For more information on
the GNU COBOL project, send mail to gnu-cobol-owner@lusars.net.