- From: Dimitre Novatchev <dnovatchev@yahoo.com>
- Date: Fri, 2 Apr 2004 05:50:04 -0800 (PST)
- To: public-qt-comments@w3.org
> A few days ago I was asked the question as to why XSLT doesn't have an < > xsl:else> element associated with an <xsl:if> element. I didn't have an > explanation that seemed to me to be compelling. > Is there a good reason for the absence of <xsl:else>? Yes and you could have tried to think about it. How would you solve the "dangling else" problem? > > I am not asking if there is a workaround. Such a question would be incorrect. Any "if then else" construct has the dangling else problem. The designers of XSLT took a correct decision, which eliminates this problem. > I can think of a couple in XSLT 1.0 and three in XSLT 2.0. Because you don't understand the real issues -- see above. > > The question is why isn't there an <xsl:else> element available? Because the designers of the language made a correct decision. > > I suppose the implicit possible follow up question, depending on the > weight of the answer to the first question, is why don't we add an > <xsl:else> element to XSLT 2.0? Because the respected designers of the language do not want to create intentional problems in this well-thought and elegant language. > > Andrew Watt Best regards, Dimitre Novatchev. __________________________________ Do you Yahoo!? Yahoo! Small Business $15K Web Design Giveaway http://promotions.yahoo.com/design_giveaway/
Received on Friday, 2 April 2004 08:50:47 UTC