Ignore:
Timestamp:
06/14/05 12:06:11 (16 years ago)
Author:
piso
Message:

DEFTYPE: signal an error if NAME is a symbol in the CL package.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/j/src/org/armedbear/lisp/deftype.lisp

    r9375 r9378  
    22;;;
    33;;; Copyright (C) 2004-2005 Peter Graves
    4 ;;; $Id: deftype.lisp,v 1.8 2005-06-14 00:53:33 piso Exp $
     4;;; $Id: deftype.lisp,v 1.9 2005-06-14 12:06:11 piso Exp $
    55;;;
    66;;; This program is free software; you can redistribute it and/or
     
    2121
    2222(defmacro deftype (name lambda-list &rest body)
     23  (when (eq (symbol-package name) +cl-package+)
     24    (error :format-control "Attempt to define ~S, a symbol in the COMMON-LISP package, as a type specifier."
     25           :format-arguments (list name)))
    2326  (check-declaration-type name)
    2427  ;; Optional and keyword parameters default to * rather than NIL.
Note: See TracChangeset for help on using the changeset viewer.