Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

TorgoX (1933)


"Il est beau comme la retractilité des serres des oiseaux rapaces [...] et surtout, comme la rencontre fortuite sur une table de dissection d'une machine à coudre et d'un parapluie !" -- Lautréamont

Journal of TorgoX (1933)

Sunday March 19, 2006
01:56 PM

XSLT funk

[ #29044 ]

Dear Log,

Man oh man, XSLT is a mess of a language.

  • It started out in a totally muddled Chang/Eng relationship with XSLFO (which, to my mind, bears no more of an essential relationship to XSLT than Perl does to RTF).
  • Its first big implementation was by Microsoft, which was of course a complete wreck.
  • Design-wise, XSLT seems to have painted itself into so many corners that it may thus have inadvertently proven that spacetime really does have eleven dimensions.
  • It is blessed/cursed by numerous vendor-specific extensions.
  • It is caught between incredible tidal forces that on the one hand want to "keep it simple" (so, variable use is crazily limited, almost stifled; there's no proper looping constructs in the core language) and on the other hand want it to be useful (templates/functions can be recursive!).
  • It may actually be the most visually unpleasant and verbose language ever.
  • Its rule-based system is really hard to be completely comfortable with.
  • There's no particularly good answer to the question "why use XSLT instead of Perl (or any other language)?", other than that it's built into Firefox and MSIE (although so is JavaScript).
  • I imagine that many applications embed it instead of JavaScript or Lisp, for the reason that "well, XSL is not a whole language like those others are"-- an argument whose speciousness tarnishes everything it touches.

And yet, XSL is just barely useful enough that it won't go away any time soon. And like MSDOS .bat language, it's not awful at big dumb rudimntary tasks.

And it's in that very odd class of things where you have to admit "if we had it to design over again, it wouldn't look anything like it does now; but since we're already this far into it, I guess we might as well stick with it, ah well".

And on the one hand, XSL replaced something (DSSSL) that was a thousand times more bizarre; but on the other, it's impossible to look at XSL and have the word "progress" come to mind. Folks, the 8KB ROM BASICs from thirty years ago were better than this.

And yet, and yet... And yet, here it is, a testament to our inability to agree on anything better.

XSL always reminds me of that quote of Hunter S. Thompson's: "There he goes. One of God's own prototypes. Some kind of high powered mutant never even considered for mass production. Too weird to live, and too rare to die."