Hi Andrew, > The cast expression of 3.12.3 and the constructor function of 3.12.5 > seem to be essentially duplicating the same functionality. > > It isn't immediately obvious to me why such duplication should be > necessary or appropriate, particularly since the cast expression > seems sometimes/always simply to add the words "cast as" before what > would otherwise be a constructor function. > > Is there a compelling reason for the continuing existence of this > seeming duplication? Or am I missing something obvious? We have to have the full "cast as" form because otherwise it wouldn't be possible for someone to create a value of a type in no namespace whose name clashed with one of the built in functions or node tests, such as "data" or "node". The short forms, on the other hand, are a lot more convenient for the common cases. Cheers, Jeni --- Jeni Tennison http://www.jenitennison.com/Received on Tuesday, 4 March 2003 11:07:49 GMT
This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:13:58 GMT