[Bug 4443] [XQuery] Unspecified how unprefixed attributes with namespace URIs are to be treated

http://www.w3.org/Bugs/Public/show_bug.cgi?id=4443


Tim Mills <tim@cbcl.co.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |tim@cbcl.co.uk




--- Comment #7 from Tim Mills <tim@cbcl.co.uk>  2008-06-24 15:03:19 ---
I may be wrong here, but I believe that the changes suggested in Comment 2 is
unnecessary.

The query:

<e>
        {
                attribute {QName("http://example.com/", "attr")} {()}
        }
</e>

will introduce a new namespace prefix, not when the attribute is created, but
rather when it is copied, as a result of the rules given in XQuery 3.7.4
In-scope Namespaces of a Constructed Element.

i.e. I expect the result of

<element>
{
  let $name := QName("http://example.com/", "attr"),
      $attr := attribute {$name} {()} return
    ( $attr, text { prefix-from-QName(node-name($attr)) } )
}
</element>

to be of the form

<element xmlns:generated-prefix="http://example.com/" 
         generated-prefix:attr=""/ >

and not

<element xmlns:generated-prefix="http://example.com/" 
         generated-prefix:attr="">generated-prefix</element>

I've given more details in Bug 5723 and how it relates to Bug 4463      
([XQuery] Missing rules for misuse of the xmlns namespace).


-- 
Configure bugmail: http://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 Tuesday, 24 June 2008 15:03:54 UTC