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 1928 - [XQuery] Recursive imports and fowards references
Summary: [XQuery] Recursive imports and fowards references
Status: CLOSED WONTFIX
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: XQuery 1.0 (show other bugs)
Version: Last Call drafts
Hardware: PC Windows XP
: 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-08-31 21:41 UTC by Michael Kay
Modified: 2005-09-30 08:59 UTC (History)
0 users

See Also:


Attachments

Description Michael Kay 2005-08-31 21:41:14 UTC
Transferred at the request of the WG from 1848:

It would be useful to clarify whether a module that imports
its own namespace is allowed to contain forwards references to its own global
variables. You can read the spec either way on this: on the one hand it says
forwards references to global variables aren't allowed; on the other hand it
says you can access all the global variables declared in a namespace that you've
imported.

It's a little odd if it isn't allowed: if cyclic references to variables are
allowed across modules, why not allow them within a module? It's also difficult
to explain (and implement!) that a module has access to all the global variables
in an imported namespace except those that are declared in the same module and
after the variable reference.

Proposal: if a module imports its own namespace, then all variables in that
namespace are in scope throughout the module, including within the entire module
where the variable is declared.

Michael Kay
Comment 1 Don Chamberlin 2005-09-29 08:59:55 UTC
On Sept. 28, 2005, the Query Working Group decided that a forward reference in 
a variable initializing expression will remain an error, even in modules that 
import their own target namespace. This is because a module import that 
references a namespace is interpreted as importing an implementation-defined 
set of modules OTHER than the module containing the import. 

If you are satisfied with this resolution, please respond by closing this 
Bugzilla entry.

Regards,
Don Chamberlin
Comment 2 Liam R E Quin 2005-09-30 08:59:54 UTC
[Mike indicated during the meeting he was OK, and I am closing this issue.
He was also present when we voted to request CR, and did not object.

 Liam
]