Re: [XQuery] Computed CDATA constructor

At 05:01 PM 11/10/2003, Sarah Wilkin wrote:

>It seems for every direct constructor there is a computed constructor -- 
>except for CDATA sections. Since the WG has allowed CDATA direct 
>constructors at all, there should be full support including computed 
>constructors. I can understand if the CDATA sections were only to ease 
>creating/viewing files that would otherwise require many entities, but 
>since they also may be serialized by implementors it is limiting to not to 
>have this functionality.
>
>Proposed rule:
>CompCdataConstructor ::= "cdata" "{" Expr? "}"

Hi Sarah,

What is it that you would like to do with such a computed constructor that 
you can't do without it? Can you think of any scenarios where the following 
two expressions could have different results?

1. <foo>{ cdata{ $a } }</foo>
2. <foo>{ $a }</foo>

For literal CDATA sections, it is useful to have direct support just so 
people can cut and paste from XML into XQuery.

Jonathan 

Received on Monday, 10 November 2003 17:17:55 UTC