chiark / gitweb /
doc/: More synopses.
authorMark Wooding <mdw@distorted.org.uk>
Tue, 22 Sep 2015 10:27:11 +0000 (11:27 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Tue, 22 Sep 2015 10:29:38 +0000 (11:29 +0100)
doc/Makefile.am
doc/clang.tex
doc/layout.tex [new file with mode: 0644]
doc/meta.tex [new file with mode: 0644]

index 882f01b2f90ff3c3b9724b2b219d8e3d59efe7d3..4e1f5f3b6b5e80a0a86c7e9444c6ba50765b4d17 100644 (file)
@@ -55,8 +55,8 @@ TEX_FILES             += lispintro.tex
 TEX_FILES              += misc.tex
 TEX_FILES              += parsing.tex
 TEX_FILES              += clang.tex
-##TEX_FILES            += meta.tex
-##TEX_FILES            += layout.tex
+TEX_FILES              += meta.tex
+TEX_FILES              += layout.tex
 ##TEX_FILES            += module.tex
 ##TEX_FILES            += ouptut.tex
 
index 8f3c676e72b47ede374eed10b4157905cc104f00..87a6b6e94fd709f99eadf30d40a733ff2bf2d99d 100644 (file)
@@ -716,6 +716,44 @@ function type is the type of the function's return value.
 
 \subsection{Parsing C types} \label{sec:clang.c-types.parsing}
 
+\begin{describe}{fun}
+    {parse-c-type @<scanner>
+      @> @<result> @<success-flag> @<consumed-flag>}
+\end{describe}
+
+\begin{describe}{fun}
+    {parse-declarator @<scanner> @<base-type> \&key :kernel :abstractp
+      \nlret @<result> @<success-flag> @<consumed-flag>}
+\end{describe}
+
+\subsection{Class types} \label{sec:clang.c-types.class}
+
+\begin{describe}{cls}
+    {c-class-type (simple-c-type) \&key :class :tag :qualifiers :name}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{c-type-class @<class-type> @> @<class>}
+     \dhead{gf}{setf (c-type-class @<class-type>) @<class>}}
+\end{describe*}
+
+\begin{describe}{fun}{find-class-type @<name> @> @<class-type-or-nil>}
+\end{describe}
+
+\begin{describe}{fun}
+    {make-class-type @<name> \&optional @<qualifiers> @> @<class-type>}
+\end{describe}
+
+\begin{describe}{fun}
+    {make-class-type @<name> \&optional @<qualifiers> @> @<class-type>}
+\end{describe}
+
+\begin{describe}{fun}{find-sod-class @<name> @> @<class>}
+\end{describe}
+
+\begin{describe}{fun}{record-sod-class @<class>}
+\end{describe}
+
 %%%--------------------------------------------------------------------------
 \section{Generating C code} \label{sec:clang.codegen}
 
