Alan Manuel Gloria: > Whoa whoa whoa - there seems to be problems with SUBLIST and SPLICE!
Are you suggesting there could be a... bug?!? Why, that could never happen :-). It appears that SUBLIST is the problem child here. In "unsweeten", using just SUBLIST, we have (as expected): amkg animals $ 1 0 ==> (amkg animals (1 0)) In the draft BNF, we have the unexpected: amkg animals $ 1 0 ==> ((amkg animals) (1 0)) If one pair of parens is good, I guess two is better :-). This was made worse because my test suite "correct" answers had the wrong results. My bad, sorry. Clearly the SUBLIST action is busted. I believe this fixes it: | SUBLIST hspace* i_expr1=i_expr - {$v=list(monify($head.v), $i_expr1.v);} + {$v=append($head.v, list(monify($i_expr1.v)));} I've posted the grammar with that change. Okay, let's try again. I took this: <* library \\ amkg animals $ 1 0 export cat rename $ rover dog import only amkg pets $ 1 0 rover define cat 'meow *> The draft BNF now generates: (library (amkg animals (1 0)) (export cat (rename (rover dog))) (import (only (amkg pets (1 0)) rover)) (define cat (quote meow))) Which can be reformatted as: (library (amkg animals (1 0)) (export cat (rename (rover dog))) (import (only (amkg pets (1 0)) rover)) (define cat (quote meow))) Is that what you expected? --- David A. Wheeler ------------------------------------------------------------------------------ Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS, MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft MVPs and experts. ON SALE this month only -- learn more at: http://p.sf.net/sfu/learnmore_122712 _______________________________________________ Readable-discuss mailing list Readable-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/readable-discuss