[asdf-devel] upgradability with ECL

Robert Goldman rpgoldman at sift.info
Wed Feb 24 13:27:44 UTC 2010


On 2/24/10 Feb 24 -6:02 AM, Tobias C. Rittweiler wrote:
> 
> Current ECL HEAD comes with asdf version "1.604", but trying to load
> upstreams asdf.lisp won't work because of
> 
>   "A package with the name ASDF-EXTENSIONS already exists."
> 
> Indeed, CLHS DEFPACKAGE says
> 
>   If one of the supplied :nicknames already refers to an existing
>   package, an error of type package-error is signaled. 
> 
> 
> In fact, using DEFPACKAGE for upgradability purposes is ill-conceived
> from the beginning because of:
> 
>   If defined-package-name already refers to an existing package, the
>   name-to-package mapping for that name is not changed. If the new
>   definition is at variance with the current state of that package, the
>   consequences are undefined; ...
> 
> And, e.g. the :EXPORT list changed in numerous points in past, and is
> not excluded from changing in the future.
> 
> The portable venue would be not to use DEFPACKAGE but either to define a
> DEFINE-PACKAGE macro on top of the functional layer yourself, or using
> the functional layer directly. Mwahaha. Suckage. :-)

Another alternative would be to rename the package we are using, and
then pass the exported symbols out through the ASDF package name later.
 That would allow us to keep defpackage, which is the preferred API for
this task.

Follow-up question:  why do we need the ASDF-EXTENSIONS nickname?  Can
we sacrifice this instead of giving up DEFPACKAGE?  Is it for backwards
compatibility with some specific, small number of symbols that used to
be in ASDF-EXTENSIONS?  In that case it would seem to me more benign to
use the functional interface to packages to fix the problem, and avoid
using the package nickname.

Best,
r




More information about the asdf-devel mailing list