From 19bb8501a73f4e9bf10550bd8ff6888af2120ae9 Mon Sep 17 00:00:00 2001 From: jjgarcia Date: Mon, 19 Sep 2005 09:30:34 +0000 Subject: [PATCH] Simplified the code for creating method combinations. Remove need for code walker here. --- src/clos/combin.lsp | 348 +++++++++++++------------------------------ src/clos/load.lsp.in | 1 - 2 files changed, 100 insertions(+), 249 deletions(-) diff --git a/src/clos/combin.lsp b/src/clos/combin.lsp index 4755dbac9..0cee6a4d5 100644 --- a/src/clos/combin.lsp +++ b/src/clos/combin.lsp @@ -9,245 +9,80 @@ (in-package "CLOS") +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;; COMPILING EFFECTIVE METHODS ;;; -;;; Convert an effective method form to a compiled effective method function. -;;; The strategy is to have compiled functions around which are are templates -;;; for effective method functions. Then the effective method functions we -;;; generate are closures over the particular methods in the effective method -;;; form. This strategy has the advantage that we don't have to call the -;;; compiler when we combine new methods. It also has the advantage that -;;; same shape effective methods share the same code vector. It is of course -;;; predicated on the assumption that funcalling compiled closures is fast. +;;; The following functions take care of transforming the forms +;;; produced by the method combinations into effective methods. In +;;; ECL effective methods are nothing but directly callable functions. +;;; Hence, this compilation should ideally just produce new compiled +;;; functions. However, we do not want to cons a lot of functions, and +;;; therefore we use closures. ;;; -;;; *effective-method-templates* is a list of effective-method template -;;; entries. Each entry is itself a list of the form: -;;; -;;; (