From: Mark Wooding Date: Wed, 2 Aug 2017 09:48:54 +0000 (+0100) Subject: doc/concepts.tex: Update `Slot initializers', about class initialization. X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/sod/commitdiff_plain/98da9322baa008239dd78cd2aff71637017592c7 doc/concepts.tex: Update `Slot initializers', about class initialization. The old initialization function has been replaced by a message. --- diff --git a/doc/concepts.tex b/doc/concepts.tex index 64f6320..7702f13 100644 --- a/doc/concepts.tex +++ b/doc/concepts.tex @@ -214,13 +214,13 @@ qualified by the defining class's nickname. \subsubsection{Slot initializers} As well as defining slot names and types, a class can also associate an \emph{initial value} with each slot defined by itself or one of its -subclasses. A class $C$ provides an \emph{initialization function} (see +subclasses. A class $C$ provides an \emph{initialization message} (see \xref{sec:concepts.lifecycle.birth}, and \xref{sec:structures.root.sodclass}) -which sets the slots of a \emph{direct} instance of the class to the correct -initial values. If several of $C$'s superclasses define initializers for the -same slot then the initializer from the most specific such class is used. If -none of $C$'s superclasses define an initializer for some slot then that slot -will be left uninitialized. +whose methods set the slots of a \emph{direct} instance of the class to the +correct initial values. If several of $C$'s superclasses define initializers +for the same slot then the initializer from the most specific such class is +used. If none of $C$'s superclasses define an initializer for some slot then +that slot will be left uninitialized. The initializer for a slot with scalar type may be any C expression. The initializer for a slot with aggregate type must contain only constant