Hi Tomas, many thanks!
I did some minor changes, and attach a new version of "lib/xml.l" to this mail. 1. There was a slight error (still '_xml2' instead of '_xml') 2. I replaced occurrences like (ifn (= '`(chop "DOCTYPE") (list (char) (char) (char) (char) (char) (char) (char))) with (if (find '((C) (<> C (char))) '`(chop "DOCTYPE")) to avoid the excessive 'list'ing. 3. The case "??? echo to string?" is a bit cumbersome. There is in fact no proper equivalent of the 'echo' functionality in e.g. 'from'. Using 'pipe' is quite elegant and short, but I'm hesitating to use it is such a context. (pipe (echo "]]>") (till NIL T)) My proposal would be (pack (head -3 (make (until (= '`(chop "]]>") (tail 3 (made))) (link (char)) ) ) ) ) This avoids the overhead of 'pipe', but is longer. Is this OK? BTW, why is the (from "]]>") ) ) ) in the following line needed? > 00000000: 3c64 6f63 3ef0 9080 80f4 8fbf bd3c 2f64 <doc>........</d > 00000010: 6f63 3e oc> The first character after the '>' starts with "F0", which is not a legal UTF-8 sequence. UTF-8 has the following structure ("doc/utf8"): 0000 .. 007F 0xxxxxxx 0080 .. 07FF 110xxxxx 10xxxxxx 0800 .. FFFF 1110xxxx 10xxxxxx 10xxxxxx The pattern 11110000 is this not possible for any (not just the first) UTF-8 character. Cheers, - Alex -- UNSUBSCRIBE: mailto:[EMAIL PROTECTED]