[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: MCL 2.0 final defsys package screw
- To: nathan@akbar.teleos.com
- Subject: Re: MCL 2.0 final defsys package screw
- From: bill@cambridge.apple.com (Bill St. Clair)
- Date: Fri, 11 Sep 1992 12:34:32 -0500
- Cc: kab@cambridge.apple.com (Kim Barrett), info-mcl
> Date: Thu, 10 Sep 92 18:09:48 EST
> From: kab@cambridge.apple.com (Kim Barrett)
> To: nathan@akbar.teleos.com
> Subject: Re: MCL 2.0 final defsys package screw
> Cc: info-mcl%cambridge.apple.com@apple.COM
>
> [...]
>
> Another (to me, clearer) way to write it is
>
> (let ((*package* (if package (find-package package) *package*)))
> (load path))
This can get you in trouble if FIND-PACKAGE can't find a package
with the given name and returns NIL. Binding *package* to NIL tends
to make MCL very unhappy. Better would be:
(let ((*package* (if package
(or (find-package package)
(error "There is no package named: ~s" package))
*package*)))
(load path))