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

Re: Re: Re: Re: Reliance on import precedence consider

Subject: Re: Re: Re: Re: Reliance on import precedence considered dangerous
From: Jeni Tennison <mail@xxxxxxxxxxxxxxxx>
Date: Sun, 18 Feb 2001 08:44:00 +0000
tennison warning
Hi Dimitre,

> This is a big step forward since you now realise that implementing
> xsl:import with the "virtual" attribute will eliminate the problems
> of having the same stylesheet imported twice.
>
> Now you're changing directions and only complain that because of
> higher import precedence an overriding template from C will also
> override an overriding template from B.

It would definitely address that case. I never argued against that.
I'm sorry that I changed tack without warning mid-thread as I realised
there were actually dangers *across the board* with import precedence,
not only in this special case.

> But this is exactly "as expected" -- this is the behaviour by
> design. Nobody can say that this "came as surprise".

I can :) Well, not so much as a surprise because naturally I know the
Rec absolutely by heart, and of course it's completely documented,
very clearly, and if you read the section carefully then you'll know
exactly what's happening. I'm not 'complaining' about that (though,
yes, my previous point about importing the same stylesheet twice is a
special case of this behaviour that I think should be highlighted in a
Note of some kind in that section, as a similar one is in the
xsl:include section).

> Again to parallel this with an OOPL, ambiguity has to be resolved in
> some way, or to be reported as error. The import precedence in XSLT
> serves to resolve ambiguity.

I understand that. I'm only commenting because thinking through the
implications of this, it doesn't resolve the ambiguity in the way that
I would have expected it to. I guess this isn't that surprising - I
probably have a very weird programming intuition.

To me, it would make more sense if a stylesheet imported into another
stylesheet could only be overridden by the templates (etc.) in the
importing stylesheet, not in other imported stylesheets, so that it
mainly retains its original behaviour, wherever it's imported. I think
that would make it easier to create modular stylesheets.

I'd like to see arguments against this so that I can understand the
rationale for the current state of affairs. I think that one of the
reasons might have been implementation ease, but I don't know whether
it's *incredibly* easier to use the list rather than the tree or just
*a little* easier to use the list rather than the tree.

Cheers,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/



 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


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-2013 All Rights Reserved.