all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* The with-slots macro shadows function names
@ 2017-03-31  6:17 Steven Allen
  2017-03-31 13:58 ` Stefan Monnier
  0 siblings, 1 reply; 2+ messages in thread
From: Steven Allen @ 2017-03-31  6:17 UTC (permalink / raw)
  To: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 331 bytes --]


The following fails to compile on emacs 26 but compiles on emacs 25:

  (lambda (obj) (with-slots (message) obj (message "")))

It fails with:

  Eager macro-expansion failure: (invalid-function ((slot-value object (quote message))))

It appears to be substituting the `message` function name with
`(slot-value object 'message)`.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: The with-slots macro shadows function names
  2017-03-31  6:17 The with-slots macro shadows function names Steven Allen
@ 2017-03-31 13:58 ` Stefan Monnier
  0 siblings, 0 replies; 2+ messages in thread
From: Stefan Monnier @ 2017-03-31 13:58 UTC (permalink / raw)
  To: emacs-devel

>>>>> "Steven" == Steven Allen <steven@stebalien.com> writes:

> The following fails to compile on emacs 26 but compiles on emacs 25:

>   (lambda (obj) (with-slots (message) obj (message "")))

> It fails with:

>   Eager macro-expansion failure: (invalid-function ((slot-value object (quote message))))

> It appears to be substituting the `message` function name with
> `(slot-value object 'message)`.

Please make it a bug report.  It's caused by:

    commit 0d112c00ba0ec14bd3014efcd3430b9ddcfe1fc1
    Author: Paul Pogonyshev <pogonyshev@gmail.com>
    Date:   Sun Mar 12 09:51:23 2017 +0100
    
        Fix bug in generator function with pcase (Bug#26068)
        
        * lisp/emacs-lisp/cl-macs.el (cl--sm-macroexpand): Remove some calls
        to symbol-name.


-- Stefan




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-03-31 13:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-31  6:17 The with-slots macro shadows function names Steven Allen
2017-03-31 13:58 ` Stefan Monnier

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.