Re: [xsl] question about identity transform

Subject: Re: [xsl] question about identity transform
From: "Evan Lenz" <evan@xxxxxxxxxxxx>
Date: Thu, 2 Nov 2006 10:52:37 -0800 (PST)
Thanks to Michael and David both for your excellent replies pinpointing
why this distinction matters for users: side effects and reliance thereon.

I'm afraid I have the opposite problem compared to all the imperative
programmers demanding to know why XSLT doesn't allow assignment
statements. I cut my programming teeth on XSLT Programmer's Reference. I'm
so firmly entrenched in declarative programming (and avoidance of any
extensions that cause side effects) that I sometimes forget that, in the
larger programming world, side effects are the way you do programming.

Wendell, I'm afraid it's not so much that my pragmatic concern for users
makes me want to protect them from learning things they could get by
without. Rather, because of my well-insulated experience in the world of
declarative programming, I forget that we even need to make this
distinction in the first place.

For a declarative programmer, time is just a metaphor! (Of course
xsl:message might output in a different order than result order--that's
the implementor's business, not mine!) If you pretend that imperative
programming doesn't exist, then you can freely use time as a metaphor
without introducing the possibility for confusion. Until you can truly
escape from the grips of the imperative mindset, then, yes, I see that
time, "processing order", etc. are dangerous metaphors.


Current Thread