Re: [xsl] Things that make you go Hmmmm!

Subject: Re: [xsl] Things that make you go Hmmmm!
From: Graydon <graydon@xxxxxxxxx>
Date: Sat, 29 Mar 2014 15:17:30 -0400
On Sat, Mar 29, 2014 at 05:56:47PM +0000, Alex Muir scripsit:
> text() deserve this rename treatment.

Urm... no.  Not unless we can get text nodes renamed in XML.  It really
is a text node.

{} is attribute value templates
() is functions or node-tests
[] is indexes of sequences
:: is an axis
: separates namespace from local name

so not obvious where some other syntax for node-tests could be found;
(text) looks odd, text% looks like a mistake, %text% looks like a
serious mistake.

> copy-all and copy-root would be more clear. copy-shallow sounds like
> it could be in between the 2 maybe.


Thing is, despite copy-of being the usual source of confusion, copy is
the complicated one; copy of an attribute or a processing instruction or
a comment returns the whole node.  It's only with element nodes that you
get "a new node with the same name as the context node", and I don't
think "copy-name-if-element-otherwise-node" is an improvement.

-- Graydon

Current Thread