freenode/#lisp - IRC Chatlog
Search
23:32:53
no-defun-allowed
In CL-WHO, it's printed if you give the WHO macro :prologue t from memory, maybe there is something like that?
0:35:49
moldybits
in CLOS, i have a class that no methods specialize on, but i want to handle any attempt of applying any method to it. (defmethod whatever ((x number)) x) (defclass foo () ()) (whatever (make-instance 'foo)) ; instead of erroring i want to intercept this
0:37:24
moldybits
my goal is to have an object that defers every method application and slot-value to another object seamlessly, except for chosen methods/slots that i want to override
0:37:43
no-defun-allowed
(defmethod no-applicable-method :around (gf &rest arguments) (if (find-if (lambda (x) (typep x 'anti-social-class)) arguments) do-something-else (call-next-method))) might work
0:39:31
oni-on-ion
wasn't someone in here looking for something like this recently ? https://github.com/plops/cl-cpp-generator
2:29:09
pjb
moldybits: AFAIK, it's not possible. Remember that methods are attached to generic functions, not to objects or classes.
2:58:10
LdBeth
Is it a good idea to rely on emacs’ font-lock text-property to predicate if a delimiter is in a string so I can ignore it?
3:18:39
LdBeth
I find the cool thing is I can change the display of many )))s to ] without affecting parent matching
3:22:36
LdBeth
ACTION uploaded an image: ima_7a79fe2.jpeg (8KB) < https://matrix.org/_matrix/media/v1/download/matrix.org/kbjWwfdpmsHKlQyBwXnEJHoD >
3:24:35
pjb
LdBeth: this can be done trivially with font-locking. But indeed, the regexp may be complex if you want to avoid strings, (and comments), notably in CL where strings can stand on several lines, and comments can be embedded.
3:32:01
LdBeth
pjb: for my purpose these should be inserted by user and doesn’t mean to be preserved across sessions
3:33:49
pjb
LdBeth: you can let the user type the )))) using paredit, and display them as a single ]