[plt-scheme] Unifying xexpr, SXML, and SHTML

From: Neil Van Dyke (neil at neilvandyke.org)
Date: Tue Mar 10 08:44:58 EDT 2009

Matthias Felleisen wrote at 03/10/2009 08:13 AM:
>
> 1. Consider using Typed Scheme to formulate the type of XEXPRs you 
> want to use.

Typed Scheme does have its appeal for this -- for checking in terms of 
XML metamodel types (e.g., "element", "cdata"), and, more interestingly, 
in terms of XML DTD or XSL model types (e.g., "movie", "title", "director").

I have been thinking of only making small changes to unify "xexpr" and 
SXML, and therefore keeping a sexp-based representation.

If you are suggesting formulating the types for a sexp-based 
representation using Typed Scheme, is Typed Scheme's current 
implementation smart enough to avoid lots of redundant type divining of 
deep sexp trees?  For example, if a large "xexpr" tree is built up 
incrementally from, say, a hundred thousand sexps, nested in various 
ways, are there situations in which there will there be lots of 
redundant traversals of deep subtrees to re-divine the types?

(Pardon if this is a stupid question, as I've not yet used Typed Scheme.)

Thanks,
Neil



Posted on the users mailing list.