freenode/#lisp - IRC Chatlog
Search
17:57:37
shka_
so you can https://github.com/sirherrbatka/vellum/blob/1315f04382547f938f4569f2b99ba038e93f75b6/run-tests.lisp#L11
18:17:54
Nilby
I still have a CL twitter client with a TUI back from when you had to send your password in cleartext over http, but then I never looked a twitter again.
18:59:38
Josh_2
Shinmera: the fun (statuses/update-with-media ..) says it takes either a pathname, usb-8 array or a base64 encoded string (in the docstring), I have just given it a usb-8 array and I get the error "Wanted one of (FUNCTION FILE-STREAM STREAM PATHNAME)."
20:18:38
contrapunctus
Uh, what's going on here :\ (ql:quickload :mcclim) => System "mcclim" not found 🤔
20:21:10
contrapunctus
phoe: yup, tried that. Although rather suspiciously, it said "1 dist to check"
20:23:12
Shinmera
Josh_2: oAuth tokens don't expire unless they're manually revoked. You have to actually save the info though.
20:23:49
mfiano
First check (ql:where-is-system :alexandria) to see if Quicklisp even has it downloaded
20:25:08
contrapunctus
mfiano: nil 🤔 but I have a /home/anon/quicklisp/dists/quicklisp/archives/alexandria-20200925-git.tgz
20:26:09
Bike
do you have cl-asdf or anything installed? maybe your global asdf configuration is something odd now
20:27:20
contrapunctus
Oh. I did install cl-asdf, because before that, SBCL was not seeing ASDF 🤔
20:28:03
phoe
and if for some reason it isn't available, quicklisp has its own fallback asdf that it uses for such situations
20:35:59
contrapunctus
phoe: removed cl-quicklisp, deleted the cache, restarted Emacs, still the same Quicklisp issue x-P
20:37:12
phoe
do you have the alexandria asd file anywhere in ~/quicklisp/dists/quicklisp/software/?
20:38:24
contrapunctus
phoe: there's a /home/anon/quicklisp/dists/quicklisp/software/alexandria-20200925-git/alexandria.asd
4:22:45
beach
I guess in the spirit of the first example, I should have written (let ('5) (let (#'quote) (+ . #'6)))
4:25:47
no-defun-allowed
SLIME would print the lambda list of a mapping function I wrote as #'SEQUENCE.
4:59:09
beach
no-defun-allowed: That's a very good example of why I want something better than Emacs for writing Common Lisp code.
5:00:39
moon-child
that doesn't seem like a fundamental limitation of emacs though, only an incidental result of slime's implementation; no?
5:09:01
fiddlerwoaroof
It's fundamentally ambiguous whether the intention here is to print code or a list, as far as I can see
5:10:19
beach
One could, for example, show the characters in the source code that defined the item to be printed.
5:10:35
beach
Then you would get the same representation as the programmer wanted when the code was written.
5:11:42
fiddlerwoaroof
Yeah, that doesn't help when you're formatting the output of MACROEXPAND-1, though
5:12:47
fiddlerwoaroof
I use tools like emacs' macrostep expander quite a bit when I'm trying to figure out what a macro does
5:13:00
beach
Perhaps I am generalizing too much, but I almost never look at the result of a macro expansion.
5:13:48
beach
I see macros the say I see function, i.e., as abstractions. Only when I write the macro itself would I be interested in how it expands.
5:14:53
fiddlerwoaroof
When I decide that a macro was a bad idea, I usually MACROEXPAND-1 and replace the source with the expansion
5:15:39
beach
This is one reason why I made a rule that SICL macros should do a lot of syntax checking, so that conditions would be shown in terms of the macro call, rather than in terms of its expansion.
5:20:05
fiddlerwoaroof
I think if you continue down that route, you end up writing macros that expand to CLOS objects
5:23:00
beach
Not sure what you mean by "CLOS object", but if you mean "standard object" then that would be some very useless macros, since those are self-evaluating.
5:24:04
beach
... unless you implementation uses standard objects for conses and symbols, of course.
5:27:19
sm2n
beach, correct me if I'm wrong, but that kind of syntax checking doesn't compose too well
5:27:47
sm2n
i.e if I have a macro that expands into a macro, and the second macro has malformed syntax, the thrown error won't be in terms of the code I wrote
5:29:12
sm2n
and (+ . (quote 6) is exactly (+ quote 6), which has quote bound lexically to 5 by the let
5:29:25
beach
sm2n: Well, if the macro is meant to be used as an abstraction, it is usually clear what the different arguments stand for, so the syntax of those can then be checked. Perhaps not fully, but I am guessing a lot better than what is typically done.
5:34:55
sm2n
no matter how much syntax checking you have in bar, the error thrown won't be in (foo), because macroexpansion destroys that context
5:36:49
beach
Ah, yes, I see. That's the reason for another SICL rule, namely to report errors in terms of source expressions in context.
5:38:09
beach
But your scenario is definitely not the one I was thinking of. In this case, my scenario would be the time when the macro FOO was written.
5:39:07
sm2n
I don't really think it's much of an issue because CL isn't conventionally written with deeply nested macros from what I can tell
5:39:20
beach
There would be some highlight of the (BAR BAZ) expression with an indication that the number of arguments is wrong.
5:40:17
sm2n
I brought this up because this was the motivation for the racket people to move to syntax objects as the result of macroexpansion, which is close to what fiddlerwoaroof was implying by macroexpanding into CLOS objects
5:40:54
fiddlerwoaroof
If you have mid-level macros that expand to standard objects, and high-level macros that expand the standard objects to conses, you can preserve all sorts of metadata
5:42:01
beach
fiddlerwoaroof: I think I see what you mean now. Not that the expansion itself is a standard object, but something like (FOO <standard-object>). Yes?
5:42:41
fiddlerwoaroof
Or, (foo (bar)) and then bar expands to (foo #<standard-object>), which foo expands itself
5:43:58
fiddlerwoaroof
I think reading your paper on SICL loop was the first time I thought of this idea
5:45:26
no-defun-allowed
I think I was approaching something like that this morning to simplify code generation for a new project. It would use vectorised loads, stores and comparison operators, but my compiler would generate something like (load #<some policy representation> vector n), which would then be expanded using a generic function that the client would specialize.
5:45:26
beach
I never thought about generalizing it to more mundane macros though. Food for thought. Thanks!
5:47:10
no-defun-allowed
It's still very fuzzy though, and I've only written down a summary of the protocol for the rest of the project so far.
5:49:30
moon-child
(aside: the above discussion of macros and abstraction makes me think that sigils are superior to namespaces. Imagine we use & for function values, % for macros and builtins, and $ for variables. Then the 'quote' symbol used by the ' reader macro cannot possibly collide with a local variable which is also named quote)