[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: alternative to repeatedly walking the ancestor axi

Subject: RE: alternative to repeatedly walking the ancestor axis in 1.0
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Sat, 2 Aug 2008 09:33:15 +0100
RE:  alternative to repeatedly walking the ancestor axi
> Out of interest, does xml:lang annotate the input tree, or does the
> lang() function walk the ancestor axis behind the scenes?  Or 
> is it all implementation dependent?

It's implementation-dependent, of course.

Saxon walks the ancestor axis when you use the lang() function. I think it's
used too rarely to be worth optimizing.

You also asked:

>why does xml:lang exist

And I think the answer is that the I18N lobby is sufficiently powerful in
W3C that they overrode the architectural arguments for putting this kind of
thing in a different layer; XML should be completely neutral as to the
meaning of element and attribute names, and such things should be defined
only in application-specific vocabularies. 

(But it's true, of course, that xml:lang is permitted only where the DTD
says it is permitted, so in that sense it's not part of core XML, it's just
available for inclusion in an application vocabulary if you choose to
include it.)

Michael Kay
http://www.saxonica.com/

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2007 All Rights Reserved.