From e4145970f0bd9237566859b52027c29231e383c8 Mon Sep 17 00:00:00 2001 From: pmai <pmai> Date: Thu, 13 Dec 2001 01:04:21 +0000 Subject: [PATCH] Reactivate the definitions of COMPILER-MACROEXPAND-1 and COMPILER-MACROEXPAND, and export them from the EXTENSIONS package, since they are useful debugging aids for compiler-macro writers, even if they could write them on their own, and ANSI CL dropped them. --- code/eval.lisp | 11 ++++++----- code/exports.lisp | 3 ++- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/code/eval.lisp b/code/eval.lisp index 8a0da779a..16c5a4f7c 100644 --- a/code/eval.lisp +++ b/code/eval.lisp @@ -5,7 +5,7 @@ ;;; Carnegie Mellon University, and has been placed in the public domain. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/eval.lisp,v 1.32 2001/03/01 21:45:33 pw Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/eval.lisp,v 1.33 2001/12/13 01:04:20 pmai Exp $") ;;; ;;; ********************************************************************** ;;; @@ -50,7 +50,8 @@ (export '(parse-body find-if-in-closure)) (in-package "EXTENSIONS") -(export '(*top-level-auto-declare*)) +(export '(*top-level-auto-declare* + compiler-macroexpand-1 compiler-macroexpand)) (in-package "KERNEL") (export '(invoke-macroexpand-hook)) @@ -439,8 +440,9 @@ (setf (info function compiler-macro-function name) function) function) -#|These seem to have been dropped from the spec, and we don't use them -internally... +;;; While these have been dropped from the spec, and we don't use them +;;; internally, we implement them anyway, for the benefit of a user +;;; trying to debug his compiler macros. (defun compiler-macroexpand-1 (form &optional env) "If FORM is a function call for which a compiler-macro has been defined, @@ -464,7 +466,6 @@ internally... (frob new-form t) (values new-form expanded))))) (frob form env))) -|# (defun constantp (object &optional environment) "True of any Lisp object that has a constant value: types that eval to diff --git a/code/exports.lisp b/code/exports.lisp index b8d8b6f4b..ed593cfa7 100644 --- a/code/exports.lisp +++ b/code/exports.lisp @@ -5,7 +5,7 @@ ;;; Carnegie Mellon University, and has been placed in the public domain. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/exports.lisp,v 1.186 2001/12/06 19:15:40 pmai Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/exports.lisp,v 1.187 2001/12/13 01:04:21 pmai Exp $") ;;; ;;; ********************************************************************** ;;; @@ -910,6 +910,7 @@ "*PROMPT*" "*REQUIRE-VERBOSE*" "*SETF-FDEFINITION-HOOK*" "*TOP-LEVEL-AUTO-DECLARE*" + "COMPILER-MACROEXPAND-1" "COMPILER-MACROEXPAND" "*UNDEFINED-WARNING-LIMIT*" "ACCEPT-TCP-CONNECTION" "ADD-OOB-HANDLER" "AMBIGUOUS-FILES" "ARGUMENT-LIST" "ASSQ" "BASIC-DEFINITION" "BIGNUMP" "BITP" "CACHE-HASH-EQ" -- GitLab