Hi Laurent, thanks a lot for the feedback!
> On 25.4.17, you simplified 'body' and 'attr' in lib/xm.l. Indeed. > The changes are not compatible with the xml files from gnumeric : I'm not sure. I think the problem is that the exact behavior of these two functions is not documented. Let me first demonstrate how they are intended to be used. We use this XML result: : (setq X '(a ((x . 1) (y . 2)) (b ((z . 3)) abc) (c NIL (d NIL def)) ) ) Which is as XML : (xml X) <a x="1" y="2"> <b z="3">abc</b> <c> <d>def</d> </c> </a> Now the 'body' function gives : (body X 'b) -> (abc) : (body X 'c 'd) -> (def) These results are identical for both the old and the new version. Accessing the top level body with tag 'a' is not possible in both versions : (body X 'a) -> NIL but I think this is all right because it is known anyway. Your example > : (car Cells-References) > -> (gnm:Cell ((Row . "0") (Col . "0") (ValueType . "60")) "Ticker") cannot be a proper XML result, because we have never a list like (gnm:Cell ...) in the CAR. So I believe that 'body' is OK in the new version. HOWEVER: 'attr' seems indeed to be wrong in the new version. The old version correctly gives: : (attr X 'x) -> 1 : (attr X 'y) -> 2 : (attr X 'b 'z) -> 3 but the new version returns NIL in all cases. I did not notice this. Sorry! I released a new PicoLisp, now with (de attr (Lst Key . @) (while (args) (setq Lst (asoq Key Lst) Key (next)) ) (get Lst 2 Key) ) I believe this is correct. Thank you very much that you found this bug! ☺/ A!ex -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe