libera/#commonlisp - IRC Chatlog
Search
17:07:05
enzuru
random-nick: good call, seems like Stallman brought them into GNU in 92 but their last stable release is 10
17:07:53
enzuru
jjnkn: best REPL experience is going to be SLIME or SLY, SLY is the newer of the two approaches
17:07:54
beach
jjnkn: You really should get something more than just readline. Like I said, most people recommend SLIME or SLY.
17:08:39
enzuru
I also recommend Lispy. It allows modal editing on parens. For instance, I can just hit "e" to eval the s-expression I am on: https://github.com/abo-abo/lispy
17:09:13
edgar-rft
jjnkn: from the shell I use rlwrap(1) like `rlwrap sbcl' but usually I'm using Emacs+Slime+SBCL
17:09:27
enzuru
Lispy is powered under the hood of course by the various Lisp IDEs (SLY/SLIME for Common Lisp, Geiser for Scheme, CIDER for Clojure, etc)
17:12:13
jjnkn
enzuru: i tried evil-mode in the past but I hadn't been programming Lisp then, so maybe will give it another shot
17:13:11
enzuru
also... i hear great things about Spacemacs from Vim converts as well, and it is "batteries included" unlike vanilla Emacs
17:13:53
enzuru
i use vanilla Emacs and do modal editing with Lispy instead of evil-mode, so i can't speak too personally about the vim-like approaches to Emacs
17:14:30
enzuru
Spacemacs comes with a "layer" for Common Lisp dev too: https://github.com/abo-abo/lispy
17:15:07
jjnkn
i find myself quite comfortable with NeoVim as it integrates nicely with Lua, which allows me to use Fennel for writing plugins
17:16:07
enzuru
Neat! Well, not trying to convert you necessarily, just letting you know your options. FYI, once you learn Common Lisp, Emacs Lisp becomes a breeze because it has imported about half the symbols in Common Lisp via the built-in cl-lib library
17:18:20
enzuru
If you like writing extensions in Lisp, and want vim keybindings, Emacs/Spacemacs/etc has top notch support for both. But stick with Neovim and Vlime if that's just the right thing for you.
17:20:40
jjnkn
well, you're slowly converting me to Emacs! i will definitely give evil-mode another shot, and rewriting some of my plugins in Emacs Lisp should be fun
17:22:39
jjnkn
i recall watching some StrangeLoop conference where the speaker was using Emacs for demonstrating code while performing some Emacs wizardry
17:24:39
enzuru
Emacs is quite addictive, because it becomes one of the easiest ways to experience the joy of interactive programming inside a running Lisp image. You evaluate bits of Lisp here and there and see your "editor" transform before your very eyes.
17:26:05
enzuru
StumpWM is also like that, I use that as my window manager on Linux. (Used to actually use Emacs for window management in the form of exwm: https://github.com/ch11ng/exwm )
17:27:45
beach
Emacs might be the best we have for Common Lisp programming (except perhaps what the commercial Common Lisp vendors propose), but it has a lot of shortcomings as well.
17:29:39
beach
Indentation is approximate. Syntax highlighting does not take symbol roles into account. I would like to see many more features that depend on analyses that Emacs can't do, like highlighting all occurrences of a particular lexical variable.
17:31:37
enzuru
i also dislike the default Emacs syntax highlighting. i prefer rainbow-blocks or prism, which highlight Lisp code based on its depth instead (which makes sense for a language with hardly any syntax): https://github.com/alphapapa/prism.el
17:50:45
jjnkn
there is a cool syntax-parsing project called tree-sitter, which has a solid integration with NeoVim
17:51:20
jjnkn
what's cool about it is that it provides syntax highlighting facilities that are based on the underlying language's structure, as opposed to primivite methods like relying on regex patterns
17:53:04
jjnkn
beach: why not? tree-sitter lets you define grammars in JavaScript that compile to parsers in C
17:53:38
beach
jjnkn: But Common Lisp does not have a fixed grammar because of macros and (even "worse") reader macros.
17:56:34
jjnkn
i see; actually, that's what has been irking me when i was creating all these grammar rules
17:57:00
beach
That's why I said: "But you can't really parse Common Lisp with anything other than READ."
17:57:10
jjnkn
for example, i had a rule for highlighting lambda lists, but it was limited only to the forms defined in the standard
17:59:03
jjnkn
btw, there is an integration of tree-sitter for Emacs too: https://emacs-tree-sitter.github.io/
17:59:53
beach
That's a bit different though. It is an example of extensions allowed by the standard. What I am saying is that you can't even parse standard Common Lisp program with a fixed grammar.
18:00:59
jjnkn
of course, i get your point; a real Common Lisp parses would need to have access to the environment of a running program
18:06:38
beach
That part we already do. But now I am working on analyses that require the first pass of a compiler too, like highlighting all occurrences of a particular lexical variable.
18:12:52
beach
Yes, it is public. But it's work in progress: https://github.com/robert-strandh/Second-Climacs
18:14:23
beach
Also, we are extracting lots of stuff to separate repositories, and I haven't really documented where those repositories can be found. It should be obvious after some search.
18:15:16
beach
Like the code corresponding to the paper is here: https://github.com/robert-strandh/Incrementalist