[oma-loty] XSLT complexity

  • From: Dave Burchell <burchell@xxxxxxxxxxxxx>
  • To: oma-loty@xxxxxxxxxxxxx
  • Date: Wed, 15 Jan 2003 14:35:15 -0600 (CST)

Mike pointed out how un-pretty the knight's tour is in XSLT.  I agree;
I didn't look at it closely, but it did look ugly.

However, I think there is a crucial difference between XSLT 1.0 and
LISP, Scheme, Haskell, and the other FP "usual suspects".

In most FP langs, I can define a function to return a value.  In XSLT
1.0, I can't do that; I can only add nodes to the output tree of XML or
not.  This complicates things quite a bit, because I need to keep
calling templates (functions) until I reach a condition in which one of
them outputs a result and/or calls no more functions.  With other FP
langs I can check the return value of a call to a function, and do or
don't do something from there based on the result.

XSLT 1.1 fixes this problem, as I understand it.

But perhaps my understanding is flawed here.  Can I somehow use a
variable in XSLT 1.0 to return a value from a template?  How would that
work?

-- 
Dave Burchell                                          40.49'N, 96.41'W
Free your mind and your software will follow.              402-467-1619
http://incolor.inetnebr.com/burchell/                  burchell@xxxxxxx     

Other related posts:

  • » [oma-loty] XSLT complexity