1 ;;;; Mostly this file contains generic functions. The exceptions are hacks.
3 ;;;; This software is part of the SBCL system. See the README file for
6 ;;;; This software is in the public domain and is provided with absolutely no
7 ;;;; warranty. See the COPYING and CREDITS files for more information.
13 (defgeneric accessor-method-slot-definition
(standard-accessor-method))
15 (defgeneric class-can-precede-list
(pcl-class))
17 (defgeneric class-defstruct-constructor
(structure-class))
19 (defgeneric class-defstruct-form
(structure-class))
21 (defgeneric class-direct-subclasses
(class))
23 (defgeneric class-direct-superclasses
(class))
25 (defgeneric class-eq-specializer
(class))
27 (defgeneric class-incompatible-superclass-list
(pcl-class))
29 (defgeneric class-name
(class))
31 (defgeneric class-precedence-list
(pcl-class))
33 (defgeneric class-wrapper
(pcl-class))
35 (defgeneric definition-source
(definition-source-mixin))
37 (defgeneric eql-specializer-object
(eql-specializer))
39 (defgeneric generic-function-declarations
(standard-generic-function))
41 (defgeneric generic-function-method-class
(standard-generic-function))
43 (defgeneric generic-function-method-combination
(standard-generic-function))
45 (defgeneric generic-function-methods
(standard-generic-function))
47 (defgeneric generic-function-name
(standard-generic-function))
49 (defgeneric gf-arg-info
(standard-generic-function))
51 (defgeneric gf-dfun-state
(standard-generic-function))
53 (defgeneric generic-function-initial-methods
(standard-generic-function))
55 (defgeneric long-method-combination-function
(long-method-combination))
57 (defgeneric method-combination-documentation
(standard-method-combination))
59 (defgeneric method-combination-options
(standard-method-combination))
61 (defgeneric method-combination-type-name
(standard-method-combination))
63 (defgeneric method-generic-function
(standard-method))
65 (defgeneric object-plist
(plist-mixin))
67 (defgeneric short-combination-identity-with-one-argument
68 (short-method-combination))
70 (defgeneric short-combination-operator
(short-method-combination))
72 (defgeneric slot-definition-class
(slot-definition))
74 (defgeneric slot-definition-defstruct-accessor-symbol
75 (structure-slot-definition))
77 (defgeneric slot-definition-initargs
(slot-definition))
79 (defgeneric slot-definition-initform
(slot-definition))
81 (defgeneric slot-definition-initfunction
(slot-definition))
83 (defgeneric slot-definition-internal-reader-function
84 (structure-slot-definition))
86 (defgeneric slot-definition-internal-writer-function
87 (structure-slot-definition))
89 (defgeneric slot-definition-location
(standard-effective-slot-definition))
91 (defgeneric slot-definition-name
(slot-definition))
93 (defgeneric slot-definition-info
(effective-slot-definition))
95 (defgeneric slot-definition-readers
(slot-definition))
97 (defgeneric slot-definition-type
(slot-definition))
99 (defgeneric slot-definition-writers
(slot-definition))
101 (defgeneric specializer-object
(class-eq-specializer))
103 (defgeneric specializer-type
(specializer))
107 (defgeneric (setf class-defstruct-constructor
) (new-value structure-class
))
109 (defgeneric (setf class-defstruct-form
) (new-value structure-class
))
111 (defgeneric (setf class-direct-slots
) (new-value slot-class
))
113 (defgeneric (setf class-incompatible-superclass-list
) (new-value pcl-class
))
115 (defgeneric (setf class-name
) (new-value class
))
117 (defgeneric (setf class-slots
) (new-value slot-class
))
119 (defgeneric (setf generic-function-method-class
) (new-value
120 standard-generic-function
))
122 (defgeneric (setf generic-function-method-combination
)
123 (new-value standard-generic-function
))
125 (defgeneric (setf generic-function-declarations
) (new-value
126 standard-generic-function
))
128 (defgeneric (setf generic-function-methods
) (new-value
129 standard-generic-function
))
131 (defgeneric (setf generic-function-name
) (new-value standard-generic-function
))
133 (defgeneric (setf gf-dfun-state
) (new-value standard-generic-function
))
135 (defgeneric (setf generic-function-initial-methods
)
136 (new-value standard-generic-function
))
138 (defgeneric (setf method-generic-function
) (new-value standard-method
))
140 (defgeneric (setf object-plist
) (new-value plist-mixin
))
142 (defgeneric (setf slot-definition-allocation
) (new-value
143 standard-slot-definition
))
145 (defgeneric (setf slot-definition-class
) (new-value slot-definition
))
147 (defgeneric (setf slot-definition-defstruct-accessor-symbol
)
148 (new-value structure-slot-definition
))
150 (defgeneric (setf slot-definition-initargs
) (new-value slot-definition
))
152 (defgeneric (setf slot-definition-initform
) (new-value slot-definition
))
154 (defgeneric (setf slot-definition-initfunction
) (new-value slot-definition
))
156 (defgeneric (setf slot-definition-internal-reader-function
)
157 (new-value structure-slot-definition
))
159 (defgeneric (setf slot-definition-internal-writer-function
)
160 (new-value structure-slot-definition
))
162 (defgeneric (setf slot-definition-location
)
163 (new-value standard-effective-slot-definition
))
165 (defgeneric (setf slot-definition-name
) (new-value slot-definition
))
167 (defgeneric (setf slot-definition-info
) (new-value effective-slot-definition
))
169 (defgeneric (setf slot-definition-readers
) (new-value slot-definition
))
171 (defgeneric (setf slot-definition-type
) (new-value slot-definition
))
173 (defgeneric (setf slot-definition-writer-function
)
174 (new-value effective-slot-definition
))
176 (defgeneric (setf slot-definition-writers
) (new-value slot-definition
))
180 (defgeneric accessor-method-slot-name
(m))
182 (defgeneric class-default-initargs
(class))
184 (defgeneric class-direct-default-initargs
(class))
186 (defgeneric class-direct-slots
(class))
188 (defgeneric class-finalized-p
(class))
190 (defgeneric class-prototype
(class))
192 (defgeneric class-slot-cells
(class))
194 (defgeneric class-slots
(class))
196 (defgeneric compute-class-precedence-list
(root))
198 (defgeneric compute-default-initargs
(class))
200 (defgeneric compute-discriminating-function
(gf))
202 (defgeneric compute-discriminating-function-arglist-info
(generic-function))
204 (defgeneric compute-slots
(class))
206 (defgeneric finalize-inheritance
(class))
208 (defgeneric function-keywords
(method))
210 (defgeneric generic-function-argument-precedence-order
(gf))
212 (defgeneric generic-function-lambda-list
(gf))
214 (defgeneric generic-function-pretty-arglist
(generic-function))
216 (defgeneric gf-fast-method-function-p
(gf))
218 (defgeneric initialize-internal-slot-functions
(slotd))
220 (defgeneric make-instances-obsolete
(class))
222 (defgeneric method-function
(method))
224 (defgeneric method-lambda-list
(m))
226 (defgeneric method-qualifiers
(m))
228 (defgeneric method-specializers
(m))
230 (defgeneric raw-instance-allocator
(class))
232 (defgeneric slot-definition-allocation
(slotd))
234 (defgeneric slots-fetcher
(class))
236 (defgeneric specializer-class
(specializer))
238 (defgeneric specializer-direct-generic-functions
(specializer))
240 (defgeneric specializer-direct-methods
(specializer))
242 (defgeneric specializer-method-table
(specializer))
244 (defgeneric specializer-method-holder
(specializer &optional create
))
246 (defgeneric update-constructors
(class))
248 (defgeneric wrapper-fetcher
(class))
252 (defgeneric add-dependent
(metaobject dependent
))
254 (defgeneric add-direct-method
(specializer method
))
256 (defgeneric add-direct-subclass
(class subclass
))
258 (defgeneric add-method
(generic-function method
))
260 (defgeneric (setf class-slot-cells
) (new-value class
))
262 (defgeneric class-slot-value
(class slot-name
))
264 (defgeneric compatible-meta-class-change-p
(class proto-new-class
))
266 (defgeneric compute-applicable-methods
(generic-function arguments
))
268 (defgeneric compute-applicable-methods-using-classes
269 (generic-function classes
))
271 (defgeneric compute-effective-slot-definition-initargs
(class direct-slotds
))
273 (defgeneric describe-object
(object stream
))
275 (defgeneric direct-slot-definition-class
(class &rest initargs
))
277 (defgeneric effective-slot-definition-class
(class &rest initargs
))
279 (defgeneric make-boundp-method-function
(class slot-name
))
281 (defgeneric make-reader-method-function
(class slot-name
))
283 (defgeneric make-writer-method-function
(class slot-name
))
285 (defgeneric map-dependents
(metaobject function
))
287 (defgeneric parse-specializer-using-class
(generic-function specializer-name
))
289 (defgeneric remove-boundp-method
(class generic-function
))
291 (defgeneric remove-dependent
(metaobject dependent
))
293 (defgeneric remove-direct-method
(specializer method
))
295 (defgeneric remove-direct-subclass
(class subclass
))
297 (defgeneric remove-method
(generic-function method
))
299 (defgeneric remove-reader-method
(class generic-function
))
301 (defgeneric remove-writer-method
(class generic-function
))
303 (defgeneric same-specializer-p
(specl1 specl2
))
305 (defgeneric slot-accessor-function
(slotd type
))
307 (defgeneric slot-accessor-std-p
(slotd type
))
309 ;;; This controls DESCRIBE-OBJECT (SLOT-OBJECT STREAM) behavior.
310 (defgeneric slots-to-inspect
(class object
))
312 (defgeneric unparse-specializer-using-class
(generic-function specializer
))
314 (defgeneric validate-superclass
(class superclass
))
316 (defgeneric invalid-superclass
(class superclass
))
318 (defgeneric (setf documentation
) (new-value slotd doc-type
)
319 (:argument-precedence-order doc-type slotd new-value
))
321 (defgeneric documentation
(slotd doc-type
)
322 (:argument-precedence-order doc-type slotd
))
326 (defgeneric (setf class-slot-value
) (nv class slot-name
))
328 ;;; CMUCL comment (from Gerd Moellmann/Pierre Mai, 2002-10-19):
330 ;;; According to AMOP, COMPUTE-EFFECTIVE-METHOD should return two
331 ;;; values. Alas, the second value is only vaguely described in AMOP,
332 ;;; and, when asked on 2002-10-18, Gregor Kiczales said he couldn't
333 ;;; remember what the second value was supposed to be. So, PCL's
334 ;;; COMPUTE-EFFECTIVE-METHOD returns one value as do Allegro and
336 (defgeneric compute-effective-method
(generic-function
340 (defgeneric compute-effective-slot-definition
(class name dslotds
))
342 (defgeneric compute-slot-accessor-info
(slotd type gf
))
344 (defgeneric find-method-combination
(generic-function type options
))
346 (defgeneric invalid-qualifiers
(generic-function combin method
))
348 (defgeneric (setf slot-accessor-function
) (function slotd type
))
350 (defgeneric (setf slot-accessor-std-p
) (value slotd type
))
352 (defgeneric slot-boundp-using-class
(class object slotd
))
354 (defgeneric slot-makunbound-using-class
(class object slotd
))
356 (defgeneric slot-unbound
(class instance slot-name
))
358 (defgeneric slot-value-using-class
(class object slotd
))
362 (defgeneric make-method-lambda
363 (proto-generic-function proto-method lambda-expression environment
))
365 (defgeneric make-method-specializers-form
366 (proto-generic-function proto-method specializer-names environment
))
368 (defgeneric (setf slot-value-using-class
) (new-value class object slotd
))
372 ;;; FIXME: This is currently unused -- where should we call it? Or should we just
374 (defgeneric add-boundp-method
(class generic-function slot-name slot-documentation source-location
))
376 (defgeneric add-reader-method
(class generic-function slot-name slot-documentation source-location
))
378 (defgeneric add-writer-method
(class generic-function slot-name slot-documentation source-location
))
380 (defgeneric make-method-initargs-form
381 (proto-generic-function proto-method lambda-expression lambda-list
384 ;;;; optional arguments
386 (defgeneric get-method
(generic-function
391 (defgeneric find-method
(generic-function
396 (defgeneric slot-missing
(class
400 &optional new-value
))
404 ;;; FIXME: make the declared &KEY arguments here agree with those that
406 (defgeneric allocate-instance
(class &rest initargs
))
408 (defgeneric ensure-class-using-class
(class
411 &key
&allow-other-keys
))
413 (defgeneric ensure-generic-function-using-class
(generic-function
415 &key
&allow-other-keys
))
417 (defgeneric initialize-instance
(instance &rest initargs
&key
&allow-other-keys
))
419 (defgeneric make-instance
(class &rest initargs
&key
&allow-other-keys
))
421 (defgeneric change-class
(instance new-class-name
&rest initargs
&key
&allow-other-keys
))
423 (defgeneric no-applicable-method
(generic-function &rest args
))
425 (defgeneric no-next-method
(generic-function method
&rest args
))
427 (defgeneric no-primary-method
(generic-function &rest args
))
429 (defgeneric reader-method-class
(class direct-slot
&rest initargs
))
431 (defgeneric reinitialize-instance
(instance &rest initargs
&key
&allow-other-keys
))
433 (defgeneric shared-initialize
(instance slot-names
&rest initargs
434 &key
&allow-other-keys
))
436 (defgeneric update-dependent
(metaobject dependent
&rest initargs
))
438 (defgeneric update-instance-for-different-class
(previous
442 (defgeneric update-instance-for-redefined-class
(instance
448 (defgeneric writer-method-class
(class direct-slot
&rest initargs
))