libera/#commonlisp - IRC Chatlog
Search
14:41:51
pjb
define-symbol-macro is more interesting. You can do lexical global variables with them, and all kind of magic, and you can shadow them in a local lexical binding.
14:42:21
pjb
jcowan: until there's a new country, or some country doesn't use it's standard abbreviation.
14:43:10
pjb
jcowan: for example, I noticed that Mongolia doesn't use its iso3166 cod in sports, but another abreviation…
14:43:27
pjb
jcowan: so if you write an application is some domain, you may want to patch this database!
14:43:47
jcowan
Throwing away the image and starting over is always an option for Maclisp descendants.
14:44:39
_death
surely there are machine readable databases of such information that are publicly available and can just be read at runtime
14:48:27
jcowan
But they are typically available as text files (or, Ghu help us, SQL Server databases you can download).
15:59:41
Colleen
Clhs: accessor symbol-value http://www.lispworks.com/documentation/HyperSpec/Body/f_symb_5.htm
16:03:54
beach
That depends on your definition of "correctly". With my definition, you need a code walker.
16:05:02
beach
jmercouris: The standard doesn't cover everything you need, but every implementation obviously has what it takes.
16:05:48
beach
jmercouris: That's why yitzi suggests a "compatibility library" that abstracts out what each implementation does.
16:06:25
yitzi
I do some it myself it here without trivial-cltl2 https://github.com/yitzchak/common-lisp-jupyter/blob/master/src/cl-jupyter/utils.lisp
16:10:09
beach
That's why we plan to use Eclector's capability of producing CSTs (which contain source information).
16:10:31
yitzi
I don't syntax highlighting in common-lisp-jupyter, but I do use eclector for symbol completion and inspection.
16:12:19
beach
My plan was to use Cleavir for that, but it looks like scymtym is going to do some work, and I don't know his plans.
16:13:47
beach
Then if you use a code walker, you may get errors from it with respect to special forms.
16:14:25
beach
And if someone writes cl::hello, you may want to prevent the symbol from being created in the Common Lisp package.
16:15:34
beach
So the plan is to configure Eclector to not intern symbols in the normal host packages, and to have Eclector recover from various reader errors.
16:16:53
beach
Plus, a paper we wrote documents the use of the reader incrementally, so that you don't have to re-read the entire buffer after each keystroke.
16:19:57
beach
jmercouris: I did start using Nyxt today. Not yet exclusively, though. Still learning.
16:21:55
scymtym
here is a prototype with some of the properties beach mentioned (using Eclector for the character-level syntax, not interning anything, code-walking for semantic highlighting): https://techfak.de/~jmoringe/semantic-highlighting-1.png https://techfak.de/~jmoringe/semantic-highlighting-2.png
16:22:26
blihp
beach: are you able to use it from your default setup (I assume lisp/slime)? It was giving me all kinds of problems until I just started a sbcl instance just for it from the command line
16:29:13
scymtym
beach: mostly just the expression syntax library. combined with code to track the current package and other state in a chain of environment objects
16:29:20
Josh_2
beach: https://plaster.tymoon.eu/view/2483#2483 thats the code, taken from aartaka and modified ofcourse, for future reference :P
16:32:48
beach
Solving the problem requires an implementation of the reader algorithm that allows client code to configure what happens when a token is about to be processed. And that's what Eclector is.
16:38:29
beach
jmercouris: You should watch that movie to get an idea of the complexity of the problem. :)
16:46:27
scymtym
beach: thanks. i have a plan at least. i ultimately want to combine the incremental parsing of Second Climacs with the s-expression parsing and environment stuff
17:04:21
jmercouris
beach: nice! That’s cool! Hopefully you won’t cringe too hard when you look at our code :-D
17:24:56
jcowan
I once saw code in which a 100 element array was initialized to 0 with 100 assignment statements. Written by a consultant.
17:35:27
yitzi
Did you ask him where he learned how to do that? I would just die if said he copy-pasted it.
17:50:30
pjb
jcowan: /* (dotimes (i 10) (insert (format "a%d = 0; " i))) */ a0 = 0; a1 = 0; a2 = 0; a3 = 0; a4 = 0; a5 = 0; a6 = 0; a7 = 0; a8 = 0; a9 = 0;
19:05:50
knusbaum
Hi, everyone. I'm playing with implementing a very simple swank server, but I'm having trouble finding good documentation about the various RPC calls.
19:06:10
knusbaum
My current issue is that SLIME seems to call swank:autodoc with a bunch of previous buffer contents including prompts. I'm not sure how to tell emacs that the previous buffer contents should be ignored.
19:07:32
knusbaum
No, Emacs/SLIME is issuing an RPC call I consider "weird", and I assume that's because I'm doing something wrong on the server side.
19:09:54
knusbaum
That could be. From (swank:connection-info) I return :modules ("SWANK-ARGLISTS" "SWANK-REPL" "SWANK-PRESENTATIONS")
19:10:45
phoe
still, regarding all the various rpc calls, I don't know of any good documentation that isn't "ask a person knowledgeable in the topic"
19:10:48
knusbaum
That's why I'm wondering if I need to be sending other requests to the client like (:clear-prompt) or something.
19:11:13
phoe
and the latter would be, I guess, asking luis and/or Joao who is knowledgeable in the ways of slynk/sly
19:13:48
phoe
I guess that, as a last resort, you could try to make a forum post at https://github.com/joaotavora/sly/discussions
19:14:35
phoe
(since that's where joao asked me to point people to if they have any kind of sly questions, and I guess that questions about the rpc protocol are borderline on-topic there)