[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gnubol: refmod again
"The subscript can be represented either by an integer, a data-name which
references an integer numeric elementary item, or an index-name associated with
the table. A data-name or index-name may be followed by either the operator +
or the operator - and an integer, which is used as an increment or decrement,
respectively. It is permissible to mix integers, data-names, and index-names."
See page V-38 of the standard also.
So basically it is
a [+|- n]
OR
n
This matches "foo + 0" but no more.
But "+ 1" does not match this. "+1" would. By the way more general expressions
are allowed as function call parameters. So you get treasures such as
function max (a (b) )
Is this two parameters "a" and "(b)" or one "a (b)". Does the ambiguity matter if
a is an array or not?
Tim Josling
Randall Bart wrote:
> > (foo + 0 + 1)
>
> That looks like one subscript to me. What am I missing?
>
--
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.