sci

teodorlu 2022-04-24T13:38:47.616089Z

would it be hard to write a sci interpreter in Emacs Lisp?

teodorlu 2022-04-25T07:07:28.885499Z

Yeah, I think you're right. A large part of sci simply refers to core functions. Not having access to things like tools.analyzer is another good point. https://github.com/babashka/sci/blob/master/src/sci/impl/namespaces.cljc#L838

borkdude 2022-04-25T09:49:55.167609Z

Another issue is that elisp hardly provides any immutable stuff, even strings are mutable I think

👍 1
teodorlu 2022-04-24T13:39:37.470239Z

I guess ... it couldn't work the same way as Clojure/Clojurescript. We don't have a Clojure-to-Emacs-Lisp compiler, as we have for Javascript and JVM.

teodorlu 2022-04-24T13:40:18.316299Z

Specifically, I was wondering about running neil source code directly in Emacs, without shelling out to anything.

lilactown 2022-04-24T15:36:39.798019Z

I think it would be better to embed bb or some other compiled sci

👍 1
phronmophobic 2022-04-24T19:42:12.451509Z

I think the challenge is that sci doesn't provide its own clojure.core library. It uses the clojure.core library provided by the jvm and clojurescript implementations.

phronmophobic 2022-04-24T19:46:18.507149Z

Most of a compiler for transpiling clojure is already available with the clojure.tools.* libraries, but there's still not a target agnostic version of the core data structures and core library (although the cljs core library is pretty close)

👍 1