On 11-03-28 12:11 PM, Florian Weimer wrote:
<!ELEMENT PAGE (TITLE, AUTHOR, ADDLIST*, ADDFOOTER*, SHIP*, (((BODY | LEAD)?, (SECTION | FAQL)*) | (SECTION | FAQL)+), REVISIONS?)>then it will be really difficult to generate a useful type from that. Even for an ML-like language, the lack of at type name for thinks like BODY | LEAD makes that difficult. There is even more nastiness, such as non-determinist content models, but the naming problem is the first obstacle.
You probably want cduce (http://www.cduce.org), which is .. pretty much unrelated to our type system :)
But this is getting off-topic. (Coincidentally, I'm looking for a schema language which maps nicely to the common core of most static type systems, that's why I asked.)
Every real type system has strange corner cases; I doubt you'll find much short of a proof assistant's logics. But yes, this is way off topic. All we need for linkage is a way to read, write and seek around in some simple / compact tree format; an additional meta-layer of static types for constraining this format is not required. We're the only producer or consumer, and we only produce or consume one kind of thing. Dynamic probing for the stuff we expect with pleasant error messages on failure is just fine.
-Graydon _______________________________________________ Rust-dev mailing list [email protected] https://mail.mozilla.org/listinfo/rust-dev
