freenode/#lisp - IRC Chatlog
Search
13:45:14
akater
Fun fact: in ECL, (defclass q nil nil nil) creates a class. In SBCL, error is signalled.
13:48:28
akater
(The error message mentions an initarg while no initarg was actually provided in the form.)
13:48:31
pjb
Something like: Class option nil is not one of (:primary-p :documentation :direct-default-initargs :direct-slots :direct-superclasses :name) ? How is that not very helpful?
13:49:05
akater
I get Invalid initialization argument: NIL in call for class #<STANDARD-CLASS COMMON-LISP:STANDARD-CLASS>.
13:51:30
akater
Yes. The initial form did not contain anything resembling an initialization argument. Also: I only checked in Maxima's ECL on my Android so it might be dated.
14:09:56
imjacobclark
Xach: So I changed my buffer length to 1 and used (print (nth-value 1 (sb-bsd-sockets:socket-receive accepted-socket *receive-buffer* (length *receive-buffer*)))) to view the second return of of the socket-receive function
14:10:22
imjacobclark
underneath the first (print (nth-value 1 (sb-bsd-sockets:socket-receive accepted-socket *receive-buffer* (length *receive-buffer*)))) I have another (print (nth-value 1 (sb-bsd-sockets:socket-receive accepted-socket *receive-buffer* (length *receive-buffer*))))
14:10:36
imjacobclark
the second nth-value prints nothing until the next socket request, but it prints 1, not 0 like you suggegst
14:20:58
Xach
imjacobclark: i suggest it will return 0 when there is no data left to read and the remote end has shut down.
14:25:12
imjacobclark
So I expect that, when running this code: https://gist.github.com/imjacobclark/89723165137efc5e506a4095fcaee7e9 - then doing "nc localhost 8080" - it will prompt for data, I will type "h" [enter] - the server will at first print the length of the sequence "h" [enter] from the socket-recieve and the second socket-recieve will print 0
14:26:44
imjacobclark
once ive done "h" [enter] it removes the ability to input, and on the server I have the line (sb-bsd-sockets:socket-send accepted-socket *response* *response-length*) - so it immediately then says "hi"
14:32:25
Xach
ctrl-d mainly means "push what data is pending" - something newline also does, but includes a newline
14:32:26
imjacobclark
so thats cool - i guess theres nothing wrong with the code, nc is sending [enter] litterally
14:34:22
imjacobclark
Last thing then, so when I have a (print buffer) directly after my socket-receive - it doesn't immediately print, it prints on the next lot of input from the client, its as if socket-receive is causing the loop to short circuit when its done reading - is that expected?
15:32:59
imjacobclark
Xach: Thanks for your help again, I'm now able to read chars sent in, at the min it overwrites the buffer each time, i just need to work out how to adjust the buffer size :) https://github.com/imjacobclark/cl-servers/blob/master/simple-tcp-server.lisp#L20-L26
17:09:44
kenu
Trying to change session-cookie-name in hunchentoot, but what does it exactly mean to specilize generic function and how one do that?
17:17:52
_death
if you have your own acceptor (sub)class, then it's a matter of (defmethod hunchentoot:session-cookie-name ((acceptor my-acceptor)) <code here>)
18:04:09
makomo
can anyone tell me how much was ELS registration the previous few years (preferably for students)?
18:04:31
makomo
i think i heard someone say that it was rather low/symbolic, especially for students
18:05:48
makomo
are such prices the norm? was it previously lower but now that it's colocated with <Programming> it's higher?
18:09:01
MichaelRaskin
In the middle of the page of year 2019 I see «Because the student fee is higher than our normal rate, we will also implement a student refund program when the conference is over, as we did two years ago.»
18:13:51
MichaelRaskin
makomo: It is possible that there is something not completely clear about the exact interaction with the maing organising committee.
18:14:56
jackdaniel
before programming the cost was (if I recall correctly) 40 euro for students and 80 euro for everyone else (early birds)
18:17:00
MichaelRaskin
Anyway, in 2017 I see an announcement of a not-too-complicated procedure with a 50€ refund for students registered for workshop days of Programming and precommitting to attend both days of ELS and signing some paperwork in the ELS room on both days.
18:18:12
MichaelRaskin
Yes, in 2017 (which was probably the first year of once-in-two-years Programming)
19:04:46
Xach
It makes me sad because this is essentially the only Common Lisp conference in the world right now.
19:21:44
margaritamike
Is it harder to do refactoring in Common Lisp than other languages like Java/Haskell?
19:40:30
fiddlerwoaroof
margaritamike: I find that paredit and keyboard macros are a pretty good substitute for the refactoring tools something like IntelliJ provides
19:41:30
fiddlerwoaroof
If you're doing something like renaming a function, there's slime-who-calls ( C-c C-w C-c ) for that
19:57:24
Xach
margaritamike: i think there are fewer tools for automatic widespread refactoring then in other environments.
20:04:55
fiddlerwoaroof
I believe there was something called redshank that provided some minimal refactorings
20:26:14
Xach
I think there are pieces available to build nice refactoring tools but I'm not aware of any completed and available projects along those lines
20:27:00
shka_
well, there is eclector and scymtym (i think?) was doing some really impressive things with it
20:30:41
shka_
anyway, eclector is currently the best base to build such refactoring tools i suspect
20:31:06
scymtym
eclector is all i can offer in that regard for now, sorry (i hope to change that this year)
20:34:50
LdBeth
however I'm not sure if people are ok with using binary file format to store their project
20:37:46
LdBeth
scymtym: I've looked into it, but the approch I choose is using a Concordia/Scribe like markup rather than serialized CLOS object. The format accepts malformed input which could be more pratical in converting exsisted projects.
23:01:46
montxero
Hi, in slime-repl, when the screen is cleared with C-l and a form is evaluated, part of the previously cleard screen comes back moveing the new results lower. How can one avoid this such after clearing the screen, old stuff doesn't come back unless one does C-l or M-v or something similar?
23:36:12
mgsk
I'm trying to write a macro that uses some lexical variable's symbol-value as the value for return-from. Having trouble thinking about compile time vs. run time, and how to do it properly https://gist.github.com/notmgsk/e1ca6f104bce29444c53255f3966db50
23:37:26
pjb
mgsk: learn about lexical variables and special variables (lexical binding vs. dynamic binding).
23:42:00
pjb
Also, you didn't mention that you wanted to work with the name of the function. There might be more than one error per line…
23:44:00
Xach
mgsk: block/return-from and throw/catch might help achieve some kind of flow control there. but it's a little hard to tell from the example.
23:44:44
Xach
It's not too hard to implicitly establish some context that is then implicitly used later but it depends on the context.
23:47:17
pjb
mgsk: https://gist.github.com/notmgsk/e1ca6f104bce29444c53255f3966db50#gistcomment-2833331
0:09:14
fiddlerwoaroof
One thing I've noticed that's a bit surprising about slime-repl-clear-buffer is that it sets *, ** and *** to nil
0:10:29
fiddlerwoaroof
It's a hook "slime-repl-clear-variables" that actually does this, so I guess you could remove that hook to avoid issues
0:12:08
fiddlerwoaroof
This snippet from swank is basically art: https://fwoar.co/pastebin/f16f291e9ce4292ea9fc54caa884d8128caba2c3.lisp.html