<_death>
that could happen if you redefine a function.. you need to compile the file to get the source locations
<_death>
I guess C-c C-c can also work in some cases
khoa has joined #commonlisp
<lad>
_death, thanks, that helps
witchuer has joined #commonlisp
<raeda_>
Is there a de facto collections library? I'm looking for a vector that automatically adjusts as I insert at the end
<hayley>
vector-push-extend?
<raeda_>
Nice, didn't know that was in the standard
<pjb>
raeda_: make-array :fill-pointer 0 :adjustable t ; vector-push-extend doesn't work if there's no fill-pointer, and won't work long if the array is not adjustable.
tyson2 has joined #commonlisp
recordgroovy has quit [Quit: leaving]
<dieggsy>
moon-child: apologies, i meant no condescension, i guess i was just saying that was the first thing that came to mind for me
<moon-child>
:)
<moon-child>
I didn't think you were being condescending. Now that I reread my own message, I think it may have come off as slighted; that was definitely not my intention
<dieggsy>
no worries. it's weird, I started off with elisp and then CL, so loop was very natural to me. Then I switched to scheme for years, and loop became the weird way. Now I'm doing both and re-learning my old ways, re-de-mystifying loop lol, but also learning a lot i never learned in the first place
<moon-child>
I recently ported an implementation of loop to scheme
<moon-child>
'why not both?'
<dieggsy>
absolutely! moon-child mind sharing? chicken has an egg for it, but it's not a complete implementation
<moon-child>
so I ended up being very familiar with all the clauses and weird corners. (loop for x in '(1 2 3) if (f x) collect it)
<dieggsy>
moon-chilled is an excellent username lol
<dieggsy>
woah, it?
<dieggsy>
keywords! great. that was also missing in the chicken impl heh
waleee has quit [Ping timeout: 240 seconds]
montxero has quit [Read error: Connection reset by peer]
montxero has joined #commonlisp
<moon-child>
yeah. I don't use them myself, but the scheme impl I use supports them so ¯\_(ツ)_/¯
<dieggsy>
boy is that a serious bit of code heh
<dieggsy>
I like to use the keywords for loop in CL
<dieggsy>
....mostly for the syntax highlighting, which could/should just be handled by emacs when they're in loop and not keywords as well
<dieggsy>
but alas it isn't. maybe there's a package for that
srhm has joined #commonlisp
srhm has quit [Client Quit]
<aeth>
well
<aeth>
using CL keywords as LOOP keywords is clever
<aeth>
it also stands out more without syntax highlighting, e.g. IRC one liners
<aeth>
e.g. (loop :for i :from 0 :below 10 :collect i) vs (loop for i from 0 below 10 collect i)
<moon-child>
I don't think I have any special highlighting for loop keywords, and I don't have any trouble reading them. I find it harder with the keywords, because they break up the flow of the text
<dieggsy>
aeth: right, that's what i normally do
srhm has joined #commonlisp
srhm has quit [Read error: Connection reset by peer]
john__ has joined #commonlisp
srhm has joined #commonlisp
gaqwas has quit [Ping timeout: 252 seconds]
srhm has quit [Read error: Connection reset by peer]
srhm has joined #commonlisp
srhm has quit [Read error: Connection reset by peer]
srhm has joined #commonlisp
silasfox has quit [Ping timeout: 240 seconds]
silasfox has joined #commonlisp
<hayley>
Another slightly esoteric question: if one wants to show off their multithreaded Java implementation, they might use SpecJBB results. Are there any similar tests for Common Lisp?
<hayley>
I wouldn't mind porting code, but I am not aware of any CL benchmarks which use parallelism.
<moon-child>
I wonder how hard it would be to make a compiler from jvm bytecode to cl (probably not very)
<moon-child>
and how well the performance of the resulting code would reflect the performance of th eimplementation at regular code (no idea)
<hayley>
If you are asking, no I am not going to pay the US$1,650 for SPECjbb 2015. Apparently they want another $7.69 to be able to download it from their servers again. Sheesh.
<hayley>
Though they implemented Java in Self once, with some minor hacking to the VM (probably double floats?) and it was the fastest Java then.
<hayley>
Yes. Though the other problem was that the Self VM doesn't expose goto, only structured control flow.
<beach>
Good morning everyone!
tyson2 has quit [Remote host closed the connection]
semz has quit [Ping timeout: 252 seconds]
aeth has quit [Ping timeout: 256 seconds]
aeth has joined #commonlisp
semz has joined #commonlisp
yitzi has quit [Ping timeout: 244 seconds]
yitzi_ has joined #commonlisp
Skyfire has joined #commonlisp
Bike has quit [Quit: Lost terminal]
<lotuseater>
Good morning from me, too.
Oladon has joined #commonlisp
kakuhen has joined #commonlisp
<hayley>
While horrendously unscientific, I suppose running Hunchentoot with some stress test program is close enough to a benchmark of parallel CL code.
<dieggsy>
is there by random chance some convenience function/macro in allegro that would allow me to run lisp code in a separate lisp process (i.e. not a thread)? Something like emacs's async package
<dieggsy>
or should i just write it myself with existing external command functions + input/argument munging
<hayley>
Forgive me for asking, why do you want it in another process?
<dieggsy>
*no-defun-allowed*: the code i want to run in it isn't my own and builds a bunch of packages and does some weird things i don't want changing the state of the current image
<hayley>
Strange code then. But I can't think of any convenience function for the problem, no.
<dieggsy>
*no-defun-allowed*: oh it's extremely strange code jaja. the situation is kind of "this is an absolute abomination, don't fight it, find ways to make it better veeeeery slowly in baby steps"
<hayley>
Okay, I hit a snag with my benchmark idea. I can make latency due to GC and whatever else arbitrarily bad by overloading the server, so there needs to be some "standard" way to pick a load amount.
<hayley>
What if, say, I took the maximum throughput, then ran the system at 75% load to get latency figures?
silasfox36 has joined #commonlisp
silasfox36 has quit [Client Quit]
<dieggsy>
*no-defun-allowed*: lol, i think i just found out a way to do away with all the weird code alltogether. with more abominable code, but way cleaner. place your bets on whether they'll accept it heh
<hayley>
Do I want to know who "they" are?
<dieggsy>
just my team
Oladon has quit [Quit: Leaving.]
<dieggsy>
it's essentially just exporting all symbols from a package (i know, i know lol). but they're doing it in an extremely roundabout way by inserting symbols into the defpackage file. i figured if you're going to do that anyway... why not just iterate and do (export symbol) within the package itself as a last build step
<dieggsy>
now yes, ideally we'd just keep track of what symbols we want to export, but that's never going to happen so lol
<dieggsy>
well, who knows
shka has joined #commonlisp
Cymew has joined #commonlisp
amb007 has quit [Ping timeout: 245 seconds]
amb007 has joined #commonlisp
rgherdt has joined #commonlisp
rgherdt has quit [Remote host closed the connection]
cosimone has joined #commonlisp
amb007 has quit [Ping timeout: 240 seconds]
amb007 has joined #commonlisp
rain3 has joined #commonlisp
amb007 has quit [Read error: Connection reset by peer]
amb007 has joined #commonlisp
pve has joined #commonlisp
attila_lendvai has joined #commonlisp
amb007 has quit [Read error: Connection reset by peer]
amb007 has joined #commonlisp
heisig has joined #commonlisp
lisp123 has joined #commonlisp
hendursa1 has joined #commonlisp
hendursaga has quit [Ping timeout: 276 seconds]
scymtym has quit [Ping timeout: 240 seconds]
yitzi_ has quit [Remote host closed the connection]
yitzi_ has joined #commonlisp
yitzi_ has quit [Quit: Leaving]
IPmonger has joined #commonlisp
IPmonger has quit [Remote host closed the connection]
lisp123 has quit [Quit: Leaving...]
jasom has quit [Ping timeout: 240 seconds]
jasom has joined #commonlisp
frgo has quit [Remote host closed the connection]
frgo has joined #commonlisp
attila_lendvai has quit [Ping timeout: 244 seconds]
kakuhen has quit [Quit: Leaving...]
jasom has quit [Ping timeout: 252 seconds]
amb007 has quit [Read error: Connection reset by peer]
amb007 has joined #commonlisp
tyson2 has joined #commonlisp
amb007 has quit [Ping timeout: 252 seconds]
amb007 has joined #commonlisp
jasom has joined #commonlisp
amb007 has quit [Read error: Connection reset by peer]
amb007 has joined #commonlisp
rain3 has quit [Read error: Connection reset by peer]
rain3 has joined #commonlisp
amb007 has quit [Read error: Connection reset by peer]
amb007 has joined #commonlisp
santiagopim has joined #commonlisp
keir has joined #commonlisp
random-nick has joined #commonlisp
scymtym has joined #commonlisp
yitzi has joined #commonlisp
cosimone has quit [Ping timeout: 252 seconds]
<pjb>
semz: the point of that is making cl21 closer to python or ruby. Pure idiocy: if you want python or ruby and never know if your vector is freshly allocated or an immutable literial, just use puthon or ruby!
<edgar-rft>
...and what if I never want to know python or ruby?
lisp123 has joined #commonlisp
<pjb>
edgar-rft: then don't consider cl21; stay with ANSI-CL.
<edgar-rft>
maybe it's because I never considered cl21 that I don't know python or ruby
slyrus_ has joined #commonlisp
slyrus has quit [Ping timeout: 250 seconds]
<shka>
make libs
<shka>
duh
tfeb has joined #commonlisp
slyrus has joined #commonlisp
slyrus_ has quit [Ping timeout: 244 seconds]
cage has joined #commonlisp
tfeb has quit [Remote host closed the connection]
Bike has joined #commonlisp
tyson2 has quit [Quit: ERC (IRC client for Emacs 27.2)]
heisig has quit [Quit: Leaving]
jhi has quit []
jhi has joined #commonlisp
makomo has quit [Ping timeout: 256 seconds]
keir has quit [Ping timeout: 244 seconds]
hendursa1 has quit [Quit: hendursa1]
hendursaga has joined #commonlisp
keir has joined #commonlisp
makomo has joined #commonlisp
cosimone has joined #commonlisp
cosimone has quit [Remote host closed the connection]
cosimone has joined #commonlisp
keir has quit [Quit: keir]
keir has joined #commonlisp
tyson2 has joined #commonlisp
lad has quit [Ping timeout: 256 seconds]
waleee has joined #commonlisp
amb007 has quit [Read error: Connection reset by peer]
keir has quit [Quit: keir]
amb007 has joined #commonlisp
keir has joined #commonlisp
attila_lendvai has joined #commonlisp
keir has quit [Quit: keir]
keir has joined #commonlisp
keir has quit [Client Quit]
keir has joined #commonlisp
<dieggsy>
Is there a way to ensure an asdf system component is built last short of specifying all others as dependencies ?
waleee has quit [Ping timeout: 245 seconds]
<dieggsy>
or is the right way to do this to define a new system depending on the last and load that
waleee has joined #commonlisp
<lisp123>
You can use :serial t
<lisp123>
and then place it at the end of your component list
keir has quit [Quit: keir]
<Bike>
i mean, yeah, if building something depends on everything else already being built, the everything else are dependencies.
keir has joined #commonlisp
<dieggsy>
lisp123: oh, that's awesome
attila_lendvai has quit [Ping timeout: 252 seconds]
<lisp123>
dieggsy: Great, let us know if any issues. I believe best practices says to avoid doing :serial t, but I see a lot of people doing it
<lisp123>
(with :serial t, its a little bit unclear on which dependencies are required for each file - the option simply tells to load in the order specified)
<Bike>
it's not unclear. what :serial t does it make it so that each component depends on each of the components before it.
<dieggsy>
lisp123: it wouldn't be necessary if we followed best practices anyway heh, it's just to alleviate an already messy situation. it should be fine, since i really do need just one file to be loaded last
<lisp123>
Bike: Yes that's true :) But if you have (in order) A, B, C and C & B both depend on A only, then that wouldn't be clear as one can only assume that C depends on A and/or B (or nothing)
waleee has quit [Quit: WeeChat 3.2]
<Bike>
oh, you just mean in an abstract way, not asdf actually does. sure.
<lisp123>
I find it annoying having to put all the :depends-on, but apparently its best practice
<Bike>
it helps with the parallel compilation systems that sort of exist.
<Bike>
if all the dependencies are serial, you can't build any of them in parallel.
<lisp123>
Oh yes, sorry, wasn't as clear originally
<lisp123>
Ah so that's the reason why it says its sometimes slower to use :setial t
<lisp123>
dieggsy: Great, (ignore me btw, I just wanted to give some additional color, but not important in the grand scheme of things)
<dieggsy>
lisp123:
<dieggsy>
whoops. eh, i appreciate the note regardless
<lisp123>
Great :)
<dieggsy>
i've recently had to do a good bit of "by the way, we shouldn't be doing this in the first place, but if we do want to do this, there's a slightly better way"
<dieggsy>
usually leaving out the first part
<lisp123>
After all, rules are meant to be broken ;) :P
<dieggsy>
so it's good to hear about standards and best practices for my own sanity as well lol
<jmercouris>
No, rules are not meant to be broken
<lisp123>
loll
<jmercouris>
rules are actually meant to be followed
<jmercouris>
otherwise they wouldn't be rules
<dieggsy>
lmao we're programmers, rules literally must be followed eh
<lisp123>
jmercouris: While you are here, do you think its possible to build GUI apps in the future with Nyxt's framework?
<lisp123>
I was thinking of going down the Electron route, but then I wondered if it would be possible
woozong has joined #commonlisp
VincentVega has joined #commonlisp
waleee has joined #commonlisp
<jmercouris>
lisp123: yes, in fact it is
yitzi has quit [Quit: Leaving]
<jmercouris>
You can look at Nyxtmuch for an example, notmuch written for Nyxt
silasfox has quit [Ping timeout: 252 seconds]
<lisp123>
jmercouris: Great, thanks, will have a look
luna-is-here has joined #commonlisp
<jmercouris>
:-)
lukego has quit []
lukego has joined #commonlisp
markthom_ has quit [Quit: Client closed]
lisp123_ has joined #commonlisp
keir has quit [Quit: keir]
lisp123 has quit [Ping timeout: 252 seconds]
markthom_ has joined #commonlisp
cosimone has quit [Ping timeout: 252 seconds]
tyson2 has quit [Quit: ERC (IRC client for Emacs 27.2)]
woozong has quit [Ping timeout: 252 seconds]
tfeb has joined #commonlisp
cosimone has joined #commonlisp
tfeb has quit [Quit: died]
micro has quit [Ping timeout: 248 seconds]
micro has joined #commonlisp
lisp123_ has quit [Ping timeout: 240 seconds]
karlosz has joined #commonlisp
amb007 has quit [Read error: Connection reset by peer]
amb007 has joined #commonlisp
amb007 has quit [Ping timeout: 240 seconds]
amb007 has joined #commonlisp
yitzi has joined #commonlisp
Jach has joined #commonlisp
amb007 has quit [Ping timeout: 256 seconds]
amb007 has joined #commonlisp
cosimone has quit [Ping timeout: 252 seconds]
amb007 has quit [Ping timeout: 252 seconds]
lad has joined #commonlisp
amb007 has joined #commonlisp
<kagevf>
jmercouris: what's nyxtmuch? couldn't ddg it ...
<kagevf>
ohhh, it's a play on "not much" emails ... like the opening quote too :)
karlosz has quit [Quit: karlosz]
karlosz has joined #commonlisp
<kagevf>
jmercouris: wow interesting thread :)
<jmercouris>
Indeed
amb007 has quit [Read error: Connection reset by peer]
amb007 has joined #commonlisp
karlosz has quit [Quit: karlosz]
<Fade>
what happens when you obviate greenspun's tenth by delivering the application in lisp to begin with?
<Fade>
is zawinski's law a corrolary? :)
amb007 has quit [Ping timeout: 240 seconds]
amb007 has joined #commonlisp
amb007 has quit [Ping timeout: 252 seconds]
amb007 has joined #commonlisp
Oladon has joined #commonlisp
elf_fortrez has joined #commonlisp
yitzi has quit [Ping timeout: 256 seconds]
ec_ has joined #commonlisp
yitzi has joined #commonlisp
<borodust>
etimmons: hmm, this is indeed might help, although i'm not actually sure what exactly was the reason in the first place ;p
yitzi has quit [Client Quit]
<borodust>
although it seems one would need to recompile sbcl to use this change which is actually won't help, cuz i can't ask usesrs to compile sbcl from scrach just to use claw ;p
<borodust>
or
<borodust>
yeh, it seems so
<borodust>
but it is certainly a nice thing, cuz maybe that's another step to allow running sbcl on android natively
<etimmons>
yeah, but I always compile my own SBCL anyways, so I can just change that signal and be able to use claw it sounds like :)
silasfox has joined #commonlisp
elf_fortrez has quit [Ping timeout: 256 seconds]
<borodust>
etimmons: pls let me know if this actually helps, i might as well just go this route
<etimmons>
I will let you know when I give it a try!
yitzi has joined #commonlisp
ec__ has joined #commonlisp
rain3 has quit [Ping timeout: 256 seconds]
<pjb>
Fade: exactly. Zawinski's.
<hendursaga>
jmercouris: nyxtmuch will be integrated into Nyxt proper or as an addon..?
ec_ has quit [Ping timeout: 276 seconds]
cosimone has joined #commonlisp
cosimone has quit [Remote host closed the connection]
cosimone has joined #commonlisp
ec__ has quit [Ping timeout: 276 seconds]
amb007 has quit [Ping timeout: 245 seconds]
amb007 has joined #commonlisp
scymtym_ has joined #commonlisp
scymtym has quit [Ping timeout: 252 seconds]
Mandus has quit [Quit: WeeChat 3.0.1]
ec__ has joined #commonlisp
Mandus has joined #commonlisp
cosimone has quit [Ping timeout: 252 seconds]
ec__ has quit [Ping timeout: 276 seconds]
ec__ has joined #commonlisp
<jmercouris>
Hard to say, perhaps as an addon
amb007 has quit [Read error: Connection reset by peer]
amb007 has joined #commonlisp
ec__ has quit [Ping timeout: 276 seconds]
ec__ has joined #commonlisp
Oladon has quit [Quit: Leaving.]
ec__ has quit [Ping timeout: 276 seconds]
dbotton has quit []
dbotton has joined #commonlisp
ec__ has joined #commonlisp
<borodust>
etimmons: thanks!
z3t07 has joined #commonlisp
z3t0 has quit [Ping timeout: 244 seconds]
z3t07 is now known as z3t0
karlosz has joined #commonlisp
vats has joined #commonlisp
Lycurgus has joined #commonlisp
lisp123 has joined #commonlisp
pve has quit [Quit: leaving]
lisp123 has quit [Quit: Leaving...]
<hexology>
i have a table of the form '((x "a" 0x01 "ITEM A") (y "b" 0x02 "ITEM B")). i want to perform lookups such that any of the 2nd-4th elements in a row returns the 1st element in the row. so looking up "b", 0x02, or "ITEM B" should return Y. any suggestions for a tidy way to store this kind of data?
ec__ has quit [Ping timeout: 276 seconds]
<hexology>
it's safe to assume that the lookup keys are unique, so there will not be 2 rows with the same key in any field
<Bike>
do you want to use the data in other ways? probably, but if not, i'd think a hash table is fine
Lycurgus has quit [Quit: Exeunt]
<hexology>
in this case i don't, i just need to look up individual elements
<hexology>
would i have 3 separate hash tables? one for each set of keys
<hexology>
or i'd "flatten" the keys all into a single hash table
<Bike>
i don't see why you'd need more than one table, if the keys never overlap
<hexology>
right
<hexology>
good idea
<moon-child>
could also find-if
<moon-child>
(member (cdr x))
ec__ has joined #commonlisp
seere has joined #commonlisp
<White_Flame>
hexology: 0x02 is a symbol, or did you want #x02?
<hexology>
White_Flame i'm actually undecided as of yet, it would either be #x02 or "0x02"
<White_Flame>
also, (find "a" my-table :key #'second :test #'string=)
<mfiano>
(car (rassoc '0x02 table :test (lambda (x y) (find x y :test #'equal))))
<hexology>
these all involve linear scans over the list, right?
<mfiano>
that is highly inefficient for large data
<White_Flame>
yeah, it's the easiest way. slow but compact
<hexology>
in this case it's not a big enough pile of data to care about performance
<mfiano>
Best would be to use a hash table if tables are large
<White_Flame>
if you use a hash table, you really mean 4 hash tables here
<White_Flame>
and makes it more complex to add/remove
<mfiano>
Depends if rows are also large
<mfiano>
If not single would be fine
<hexology>
White_Flame i mentioned this above, but in this case there are exactly 3 "keys" per "value", and the keys are all distinct, so they can be in a single flat hash table
<hexology>
that was Bike's idea
<White_Flame>
ok, but it's still 4 adds/removes per item to manage
<hexology>
true. also in this case the table won't be modified, just read from
<White_Flame>
I tend to just stick with very simple/dumb/linear approaches in the beginning, then if it's too slow you can find exactly what you need to optimize
ec__ has quit [Ping timeout: 276 seconds]
mariari has quit [Quit: WeeChat 3.2]
<White_Flame>
and oftentimes, as you look at optimization strategies, you'll see that there's other data also associated with this, and do a more holistic optimization pass rather than just focus on 1 individual data structure
mariari has joined #commonlisp
<White_Flame>
eg, algorithmic optimization or refactoring how things work
cage has quit [Quit: rcirc on GNU Emacs 27.1]
ec__ has joined #commonlisp
<etimmons>
borodust: Doesn't seem to have fixed it :(
<borodust>
etimmons: :( something else then
<borodust>
one day i'll tend to it :)
<borodust>
till then for generating bindings ccl will suffice
silasfox has quit [Ping timeout: 252 seconds]
Cymew has quit [Ping timeout: 252 seconds]
<hexology>
that's very fair White_Flame. another reason to use a list is that i can do fuzzy search that way in the future
karlosz has quit [Ping timeout: 244 seconds]
antonv has joined #commonlisp
lisp123 has joined #commonlisp
ec__ has quit [Ping timeout: 276 seconds]
<pjb>
(let ((table '((x "a" 0x01 "ITEM A") (y "b" 0x02 "ITEM B"))) (keys '("a" 2 0x02 "item b"))) (loop for key in keys collect (first (find key table :key (function rest) :test (lambda (k l) (member k l :test (function equalp))))))) #| --> (x nil y y) |#
<pjb>
hexology: ^
<pjb>
hexology: note: 0x02 is a symbol. #x02 is an integer.
ec__ has joined #commonlisp
antonv has quit [Quit: Client closed]
<hexology>
if i use 0x02 i'll do it as a string, not a symbol
<_death>
internally you can use, say, a hash-table.. later you can switch to whatever representation you need
karlosz has joined #commonlisp
Everything has joined #commonlisp
<hexology>
i was already planning on having a function like (lookup-index *items-table* #x02) --> 'y
Guest71 has joined #commonlisp
<Bike>
the operation of key arguments is explained in detail in clhs 17.2.1 and 17.2.2. sequence functions don't actually reference those sections, which is pretty annoying
Lord_of_Life_ has joined #commonlisp
Lord_of_Life has quit [Ping timeout: 240 seconds]
Lord_of_Life_ is now known as Lord_of_Life
karlosz has quit [Quit: karlosz]
ec__ has quit [Ping timeout: 276 seconds]
Lycurgus has joined #commonlisp
ec__ has joined #commonlisp
karlosz has joined #commonlisp
gxt has quit [Quit: WeeChat 3.2]
gxt has joined #commonlisp
lisp123_ has joined #commonlisp
lisp123_ has quit [Read error: Connection reset by peer]