ISO 10303-14: issues resolution - another grammar issue?
Jochen Haenisch
Jochen.Haenisch at epmtech.jotne.com
Wed Nov 13 06:38:11 EST 2002
Dear P14 ballot comment resolvers,
there seems to be an error in the grammar of P14 that is not reported,
yet!?!
Summarized, the problem is that the current P14 grammar can interpret the
following:
==> a := FOR EACH x in Agg1 RETURN x.att + y
as either
==> a := (FOR EACH x in Agg1 RETURN x.att) + y
or
==> a := FOR EACH x in Agg1 RETURN (x.att + y)
What indicates the end of the return expression?
To resolve the conflict the grammar probably needs to be changed, e.g. in
the following way:
original:
81 foreach_expr = EACH var_id IN expression [where_clause]
RETURN expression.
82 forloop_expr = repeat_control RETURN expression .
85 for_expr = FOR (foreach_expr | forloop_expr ) .
corrected variant:
81 foreach_expr = EACH var_id IN expression [where_clause]
RETURN '('expression ')' .
82 forloop_expr = repeat_control RETURN '(' expression ')' .
85 for_expr = FOR (foreach_expr | forloop_expr ) .
Do you agree?
Best regards, Jochen.
____________________________________________________________
Jochen Haenisch E-mail: Jochen.Haenisch at epmtech.jotne.com
EPM Technology AS Home of the EXPRESS Data Manager
P.O Box 6629 Etterstad Tel: Int + 47 23 17 17 26; mobile: Int + 47
922 60 274
N-0607 Oslo Fax: Int + 47 23 17 17 01
Norway Web: http://www.epmtech.jotne.com
More information about the wg11
mailing list