aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorJuanma Barranquero2009-10-09 02:58:57 +0000
committerJuanma Barranquero2009-10-09 02:58:57 +0000
commit310dbb050f266b8542adef11484924e6f619b23c (patch)
tree2850a1dc364921b4cd51dc8e5aabe42eb0dbff79 /doc
parent4f54db4b41893b613d7707e6bb64ccecafe3c91d (diff)
downloademacs-310dbb050f266b8542adef11484924e6f619b23c.tar.gz
emacs-310dbb050f266b8542adef11484924e6f619b23c.zip
* eieio.texi: Fix typos.
Diffstat (limited to 'doc')
-rw-r--r--doc/misc/ChangeLog4
-rwxr-xr-xdoc/misc/eieio.texi56
2 files changed, 32 insertions, 28 deletions
diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog
index 703319269d2..004cafa691d 100644
--- a/doc/misc/ChangeLog
+++ b/doc/misc/ChangeLog
@@ -1,3 +1,7 @@
12009-10-09 Juanma Barranquero <lekktu@gmail.com>
2
3 * eieio.texi: Fix typos.
4
12009-10-07 Chong Yidong <cyd@stupidchicken.com> 52009-10-07 Chong Yidong <cyd@stupidchicken.com>
2 6
3 * cl.texi (Argument Lists): Clarify explicit keyword arguments. 7 * cl.texi (Argument Lists): Clarify explicit keyword arguments.
diff --git a/doc/misc/eieio.texi b/doc/misc/eieio.texi
index 1bb38dfa1e5..d833eb1e0ab 100755
--- a/doc/misc/eieio.texi
+++ b/doc/misc/eieio.texi
@@ -172,7 +172,7 @@ In these examples, @eieio{} automatically examines the class of
172@code{rec}, and ensures that the method defined above is called. If 172@code{rec}, and ensures that the method defined above is called. If
173@code{rec} is some other class lacking a @code{call-record} method, or 173@code{rec} is some other class lacking a @code{call-record} method, or
174some other data type, Emacs signals a @code{no-method-definition} 174some other data type, Emacs signals a @code{no-method-definition}
175error. @ref{Signals}. 175error. @ref{Signals}.
176 176
177@node Introduction 177@node Introduction
178@comment node-name, next, previous, up 178@comment node-name, next, previous, up
@@ -469,7 +469,7 @@ will not be evaluated at instantiation time, and the value in this
469slot will instead be @code{(lambda () some-variablename)}. 469slot will instead be @code{(lambda () some-variablename)}.
470 470
471After a class has been created with @code{defclass}, you can change 471After a class has been created with @code{defclass}, you can change
472that default value with @code{oset-default}. @ref{Accessing Slots}. 472that default value with @code{oset-default}. @ref{Accessing Slots}.
473 473
474@item :type 474@item :type
475An unquoted type specifier used to validate data set into this slot. 475An unquoted type specifier used to validate data set into this slot.
@@ -542,11 +542,11 @@ This options is specific to Emacs, and is not in the CLOS spec.
542 542
543@item :printer 543@item :printer
544This routine takes a symbol which is a function name. The function 544This routine takes a symbol which is a function name. The function
545should accept one argument. The a rgument is the value from the slot 545should accept one argument. The argument is the value from the slot
546to be printed. The function in @code{object-write} will write the 546to be printed. The function in @code{object-write} will write the
547slot value out to a printable form on @code{standard-output}. 547slot value out to a printable form on @code{standard-output}.
548 548
549The output format MUST be something that could in turn be interpreted 549The output format MUST be something that could in turn be interpreted
550with @code{read} such that the object can be brought back in from the 550with @code{read} such that the object can be brought back in from the
551output stream. Thus, if you wanted to output a symbol, you would need 551output stream. Thus, if you wanted to output a symbol, you would need
552to quote the symbol. If you wanted to run a function on load, you 552to quote the symbol. If you wanted to run a function on load, you
@@ -682,7 +682,7 @@ Example of creating an object from a class:
682 682
683@end defun 683@end defun
684 684
685To create an object from a class symbol, use use @code{make-instance}. 685To create an object from a class symbol, use @code{make-instance}.
686 686
687@defun make-instance class &rest initargs 687@defun make-instance class &rest initargs
688@anchor{make-instance} 688@anchor{make-instance}
@@ -700,7 +700,7 @@ for each slot. For example:
700 (make-instance @code{'foo} @code{:slot1} value1 @code{:slotN} valueN) 700 (make-instance @code{'foo} @code{:slot1} value1 @code{:slotN} valueN)
701@end example 701@end example
702 702
703Compatability note: 703Compatibility note:
704 704
705If the first element of @var{initargs} is a string, it is used as the 705If the first element of @var{initargs} is a string, it is used as the
706name of the class. 706name of the class.
@@ -730,7 +730,7 @@ This macro sets the @code{:initform} for @var{slot} in @var{class} to
730@var{value}. 730@var{value}.
731 731
732This allows the user to set both public and private defaults after the 732This allows the user to set both public and private defaults after the
733class has been constructed, and provides a way to to configure the 733class has been constructed, and provides a way to configure the
734default behavior of packages built with classes (the same way 734default behavior of packages built with classes (the same way
735@code{setq-default} does for buffer-local variables). 735@code{setq-default} does for buffer-local variables).
736 736
@@ -817,7 +817,7 @@ slot.
817@end example 817@end example
818 818
819Where each @var{var} is the local variable given to the associated 819Where each @var{var} is the local variable given to the associated
820@var{slot}. A Slot specified without a variable name is given a 820@var{slot}. A slot specified without a variable name is given a
821variable name of the same name as the slot. 821variable name of the same name as the slot.
822 822
823@example 823@example
@@ -1070,13 +1070,13 @@ Will fetch the documentation string for @code{eieio-default-superclass}.
1070@defun class-constructor class 1070@defun class-constructor class
1071Return a symbol used as a constructor for @var{class}. The 1071Return a symbol used as a constructor for @var{class}. The
1072constructor is a function used to create new instances of 1072constructor is a function used to create new instances of
1073@var{CLASS}. This function provides a way to make an object of a class 1073@var{CLASS}. This function provides a way to make an object of a class
1074without knowing what it is. This is not a part of CLOS. 1074without knowing what it is. This is not a part of CLOS.
1075@end defun 1075@end defun
1076 1076
1077@defun object-name obj 1077@defun object-name obj
1078Return a string of the form @samp{#<object-class myobjname>} for @var{obj}. 1078Return a string of the form @samp{#<object-class myobjname>} for @var{obj}.
1079This should look like Lisp symbols from other parts of emacs such as 1079This should look like Lisp symbols from other parts of Emacs such as
1080buffers and processes, and is shorter and cleaner than printing the 1080buffers and processes, and is shorter and cleaner than printing the
1081object's vector. It is more useful to use @code{object-print} to get 1081object's vector. It is more useful to use @code{object-print} to get
1082and object's print form, as this allows the object to add extra display 1082and object's print form, as this allows the object to add extra display
@@ -1155,7 +1155,7 @@ to manage association lists of @eieio{} objects:
1155@defun object-assoc key slot list 1155@defun object-assoc key slot list
1156@anchor{object-assoc} 1156@anchor{object-assoc}
1157Return an object if @var{key} is @dfn{equal} to SLOT's value of an object in @var{list}. 1157Return an object if @var{key} is @dfn{equal} to SLOT's value of an object in @var{list}.
1158@var{list} is a list of objects who's slots are searched. 1158@var{list} is a list of objects whose slots are searched.
1159Objects in @var{list} do not need to have a slot named @var{slot}, nor does 1159Objects in @var{list} do not need to have a slot named @var{slot}, nor does
1160@var{slot} need to be bound. If these errors occur, those objects will 1160@var{slot} need to be bound. If these errors occur, those objects will
1161be ignored. 1161be ignored.
@@ -1309,7 +1309,7 @@ The @code{eieio-instance-inheritor} class works by causing cloned
1309objects to have all slots unbound. This class' @code{slot-unbound} 1309objects to have all slots unbound. This class' @code{slot-unbound}
1310method will cause references to unbound slots to be redirected to the 1310method will cause references to unbound slots to be redirected to the
1311parent instance. If the parent slot is also unbound, then 1311parent instance. If the parent slot is also unbound, then
1312@code{slot-unbound} will signal an an error named @code{slot-unbound}. 1312@code{slot-unbound} will signal an error named @code{slot-unbound}.
1313 1313
1314@node eieio-instance-tracker 1314@node eieio-instance-tracker
1315@section @code{eieio-instance-tracker} 1315@section @code{eieio-instance-tracker}
@@ -1342,7 +1342,7 @@ This may let the garbage collector nab this instance.
1342This convenience function lets you find instances. @var{key} is the 1342This convenience function lets you find instances. @var{key} is the
1343value to search for. @var{slot} is the slot to compare @var{KEY} 1343value to search for. @var{slot} is the slot to compare @var{KEY}
1344against. The function @code{equal} is used for comparison. 1344against. The function @code{equal} is used for comparison.
1345The paramter @var{list-symbol} is the variable symbol which contains the 1345The parameter @var{list-symbol} is the variable symbol which contains the
1346list of objects to be searched. 1346list of objects to be searched.
1347@end deffn 1347@end deffn
1348 1348
@@ -1426,7 +1426,7 @@ access to it.
1426This class is in package @file{eieio-speedbar}. 1426This class is in package @file{eieio-speedbar}.
1427 1427
1428If a series of class instances map to a tree structure, it is possible 1428If a series of class instances map to a tree structure, it is possible
1429to cause your classes to be displayable in Speedbar. @xref{Top,,,speedbar}. 1429to cause your classes to be displayable in Speedbar. @xref{Top,,,speedbar}.
1430Inheriting from these classes will enable a speedbar major display mode 1430Inheriting from these classes will enable a speedbar major display mode
1431with a minimum of effort. 1431with a minimum of effort.
1432 1432
@@ -1519,7 +1519,7 @@ on how speedbar modes work
1519@chapter Browsing class trees 1519@chapter Browsing class trees
1520 1520
1521The command @kbd{M-x eieio-browse} displays a buffer listing all the 1521The command @kbd{M-x eieio-browse} displays a buffer listing all the
1522currently loaded classes in emacs. The classes are listed in an 1522currently loaded classes in Emacs. The classes are listed in an
1523indented tree structure, starting from @code{eieio-default-superclass} 1523indented tree structure, starting from @code{eieio-default-superclass}
1524(@pxref{Default Superclass}). 1524(@pxref{Default Superclass}).
1525 1525
@@ -1542,19 +1542,19 @@ comes out upside-down.
1542@chapter Class Values 1542@chapter Class Values
1543 1543
1544Details about any class or object can be retrieved using the function 1544Details about any class or object can be retrieved using the function
1545@code{eieio-describe-class} function. Interactively, type in the name of 1545@code{eieio-describe-class}. Interactively, type in the name of
1546a class. In a program, pass it a string with the name of a class, a 1546a class. In a program, pass it a string with the name of a class, a
1547class symbol, or an object. The resulting buffer will display all slot 1547class symbol, or an object. The resulting buffer will display all slot
1548names. 1548names.
1549 1549
1550Additionally, all methods defined to have functionality on this class is 1550Additionally, all methods defined to have functionality on this class
1551displayed. 1551are displayed.
1552 1552
1553@node Default Superclass 1553@node Default Superclass
1554@comment node-name, next, previous, up 1554@comment node-name, next, previous, up
1555@chapter Default Superclass 1555@chapter Default Superclass
1556 1556
1557All defined classes, if created with no specified parent class) will 1557All defined classes, if created with no specified parent class, will
1558inherit from a special class stored in 1558inherit from a special class stored in
1559@code{eieio-default-superclass}. This superclass is quite simple, but 1559@code{eieio-default-superclass}. This superclass is quite simple, but
1560with it, certain default methods or attributes can be added to all 1560with it, certain default methods or attributes can be added to all
@@ -1615,7 +1615,7 @@ This is called from the default @code{constructor}.
1615@node Basic Methods 1615@node Basic Methods
1616@section Basic Methods 1616@section Basic Methods
1617 1617
1618Additional useful methods defined on the base sublcass are: 1618Additional useful methods defined on the base subclass are:
1619 1619
1620@defun clone obj &rest params 1620@defun clone obj &rest params
1621@anchor{clone} 1621@anchor{clone}
@@ -1650,7 +1650,7 @@ to prepend a space.
1650 (cons (format " value: %s" (render this)) strings))) 1650 (cons (format " value: %s" (render this)) strings)))
1651@end example 1651@end example
1652 1652
1653here is what some output could look like: 1653Here is what some output could look like:
1654@example 1654@example
1655(object-print test-object) 1655(object-print test-object)
1656 => #<data-object test-object value: 3> 1656 => #<data-object test-object value: 3>
@@ -1674,7 +1674,7 @@ By implementing one of these methods for a class, you can change the
1674behavior that occurs during one of these error cases, or even ignore 1674behavior that occurs during one of these error cases, or even ignore
1675the error by providing some behavior. 1675the error by providing some behavior.
1676 1676
1677@defun slot-missing ab &rest foo 1677@defun slot-missing object slot-name operation &optional new-value
1678@anchor{slot-missing} 1678@anchor{slot-missing}
1679Method invoked when an attempt to access a slot in @var{object} fails. 1679Method invoked when an attempt to access a slot in @var{object} fails.
1680@var{slot-name} is the name of the failed slot, @var{operation} is the type of access 1680@var{slot-name} is the name of the failed slot, @var{operation} is the type of access
@@ -1721,9 +1721,9 @@ value becomes the return value of the original method call.
1721@anchor{no-next-method} 1721@anchor{no-next-method}
1722Called from @dfn{call-next-method} when no additional methods are available. 1722Called from @dfn{call-next-method} when no additional methods are available.
1723@var{object} is othe object being called on @dfn{call-next-method}. 1723@var{object} is othe object being called on @dfn{call-next-method}.
1724@var{args} are the arguments it is called by. 1724@var{args} are the arguments it is called by.
1725This method signals @dfn{no-next-method} by default. Override this 1725This method signals @dfn{no-next-method} by default. Override this
1726method to not throw an error, and it's return value becomes the 1726method to not throw an error, and its return value becomes the
1727return value of @dfn{call-next-method}. 1727return value of @dfn{call-next-method}.
1728@end defun 1728@end defun
1729 1729
@@ -1826,7 +1826,7 @@ instead pre-builds a method that gets the slot's value.
1826 1826
1827@item :type 1827@item :type
1828Specifier uses the @code{typep} function from the @file{cl} 1828Specifier uses the @code{typep} function from the @file{cl}
1829package. @xref{(cl)Type Predicates}. It therefore has the same issues as 1829package. @xref{(cl)Type Predicates}. It therefore has the same issues as
1830that package. Extensions include the ability to provide object names. 1830that package. Extensions include the ability to provide object names.
1831@end table 1831@end table
1832 1832
@@ -1846,7 +1846,7 @@ except @code{:around}.
1846Calls defgeneric, and accepts most of the expected arguments. Only 1846Calls defgeneric, and accepts most of the expected arguments. Only
1847the first argument to the created method may have a type specifier. 1847the first argument to the created method may have a type specifier.
1848To type cast against a class, the class must exist before defmethod is 1848To type cast against a class, the class must exist before defmethod is
1849called. In addition, the @code{:around} tag is not supported. 1849called. In addition, the @code{:around} tag is not supported.
1850 1850
1851@item call-next-method 1851@item call-next-method
1852Inside a method, calls the next available method up the inheritance tree 1852Inside a method, calls the next available method up the inheritance tree
@@ -1874,10 +1874,10 @@ In @eieio{} tags are in lower case, not mixed case.
1874@chapter Wish List 1874@chapter Wish List
1875 1875
1876@eieio{} is an incomplete implementation of CLOS. Finding ways to 1876@eieio{} is an incomplete implementation of CLOS. Finding ways to
1877improve the compatability would help make CLOS style programs run 1877improve the compatibility would help make CLOS style programs run
1878better in Emacs. 1878better in Emacs.
1879 1879
1880Some important compatability features that would be good to add are: 1880Some important compatibility features that would be good to add are:
1881 1881
1882@enumerate 1882@enumerate
1883@item 1883@item