freenode/#lisp - IRC Chatlog
Search
19:55:03
jasom
though a few tests I just ran on cl-marshal show some weaknesses; it only marshals to a list, so it is up to you to turn thie list into a string (presumably with *print-readably*. It also does not generate references for non-aggregate types, so you would need *print-circle* to correctly handle gensyms (though that still would only guarantee equality within the serialization, which is the best you
19:57:45
Josh_2
I think I will just utilize some of what markasoftware provided to make it easier to extend my own
20:09:28
cage_
i have not touched the library in years, if you can show some code to reproduce the issue i can try to see what is wrong
20:10:13
cage_
i am quite busy but i will try to address the problem when (and, sadly if) possible :)
20:11:43
Josh_2
https://github.com/K1D77A/Moonbot/blob/master/src/classes.lisp here It's the first class 'moonbot'
20:30:41
cage_
Josh_2, sorry to bother but may i ask to provide the code to initialize the class, sorry for the lazyness
20:36:47
markasoftware
for what it's worth i just discovered that my (consify) will not work on improper lists, i will need to think about this
20:39:37
Josh_2
Thats probably because I specialized my class and put '(communities ..) as one of the slots, while not telling cl-marshal how to marshal a community
20:56:59
cage_
jasom, sorry but my knowlege of the library is a bit rusty, i think the library can already serialze/deserialze symbols so thre is some problem that your code adrress that i can not see at this moment
20:57:27
jasom
cage_: right now it serializes symbols as symbols and does not generate e.g. references for gensyms
20:58:56
jasom
so two problems: 1) the SEXP->(string|bytes) must be package aware 2) the SEXP->(string|bytes) must be *print-circle* aware.
21:01:43
jasom
(let ((*package* <any package>) (*print-circle* t) (*print-readably* t)) (print)) (and similar dynamic bindings for (read)) will work; just about any other way of stringifying the sexp is likely to have subtle bugs
21:03:23
cage_
your code to serialize symbols seems reasonably to me (but take into account i am a bit tired :-)) would you file an pull request?
21:05:28
cage_
honestly my knowelege of CL never would allow me the problem you brougth to my attention here
23:05:11
White_Flame
hmm, cl+ssl doesn't quickload because of a non-exported symbol from usocket. This can't just be me, right?
23:05:25
White_Flame
broke in my old code when I cleared cache, as well as after the latest update-all-dists
23:15:52
White_Flame
yep, I just found an old usocket nested deep in some old libs directory of one of my local-projects symlinks. whee
0:19:35
torbo
Is the runtime of the length function when called on a string in Common Lisp/SBCL (O 1) or (O n), where n is the number of characters in the string?
0:21:53
Bike
there's no formal guarantee or anything, but every lisp implementation i know of implements strings (and arrays generally) as contiguous memory blocks like you'd expect
0:23:23
torbo
Right, I'm wondering whether the size of the contiguous memory block is something that's tracked, or does SBCL have to iterate through it until it gets to the end to find out how big it is.
0:51:02
Bike
technically an implementation could not do this, and instead use null termination or something, but that's pretty unlikely
3:47:31
jasom
Technically Nul is not one of the standard characters so an implementation could fail to support embedded Nul characters
3:48:16
Bike
i didn't mention that since that makes the scenario more fanciful. also if there is a character it would have to support putting that character in a string
4:26:12
easye
ABCL could really use a release that optimizes loading times: the new implementation of loading things in abcl-1.8.0 slowed things down by a factor of 2x-3x.
4:30:54
beach
easye: Yes, I know. I just don't know whether it is good to work a lot (and not get much done) or work less (for the same amount of work).
4:32:24
beach
In the past I often had students who complained about mediocre grades on some homework, saying they put in a lot of work. But I told them, it's the result that counts, not how tired you are.
7:42:34
White_Flame
so when using ql libs that pull in .so/.dynlib, are there tools or best practices on how to get an actual executable that doesn't die on startup on another machine without a bunch of stuff natively installed?