freenode/#lisp - IRC Chatlog
Search
20:18:25
Xach
zxcvz: that will land you in the debugger, which starts out with "0]". :backtrace will show the backtrace.
20:20:45
Xach
zxcvz: oh. i haven't used Sublime, so I'm not sure what it might be doing, but if you are using the sbcl repl directly it will enter the debugger on error. I'm not sure how to get help with what sublime is doing, sorry.
20:21:01
Xach
with emacs and slime, "v" will jump from the frame to the error location. it is handy.
20:23:11
ealfonso
zxcvz maybe something is trapping your error? are you using a framework or library?
20:25:52
zxcvz
Xach: Running a program. Apparently I've made some change some where. A bit irritating with just an error message without the debugger.
20:39:22
aeth
In, practice, though, if you use enough libraries you're only going to get it to run on SBCL, CCL, and maybe ECL. At least, the libraries I've happened to use.
20:43:08
Xof
well, all CL implementations that I've found to play with today have the opposite behaviour for (:method-combination foo x) than I sort-of want
20:44:18
Xof
(probably very little: see previous discussions about no-one using long-form method combination)
20:48:52
Xof
I am imagining code a bit like (let ((shared (cons nil nil))) (defgeneric foo (x) (:method-combination weird shared) (:method foo (x) (car shared))) (defgeneric bar (x) (:method-combination weird shared) (:method bar (x) (cdr shared))))
20:49:54
Xof
but I know that it's not possible if you don't evaluate method combination args, whereas you can get the current de-facto standard behaviour by quoting everything
20:52:48
Xof
I don't know. This is probably not the hill I should be trying to climb, let alone making my last stand on
20:54:24
Bike
i did the same thing a while back trying to figure out if the options returned by make-method-lambda are evaluated
0:11:06
White_Flame
If I have a macro which should build up a hash table in a lexical scope for runtime code to use, what's the best way to do that? (let ((table ,populated-table)) ...) doesn't seem to be valid source code
0:30:20
pfdietz
You want the code generated from the macro to refer to the same hash table everywhere?
0:45:33
White_Flame
sorry, was afk for a bit. I run a compiler at compile-time, contained to a lexical scope. Some of its output should be exposed to the runtime as a hashtable. This generated function body should be able to run multiple times, seeing the same (read-only) hashtable which was populated at compile-time
0:46:31
White_Flame
so it's not the same hash table everywhere; each instance of it should have its own table it sees
0:48:23
White_Flame
I'm cleaning up old hacks, as well as fixing up code isn't working on new SBCL releases
0:48:58
White_Flame
so code isn't fine, but I'm also not sure that the crashes I'm hitting are related to this setup step
0:49:12
White_Flame
however, it's a hack I wish to eliminate, so gathering thoughts on a way this could be done
0:51:24
White_Flame
that wasn't working years ago, hence lots of workarounds. Might have been various pebcak problems
2:04:03
aeth
White_Flame: I don't see it as a hack, I see it as a valuable feature... that you can trivially make custom classes/structs also be able to do.
2:05:55
aeth
Trivial compile time evaluation is one of the last major remaining secret weapons CL has.
2:07:22
pfdietz
You could have multiple files using the macro, compiled at different times. How do you resolve the hash table differences?
2:10:09
pfdietz
One trick is to propagate values in the macroexpansion environment. I've used that for compile time lexical information.
2:23:49
White_Flame
aeth: the hack in place is to have a single global hashtable of hashtables, with gensyms per location doing a looup on invocation
2:24:54
White_Flame
ie, the code tested originally which tried to place hashtables in source code blew up. Now, I dont' recall if that was because of fasl loading or whatnot. Almost every problem we hit seems to be because we do appliation servers that are deployed as executable images, which then load up more code at the deployment site
3:18:19
aeth
White_Flame: What kind of functions? If they're 'foo instead of #'foo or lambda it should afaik be OK to funcall because it will look it up at runtime
3:21:57
_berke_
hi. I recall reading that there was something like a with-symbols macro but I can't find it
3:28:26
_berke_
now slime question. when you have erroneous code and hit C-c C-k slime asks you if you want to load the fasl. I don't, how can I get slime to STFU in that situation.
3:54:54
aeth
Personally, I use the online quicklisp because I can search it through !l1sp on DuckDuckGo (that's actually one of several supported sites), and I have a local copy as a backup for when the website is down or I am offline.
3:55:03
clintm
I swear there is, or used to be, a ql-installable package that starts a server in whatever image you load it on that has it.
3:57:44
jack_rabbit
hmmmm. (documentation 'package-name t) does not return my docstring... I must be doing something wrong in the defpackage.
3:59:21
beach
jack_rabbit: In the long run, you will save a lot of time by learning how to interpret the (sometimes a bit cryptic) dictionary pages of the Common Lisp HyperSpec.
4:00:00
jack_rabbit
beach, Yes, I need to get better at that. I realized my mistake, but not quick enough.
4:22:28
_berke_
I'm trying some cl-cuda examples and I wrote a simple macro, but as soon as I use quasiquotations I get a ton of SBCL warnings. https://pastebin.com/FMpVhysG (test1 totoro) is fine, (test2 totoro) gives warnings
4:32:41
_berke_
interestingly if I use (intern (symbol-name (gensym))) instead of straight up (gensym) it works, but I have no idea why or if this is correct
6:47:36
pillton
shka: I usually do (assert (typep x type)) to avoid the use-value restart messing with type inference.
7:04:43
pillton
Oh it is checked. The fact that an arbitrary value can be stored in the variable is probably the problem.