Closed oubiwann closed 5 years ago
hey, thanks for this. i think we need to discuss collectively whether a repl should be included or if this set of components makes more sense in the corresponding LispREPL
package. I don't think we fully resolved this.
i think we need to discuss collectively whether a repl should be included or if this set of components makes more sense in the corresponding LispREPL package. I don't think we fully resolved this.
Personally, I don't really see why one wouldn't want it to be included but of course this is your repo so its your call.
I actually did start this change with the REPL code as its own package, but then I second-guessed myself, thinking I was over complicating it and that the PR would be 👎 'ed ;-)
(Because, based on other Lisps like Clojure, the next step was to actually have the LispReader.jl
package ... even though it would be tiny; readers are typically useful in more than just the REPL context.)
Then, as I was thinking about pulling it into the LispSyntax.jl
, I thought about how this package is really more than just syntax, the project seems like it might be growing beyond the name ... and in that sense, it felt right just being here ...
Now you've had a peek inside me brains!
Btw: no strong opinion here! Totally cool with any direction.
Alternatively, if we want to keep the scope of this repository small, things like #29 and #28 (if I ever get around to them) and this PR could all go in separate packages and then there can just be a frontend package that pulls them all into one namespace and exports it.
Regarding the parser side of things, there's been some discussion of having a SExpressions parser as a stdlib to support testing of the julia compiler lowering pass. See https://github.com/JuliaLang/julia/pull/32201 and https://github.com/TotalVerb/SExpressions.jl/issues/3#issuecomment-500648914
Personally I'm somewhat biased toward scheme rather than clojure syntax for quoting etc but I imagine we should be able to support both from the same parser.
Thanks again, @MasonProtter: I've pushed the changes you suggested.
Given all of the comments, it might be better to refactor the s-expression parser at some point. For now, I'm going to merge this. Eventually moving out some of the functionality into submodules as Mason suggests would be good.
I've tweaked the REPL support to include some sane defaults. Added custom REPL tweaking to its own Markdown file in the
docs
dir.