freenode/#lisp - IRC Chatlog
Search
18:51:51
pxpxp
(if I remove the :add-session-id nil and only (setf hunchentoot:*content-types-for-url-rewrite* nil) once on server startup)
18:53:15
jasom
pxpxp: apparently there's also hunchentoot:*rewrite-for-session-urls* which is probably the better way anyways; I'll try with a quick test
18:59:05
jasom
my quick test was (define-easy-handler (foo :uri "/foo") () (start-session) (redirect "/bar"))
19:52:04
pxpxp
jasom: interesting, it doesn't for me (I already had this line in my initial question)
20:22:49
dbotton__
is there a reason examples of clos use a defgeneric when it is automatically generated on first defmethod?
20:29:38
no-defun-allowed
It's considered better style, and you need a DEFGENERIC to use a non-standard method combination or other settings.
21:42:52
no-defun-allowed
And you usually see DEFGENERIC in definitions of a protocol, as well as defining protocol classes.
21:44:53
Bike
it can vary. beach, for example, likes to have a separate protocol definition, like this https://github.com/robert-strandh/SICL/blob/master/Code/Cleavir/CST-to-AST/generic-functions.lisp
21:48:16
no-defun-allowed
My code usually has protocol files, but they're probably not as clean as beach-style, as it also contains default implementations.
21:48:50
aeth
I usually put defgeneric, defconstant, etc., at the very top of the first relevant file, and then the other non-defun/defmethod defines like deftype/defclass/defstruct right below them
21:55:16
aeth
Often it makes sense to e.g. have a file full of just define-condition or a file full of just defconstant or whatever, but those are usually larger projects, which are rare. I could see myself having a file full of defgeneric, but it would have to be a pretty large application
3:47:45
pillton
I am going to try and be a regular. I miss the discussions and the references that come up.
3:48:16
pillton
e.g. I don't know who recommended "The Art of Multiprocessing Programming" but thank you. I really enjoyed it.
3:49:11
beach
Speaking of books, can I assume you know that phoe's book on the condition system is now (or soon?) available on Apress?
3:51:05
pillton
"It is not easy to understand even for Lispers. I had two attempts that I abandoned."
3:53:52
pillton
The discussion about syntactic, glue and programmatic layers really resonated with me. A lot of what I write follows that design pattern.
4:15:12
borei
quick question - if i do foreign-alloc within lisp function and i don't do foreign-free - im getting memory leak ?
4:20:10
borei
yep, totally agree. im working on the rados client, which depends on librados - which is C-library, so there will be pretty big portion of code dealing with for low level memory operation.
4:20:59
borei
was looking to do pure lisp implementation for the client - but im not there yet. Too complex.