[pro] Order of package declarations

Bart Botta 00003b at gmail.com
Wed Apr 6 18:52:59 UTC 2011


On Wed, Apr 6, 2011 at 12:12 PM, Daniel Weinreb <dlw at itasoftware.com> wrote:
> Possible approaches:
>
> (1) Too bad; you really do have to load
> the Lisp files that created those internal
> symbols after defining package X and
> before defining package Y.
>
> (2) For Y to export symbols of X that
> X does not export, while being valid
> Common Lisp, is a bad practice.
>

(3) (defpackage :x-and-y-need-refactored (:export :a1 :a2)), then
(:use :x-and-y-need-refactored) in X and Y

(4) (defpackage :x (:import-from :y y::a1 y::a2)), assuming Y isn't
locked on implementations that support that sort of thing

-b-




More information about the pro mailing list