all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: David Engster <deng@randomsample.de>
To: 9313@debbugs.gnu.org
Subject: bug#9313: 24.0.50; Emacs 24 cannot load byte-compiled code from Emacs 23.3 when using EIEIO's defmethod
Date: Wed, 17 Aug 2011 17:52:03 +0200	[thread overview]
Message-ID: <87wreckpcs.fsf@engster.org> (raw)

This is a very late followup to an older message from emacs-devel,
regarding the issue that Emacs24 after the lexbind merge cannot run
byte-compiled code from Emacs23.3 if that is using EIEIO's 'defmethod':

http://thread.gmane.org/gmane.emacs.devel/138030/focus=78338

In that message Stefan Monnier says that this is considered a bug, so
I'm writing this report. Also, this issue is popping up more frequently
now as people are migrating to Emacs24-bzr, but still have compiled Gnus
or CEDET sources with Emacs23, so I think this should be fixed before a
release.

Here's a recipe:

* Create a file ~/eieio-test/eieio-test.el with the following contents:

 (require 'eieio)

 (defclass someclass ()
   ((astring :initarg :astring
             :initform ""))
   "Some test class.")

 (defmethod somemethod ((arg someclass))
   "Some method."
   (message "Somemethod called."))

 (provide 'eieio-test)

* Byte-compile the file using Emacs 23.3:

  emacs23 --batch -f batch-byte-compile eieio-test.el

* Load Emacs24-bzr with

  emacs24 -Q -L ~/eieio-test

  and evaluate

  (require 'eieio-test)

* The following backtrace will appear:

Debugger entered--Lisp error: (void-function eieio-defmethod)
  (eieio-defmethod (quote somemethod) (quote (((arg someclass)) #[(arg) "\300\301!\207" [message "Somemethod called."] 2 "Some method."])))
  require(eieio-test)
  eval((require (quote eieio-test)) nil)


* Note that the following setups work:

  - Byte compile with Emacs23, require with Emacs23
  - Byte compile with Emacs24, require with Emacs24
  - Require uncompiled el-file.

* This issue is occuring since the lexbind merge.


Cheers,
David





             reply	other threads:[~2011-08-17 15:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-17 15:52 David Engster [this message]
2011-08-22 21:47 ` bug#9313: 24.0.50; Emacs 24 cannot load byte-compiled code from Emacs 23.3 when using EIEIO's defmethod Stefan Monnier
2011-08-23 16:13   ` David Engster
2011-08-23 18:54     ` 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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87wreckpcs.fsf@engster.org \
    --to=deng@randomsample.de \
    --cc=9313@debbugs.gnu.org \
    /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 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.