From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Jambunathan K <kjambunathan@gmail.com>
Cc: Nicolas Goaziou <n.goaziou@gmail.com>,
emacs-orgmode@gnu.org, emacs-devel@gnu.org
Subject: Re: (Emacs 23/24 binary compatibility): defstruct, setf
Date: Tue, 03 Sep 2013 22:57:03 -0400 [thread overview]
Message-ID: <jwv8uzd484p.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <87eh95mwtt.fsf@gmail.com> (Jambunathan K.'s message of "Wed, 04 Sep 2013 02:44:54 +0530")
>>> I think existing *.elc files compiled against Emacs-23.2.1 should load
>>> fine on new Emacs versions.
>> It's indeed an incompatibility I introduced when we switched from CL's
>> setf to gv.el's setf, because the two work in a very different way.
> In simple terms, the problem seems to be a 24.x style `setf' on a 23.x
> defstruct.
More specifically, the setf and the defstruct need to be compiled with
"the same version" (either both cl.el, or both gv.el).
> If we could report on incompatibiliy that would be awesome. Can the
> FIRST EVER setf call make (additional) version checks and report errors.
Does the patch below work for you?
Stefan
=== modified file 'lisp/emacs-lisp/gv.el'
--- lisp/emacs-lisp/gv.el 2013-08-13 02:30:52 +0000
+++ lisp/emacs-lisp/gv.el 2013-09-04 02:56:26 +0000
@@ -102,7 +102,11 @@
;; Follow aliases.
(setq me (cons (symbol-function head) (cdr place))))
(if (eq me place)
- (error "%S is not a valid place expression" place)
+ (error
+ (if (and (symbolp head) (get head 'setf-method))
+ "Incompatible place expression needs recompilation: %S"
+ "%S is not a valid place expression")
+ place)
(gv-get me do)))))))
;;;###autoload
next prev parent reply other threads:[~2013-09-04 2:57 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-03 8:42 (Emacs 23/24 binary compatibility): defstruct, setf Jambunathan K
2013-09-03 19:06 ` Stefan Monnier
2013-09-03 21:14 ` Jambunathan K
2013-09-04 2:57 ` Stefan Monnier [this message]
2013-09-04 4:01 ` Jambunathan K
2013-09-04 20:04 ` Stefan Monnier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jwv8uzd484p.fsf-monnier+emacs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=emacs-devel@gnu.org \
--cc=emacs-orgmode@gnu.org \
--cc=kjambunathan@gmail.com \
--cc=n.goaziou@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).