Python finally invented #sci! https://peps.python.org/pep-0554/
> Looks like the stdlib might support it: https://docs.python.org/3/library/ast.html > Yeah, there's support for going text->ast and back, plus interpretation of the ast. But writing that ast is such a chore compared to a quoted sexp (I tried)
there is some really brilliant AST code out there though
Both of those kinda blow my mind at their ability to extend Python
Yeah - it's amazing how dynamic Python is when you start digging
One of those uses the AST directly to modify the interpreter live
yeah the kit certainly comes with enough rope to hang yourself haha
😁
I'd say lots of languages deserve a sci! So much simpler to provide a flexible userspace when there's an interpreter isolated from side effects.
Shame they don't have code as data and have to rely on passing strings around :(
Can you pass a Python AST as an argument to a function? Would be a nice alternative to strings alone.
Looks like the stdlib might support it: https://docs.python.org/3/library/ast.html
hehh I'm pretty interested in some nightmare combination of these subinterpreters + sci + libpython-clj and see how much damage we can do there
I bet we can pass a libpython-clj form into a libpython-clj subinterpreter
and just bypass the AST thing altogether