[Bug 19267] New: [XQ3.0] Context item declared in multiple modules


           Summary: [XQ3.0] Context item declared in multiple modules
           Product: XPath / XQuery / XSLT
           Version: Last Call drafts
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XQuery 3.0
        AssignedTo: jonathan.robie@gmail.com
        ReportedBy: mike@saxonica.com
         QAContact: public-qt-comments@w3.org

It is permitted for context item declarations to appear in more than one

The declaration in a library module is not allowed to set an initial value for
the context item. A declaration that does not set an initial value must, by the
nature of the syntax, specify "external".

The semantics of "external" require the value to be supplied "by the external
environment". However, the main module might contain an initializer for the
context item, in which case it makes sense to use the value from that
initializer, rather than reporting an error because the value was not supplied

(Perhaps it was intended that the "external environment" of a library module
includes the main module - if so, it should say so.)

The simplest fix is to change the semantics of "external" to permit the value
to be supplied as a result of evaluating the initializer contained in the main
module. A bolder fix would be to change the grammar so that in a library
module, neither "external" nor an initial value may be specified (only a type,
which is why the declaration exists in a library module).

Configure bugmail: https://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

Received on Wednesday, 3 October 2012 22:57:41 UTC