libera/#commonlisp - IRC Chatlog
Search
15:45:27
NotThatRPG
Using SLIME, should I expect evaluating a special variable in a debugger frame to give an accurate value for that special variable at that point in the stack? I'm getting a NIL where a function called incorrectly *binds* that variable, but I don't see the value set initially at the bottom of the stack. Using SBCL.
15:56:26
beach
It is interesting that the standard is ambiguous when it comes to the word "bound". I would like to fix that some day.
16:02:14
jackdaniel
NotThatRPG: if you mean the value before the dynamic binding, you may call symbol-value on it
16:06:23
jackdaniel
I see, thanks. I must have confused that with something else, because I'm sure I saw something like this..
16:06:56
random-nick
I don't think the standard provides a way to access the global value of a special variable?
16:07:24
beach
Here is an example of the ambiguity: (defparameter *a* 10) (defparameter *b* 20) (progv '(*a* *b*) '(30) (list (boundp '*a*) (boundp '*b*))) gives (T NIL).
16:08:44
beach
But the dictionary entry for PROGV says that *b* is "bound" (but "then made to have no value").
16:10:39
beach
I would like to fix the terminology so that there is a separation between "bound", i.e., a binding exists, and "having a value".
16:12:33
Catie
What would it mean for a symbol to be bound, but have no value? Just that BOUNDP would return T?
16:13:26
beach
Catie: It means the case illustrated by PROGV, and yes, if BOUNDP were correctly named in that situation, it would return T.
17:20:37
Bike
What's the best practice for having custom asdf component types? I remember it being an old problem that defsystem-depends-on doesn't help if your component class names are symbols in some dependent package, but I don't remember the solution.
17:21:55
jackdaniel
I don't know what is the best practice however asdf-user is a package that should exist
17:23:53
_death
I remember that problem with cffi grovel.. in the end it was resolved by it too using a keyword
17:24:02
random-nick
cffi seems to just alias its classes into the asdf package https://github.com/cffi/cffi/blob/master/grovel/asdf.lisp#L150
17:24:20
etimmons
Use strings instead of symbols for the component class names. The strings are READ-FROM-STRING after all defsystem-depends-on are loaded.
17:29:08
random-nick
by the way, I might have asked this question earlier, but how do you generate code and compile it with the file compiler while playing along with asdf?
17:30:39
random-nick
do you need to make a separate component type which runs the generator and then uses the result? where do you put the generated file? same place as the system's source files or into wherever asdf keeps the fasls?
17:32:45
phoe
in particular, https://github.com/edicl/cl-unicode/blob/2790a6b8912be1cb051437f463400b4a7198748a/cl-unicode.asd#L48-L49
17:37:22
random-nick
hmm, kind of weird? it seems to make a separate system which has additional outputs on load-op, then on the main system it additionally checks whenever all of them are present, and if not, loads that separate system?
17:38:14
random-nick
and I guess where to place the additional outputs is handled by asdf? or is it just at the root of the system
17:42:39
random-nick
on my installation they seem to be present in the root of the cl-unicode system
17:51:11
phoe
note that the source tarballs or the repo at https://github.com/edicl/cl-unicode/ does not include these files
17:57:43
random-nick
phoe: what seems rather confusing to me is that the generated files seem to have an older modification date compared to the human-written files
18:01:50
random-nick
phoe: anyway, thanks for the pointers, this seems to work fine since cl-unicode is a very popular package
18:02:27
phoe
I know that guix people had to work around it generating source files in its source directory, since source directories in guix are immutable and therefore read-only
18:11:13
Bike
i'm still having a heck of a time understanding checkl. with cl-conspack, even if i try testing with upstream conspack instead of my fork, fiveam says it's not doing anything
18:21:22
phoe
after a brief glance I have no idea if the code that invokes checkl via fiveam actually works
18:24:05
Bike
i also get some deprecation warnings. maybe i should just port the tests to use fiveam directly.
18:26:44
phoe
honestly, I'd do it - even if respecting the principle of least surprise is everything you get out of it
18:27:23
phoe
I've read the manual the last time you've mentioned checkl and it still seems too clever for me
18:53:30
NotThatRPG
beach, jackdaniel : I had to go out before your responses. I was talking to Phoebe and they said that SBCL implements dynamic bindings efficiently using UNWIND-PROTECT, which avoids a lot of the performance issues of specials, but isn't well suited for this kind of debugging use case.
19:07:03
NotThatRPG
@jackdaniel: I'm not sure how that would work, but I'm not familiar with the SLIME-db internals.
19:07:45
jackdaniel
phoe: that's the point - how to look up the symbol value ignoring dynamic bindings
19:08:05
NotThatRPG
@jackdaniel: I wasn't trying to *ignore* dynamic bindings and get a global variable.
19:08:28
NotThatRPG
I wanted to get the current-for-this-stack-frame value in the debugger as I move up and down the stack.
20:03:59
nij-
There's trivial-timers in my quicklisp distribution, but I think something else gets loaded.. can't find out.
23:28:49
yitzi
Josh_2: shasht uses whatever is in `*symbol-name-function*` to print symbols. https://github.com/yitzchak/shasht/blob/4fc7c9dad567a4266ec3a6596d50744df9ea1c61/src/config.lisp#L65