X-Git-Url: https://git.distorted.org.uk/~mdw/sod/blobdiff_plain/30eb3c686a1bb2cea791798324c2eea08ffc341d..refs/heads/mdw/progfmt:/src/method-proto.lisp diff --git a/src/method-proto.lisp b/src/method-proto.lisp index ac662ca..0a20f39 100644 --- a/src/method-proto.lisp +++ b/src/method-proto.lisp @@ -49,6 +49,13 @@ will be a list of applicable methods sorted in most-to-least specific order.")) +(export 'sod-message-receiver-type) +(defgeneric sod-message-receiver-type (message class) + (:documentation + "Return the type of the `me' argument in a MESSAGE received by CLASS. + + Typically this will just be `CLASS *' or `const CLASS *'.")) + (export 'sod-message-applicable-methods) (defgeneric sod-message-applicable-methods (message class) (:documentation @@ -288,9 +295,9 @@ (:documentation "Returns true if the effective METHOD is live. - An effective method is `live' if it should actually have proper method entry - functions associated with it and stored in the class vtable. The other - possibility is that the method is `dead', in which case the function + An effective method is `live' if it should actually have proper method + entry functions associated with it and stored in the class vtable. The + other possibility is that the method is `dead', in which case the function pointers in the vtable are left null.")) ;;;-------------------------------------------------------------------------- @@ -340,6 +347,15 @@ (definst convert-to-ilayout (stream :export t) (%class chain-head %expr) + "Expression to convert EXPR to point to its enclosing `ilayout'. + + Given a pointer EXPR which points into a direct instance of CLASS, + specifically to the `ichain' whose head class is CHAIN-HEAD, evaluate the + base address of the enclosing `ilayout' structure. + + The output looks like: + + SOD_ILAYOUT(CLASS, NICK, EXPR)" (format stream "SOD_ILAYOUT(~@<~A, ~_~A, ~_~A~:>)" class (sod-class-nickname chain-head) expr))