diff --git a/doc/layout.tex b/doc/layout.tex
new file mode 100644 (file)
index 0000000..c4f095a
--- /dev/null
@@ -0,0 +1,458 @@
+%%% -*-latex-*-
+%%%
+%%% Class layout and method combination protocols
+%%%
+%%% (c) 2015 Straylight/Edgeware
+%%%
+
+%%%----- Licensing notice ---------------------------------------------------
+%%%
+%%% This file is part of the Sensble Object Design, an object system for C.
+%%%
+%%% SOD is free software; you can redistribute it and/or modify
+%%% it under the terms of the GNU General Public License as published by
+%%% the Free Software Foundation; either version 2 of the License, or
+%%% (at your option) any later version.
+%%%
+%%% SOD is distributed in the hope that it will be useful,
+%%% but WITHOUT ANY WARRANTY; without even the implied warranty of
+%%% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+%%% GNU General Public License for more details.
+%%%
+%%% You should have received a copy of the GNU General Public License
+%%% along with SOD; if not, write to the Free Software Foundation,
+%%% Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+\chapter{Class layout and method combination}
+
+%%%--------------------------------------------------------------------------
+\section{Class layout protocol} \label{sec:layout.instance}
+
+\begin{describe}{fun}{islots-struct-tag @<class> @> @<string>}
+\end{describe}
+
+\begin{describe}{fun}{ichain-struct-tag @<class> @<chain-head> @> @<string>}
+\end{describe}
+
+\begin{describe}{fun}{ichain-union-tag @<class> @<chain-head> @> @<string>}
+\end{describe}
+
+\begin{describe}{fun}{ilayout-struct-tag @<class> @> @<string>}
+\end{describe}
+
+\begin{describe}{fun}{vtmsgs-struct-tag @<class> @<super> @> @<string>}
+\end{describe}
+
+\begin{describe}{fun}{vtable-union-tag @<class> @<chain-head> @> @<string>}
+\end{describe}
+
+\begin{describe}{fun}{vtable-struct-tag @<class> @<chain-head> @> @<string>}
+\end{describe}
+
+\begin{describe}{fun}{vtable-name @<class> @<chain-head> @> @<string>}
+\end{describe}
+
+\begin{describe}{fun}{message-macro-name @<class> @<entry> @> @<string>}
+\end{describe}
+
+\begin{describe}{cls}{effective-slot () \&key :class :slot :initializer}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{effective-slot-class @<slot> @> @<class>}
+     \dhead{gf}{effective-slot-direct-slot @<slot> @> @<direct-slot>}
+     \dhead{gf}{effective-slot-initializer @<slot> @> @<init-or-nil>}}
+\end{describe*}
+
+\begin{describe}{gf}
+    {find-slot-initializer @<class> @<slot> @> @<init-or-nil>}
+\end{describe}
+
+\begin{describe}{gf}
+    {compute-effective-slot @<class> @<slot> @> @<effective-slot>}
+\end{describe}
+
+\begin{describe}{cls}
+    {sod-class-effective-slot (effective-slot) \\ \ind
+      \&key :class :slot :initializer-function :prepare-function}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{effective-slot-initializer-function @<slot> @> @<function>}
+     \dhead{gf}{effective-slot-prepare-function @<slot> @> @<function>}}
+\end{describe*}
+
+\begin{describe}{cls}{islots () \&key :class :subclass :slots}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{islots-class @<islots> @> @<class>}
+     \dhead{gf}{islots-subclass @<islots> @> @<class>}
+     \dhead{gf}{islots-slots @<islots> @> @<list>}}
+\end{describe*}
+
+\begin{describe}{gf}{compute-islots @<class> @<subclass> @> @<islots>}
+\end{describe}
+
+\begin{describe}{gf}{vtable-pointer () \&key :class :chain-head :chain-tail}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{vtable-pointer-class @<vtable-pointer> @> @<class>}
+     \dhead{gf}{vtable-pointer-chain-head @<vtable-pointer> @> @<class>}
+     \dhead{gf}{vtable-pointer-chain-tail @<vtable-pointer> @> @<class>}}
+\end{describe*}
+
+\begin{describe}{gf}{ichain () \&key :class :chain-head :chain-tail :body}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{ichain-class @<ichain> @> @<class>}
+     \dhead{gf}{ichain-chain-head @<ichain> @> @<class>}
+     \dhead{gf}{ichain-chain-tail @<ichain> @> @<class>}
+     \dhead{gf}{ichain-body @<ichain> @> @<list>}}
+\end{describe*}
+
+\begin{describe}{gf}{compute-ichain @<class> @<chain> @> @<ichain>}
+\end{describe}
+
+\begin{describe}{gf}{ilayout () \&key :class :ichains}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{ilayout-class @<ilayout> @> @<class>}
+     \dhead{gf}{ilayout-ichains @<ilayout> @> @<list>}}
+\end{describe*}
+
+\begin{describe}{gf}{compute-ilayout @<class> @> @<ilayout>}
+\end{describe}
+
+\begin{describe}{cls}
+    {vtmsgs () \&key :class :subclass :chain-head :chain-tail :entries}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{vtmsgs-class @<vtmsgs> @> @<class>}
+     \dhead{gf}{vtmsgs-subclass @<vtmsgs> @> @<class>}
+     \dhead{gf}{vtmsgs-chain-head @<vtmsgs> @> @<class>}
+     \dhead{gf}{vtmsgs-chain-tail @<vtmsgs> @> @<class>}
+     \dhead{gf}{vtmsgs-entries @<vtmsgs> @> @<list>}}
+\end{describe*}
+
+\begin{describe}{cls}
+    {class-pointer () \&key :class :chain-head :metaclass :meta-chain-head}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{class-pointer-class @<class-pointer> @> @<class>}
+     \dhead{gf}{class-pointer-chain-head @<class-pointer> @> @<class>}
+     \dhead{gf}{class-pointer-metaclass @<class-pointer> @> @<class>}
+     \dhead{gf}{class-pointer-meta-chain-head @<class-pointer> @> @<class>}}
+\end{describe*}
+
+\begin{describe}{fun}
+    {make-class-pointer @<class> @<chain-head>
+                        @<metaclass> @<meta-chain-head>
+      @> @<class-pointer>}
+\end{describe}
+
+\begin{describe}{cls}{base-offset () \&key :class :chain-head}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{base-offset-class @<base-offset> @> @<class>}
+     \dhead{gf}{base-offset-chain-head @<base-offset> @> @<class>}}
+\end{describe*}
+
+\begin{describe}{fun}
+    {make-base-offset @<class> @<chain-head> @> @<base-offset>}
+\end{describe}
+
+\begin{describe}{cls}{chain-offset () \&key :class :chain-head :target-head}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{chain-offset-class @<chain-offset> @> @<class>}
+     \dhead{gf}{chain-offset-chain-head @<chain-offset> @> @<class>}
+     \dhead{gf}{chain-offset-target-head @<chain-offset> @> @<class>}}
+\end{describe*}
+
+\begin{describe}{fun}
+    {make-chain-offset @<class> @<chain-head> @<target-head>
+      @> @<chain-offset>}
+\end{describe}
+
+\begin{describe}{gf}{vtable () \&key :class :chain-head :chain-tail :body}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{vtable-class @<vtable> @> @<class>}
+     \dhead{gf}{vtable-chain-head @<vtable> @> @<class>}
+     \dhead{gf}{vtable-chain-tail @<vtable> @> @<class>}
+     \dhead{gf}{vtable-body @<vtable> @> @<list>}}
+\end{describe*}
+
+\begin{describe}{gf}
+    {compute-vtable-items @<class> @<super>
+                          @<chain-head> @<chain-tail>
+                          @<emit-function>}
+\end{describe}
+
+\begin{describe}{gf}{compute-vtable @<class> @<chain> @> @<vtable>}
+\end{describe}
+
+\begin{describe}{gf}{compute-vtables @<class> @> @<list>}
+\end{describe}
+
+%%%--------------------------------------------------------------------------
+\section{Method combination} \label{sec:layout.methods}
+
+\begin{describe}{cls}{effective-method () \&key :message :class}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{effective-method-message @<method> @> @<message>}
+     \dhead{gf}{effective-method-class @<method> @> @<class>}}
+\end{describe*}
+
+\begin{describe}{gf}{message-effective-method-class @<message> @> @<class>}
+\end{describe}
+
+\begin{describe}{gf}{primary-method-class @<message> @> @<class>}
+\end{describe}
+
+\begin{describe}{gf}
+    {compute-sod-effective-method @<message> @<class> @> @<method>}
+\end{describe}
+
+\begin{describe}{gf}{compute-effective-methods @<class> @> @<list>}
+\end{describe}
+
+\begin{describe}{cls}
+    {method-entry () \&key :method :chain-head :chain-tail :role}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{method-entry-effective-method @<method-entry> @> @<method>}
+     \dhead{gf}{method-entry-chain-head @<method-entry> @> @<class>}
+     \dhead{gf}{method-entry-chain-tail @<method-entry> @> @<class>}
+     \dhead{gf}{method-entry-role @<method-entry> @> @<role>}}
+\end{describe*}
+
+\begin{describe}{gf}
+    {make-method-entries @<effective-method> @<chain-head> @<chain-tail>
+      @> @<list>}
+\end{describe}
+
+
+\begin{describe}{gf}{sod-message-argument-tail @<message> @> @<list>}
+\end{describe}
+
+\begin{describe}{gf}{sod-message-no-varargs-tail @<message> @> @<list>}
+\end{describe}
+
+\begin{describe}{gf}{sod-method-function-type @<method> @> @<c-type>}
+\end{describe}
+
+\begin{describe}{gf}{sod-method-next-method-type @<method> @> @<c-type>}
+\end{describe}
+
+\begin{describe}{gf}{sod-method-function-name @<method> @> @<string>}
+\end{describe}
+
+\begin{describe}{fun}{varargs-message-p @<message> @> @<generalized-boolean>}
+\end{describe}
+
+\begin{describe}{gf}{method-entry-function-type @<entry> @> @<c-type>}
+\end{describe}
+
+\begin{describe}{gf}{method-entry-slot-name @<entry> @> @<string>}
+\end{describe}
+
+\begin{describe}{gf}
+    {method-entry-slot-name-by-role @<entry> @<role> @<name> @> @<string>}
+\end{describe}
+
+\begin{describe}{gf}
+    {effective-method-basic-argument-names @<method> @> @<list>}
+\end{describe}
+
+
+
+\begin{describe}{cls}
+    {method-codegen (codegen) \\ \ind
+      \&key :vars :insts :temp-index
+            :message :class :method :target}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{codegen-message @<codegen> @> @<message>}
+     \dhead{gf}{codegen-class @<codegen> @> @<class>}
+     \dhead{gf}{codegen-method @<codegen> @> @<method>}
+     \dhead{gf}{codegen-target @<codegen> @> @<target>}}
+\end{describe*}
+
+\begin{describe*}
+    {\dhead{cls}{convert-to-ilayout-inst (inst)}
+     \dhead{fun}
+       {make-convert-to-ilayout-inst @<class> @<chain-head> @<expr>}}
+  \begin{prog}
+    SOD_ILAYOUT(@<class>, @<chain-head-nick>, @<expr>)
+  \end{prog}
+\end{describe*}
+
+
+\begin{describe}{gf}
+    {compute-effective-method-body @<method> @<codegen> @<target>}
+\end{describe}
+
+\begin{describe}{gf}{simple-method-body @<method> @<codegen> @<target>}
+\end{describe}
+
+\begin{describe}{fun}
+    {invoke-method @<codegen> @<target> @<arguments-tail> @<direct-method>}
+\end{describe}
+
+\begin{describe}{fun}{ensure-ilayout-var @<codegen> @<super>}
+\end{describe}
+
+\begin{describe}{fun}{make-trampoline @<codegen> @<super> @<body-func>}
+\end{describe}
+
+\begin{describe}{gf}{effective-method-function-name @<method> @> @<string>}
+\end{describe}
+
+\begin{describe}{gf}
+    {method-entry-function-name @<method> @<chain-head> @<role> @> @<string>}
+\end{describe}
+
+\begin{describe}{gf}{compute-method-entry-functions @<method> @> @<list>}
+\end{describe}
+
+\begin{describe}{fun}
+    {invoke-delegation-chain @<codegen> @<target> @<basic-tail>
+                             @<chain> @<kernel-func>}
+\end{describe}
+
+\begin{describe}{cls}
+    {basic-message (sod-message) \&key :name :location :class :type}
+\end{describe}
+
+\begin{describe}{cls}
+    {simple-message (basic-message) \&key :name :location :class :type}
+\end{describe}
+
+\begin{describe}{cls}
+    {basic-direct-method (sod-method)
+      \&key :message :location :class :type :body :role}
+\end{describe}
+
+\begin{describe}{gf}{sod-method-role @<method> @> @<role>}
+\end{describe}
+
+\begin{describe}{cls}
+    {daemon-direct-method (basic-direct-method) \\ \ind
+      \&key :message :location :class :type :body :role}
+\end{describe}
+
+\begin{describe}{cls}
+    {delegating-direct-method (basic-direct-method) \\ \ind
+      \&key :message :location :class :type :body :role}
+\end{describe}
+
+\begin{describe}{cls}
+    {basic-effective-method (effective-method) \\ \ind
+      \&key :message :class :around-methods :before-methods :after-methods}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}
+       {effective-method-around-methods @<effective-method> @> @<list>}
+     \dhead{gf}
+       {effective-method-before-methods @<effective-method> @> @<list>}
+     \dhead{gf}
+       {effective-method-after-methods @<effective-method> @> @<list>}
+     \dhead{gf}{effective-method-functions @<effective-method> @> @<list>}}
+\end{describe*}
+
+\begin{describe}{cls}
+    {simple-effective-method (basic-effective-method) \\ \ind
+      \&key :message :class
+            :around-methods :before-methods :after-methods :primary-methods}
+\end{describe}
+
+\begin{describe}{fun}
+    {basic-effective-method-body @<codegen> @<target> @<method> @<body>}
+\end{describe}
+
+\begin{describe}{cls}
+    {standard-message (simple-message) \&key :name :location :class :type}
+\end{describe}
+
+\begin{describe}{cls}
+    {standard-effective-method (simple-effective-method) \\ \ind
+      \&key :message :class
+            :around-methods :before-methods :after-methods :primary-methods}
+\end{describe}
+
+\begin{describe}{cls}
+    {aggregating-message (simple-message)
+      \&key :name :location :class :type :combination}
+\end{describe}
+
+\begin{describe}{gf}
+    {aggregating-message-properties @<message> @<combination> @> @<plist>}
+\end{describe}
+
+\begin{describe}{gf}
+    {compute-aggregating-message-kernel
+      \=@<message> @<combination> @<target> \+ \\
+        @<methods> @<arg-names> \&key}
+\end{describe}
+
+\begin{describe}{gf}
+    {check-aggregating-message-type @<message> @<combination> @<c-type>}
+\end{describe}
+
+\begin{describe}{cls}
+     {aggregating-effective-method (simple-effective-method) \\ \ind
+      \&key :message :class
+            :around-methods :before-methods :after-methods :primary-methods}
+\end{describe}
+
+\begin{describe}{mac}
+    {define-aggregating-method-combination @<combination> \\ \ind\ind
+        ((@<var-name>^*)
+         @[[ :codegen @<codegen-var> @!
+             :methods @<methods-var> @]]) \- \\
+      @[[ \=:properties (@{ (@{ @<name> @! (@[@<keyword>@] @<name>) @}
+                             @<c-type>
+                             @[@<default>
+                               @[@<suppliedp-var>@]@]) @}^*) @! \+ \\
+            :return-type @<c-type> @! \\
+            :around @<around-func> @!
+            :first-method @<first-method-func> @!
+            :method @<method-func> @]]}
+\end{describe}
+
+%%% the method combination story
+%% compute-effective-methods --> compute-sod-effective-method
+
+%% hook-output (basic-effective-method :c)
+%%   basic-effective-method.functions
+%%     compute-method-entry-functions
+%%       compute-effective-method-body
+%%
+%% compute-effective-method-body (simple-effective-method)
+%%   basic-effective-method-body
+%%   simple-method-body (standard-effective-method)
+%%   simple-method-body (aggregating-effective-method)
+%%     message-kernel-function
+
+%%%----- That's all, folks --------------------------------------------------
+
+%%% Local variables:
+%%% mode: LaTeX
+%%% TeX-master: "sod.tex"
+%%% TeX-PDF-mode: t
+%%% End:
diff --git a/doc/meta.tex b/doc/meta.tex
new file mode 100644 (file)
index 0000000..7114312
--- /dev/null
@@ -0,0 +1,288 @@
+%%% -*-latex-*-
+%%%
+%%% Translation-time metaobjects
+%%%
+%%% (c) 2015 Straylight/Edgeware
+%%%
+
+%%%----- Licensing notice ---------------------------------------------------
+%%%
+%%% This file is part of the Sensble Object Design, an object system for C.
+%%%
+%%% SOD is free software; you can redistribute it and/or modify
+%%% it under the terms of the GNU General Public License as published by
+%%% the Free Software Foundation; either version 2 of the License, or
+%%% (at your option) any later version.
+%%%
+%%% SOD is distributed in the hope that it will be useful,
+%%% but WITHOUT ANY WARRANTY; without even the implied warranty of
+%%% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+%%% GNU General Public License for more details.
+%%%
+%%% You should have received a copy of the GNU General Public License
+%%% along with SOD; if not, write to the Free Software Foundation,
+%%% Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+\chapter{Translation-time metaobjects} \label{ch:meta}
+
+%%%--------------------------------------------------------------------------
+\section{Base metaobject classes} \label{sec:meta.classes}
+
+\begin{describe}{cls}
+    {sod-class () \\ \ind
+      \&key \=:name :nick :location :pset \+ \\
+              :superclasses :link :metaclass \\
+              :slots :instance-initializers :class-initializers \\
+              :messages :methods}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{sod-class-name @<class> @> @<string>}
+     \dhead{gf}{sod-class-nickname @<class> @> @<string>}
+     \dhead{gf}{sod-class-direct-superclasses @<class> @> @<list>}
+     \dhead{gf}{sod-class-chain-link @<class> @> @<class-or-nil>}
+     \dhead{gf}{sod-class-metaclass @<class> @> @<metaclass>}
+     \dhead{gf}{sod-class-slots @<class> @> @<list>}
+     \dhead{gf}{setf (sod-class-slots @<class>) @<list>}
+     \dhead{gf}{sod-class-instance-initializers @<class> @> @<list>}
+     \dhead{gf}{setf (sod-class-instance-initializers @<class>) @<list>}
+     \dhead{gf}{sod-class-class-initializers @<class> @> @<list>}
+     \dhead{gf}{setf (sod-class-class-initializers @<class>) @<list>}
+     \dhead{gf}{sod-class-messages @<class> @> @<list>}
+     \dhead{gf}{setf (sod-class-messages @<class>) @<list>}
+     \dhead{gf}{sod-class-methods @<class> @> @<list>}
+     \dhead{gf}{setf (sod-class-methods @<class>) @<list>}}
+\end{describe*}
+
+%% layout protocol
+\begin{describe*}
+    {\dhead{gf}{sod-class-ilayout <class> @> @<ilayout>}
+     \dhead{gf}{sod-class-effective-methods @<class> @> @<list>}
+     \dhead{gf}{sod-class-vtables @<class> @> @<list>}}
+\end{describe*}
+
+\begin{describe}{gf}{guess-metaclass @<class> @> @<metaclass>}
+\end{describe}
+
+\begin{describe}{fun}
+    {make-sod-class @<name> @<superclasses> @<pset> \&optional @<floc>
+      @> @<class>}
+\end{describe}
+
+\begin{describe}{mac}
+    {define-sod-class @<name> (@<superclass>^*) \\ \ind
+      @{ @<keyword> @<value> @}^* \\
+      @<declaration>^* \\
+      @<form>^*}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{lmac}{slot @<name> @<type> @{ @<keyword> @<value> @}^*}
+     \dhead{lmac}{instance-initializer @<nick> @<name>
+                                       @<value-kind> @<value-form>
+                                       @{ @<keyword> @<value> @}^*}
+     \dhead{lmac}{class-initializer @<nick> @<name>
+                                    @<value-kind> @<value-form>
+                                    @{ @<keyword> @<value> @}^*}
+     \dhead{lmac}{message @<name> @<type> @{ @<keyword> @<value> @}^*}
+     \dhead{lmac}{method @<nick> @<name> @<type> @<body>
+                         @{ @<keyword> @<value> @}^*}}
+\end{describe*}
+
+\begin{describe}{fun}
+    {find-superclass-by-nick @<class> @<nick> @> @<superclass>}
+\end{describe}
+
+\begin{describe}{fun}
+    {sod-subclass-p @<class-a> @<class-b> @> @<generalized-boolean>}
+\end{describe}
+
+\begin{describe}{fun}{valid-name-p @<name> @> @<generalized-boolean>}
+\end{describe}
+
+\begin{describe}{fun}{find-root-superclass @<class> @> @<superclass>}
+\end{describe}
+
+\begin{describe}{fun}{find-root-metaclass @<class> @> @<metaclass>}
+\end{describe}
+
+\begin{describe}{cls}{sod-slot () \&key :name :location :pset :class :type}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{sod-slot-name @<slot> @> @<string>}
+     \dhead{gf}{sod-slot-class @<slot> @> @<class>}
+     \dhead{gf}{sod-slot-type @<slot> @> @<c-type>}}
+\end{describe*}
+
+\begin{describe}{gf}
+    {make-sod-slot @<class> @<name> @<type> @<pset> \&optional @<floc>
+      @> @<slot>}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{fun}
+      {find-instance-slot-by-name @<class> @<super-nick> @<slot-name>
+        @> @<slot>}
+     \dhead{fun}
+      {find-class-slot-by-name @<class> @<super-nick> @<slot-name>
+        @> @<slot>}}
+\end{describe*}
+
+\begin{describe}{fun}
+    {find-instance-slot-by-name @<class> @<super-nick> @<slot-name>
+      @> @<slot>}
+\end{describe}
+
+\begin{describe}{cls}
+    {sod-class-slot (sod-slot) \\ \ind
+      \&key :name :location :pset :class :type
+            :initializer-function :prepare-function}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{sod-slot-initializer-function @<slot> @> @<function>}
+     \dhead{gf}{sod-slot-prepare-function @<slot> @> @<function>}}
+\end{describe*}
+
+\begin{describe*}
+    {\dhead{cls}{sod-initializer ()
+       \&key :slot :location :class :value-kind :value-form}
+     \dhead{cls}{sod-instance-initializer (sod-initializer)
+       \&key :slot :location :class :value-kind :value-form}
+     \dhead{cls}{sod-class-initializer (sod-initializer)
+       \&key :slot :location :class :value-kind :value-form}}
+\end{describe*}
+
+\begin{describe*}
+    {\dhead{gf}{sod-initializer-slot @<init> @> @<slot>}
+     \dhead{gf}{sod-initializer-value-kind @<init> @> @<kind>}
+     \dhead{gf}{sod-initializer-value-form @<init> @> @<fragment>}}
+\end{describe*}
+
+\begin{describe*}
+    {\dhead{gf}
+      {make-slot-instance-initializer \=@<class> @<nick> @<name>
+                                        @<value-kind> @<value-form> \+ \\
+                                        @<pset> \&optional @<floc> \-
+        \nlret @<init>}
+     \dhead{gf}
+      {make-slot-class-initializer \=@<class> @<nick> @<name>
+                                     @<value-kind> @<value-form> \+ \\
+                                     @<pset> \&optional @<floc> \-
+        \nlret @<init>}}
+\end{describe*}
+
+\begin{describe}{gf}
+    {make-sod-initializer-using-slot \=@<class> @<slot> @<init-class>
+                                       @<value-kind> @<value-form> \+ \\
+                                       @<pset> \&optional @<floc> \-
+      \nlret @<init>}
+\end{describe}
+
+\begin{describe}{cls}{sod-message () \&key :name :location :class :type}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{sod-message-name @<message> @> @<string>}
+     \dhead{gf}{sod-message-class @<message> @> @<class>}
+     \dhead{gf}{sod-message-type @<message> @> @<c-type>}}
+\end{describe*}
+
+\begin{describe}{gf}
+    {make-sod-message @<class> @<name> @<type> @<pset> \&optional @<floc>
+      @> @<message>}
+\end{describe}
+
+\begin{describe}{gf}{check-message-type @<message> @<type>}
+\end{describe}
+
+\begin{describe}{fun}
+    {find-message-by-name @<class> @<super-nick> @<message-name>
+      @> @<message>}
+\end{describe}
+
+\begin{describe}{cls}
+    {sod-method () \&key :message :location :class :type :body}
+\end{describe}
+
+\begin{describe*}
+    {\dhead{gf}{sod-method-message @<method> @> @<message>}
+     \dhead{gf}{sod-method-class @<method> @> @<class>}
+     \dhead{gf}{sod-method-type @<method> @> @<c-type>}
+     \dhead{gf}{sod-method-body @<method> @> @<fragment-or-nil>}}
+\end{describe*}
+
+\begin{describe}{gf}
+    {make-sod-method \=@<class> @<nick> @<name> @<type> @<body> \+ \\
+                       @<pset> \&optional @<floc> \-
+      \nlret @<method>}
+\end{describe}
+
+\begin{describe}{gf}
+    {make-sod-method-using-message \=@<message> @<class>
+                                     @<type> @<body> \+ \\
+                                     @<pset> \&optional @<floc> \-
+      \nlret @<method>}
+\end{describe}
+
+\begin{describe}{gf}
+    {sod-message-method-class @<message> @<class> @<pset> @> @<method-class>}
+\end{describe}
+
+\begin{describe}{gf}{check-method-type @<method> @<message> @<type>}
+\end{describe}
+
+\begin{describe}{fun}
+    {argument-lists-compatible-p @<message-args> @<method-args>
+      @> @<generalized-boolean>}
+\end{describe}
+
+%%%--------------------------------------------------------------------------
+\section{Class finalization protocol} \label{sec:meta.finalization}
+
+\begin{describe*}
+    {\dhead{gf}{sod-class-precedence-list <class> @> @<list>}
+     \dhead{gf}{sod-class-type @<class> @> @<c-type>}
+     \dhead{gf}{sod-class-chain-head @<class> @> @<class>}
+     \dhead{gf}{sod-class-chain @<class> @> @<list>}
+     \dhead{gf}{sod-class-chains @<class> @> @<list>}
+     \dhead{gf}{sod-class-state @<class> @> @<state>}}
+\end{describe*}
+
+\begin{describe}{gf}{compute-cpl @<class> @> @<list>}
+\end{describe}
+
+\begin{describe}{gf}{compute-chains @<class> @> @<list>}
+\end{describe}
+
+\begin{describe}{gf}{check-sod-class @<class>}
+\end{describe}
+
+\begin{describe}{gf}{finalize-sod-class @<class>}
+\end{describe}
+
+\begin{describe}{fun}{clos-cpl @<class> @> @<list>}
+\end{describe}
+
+\begin{describe}{fun}{dylan-cpl @<class> @> @<list>}
+\end{describe}
+
+\begin{describe}{fun}{c3-cpl @<class> @> @<list>}
+\end{describe}
+
+\begin{describe}{fun}{flavors-cpl @<class> @> @<list>}
+\end{describe}
+
+\begin{describe}{fun}{python-cpl @<class> @> @<list>}
+\end{describe}
+
+\begin{describe}{fun}{l*loops-cpl @<class> @> @<list>}
+\end{describe}
+%%%----- That's all, folks --------------------------------------------------
+
+%%% Local variables:
+%%% mode: LaTeX
+%%% TeX-master: "sod.tex"
+%%% TeX-PDF-mode: t
+%%% End: