On Sun, Aug 3, 2008 at 12:01 PM, Gregory Vanuxem <g.vanu...@orange.fr> wrote: > Le dimanche 03 août 2008 à 11:21 -0500, Gabriel Dos Reis a écrit : >> Gregory Vanuxem <g.vanu...@orange.fr> writes: >> >> | Le dimanche 03 août 2008 à 09:56 -0500, Gabriel Dos Reis a écrit : >> | >> | [...] >> | >> | > This is a parsing bug in the old parser/postparser. I ran into it >> | > once but marked it as low priority to fix >> | >> | Ok, thanks for the information. Feel free to fix it shortly :-) >> >> It appears to be a problem only when you have a `nested' one-armed >> if-statement. > > Yes, it seemed to me. I'm filing an issue on MathAction (it's not > OpenAxiom specific). > > Greg >
Greg -- I had a closer look into this and it turns out that, it is not even a parsing bug: It is a preparsing bug! Well, that may sound a bit pedantic, but it has a practical implication. Preparsing is the phase before tokenization and parsing. The purpose of that phase in the old parser is to munge input text, putting parenthesis around things that are in pile, and separating the items with semi-colons, (You may have noticed the compiler sometimes displays severly molested input text in case it thinks you made a syntax error). That phase is improperly putting parenthesis and around things (more precisely, it misses places where it should put parenthesis). I suspect a proper fix for that is to do actual tokenization, but the whole purpose of the preparsing phase is that it is done before tokenization. A proper fix to that problem is probably: Just Throw Away The Old Parser. The interpreter parser has a better logic. -- Gaby ------------------------------------------------------------------------------ SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. The future of the web can't happen without you. Join us at MIX09 to help pave the way to the Next Web now. Learn more and register at http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ _______________________________________________ open-axiom-devel mailing list open-axiom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/open-axiom-devel