From: Robert D. <rob...@gm...> - 2024-02-17 21:25:26
|
I'm continuing to work on the lexical symbols implementation, on the branch lexical-symbols-take-3 in the Git repo. The stuff I've done so far is described by: https://sourceforge.net/p/maxima/code/ci/lexical-symbols-take-3/tree/README-lexical-symbols.md The implementation covers lexical symbols for local variables in functions, block, and for loops; it doesn't include lexical closures. I have a separate proof of concept for closures which I have not tried to merge into Maxima, although I am going to try that at some point. At this point, run_testsuite() reports no unexpected errors and run_testsuite(share_tests = only) reports unexpected errors in two packages, simplify_sum and pytranslate. More about that in the PS. The lexical symbols implementation is stable enough at this point that I think it is meaningful to talk about how it would be rolled out in Maxima. I am thinking that lexical symbols is enough of a difference in the way things work that the major version number should be bumped from 5 to 6, so that Maxima 6.nnn has lexical symbols while Maxima 5.nnn doesn't. Assuming this lexical symbol stuff actually gets off the ground, I don't know whether we or anyone would want to continue Maxima 5.nnn releases, although it doesn't seem out of the question. I'd like to ask interested parties to take a look at the branch lexical-symbols-take-3 (which may be superseded by take-4 at some point). Any comments or questions are welcome. best Robert PS. pytranslate needs to be rewritten because it was designed to accurately reproduce dynamic binding in the translated Python code. The good news is that assuming lexical binding will make translated code much more like it would be written by hand. I'm not sure what the problem in simplify_sum is, but I'll continue to look at it. |