GNU bug report logs -
#77058
[PATCH] Add cl-with-accessors
Previous Next
Reported by: Okamsn <okamsn <at> protonmail.com>
Date: Sun, 16 Mar 2025 18:25:02 UTC
Severity: normal
Tags: patch
Done: Stefan Monnier <monnier <at> iro.umontreal.ca>
Bug is archived. No further changes may be made.
Full log
Message #23 received at 77058 <at> debbugs.gnu.org (full text, mbox):
>> You could get away from the need for compile-time visible of classes
>> by switching from cl-symbol-macrolet to a custom expander function
>> (which is how cl-symbol-macrolet itself is implemented), but I was
>> too lazy.
I don't think this comment by Daniel was about your code but about his.
At least, AFAICT, your code already does not need compile-time
visibility of classes (it's not even specific to classes at all).
> I wrote `cl-with-accessors' with `cl-symbol-macrolet' because the
> definition at http://clhs.lisp.se/Body/m_w_acce.htm used
> `symbol-macrolet'. Do you believe that it should be done differently or
> be more like what you wrote?
While it's often simpler to forgo `cl-macrolet` and directly call
`macroexpand-all` instead, the implementation of `cl-symbol-macrolet` is
significantly more delicate, so the use of `cl-symbol-macrolet` is the
right choice here.
> + (_
> + (error "Malformed `cl-with-accessors' binding: %s" b))))
This should be `%S` rather than `%s`.
Stefan
This bug report was last modified 51 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.