@@ -817,6 +817,7 @@ otherwise work well.")
817
817
(excl ::dump-lisp-source x)))
818
818
819
819
(defmethod py-function-name ((x function))
820
+ (declare (ignorable x))
820
821
#+ allegro (format nil " ~A " (excl ::func_name x))
821
822
#- allegro (call-next-method ))
822
823
@@ -3171,27 +3172,32 @@ invocation form.\"")
3171
3172
(defgeneric py-class-of (x)
3172
3173
3173
3174
; ; Lisp objects lead to their proxy class
3174
- (:method ((x hash-table )) (ltv-find-class ' dict))
3175
- (:method ((x integer )) (ltv-find-class ' py-int ))
3176
- (:method ((x real )) (ltv-find-class ' py-float ))
3177
- (:method ((x complex )) (ltv-find-class ' py-complex))
3178
- (:method ((x string )) (ltv-find-class ' py-string ))
3179
- (:method ((x vector )) (ltv-find-class ' py-list ))
3175
+ (:method ((x hash-table )) (declare ( ignorable x)) ( ltv-find-class ' dict))
3176
+ (:method ((x integer )) (declare ( ignorable x)) ( ltv-find-class ' py-int ))
3177
+ (:method ((x real )) (declare ( ignorable x)) ( ltv-find-class ' py-float ))
3178
+ (:method ((x complex )) (declare ( ignorable x)) ( ltv-find-class ' py-complex))
3179
+ (:method ((x string )) (declare ( ignorable x)) ( ltv-find-class ' py-string ))
3180
+ (:method ((x vector )) (declare ( ignorable x)) ( ltv-find-class ' py-list ))
3180
3181
(:method ((x list )) (cond ((null x)
3181
3182
(break " PY-CLASS-OF of NIL" ))
3182
3183
((and (listp (car x)) (symbolp (caar x)))
3183
3184
(ltv-find-class ' py-alist))
3184
3185
(t
3185
3186
(ltv-find-class ' py-tuple))))
3186
- (:method ((x symbol )) (ltv-find-class ' py-symbol ))
3187
- (:method ((x function)) (ltv-find-class ' py-function))
3188
- (:method ((x py-function)) (ltv-find-class ' py-function))
3189
- (:method ((x package )) (ltv-find-class ' lisp-package))
3187
+ (:method ((x symbol )) (declare (ignorable x))
3188
+ (ltv-find-class ' py-symbol ))
3189
+ (:method ((x function)) (declare (ignorable x))
3190
+ (ltv-find-class ' py-function))
3191
+ (:method ((x py-function)) (declare (ignorable x))
3192
+ (ltv-find-class ' py-function))
3193
+ (:method ((x package )) (declare (ignorable x))
3194
+ (ltv-find-class ' lisp-package))
3190
3195
3191
3196
#+ (or )(:method ((x py-type)) (ltv-find-class ' py-type))
3192
3197
3193
3198
(:method ((x py-meta-type)) ; ; metatypes (including `type')
3194
3199
; ; fake being of type `type'
3200
+ (declare (ignorable x))
3195
3201
(ltv-find-class ' py-type))
3196
3202
3197
3203
(:method ((x py-type)) (class-of x))
@@ -3341,12 +3347,12 @@ finished; F will then not be called again."
3341
3347
; ; XXX Speed up slot value lookup by using
3342
3348
; ; MOP:SLOT-DEFINITION-LOCATION, MOP:STANDARD-INSTANCE-ACCESS.
3343
3349
(:method ((f null ) &rest args)
3344
- (declare (ignore args) (dynamic-extent args))
3350
+ (declare (ignore args) (ignorable f) ( dynamic-extent args))
3345
3351
(error " PY-CALL of NIL" ))
3346
3352
3347
3353
(:method ((f class ) &rest args)
3348
3354
(declare (dynamic-extent args)
3349
- (ignorable args)
3355
+ (ignorable f args)
3350
3356
(optimize (speed 3 ) (safety 0 ) (debug 0 )))
3351
3357
#- clpython-exceptions-are-python-objects
3352
3358
(when (subtypep f ' {Exception})
@@ -4025,6 +4031,7 @@ Returns one of (-1, 0, 1): -1 iff x < y; 0 iff x == y; 1 iff x > y")
4025
4031
(setf (get x ' py-hash) hash))))
4026
4032
4027
4033
(defmethod py-repr ((x (eql nil )))
4034
+ (declare (ignorable x))
4028
4035
" #<the symbol NIL>" )
4029
4036
4030
4037
#||
0 commit comments