Re: CLOS / MOP package name
From: Duane Rettig (duane_at_franz.com)
Date: 02/15/05
- Next message: Christophe Rhodes: "Re: CLOS / MOP package name"
- Previous message: Marco Antoniotti: "Re: SHADOW, EXPORT And DEFMACRO"
- In reply to: Bruno Haible: "Re: CLOS / MOP package name"
- Next in thread: Bruno Haible: "Re: CLOS / MOP package name"
- Reply: Bruno Haible: "Re: CLOS / MOP package name"
- Reply: Marco Antoniotti: "Re: CLOS / MOP package name"
- Reply: Mike Thomas: "Re: CLOS / MOP package name"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 15 Feb 2005 08:41:29 -0800
Bruno Haible <bruno@clisp.org> writes:
> Rob Warnock wrote:
> >| (CLOS:METHOD-FUNCTION method)
> >
> > Note that in CMUCL that needs to be PCL:METHOD-FUNCTION,
>
> Yes, and it's annoying that the implementations don't provide a unique
> package name for their MOP implementation.
>
> Allegro: "CLOS"
Note first that the implementation of the MOP is actually internally
implemented in Allegro's EXCL package, because it is just part of
CLOS and is integrated with the rest of the lisp in our general
implementation package. The package which _exports_ the MOP
interface has CLOS as a nicknme, but its actual name is ACLMOP,
to keep from confiscating any generic names (if done carefully,
users can use rename-package to grab nicknames they want to use
for other purposes). The nicknames for the ACLMOP package are
MOP, CLOS (of course), and ACL-MOP (for back-compatibility; some
don't like hyphens in package names for esthetic reasons).
> GNU clisp: "CLOS"
> LispWorks: "CLOS"
I have no problem with CLOS as a name for MOP functions, and we use
it in Allegro CL for backward compatibility for traditional usages
of MOP functions. However, it is ironic that those CLOS names which
are explicitly specified by ANS cannot be homed in a separate CLOS
package, since they are in the Common Lisp package. In our own
source code, we tend to use MOP as the package identifier, as in
(mop:generic-function-methods #'print-object)
> GNU gcl: "PCL"
> CMUCL: "PCL"
> SBCL: "SB-PCL"
PCL is not CLOS, and that is why through the years we took references
to PCL out of our code, as we tried to work toward more CLOS conformance
and MOP agreement.
> OpenMCL: "OPENMCL-MOP"
This would seem like a good package name if CLOS were added as a
nickname.
> It's time for all implementations to support the name "CLOS" as a nickname,
> at least. Otherwise portable code needs to carry around stuff like this
> eternally:
>
> #-(or CLISP ALLEGRO LISPWORKS)
> (let ((packname
> #+SBCL "SB-PCL" ; or "SB-MOP"?
> #+CMU "PCL" ; or "MOP"?
> #+OpenMCL "OPENMCL-MOP" ; or "CCL" ?
> ))
> #+SBCL (unlock-package packname)
> (rename-package packname packname
> (cons "CLOS" (package-nicknames packname))))
I agree. But why CLOS, and not MOP? CLOS (the system) is already
standardized, and is part of Common Lisp, and the interface functions
mentioned in the standard are mandated to be in the Common Lisp package.
The name MOP more closely reflects the intention of those functions
which are not part of Common Lisp but which align themselves to the
MOP.
-- Duane Rettig duane@franz.com Franz Inc. http://www.franz.com/ 555 12th St., Suite 1450 http://www.555citycenter.com/ Oakland, Ca. 94607 Phone: (510) 452-2000; Fax: (510) 452-0182
- Next message: Christophe Rhodes: "Re: CLOS / MOP package name"
- Previous message: Marco Antoniotti: "Re: SHADOW, EXPORT And DEFMACRO"
- In reply to: Bruno Haible: "Re: CLOS / MOP package name"
- Next in thread: Bruno Haible: "Re: CLOS / MOP package name"
- Reply: Bruno Haible: "Re: CLOS / MOP package name"
- Reply: Marco Antoniotti: "Re: CLOS / MOP package name"
- Reply: Mike Thomas: "Re: CLOS / MOP package name"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|