<grumpyvegetable>
I think someone in here said, a few days ago, that there was a video of someone utilizing the DESCRIBE functionality from CL the way you can with Python's help() in the REPL
<grumpyvegetable>
A youtube video, I think
<grumpyvegetable>
Anyone know where that video is?
<Bike>
that's what aeth was talking about, at least
<_death>
to get something analogous to python's help, you need to combine describe-like traversal with documentation-centric qualities of documentation
prince1 has quit [Ping timeout: 264 seconds]
epony has joined #lisp
efm has quit [Ping timeout: 250 seconds]
n1kio has quit [Remote host closed the connection]
patrixl has joined #lisp
efm has joined #lisp
karlosz has quit [Quit: karlosz]
oxum has quit [Remote host closed the connection]
jackhill has quit [Quit: leaving]
jackhill has joined #lisp
ebzzry_ has joined #lisp
trocado has joined #lisp
xlei has quit [Ping timeout: 255 seconds]
xlei has joined #lisp
bilegeek has joined #lisp
Nilby has quit [Read error: Connection reset by peer]
cosimone has quit [Quit: Quit.]
oxum has joined #lisp
orivej has quit [Ping timeout: 246 seconds]
oxum has quit [Ping timeout: 250 seconds]
<_death>
as an aside, isn't it funny that the Lambda-list shown in your snippet has the opposite symbol qualification from a usability point of view.. you'd expect it to show (NAME-AND-OPTION TYPED-LAMBDA-LIST CL:&BODY BODY)
<_death>
qualification could also be useful if the symbol names a special variable
Josh_2 has quit [Ping timeout: 250 seconds]
oxum has joined #lisp
isBEKaml has joined #lisp
devrtz has quit [Ping timeout: 256 seconds]
karlosz has joined #lisp
quazimod1 has quit [Ping timeout: 258 seconds]
quazimodo has joined #lisp
isBEKaml has quit [Quit: leaving]
semz has quit [Ping timeout: 246 seconds]
oxum has quit [Remote host closed the connection]
X-Scale has quit [Ping timeout: 240 seconds]
X-Scale` has joined #lisp
X-Scale` is now known as X-Scale
torbo has quit [Remote host closed the connection]
semz has joined #lisp
semz has quit [Changing host]
semz has joined #lisp
FennecCode has quit [Quit: ERC (IRC client for Emacs 26.2)]
mange has joined #lisp
mono has joined #lisp
Nilby has joined #lisp
monokrom has quit [Ping timeout: 246 seconds]
lavaflow has quit [Ping timeout: 260 seconds]
lavaflow has joined #lisp
shangul has joined #lisp
oxum has joined #lisp
Bike has quit [Ping timeout: 246 seconds]
oxum has quit [Ping timeout: 250 seconds]
prince1 has joined #lisp
Josh_2 has joined #lisp
ebzzry_ has quit [Ping timeout: 264 seconds]
ebzzry_ has joined #lisp
Bike has joined #lisp
Necktwi has joined #lisp
cyberlard has quit [Ping timeout: 246 seconds]
devrtz has joined #lisp
ebzzry_ has quit [Read error: Connection reset by peer]
EvW has joined #lisp
<beach>
Good morning everyone!
<Josh_2>
Mornin beach :)
oxum has joined #lisp
oxum has quit [Remote host closed the connection]
<Bike>
good morning.
oxum has joined #lisp
<iAmDecim>
How hard do you think it would be to make a modern web server in lisp?
<iAmDecim>
I’ve noticed those haven’t been touched in a long time. I was actually coming to Common Lisp but the servers available scared me a little
<no-defun-allowed>
What constitutes "modern" for you?
* beach
was just about to ask the same question.
<iAmDecim>
Http/2 for starters
<iAmDecim>
Also from a layman’s view it seems speed isn’t up to par with say immutant/http-kit in clojure
<Josh_2>
did you look at woo?
<iAmDecim>
And I may be completely wrong. I’m not all that experienced but it seems they are a little behind
<no-defun-allowed>
Which are you comparing to?
pnq has joined #lisp
<no-defun-allowed>
Hunchentoot is a tad slow, but I think it's excusable because it is also very dynamic and flexible.
<iAmDecim>
Part of my question was I was trying to decide if I should try to make one partially for my own learning
<iAmDecim>
no-defun-allowed: ahh ok so a library you can plug in. That could be helpful
<beach>
I think that's an excellent idea.
<iAmDecim>
I’m coming from clojure(no expert there) but I did like what I saw from reading half of pcl. In fact it made clojure more clear
<Josh_2>
Imagine Hunchentoot, but with http2
<Josh_2>
sounds great :D
<no-defun-allowed>
In my opinion, HTTP/2 seems more difficult to implement than HTTP/1
<iAmDecim>
no-defun-allowed: more than likely but how much so?
lemoinem has quit [Read error: Connection reset by peer]
lemoinem has joined #lisp
<no-defun-allowed>
I don't know, I haven't written proper implementations of either. (My lparallel-backed test implementation of HTTP/1 was faster than I could get Node to go, for the record.)
akoana has left #lisp ["Leaving"]
<iAmDecim>
no-defun-allowed: it’s on github?
Burleigh has quit [Remote host closed the connection]
<no-defun-allowed>
Still, I would guess it could take about 5x the time to write a HTTP/2 implementation? HTTP/1 has some weird kludges like flipping between reading octets and characters, but otherwise it's not multiplexed and mostly text, which is easy to debug.
<no-defun-allowed>
No, I can't remember where I saved it.
<iAmDecim>
Sounds scary already. =)
pnq has quit [Remote host closed the connection]
<no-defun-allowed>
Not that it wouldn't be great to have, but it would be difficult.
<iAmDecim>
Hmm well that may be a bit for me to chew just yet.
<beach>
It sounds "messy", but "straightforward", so just a matter of putting in the effort, no? I mean, there are no particular difficult design aspects, are there?
EvW has quit [Ping timeout: 246 seconds]
oni-on-ion has quit [Ping timeout: 268 seconds]
<no-defun-allowed>
My understanding is that HTTP/2 is fully multiplexed, and servers can send content to clients it believes the client will request soon (such as CSS and JavaScript files for a HTML document).
<no-defun-allowed>
s/servers/a server
Bike has quit [Quit: leaving]
<no-defun-allowed>
iAmDecim: The only thing I did was submit a task to lparallel's thread pool with each connection. The rest was pretty normal, except that it used a Node-ish protocol where you write out strings or byte arrays to the connection.
oldtopman has quit [Read error: Connection reset by peer]
oldtopman has joined #lisp
ebzzry_ has quit [Read error: Connection reset by peer]
davepdot_ has quit [Read error: Connection reset by peer]
sarna has quit [Quit: bye]
davepdotorg has joined #lisp
sarna has joined #lisp
ebzzry_ has joined #lisp
dddddd has quit [Ping timeout: 246 seconds]
vlatkoB has joined #lisp
narimiran has joined #lisp
sauvin has joined #lisp
sauvin has quit [Max SendQ exceeded]
stux|RC-only has quit [Quit: Aloha!]
stux|RC-only has joined #lisp
gravicappa has joined #lisp
dale has quit [Quit: My computer has gone to sleep]
sauvin has joined #lisp
sauvin has quit [Max SendQ exceeded]
mono has quit [Remote host closed the connection]
KDr22 has quit [Remote host closed the connection]
KDr22 has joined #lisp
<moon-child>
new to asdf, and lisp in general; how do I integrate asdf with quicklisp?
<Josh_2>
asdf comes with most distros
<Josh_2>
if not all
<moon-child>
I made an asdf system, and I try to ql:quickload in a lisp file, but get an error
<Josh_2>
ah
<moon-child>
ql:quickload works fine at repl
<moon-child>
if I quickload the package I need ahead of time, everything works as I would expect
<Josh_2>
yeh
<Josh_2>
quickload is mostly for repl
<moon-child>
so how should I use quicklisp packages outside of the repl?
<Josh_2>
In other projects?
<no-defun-allowed>
Usually you define an ASDF system, and load that.
<Josh_2>
^
<no-defun-allowed>
Say you have a file foo.lisp, you might write (asdf:define-system :foo :depends-on (:a-dependency :another-dependency ...) :components ((:file "foo"))) in foo.asd
<Josh_2>
if you want to execute your code at terminal then you should load it all up in the repl and then dump the image
<moon-child>
ok
<Josh_2>
then you have an executable
gravicappa has quit [Remote host closed the connection]
<moon-child>
how does that work, by the way? I've been trying to get it to work. I see program-op and entry-point, and uiop:dump-image
<Josh_2>
you dump the image in the state you had it in, and then you can specify a function that is called when the image is executed
<iAmDecim>
For anyone that uses clojure and Common Lisp. Does slime have a feature that displays the result in the editor. Ciders overlay-result feature?
<White_Flame>
result of what? the normal REPL expression? of course
<no-defun-allowed>
In a Common Lisp buffer, (+ 2 2) C-j
<White_Flame>
under the SLIME menu, under Evaluation and Compilation is a bunch of stuff
<White_Flame>
for evaluating a region, a toplevel expression, etc etc
<White_Flame>
the result is normally in the minibuffer
mange has quit [Ping timeout: 264 seconds]
MichaelRaskin has quit [Ping timeout: 258 seconds]
<iAmDecim>
White_Flame: oh ok. I’ll take a look. I’ve just been going through the books I bought. I’ll have to do some tinkering with slime today. I was sure it would exist. I imagine everything in cider they got the idea from slime and have a long ways to go
<no-defun-allowed>
Yes, SLIME exposes Common Lisp's interactive debugger at the least.
sauvin has joined #lisp
orivej has joined #lisp
jackdaniel2 has joined #lisp
Cymew has joined #lisp
jd has joined #lisp
jd has quit [Client Quit]
jd-mob has joined #lisp
jackdaniel2 has quit [Ping timeout: 250 seconds]
MichaelRaskin has joined #lisp
flamebeard has joined #lisp
shka_ has joined #lisp
seisatsu has quit [Quit: ZNC 1.6.5+deb1+deb9u2 - http://znc.in]
shka_ has quit [Read error: Connection reset by peer]
jprajzne has joined #lisp
random-nick has joined #lisp
McParen has joined #lisp
lavaflow has quit [Ping timeout: 264 seconds]
bilegeek has quit [Quit: Leaving]
refpga has joined #lisp
v88m has quit [Ping timeout: 256 seconds]
oxum has quit [Remote host closed the connection]
amerlyq has joined #lisp
lanu has joined #lisp
lanu has quit [Client Quit]
karlosz has quit [Quit: karlosz]
jd-mob has quit [Read error: Connection reset by peer]
jd-mob2 has joined #lisp
heisig has joined #lisp
jd-mob2 has quit [Read error: Connection reset by peer]
even4void has joined #lisp
jd-mob has joined #lisp
Duuqnd has joined #lisp
vhost- has quit [Ping timeout: 264 seconds]
rwcom has joined #lisp
jd-mob has quit [Read error: Connection reset by peer]
oxum has joined #lisp
oxum has quit [Remote host closed the connection]
oxum has joined #lisp
jd-mob has joined #lisp
patrixl has quit [Read error: Connection reset by peer]
patrixl has joined #lisp
jd-mob has quit [Read error: Connection reset by peer]
donotturnoff has joined #lisp
pmden has joined #lisp
Duuqnd has quit [Remote host closed the connection]
Duuqnd has joined #lisp
arnaudga has joined #lisp
Duuqnd is now known as Guest15040
Guest15040 has quit [Client Quit]
Duuqnd_ has joined #lisp
Duuqnd_ has quit [Remote host closed the connection]
<no-defun-allowed>
Does anyone else seem to get frequently bitten by DOLIST, LOOP, and some other iterating forms changing bindings instead of creating them?
v88m has joined #lisp
<Shinmera>
I expect them to do it
<Shinmera>
But sure, sometimes one forgets.
<no-defun-allowed>
The two times I can remember making closures in an iteration form, I have done that. Maybe I didn't remember the others because they weren't problematic, though.
<phoe>
no-defun-allowed: changing? what do you mean?
<phoe>
do you mean mutating or shadowing?
<no-defun-allowed>
Mutating.
<phoe>
could you give an example?
shka_ has joined #lisp
<no-defun-allowed>
Say, if (dolist (x xs) b) was implemented as (prog* ((step xs) (x (car step)) loop (when (null step) (return)) b (setf step (cdr step) x (car step)) (go loop)) or something like that, it would be mutating the binding of X.
<shka_>
hello dear lispers
oxum has quit [Remote host closed the connection]
<shka_>
when should i use cl:rational and when cl:rationalize?
<no-defun-allowed>
A Common Lisp implementation is allowed to do that, or something more like (prog ((step xs)) loop (when (null step) (return)) (let ((x (car xs))) b) (setf step (cdr step)) (go loop)) which creates new bindings for X.
<pjb>
iAmDecim: (+ 1 2) C-u C-x C-e
<shka_>
clhs states that rationalize gives approximation +/- machine epsilon
<shka_>
however, does this makes rationalize faster then rational?
<shka_>
in practice
<pjb>
iAmDecim: C-x C-e is usually bound to slime-eval-last-expression in lisp-mode.
<pjb>
iAmDecim: when prefixed with C-u, it inserts the result at the point.
<pjb>
shka_: clhs rational says: If number is a float, rational returns a rational that is mathematically equal in value to the float. rationalize returns a rational that approximates the float to the accuracy of the underlying floating-point representation.
<pjb>
It's not a question of speed, but of semantics.
<phoe>
no-defun-allowed: I never got bitten by that, I don't remember any issue like that
<aeth>
no-defun-allowed: you can see the difference by creating a closure each step of the iteration.
<no-defun-allowed>
shka_: A quick test with (the-cost-of-nothing:bench (rational/rationalize (the-cost-of-nothing:touch pi))) suggests RATIONAL is about 23 times faster.
<no-defun-allowed>
Granted, that is a worst-case scenario in some ways.
<iAmDecim>
pjb: sweet. That sounds exactly like what I’m looking for. I’ll be home in a few to do some playing
<shka_>
wow, ok
<shka_>
interesting
<no-defun-allowed>
aeth: That's how I got bitten in the backside by it.
<shka_>
no-defun-allowed: you tested that on the SBCL is presume?
<no-defun-allowed>
Yeah.
<aeth>
no-defun-allowed: A mutation means all the closures refer to the same, final value like 11 11 11 11... New bindings means that the closures all refer to their original iteration, like 0 1 2 3 4 5...
<aeth>
The only real way to see, afaik
<no-defun-allowed>
Yes, that's why I asked.
<aeth>
The real fun part is that the final value is probably (but not necessarily) 1 more than what you think the final value is... I say "not necessarily" because it depends on the semantics of the test
<aeth>
So there's actually at least 3 possibilities.
<no-defun-allowed>
...though my problems arose with LOOPing over a list, which usually is expanded to something that mutates bindings.
<aeth>
oh LOOP is even weirder
<shka_>
no-defun-allowed: my basic problem here is that i can't seem to understand why both rational and rationalize exist
<aeth>
the hyperspec has it
<aeth>
(rational .1) could be 13421773/134217728 and (rationalize .1) is 1/10
<aeth>
RATIONAL gives you what it is, RATIONALIZE gives you what you probably want it to be
shidima has joined #lisp
<iAmDecim>
Just focus on the word choices. The latter is a verb so it’s acting out for you opposed to an actual rational
jd-mob has joined #lisp
jd-mob has quit [Read error: Connection reset by peer]
ebzzry_ has quit [Read error: Connection reset by peer]
<phoe>
oooh, you mean *this*
<phoe>
no-defun-allowed: so you close over loop variables and have them mutated by the iteration
<no-defun-allowed>
Yeah.
<shka_>
aeth: ok?
<shka_>
i guess
<aeth>
shka_: remember that it probably looks like 1010100101010010101010000100110111 (pretend that's a correct length) and so it is necessarily a rational number already
<flip214>
trying (rationalize pi) gives me 245850922/78256779
<aeth>
we use them to represent reals, but they're not
<flip214>
that looks like a SHORT-FLOAT conversion...
<aeth>
flip214: no
<aeth>
flip214: (coerce 245850922/78256779 'double-float) and pi both print to 3.141592653589793d0 for me. Compare with (coerce pi 'single-float) which to me prints as 3.1415927 and then if you do (coerce (coerce pi 'single-float) 'double-float) you get 3.1415927410125732d0
<flip214>
aeth: 78256779 only has 27 bits, so that being used to represent a double-float with >40 bits mantissa seems lucky
<aeth>
and (rationalize (coerce pi 'single-float)) => 93343/29712
<shka_>
aeth: ok, thanks for explanation
<shka_>
this makes more sense to me now
ealfonsoe has joined #lisp
<aeth>
flip214: there is some luck involved. What I just shows prints as 3.1415253
<aeth>
(when FLOATifid again)
heisig has quit [Remote host closed the connection]
_heisig has joined #lisp
space_otter has quit [Remote host closed the connection]
ealfonsoe has quit [Ping timeout: 246 seconds]
shidima has quit [Remote host closed the connection]
jprajzne has quit [Quit: jprajzne]
jprajzne has joined #lisp
logicmoo has joined #lisp
jfb4_ has joined #lisp
nowhere_man has quit [Ping timeout: 272 seconds]
quantico has joined #lisp
bars0_ has joined #lisp
jprajzne has quit [Client Quit]
jprajzne has joined #lisp
omtrent has joined #lisp
<no-defun-allowed>
Hm, my issue noting a copy-paste mistake on safe-queue hasn't been noticed for about 6 months now. What should I do about it?
<no-defun-allowed>
When I had to wait six months last time, I just pinged the person by @name and it was responded to quickly, I guess.
dlowe_ has joined #lisp
jfb4 has quit [*.net *.split]
bars0 has quit [*.net *.split]
dlowe has quit [*.net *.split]
zaquest has quit [*.net *.split]
quantico_ has quit [*.net *.split]
dmiles has quit [*.net *.split]
PuercoPope has quit [*.net *.split]
ravndal has quit [*.net *.split]
hiroaki has quit [*.net *.split]
Intensity has quit [*.net *.split]
hiroaki has joined #lisp
zaquest has joined #lisp
<phoe>
say "bump" in the thread
<phoe>
in the worst case, just submit the PR
ebzzry_ has joined #lisp
lonjil has quit [Quit: No Ping reply in 180 seconds.]
<no-defun-allowed>
Right then.
lonjil has joined #lisp
varjag has joined #lisp
nowhere_man has joined #lisp
donotturnoff has quit [Quit: Leaving]
donotturnoff has joined #lisp
flazh has quit [Read error: Connection reset by peer]
davepdotorg has quit [Remote host closed the connection]
davepdotorg has joined #lisp
flazh has joined #lisp
lonjil has quit [Client Quit]
lonjil has joined #lisp
_heisig is now known as heisig
vlatkoB has quit [Remote host closed the connection]
vlatkoB has joined #lisp
sysz has joined #lisp
sysz has quit [Client Quit]
oxum has quit [Remote host closed the connection]
arnaudga has quit [Ping timeout: 272 seconds]
thunderstruck has joined #lisp
davepdot_ has joined #lisp
davepdotorg has quit [Read error: Connection reset by peer]
jd-mob has joined #lisp
jd-mob has quit [Read error: Connection reset by peer]
oxum has joined #lisp
MichaelRaskin has quit [Quit: MichaelRaskin]
ljavorsk has joined #lisp
Krystof has quit [Ping timeout: 258 seconds]
<no-defun-allowed>
That worked again. Does GitHub not notify people when someone creates an issue or pull request?
iAmDecim has quit []
iAmDecim has joined #lisp
<phoe>
It notifies them! It's people who forget about notifications though.
<phoe>
I last encountered then when I noticed my PR from like a year ago that I made to pgloader and then forget to clean up and merge.
<no-defun-allowed>
Bummer.
<Shinmera>
I try to stay on top of issues and prs but sometimes I just can't be bothered to deal with it at the moment, and then it gets lost in time.
ebzzry_ has quit [Read error: Connection reset by peer]
flazh has quit [Read error: Connection reset by peer]
flazh has joined #lisp
nowhereman has joined #lisp
nowhere_man has quit [Ping timeout: 264 seconds]
narimiran has quit [Ping timeout: 250 seconds]
dlowe_ has left #lisp [#lisp]
dlowe has joined #lisp
prince1 has quit [Ping timeout: 250 seconds]
jd-mob has joined #lisp
nowhereman has quit [Ping timeout: 246 seconds]
jd-mob has quit [Read error: Connection reset by peer]
nowhereman has joined #lisp
trocado has quit [Ping timeout: 250 seconds]
McParen has quit [Quit: Hey! Where'd my controlling terminal go?]
jprajzne has quit [Quit: jprajzne]
ebzzry_ has joined #lisp
jprajzne has joined #lisp
jprajzne has quit [Client Quit]
jprajzne has joined #lisp
Lord_of_Life_ has joined #lisp
jd-mob has joined #lisp
jd-mob has quit [Client Quit]
Lord_of_Life has quit [Ping timeout: 250 seconds]
Lord_of_Life_ is now known as Lord_of_Life
xkapastel has joined #lisp
<flip214>
I noticed that when you get a repo transferred you're not automatically subscribed - and a few similar cases where you wouldn't be notified about issues and PRs.
jprajzne has quit [Quit: jprajzne]
jprajzne has joined #lisp
vaporatorius has joined #lisp
pmden has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
pmden has joined #lisp
even4void has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ArthurStrong has joined #lisp
jprajzne has quit [Client Quit]
jprajzne has joined #lisp
Krystof has joined #lisp
davepdotorg has joined #lisp
davepdo__ has joined #lisp
davepdot_ has quit [Ping timeout: 264 seconds]
davepdotorg has quit [Ping timeout: 250 seconds]
ggole has joined #lisp
iAmDecim has quit [Quit: WeeChat 1.9]
gko_ has joined #lisp
iAmDecim has joined #lisp
narimiran has joined #lisp
<flip214>
when catching an UNDEFINED-FUNCTION condition, is there some compatible way to get at the name? SBCL has a SB-KERNEL::NAME slot in the condition, is there some trivial- library?
FreeBirdLjj has quit [Read error: Connection timed out]
lavaflow has joined #lisp
FreeBirdLjj has joined #lisp
h11 has joined #lisp
FreeBirdLjj has quit [Remote host closed the connection]
igemnace has joined #lisp
prince1 has joined #lisp
grabarz has quit [Ping timeout: 246 seconds]
prince1 has quit [Ping timeout: 264 seconds]
dale_ has joined #lisp
oxum has joined #lisp
dale_ is now known as dale
shka_ has joined #lisp
nowhere_man has joined #lisp
davepdot_ has quit [Remote host closed the connection]
davepdotorg has joined #lisp
tirrho has joined #lisp
davepdot_ has joined #lisp
nonlinear[m] has quit [Ping timeout: 245 seconds]
davepdotorg has quit [Ping timeout: 250 seconds]
oxum has quit [Ping timeout: 250 seconds]
oni-on-ion has joined #lisp
nonlinear[m] has joined #lisp
sjl_ has joined #lisp
zaquest has quit [Remote host closed the connection]
_whitelogger has joined #lisp
ljavorsk has quit [Remote host closed the connection]
ljavorsk has joined #lisp
tirrho has quit [Ping timeout: 264 seconds]
oxum has joined #lisp
Bike has quit [Ping timeout: 250 seconds]
davepdot_ has quit [Remote host closed the connection]
davepdotorg has joined #lisp
lemoinem has quit [Killed (barjavel.freenode.net (Nickname regained by services))]
lemoinem has joined #lisp
slyrus__ has joined #lisp
EvW1 has joined #lisp
slyrus_ has quit [Ping timeout: 256 seconds]
luni has quit [Remote host closed the connection]
trocado has joined #lisp
even4void has joined #lisp
heisig has quit [Quit: Leaving]
gioyik has joined #lisp
oni-on-ion has quit [Ping timeout: 240 seconds]
ebzzry_ has quit [Ping timeout: 250 seconds]
ebzzry_ has joined #lisp
flamebeard has quit []
Nilby has quit [Remote host closed the connection]
refpga has quit [Remote host closed the connection]
grabarz has joined #lisp
cg505 has quit [Ping timeout: 258 seconds]
trocado has quit [Ping timeout: 264 seconds]
oxum has quit [Ping timeout: 250 seconds]
KDr22 has quit [Remote host closed the connection]
oxum has joined #lisp
KDr22 has joined #lisp
ljavorsk has quit [Ping timeout: 250 seconds]
ggole has quit [Quit: Leaving]
ebzzry_ has quit [Read error: Connection reset by peer]
vhost- has joined #lisp
vhost- has joined #lisp
even4void has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
prince1 has joined #lisp
gravicappa has joined #lisp
gko_ has quit [Ping timeout: 250 seconds]
ArthurStrong has quit [Ping timeout: 264 seconds]
oxum has quit [Quit: Leaving...]
xkapastel has quit [Quit: Connection closed for inactivity]
prince1 has quit [Ping timeout: 265 seconds]
ArthurStrong has joined #lisp
Kemwer has joined #lisp
Bike has joined #lisp
xkapastel has joined #lisp
cg505 has joined #lisp
even4void has joined #lisp
gioyik has quit [Quit: WeeChat 2.7.1]
shidima has joined #lisp
KDr22 has quit [Remote host closed the connection]
KDr22 has joined #lisp
KDr22 has quit [Remote host closed the connection]
KDr22 has joined #lisp
KDr23 has joined #lisp
KDr22 has quit [Ping timeout: 256 seconds]
varjag has quit [Read error: Connection reset by peer]
varjag has joined #lisp
EvW1 has quit [Ping timeout: 246 seconds]
varjagg has joined #lisp
v_m_v has joined #lisp
varjag has quit [Ping timeout: 250 seconds]
tirrho has joined #lisp
sarna has quit [Quit: bye]
davepdot_ has joined #lisp
sarna has joined #lisp
v_m_v has quit [Remote host closed the connection]
davepdotorg has quit [Ping timeout: 264 seconds]
davepdot_ has quit [Remote host closed the connection]
pmden has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
tirrho has quit [Remote host closed the connection]
whiteline has quit [Remote host closed the connection]
even4void has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
whiteline has joined #lisp
william1_ has joined #lisp
v_m_v has joined #lisp
v_m_v has quit [Remote host closed the connection]
v_m_v has joined #lisp
v_m_v has quit [Ping timeout: 250 seconds]
davepdotorg has joined #lisp
knicklux has joined #lisp
pyc has joined #lisp
clothespin has joined #lisp
<pyc>
Hi Everyone! We are starting a special interest group to discuss mathematics and computer science literature. We plan to have web-based meetings for knowledge sharing sessions. Lisp, Fortran, Logo, BASIC, etc. are on-topic too. Please /join #euclidpoint if you're interested.
davepdotorg has quit [Ping timeout: 246 seconds]
CrazyEddy has quit [Ping timeout: 258 seconds]
grabarz has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
orivej has quit [Read error: Connection reset by peer]
orivej has joined #lisp
hlavaty has joined #lisp
karlosz has joined #lisp
davepdotorg has joined #lisp
davepdotorg has quit [Ping timeout: 246 seconds]
cosimone has quit [Remote host closed the connection]
sauvin has quit [Read error: Connection reset by peer]
cosimone has joined #lisp
hlavaty has quit [Remote host closed the connection]
<dlowe>
That sounds like nerd gladiator arena to me
pfdietz has quit [Remote host closed the connection]
knicklux has quit [Ping timeout: 246 seconds]
grabarz has joined #lisp
shidima has quit [Remote host closed the connection]
shidima has joined #lisp
shka_ has quit [Ping timeout: 264 seconds]
vivit has joined #lisp
vivit has quit [Changing host]
vivit has joined #lisp
<vivit>
Is there a library that provides abstraction for nested iteration?
<vivit>
If I want to use iter to loop over a two-dimensional array, for example, I have to write two nested loops. That creates a lot of code duplication. Is there a library that simplifies this?
knicklux has joined #lisp
<dlowe>
vivit: if you want to loop over a two-dimensional array, you can use row-major-aref to use a single loow
z147 has joined #lisp
<dlowe>
*loop
<sjl_>
iterate is extensible enough to allow you to write a nested iteration construct yourself, but doesn't provide one by default
<dlowe>
row-major-aref will also allow you to loop over n-dimensional arrays
<dlowe>
however, it's hard to see how a two loops would create massive amounts of code duplication
v88m has quit [Remote host closed the connection]
<dlowe>
wouldn't it just be (loop for y below height do (loop for x below width do ...))?
<dlowe>
(or whatever iter thing is in vogue)
<alandipert>
dlowe didn't know about row-major-aref, thanks for that
<sjl_>
loop or dotimes or whatever are okay if you just want to iterate for side effects. If you want to :collect or whatever then you need to bubble the results up through the intermediate loops.
<pjb>
and faster too. With loop, you'd have to use append or nconc and destroy it complexity-wise.
<_death>
you may also use displaced arrays, e.g. to flatten an array or work on rows of a matrix
<pjb>
Sometimes you can't.
<pjb>
displacing matrices wouldn't help in multiplying them.
|Pirx| has quit [Remote host closed the connection]
|Pirx| has joined #lisp
vap1 has joined #lisp
prince1 has joined #lisp
<_death>
it could if you have one of them transposed
<moon-child>
is there a way to find the precision of the different floating-point types? I assume single-float and double-float are the same as whatever float and double are in c (ieee 754 32-bit and 64-bit precision). Is that true? What are short-float and long-float?
<jackdaniel>
moon-child: it is not specified whether common lisp floats are ieee 754 compatible (they usually are though)
<splittist>
jackdaniel: the McClim/5 thing looks great.
<jackdaniel>
thank you :)
minion has joined #lisp
specbot has joined #lisp
iAmDecim has joined #lisp
iAmDecim has quit [Ping timeout: 256 seconds]
iAmDecim has joined #lisp
shidima has quit [Remote host closed the connection]
shidima has joined #lisp
gareppa has joined #lisp
narimiran has quit [Ping timeout: 250 seconds]
slyrus__ has joined #lisp
slyrus_ has quit [Ping timeout: 264 seconds]
gareppa has quit [Quit: Leaving]
iAmDecim has quit [Ping timeout: 246 seconds]
shangul has quit [Ping timeout: 256 seconds]
knicklux has quit [Ping timeout: 250 seconds]
slyrus_ has joined #lisp
slyrus__ has quit [Ping timeout: 250 seconds]
karlosz has quit [Quit: karlosz]
<moon-child>
Bike: that is helpful. I am confused, though; (float-digits 5.0) returns 24. But wikipedia says 32-bit ieee 754 has a 23-bit mantissa
<Bike>
"The true significand includes 23 fraction bits to the right of the binary point and an implicit leading bit (to the left of the binary point) with value 1, unless the exponent is stored with all zeros."
<moon-child>
oic
<Bike>
i suppose that is what the float-digits page means by "hidden bit"
<Bike>
by the way, even if an implementation didn't use IEEE754, the standard requires (to skip some parts) that a single float has at least 24 significand and 8 exponent bits, and a double has at least 50 significand and 8 exponent, so you should be fairly safe with most things
<Bike>
i don't know if there are any modern lisps that don't use IEEE754 for at least singles and doubles, though
lucasb has quit [Quit: Connection closed for inactivity]
shidima` has joined #lisp
sjl_ has quit [Ping timeout: 264 seconds]
<moon-child>
I care less about minimum precision than maximum precision--want to make sure they're not taking up too much memory
ArthurStrong has quit [Quit: leaving]
shidima has quit [Ping timeout: 250 seconds]
<Bike>
these operators don't reflect memory usage. for example on a 32 bit implementation, single floats will probably be boxed
<moon-child>
but if I have a vector of all float, that can be detected, right?
<aeth>
:element-type 'single-float or :element-type 'double-float
<aeth>
You need to do it manually
<aeth>
(in MAKE-ARRAY)
<aeth>
There's a chance that that implementation still won't optimize it, but that's not an implementation you should be using for this sort of thing, anyway
<moon-child>
I'm probably only supporting sbcl, so yah that's fine
<aeth>
(64-bit) SBCL is pretty smart. You can make your own box for double-floats by keeping them in arrays with element-type double-float
<aeth>
Then as long as they don't leave the function scope, they won't get heap-allocated.
Lycurgus has quit [Remote host closed the connection]
<aeth>
You will have to use type declarations, though.
<aeth>
something like this iirc: (defun foo (a) (declare (type (simple-array double-float (*)) a)) (incf (aref a 0)) a)
<aeth>
if you don't return A at the end, then it will box the result, though, since INCF will implicitly return the number
<moon-child>
ahh, cool
<aeth>
Not every implementation will do this, but every implementation could do this if someone submits patches. Of course, what leaves scope will depend on the implementations. e.g. SBCL will allocate if you print that float with FORMAT, but in theory an implementation might be able to optimize that away, too
<aeth>
In SBCL (declare (optimize (speed 3))) will tell you these things as a note
<Bike>
if you rae using sbcl, you should declare a high optimize level, which will make sbcl spit out a note for everything you're doing suboptimally
<Bike>
it's a lot of output
whiteline has quit [Read error: Connection reset by peer]
vhost- has joined #lisp
vhost- has quit [Changing host]
vhost- has joined #lisp
varjagg has quit [Quit: ERC (IRC client for Emacs 26.1)]
karlosz has joined #lisp
random-nick has quit [Ping timeout: 246 seconds]
gravicappa has quit [Ping timeout: 250 seconds]
iAmDecim has joined #lisp
whiteline has joined #lisp
donotturnoff has quit [Read error: Connection reset by peer]
madage has quit [Remote host closed the connection]
madage has joined #lisp
iAmDecim has quit [Ping timeout: 250 seconds]
prince1 has joined #lisp
iAmDecim has joined #lisp
prince1 has quit [Ping timeout: 250 seconds]
torbo has joined #lisp
CrazyEddy has joined #lisp
iAmDecim has quit [Ping timeout: 250 seconds]
z147 has quit [Quit: z147]
iAmDecim has joined #lisp
trocado has joined #lisp
iAmDecim has quit [Ping timeout: 264 seconds]
grabarz has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
whiteline has quit [Read error: Connection reset by peer]