This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 1369 - [XQuery] some editorial comments on 3.4 Arithmetic Expressions
Summary: [XQuery] some editorial comments on 3.4 Arithmetic Expressions
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XQuery 1.0 (show other bugs)
Version: Last Call drafts
Hardware: All All
: P2 normal
Target Milestone: ---
Assignee: Don Chamberlin
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-05-11 07:15 UTC by Michael Dyck
Modified: 2005-07-01 00:40 UTC (History)
0 users

See Also:


Attachments

Description Michael Dyck 2005-05-11 07:15:15 UTC
3.4 Arithmetic Expressions

"A subtraction operator must be preceded by whitespace if it could otherwise be
interpreted as part of the previous token. For example, a-b will be interpreted
as a name, but a - b and a -b will be interpreted as arithmetic operations."
    Change "operations" to "expressions".

    The phrase "could otherwise" is vague. For instance, consider the query:
        a- b
    There's only one way to derive these characters from Expr (the "a minus b"
    way). That is, there isn't a legal way to interpret the '-' as part of the
    previous token. So one could say that the "could otherwise be interpreted"
    clause does not hold, and conclude that the hyphen needn't be preceded by
    whitespace. This is presumably not what you want, since the first example
    in A.2.2.1 says that
        foo- foo
    is a syntax error.
    It might suffice to tack on something like "See section [blah] for full
    details regarding the use of whitespace." which at least conveys that the
    sentences in question don't give a complete statement.

    Maybe put the sentences in a Note.
Comment 1 Don Chamberlin 2005-07-01 00:39:45 UTC
Michael,
Thanks for your thorough reading and comments. Since you have labeled these 
suggestions as editorial, I have exercised some discretion and applied them 
where I found them helpful.
Regards,
Don Chamberlin