freenode/#lisp - IRC Chatlog
Search
5:56:42
gabbiel
but when the function runs, surely the var will have a value. also, why couldn't it work onormal vars
5:57:03
pjb
gabbiel: the problem with lexical variables, is that their name disappear once compiled.
5:58:15
beach
LdBeth: Here is one paper, but that's not the one I am thinking of: https://www.researchgate.net/profile/Ralf_Moeller5/publication/246460414_User_Interface_Management_Systems_The_CLIM_Perspective/links/545b53940cf28779a4db0700.pdf
6:00:02
gabbiel
this is confusing, I didnt know this would be a problem: (let ((val var)) body (setf var val))
6:04:01
beach
LdBeth: I have a specific paper in mind, but I can't seem to find it now. Maybe I dreamed it up.
6:20:10
pjb
gabbiel: if you want to restore a variable after usage, perhaps you want to use unwind-protect too?
6:21:30
pjb
Actually, we'd need more than a paste service. Well, for short throwable snippets, ok. But often we have more complete code, that can be referenced years later. So perhaps something like codeshare.io
6:25:08
gabbiel
but pjb's solution is more general, allows for resetting whenever you want, that's nice
6:25:18
pjb
gabbiel: what if an error occurs in body? Do you want to keep the modified value or do you want to restore the old value?
6:36:45
pjb
works on places. but foremost, it uses unwind-protect to restore it even if body makes a non-local exit (error, return, throw, etc).
6:44:19
gabbiel
I was also going to write a save-variables macro, or in your case, a save-places macro, I guess it'd be easy to implement by just having a places and &body arg
7:07:41
pjb
minion: memo for gabbiel: the &environment parameter is required to handle things like (let ((x 42) (y 33)) (list 'outer (symbol-macrolet ((y x)) (list 'inner (save-place (y) (setf y 0) (list x y)) (list 'mid x y))) x y)) #| --> (outer (inner (0 0) (mid 42 42)) 42 33) |#
9:42:14
beach
I don't see anything that requires IGNORE to be a closed declaration, but it won't work anyway, because in the scope between the two LETs, it is still not referenced.
9:47:07
jdz
fivo: Yes, that's why I said "maybe", because I don't know why you'd want to do what you're doing at the moment.
11:51:27
schweers
fivo: do you know of metabang-bind? https://common-lisp.net/project/metabang-bind/user-guide.html
11:51:27
minion
schweers, memo from jkordani: did you figure out what was going on with your code coverage issue?
11:51:58
schweers
jkordani: sadly no, other than that it seems to have problems with some code. For instance with lparallel.
12:31:55
prxq
I'm trying to use slime to edit and run code on another machine (a windows one). I'm having trouble with the slime-tramp extension. Specifically,
12:33:22
prxq
the problem is that I use the cygwin ssh server, and the path to the windows file C:\this\file.cl will be /cygdrive/c/this/file.cl.
12:34:32
prxq
Anyone knows how I can insert the /cygdrive/c/ part into a SLIME-FILENAME-TRANSLATION?
12:36:45
pjb
prxq: emacs lisp is case sensitive and doesn't have a readtable to upcase or preserve it!
13:12:59
Xach
ebzzry: i should fix xach.com/clhs for certain, but something about the setup is giving me problems.
13:15:42
ebzzry
Xach: the problem is when the problem doesn’t come from the machine+configuration, but when it’s due to external factors like changes in networknig
13:17:27
Xach
these problems started when i had to add a weird nginx proxy to apache to keep php happy on a debian 6 upgrade many years ago, then bumping up to debian 9 on a new server, where half the requests are proxied and half are not