freenode/#lisp - IRC Chatlog
Search
20:13:07
rpg
phoe: It's OK, I just figured it out -- I was having troubles with cl4py with undefined functions. Then I dug around and figured out that macros (for reasons that are obvious when I think about it) are not available
20:16:52
phoe
pve: that'll almost work, lispworks doesn't let you defun on keywords for whatever reason
20:21:29
phoe
I have no idea how you could confuse us two, he's the cooler and smarter one and weighs much less
20:57:10
sgithens
I just noticed that the quickdocs powering the quicklisp search from the quicklist webisite has been shutdown... what is the current suggested way of searching quicklisp modules?
7:42:10
easye
Mornin' Just to confirm an obscure part of our favorite CONS: the only standard way to associate documentation with the MAKE-* constructor created by DEFSTRUCT is to use the DOCUMENTATION SETF expander?
7:44:07
phoe
easye: yes, it seeems that (setf (documentation 'make-foo 'function) "...") is the way to go
7:44:43
beach
easye: It's the way I recommend in other cases as well, since I don't think documentation belongs in the source code.
7:45:20
beach
Documentation is for the user, whereas the person reading the code presumably knows how to use it already, so documentation is noise for the maintainer.
7:45:55
beach
The practice of putting documentation in the source code seems to encourage too brief documentation strings.
7:46:17
easye
Writing as an implementation maintainer, I don't find documentation to be noise at all. I often forget things about something I wrote some time ago.
7:46:36
no-defun-allowed
Does bordeaux-threads define if a thread can release a lock that a different thread acquired? Or, to cut out the middleman, is there an easy to access implementation of a readers-writer lock?
7:46:48
beach
Like SBCL (documentation 'car 'function) => "Return the 1st object in a list." which is incomplete.
7:47:30
beach
easye: I didn't recommend eliminating the documentation. Just putting it in a different place from that of the source code.
7:47:42
easye
But regardless of whether source code should contain documentation, I would argue that ANSI CL could use some way of documenting the constructor that DEFSTRUCT makes in the same form, otherwise such additions tend to get "lost" when moving code around.
7:48:14
easye
Sometimes what you call "documentation", I might soften as "annotation" to indicate that something is better than nothing.
7:48:59
easye
Anyways, beach, it is an interesting, strong position to advocate. It does require some level of tooling to keep the source and the docs in sync as well as docstrings.
7:49:07
phoe
no-defun-allowed: https://github.com/sionescu/bordeaux-threads/blob/master/apiv1/default-implementations.lisp#L120-L122
7:49:23
phoe
"It is an error to call this unless the lock has previously been acquired (and not released) by the same thread."
7:49:43
beach
easye: Yes, and unfortunately we seem to lack good support for my position, at least at the moment.
7:54:13
TMA
beach: It sounds like a sound position to me. Multiline docstrings are bothersome in the code. Single-line ones are not informative enough.
7:54:46
cl-arthur
beach: what improvements/differences do you have in mind? (Or maybe there's some good discussion of emacs' deficiencies somewhere you can link me?)
7:55:16
beach
TMA: Definitely. I sometimes use #.(format nil "..."). That way, I can at least indent the lines correctly, using ~@ to end the preceding ones.
7:56:12
beach
Emacs doesn't really analyze the code very well, so it often can't distinguish between different roles of a symbol.
7:58:49
beach
To get a better analysis, you can invoke the compiler, but then you have to it some key sequence, like C-c C-c. It would be preferable to get feedback sooner, like for each keystroke.
7:59:53
phoe
the recent Online Lisp Meetings talk on Eclector already shows a bit of work that has been done towards that on the reader level, so before the code is read and passed to the compiler
8:00:04
beach
Emacs/SLIME can often indent code sort of OK-ish, but there is no feedback when indentation is bad. Such feedback would catch mistakes like missing parentheses or too many closing parentheses much earlier.
8:01:02
beach
phoe: Sort of. But scymtym also included sneak previews of the next level of processing.
8:01:48
beach
Unfortunately, he sometimes forgot to clearly distinguish between the different levels.
8:03:30
beach
That kind of real-time analysis is highly desirable, and Emacs is totally incapable of doing it.