From: Stefan Monnier <monnier@iro.umontreal.ca>
To: OKAZAKI Tetsurou <okazaki.tetsurou@gmail.com>
Cc: 17024@debbugs.gnu.org
Subject: bug#17024: 24.3.50; eieio-compiled-function-arglist is broken
Date: Tue, 18 Mar 2014 16:21:38 -0400 [thread overview]
Message-ID: <jwvk3br9s3a.fsf-monnier+emacsbugs@gnu.org> (raw)
In-Reply-To: <861ty1m0iq.wl%%5253605f36527b613438407bc85287410830e04c@gmail.com> (OKAZAKI Tetsurou's message of "Mon, 17 Mar 2014 22:13:01 +0900")
> The library `emacs-lisp/eieio-core.el' defines the function
> `eieio-compiled-function-arglist' for compatibility but
> its implementation is broken.
> In *scratch* buffer:
> (eieio-compiled-function-arglist (symbol-function 'make-temp-file))
> => 769
> The function `help-function-arglist' does the right thing.
> (help-function-arglist (symbol-function 'make-temp-file))
> => (arg1 &optional arg2 arg3)
Does the patch below work for you?
And could you explain in which circumstance you've bumped into
this problem?
Stefan
=== modified file 'lisp/emacs-lisp/eieio-core.el'
--- lisp/emacs-lisp/eieio-core.el 2014-01-01 07:43:34 +0000
+++ lisp/emacs-lisp/eieio-core.el 2014-03-18 20:19:52 +0000
@@ -34,18 +34,11 @@
(eval-when-compile (require 'cl)) ;FIXME: Use cl-lib!
;; Compatibility
-(if (fboundp 'compiled-function-arglist)
-
+(defalias 'eieio-compiled-function-arglist
+ (if (featurep 'xemacs)
;; XEmacs can only access a compiled functions arglist like this:
- (defalias 'eieio-compiled-function-arglist 'compiled-function-arglist)
-
- ;; Emacs doesn't have this function, but since FUNC is a vector, we can just
- ;; grab the appropriate element.
- (defun eieio-compiled-function-arglist (func)
- "Return the argument list for the compiled function FUNC."
- (aref func 0))
-
- )
+ #'compiled-function-arglist
+ #'help-function-arglist))
(put 'eieio--defalias 'byte-hunk-handler
#'byte-compile-file-form-defalias) ;;(get 'defalias 'byte-hunk-handler)
prev parent reply other threads:[~2014-03-18 20:21 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-17 13:13 bug#17024: 24.3.50; eieio-compiled-function-arglist is broken OKAZAKI Tetsurou
2014-03-18 20:21 ` Stefan Monnier [this message]
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=jwvk3br9s3a.fsf-monnier+emacsbugs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=17024@debbugs.gnu.org \
--cc=okazaki.tetsurou@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 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.