emacs-pretest-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

make bootstrap fails on macro expansion


From: Daniel Pfeiffer
Subject: make bootstrap fails on macro expansion
Date: Wed, 1 Sep 2004 10:07:37 +0200

Hi,

on a freshly configured CVS copy I get:

...
Compiling /home/pfeiffer/.emacs.d/cvs/lisp/./mh-e/mh-acros.el
Compiling /home/pfeiffer/.emacs.d/cvs/lisp/./mh-e/mh-alias.el
Source file `/home/pfeiffer/.emacs.d/cvs/lisp/mh-e/mh-e.el' newer than
byte-compiled file
Source file `/home/pfeiffer/.emacs.d/cvs/lisp/mh-e/mh-inc.el' newer than
byte-compiled file
Source file `/home/pfeiffer/.emacs.d/cvs/lisp/mh-e/mh-utils.el' newer than
byte-compiled file
Source file `/home/pfeiffer/.emacs.d/cvs/lisp/mh-e/mh-customize.el' newer than
byte-compiled file
Source file `/home/pfeiffer/.emacs.d/cvs/lisp/mh-e/mh-utils.el' newer than
byte-compiled file
Source file `/home/pfeiffer/.emacs.d/cvs/lisp/mh-e/mh-identity.el' newer than
byte-compiled file

In toplevel form:
mh-e/mh-alias.el:35:1:Error: Invalid function: (macro lambda nil "Macro to
load `cl' if needed.
Some versions of `cl' produce code for the expansion of
(setf (gethash ...) ...) that uses functions in `cl' at run time.  This macro
recognizes that and loads `cl' where appropriate." (if (eq (car (macroexpand
(quote (setf (gethash foo bar) baz)))) (quote cl-puthash)) (\` (progn (require
(quote cl)) (autoload (quote cl-puthash) "cl") (autoload (quote values) "cl")
(autoload (quote copy-tree) "cl"))) (\` (eval-when-compile (require (quote
cl))))))
make[1]: *** [compile] Error 1
make[1]: Leaving directory `/var/home/pfeiffer/.emacs.d/cvs/lisp'

The former module defines an innocent looking (other than that it uselessly
employs backquotes instead of quotes and that the autoloads would seem
redundant after require) macro:

;; The Emacs coding conventions require that the cl package not be required at
;; runtime. However, the cl package in versions of Emacs prior to 21.4 left cl
;; routines in their macro expansions. Use mh-require-cl to provide the cl
;; routines in the best way possible.
(defmacro mh-require-cl ()
  "Macro to load `cl' if needed.
Some versions of `cl' produce code for the expansion of
\(setf (gethash ...) ...) that uses functions in `cl' at run time.  This macro
recognizes that and loads `cl' where appropriate."
  (if (eq (car (macroexpand '(setf (gethash foo bar) baz))) 'cl-puthash)
      `(progn
         (require 'cl)
         ;; Autoloads of CL functions go here...
         (autoload 'cl-puthash "cl")
         (autoload 'values "cl")
         (autoload 'copy-tree "cl"))
    `(eval-when-compile (require 'cl))))

And the latter module fails when compiling a call to this as a function.

coralament / best Grötens / liebe Grüße / best regards / elkorajn salutojn
Daniel Pfeiffer

-- 
lerne / learn / apprends / lär dig / ucz się    Esperanto:
                              http://lernu.net/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]