Cleanup C++ to Lisp translation
src/cxx-method.lisp
Sun Aug 2 12:12:41 CEST 2009 Tobias Rautenkranz <tobias@rautenkranz.ch>
* Cleanup C++ to Lisp translation
--- old-smoke/src/cxx-method.lisp 2014-10-30 08:11:51.000000000 +0100
+++ new-smoke/src/cxx-method.lisp 2014-10-30 08:11:51.000000000 +0100
@@ -1,13 +1,11 @@
(in-package :smoke)
(defclass cxx-generic-function (standard-generic-function)
- ((gf-methods :initform nil
+ ((gf-methods :initform nil :type list
:accessor gf-methods
- :type list
- :documentation "Generic functions for different argument counts."))
+ :documentation "gf for different argument counts."))
(:metaclass closer-mop:funcallable-standard-class)
- (:documentation
- "A generic function that can be overloaded by argument count."))
+ (:documentation "gf that can be overloaded by argument count."))
(defclass cxx-method-generic-function (standard-generic-function)
((generic-function :accessor cxx-generic-function
@@ -36,8 +34,7 @@
((integer 0) argument-count)
(values (or cxx-method-generic-function null)))
(find-if #'(lambda (gf)
- (= argument-count
- (argument-count gf)))
+ (= argument-count (argument-count gf)))
(gf-methods cxx-generic-function)))
(defun cxx-method-generic-function-name (cxx-generic-function argument-count)
@@ -80,8 +77,9 @@
(defun push-method (method cxx-generic-function)
"Adds METHOD to a cxx-method-generic-function of CXX-GENERIC-FUNCTION."
(declare (optimize (speed 3)))
- (let ((generic-function (ensure-gf-by-argument-count cxx-generic-function
- (method-argument-count method))))
+ (let ((generic-function (ensure-gf-by-argument-count
+ cxx-generic-function
+ (method-argument-count method))))
(add-method generic-function method)))
(defun unpush-method (method)