make funcallable-standard-object a funcallable-standard-class.

- following SBCL's behavior.
parent 8ba6f964
......@@ -842,7 +842,7 @@ present in the \code{sun.net.protocol.dynamic} package. See
dynamically loaded resources for the JVM. The \code{EXT:URL-PATHNAME}
specialization has a corresponding \textsc{URI} whose canonical
representation is defined to be the \code{NAMESTRING} of the
\cpde{CL:PATHNAME}. The \code{EXT:JAR-PATHNAME} extension further
\code{CL:PATHNAME}. The \code{EXT:JAR-PATHNAME} extension further
specializes the the \code{EXT:URL-PATHNAME} to provide access to
components of zip archives.
......@@ -1108,6 +1108,11 @@ method definition (see the section below).
specified in \textsc{(A)MOP}. The symbols are exported from the
package \code{MOP}.
Contrary to the AMOP specification and following \textsc{SBCL}'s lead,
the metaclass \code{funcallable-standard-object} has
\code{funcallable-standard-class} as metaclass instead of
\code{standard-class}.
\subsection{Specializing on Java classes}
There is an additional syntax for specializing the parameter of a
......
......@@ -1465,6 +1465,11 @@ method definition (see the section below).
ABCL implements the metaobject protocol for CLOS as specified in AMOP.
The symbols are exported from the package @code{MOP}.
Contrary to the AMOP specification and following SBCL's lead,
the metaclass @code{funcallable-standard-object} has
@code{funcallable-standard-class} as metaclass instead of
@code{standard-class}.
@node Specializing on Java classes
@subsection Specializing on Java classes
......
......@@ -424,6 +424,14 @@ public class StandardClass extends SlotClass
return c;
}
private static final FuncallableStandardClass addFuncallableStandardClass
(Symbol name, LispObject directSuperclasses)
{
FuncallableStandardClass c = new FuncallableStandardClass(name, directSuperclasses);
addClass(name, c);
return c;
}
// At this point, BuiltInClass.java has not been completely loaded yet, and
// BuiltInClass.CLASS_T is null. So we need to call setDirectSuperclass()
// for STANDARD_CLASS and STANDARD_OBJECT in initializeStandardClasses()
......@@ -466,16 +474,15 @@ public class StandardClass extends SlotClass
// BuiltInClass.FUNCTION is also null here (see previous comment).
// Following SBCL's lead, we make funcallable-standard-object a
// funcallable-standard-class.
public static final StandardClass FUNCALLABLE_STANDARD_OBJECT =
addStandardClass(Symbol.FUNCALLABLE_STANDARD_OBJECT,
addFuncallableStandardClass(Symbol.FUNCALLABLE_STANDARD_OBJECT,
list(STANDARD_OBJECT, BuiltInClass.FUNCTION));
public static final StandardClass GENERIC_FUNCTION =
new FuncallableStandardClass(Symbol.GENERIC_FUNCTION,
list(METAOBJECT, FUNCALLABLE_STANDARD_OBJECT));
static {
addClass(Symbol.GENERIC_FUNCTION, GENERIC_FUNCTION);
}
addFuncallableStandardClass(Symbol.GENERIC_FUNCTION,
list(METAOBJECT, FUNCALLABLE_STANDARD_OBJECT));
public static final StandardClass CLASS =
addStandardClass(Symbol.CLASS, list(SPECIALIZER));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment