Changeset 2529

Show
Ignore:
Timestamp:
02/18/08 11:35:20 (9 months ago)
Author:
hhubner
Message:

Fix warnings.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/trunk-reorg/bknr/datastore/src/indices/category-index.lisp

    r1112 r2529  
    142142               (null key)) 
    143143      (return-from index-add)) 
    144     (multiple-value-bind (value presentp) 
    145         (gethash key hash-table) 
    146       (if presentp 
    147           (push object (gethash key hash-table)) 
    148           (progn 
    149             (tree-add-category tree key) 
    150             (setf (gethash key hash-table) (list object))))))) 
     144    (if (nth-value 1 (gethash key hash-table)) 
     145        (push object (gethash key hash-table)) 
     146        (progn 
     147          (tree-add-category tree key) 
     148          (setf (gethash key hash-table) (list object)))))) 
    151149 
    152150(defmethod index-remove ((index category-index) object) 
  • branches/trunk-reorg/bknr/datastore/src/indices/indices.lisp

    r1565 r2529  
    136136               (null key)) 
    137137      (return-from index-add)) 
    138     (multiple-value-bind (value presentp) 
    139         (gethash key hash-table) 
    140       (if presentp 
    141           (push object (gethash key hash-table)) 
    142           (setf (gethash key hash-table) (list object)))))) 
     138    (if (nth-value 1 (gethash key hash-table)) 
     139        (push object (gethash key hash-table)) 
     140        (setf (gethash key hash-table) (list object))))) 
    143141 
    144142(defmethod index-remove ((index hash-index) object) 
     
    173171             (let ((key (class-name class)) 
    174172                   (hash-table (slot-index-hash-table index))) 
    175                (multiple-value-bind (value presentp) 
    176                    (gethash key hash-table) 
    177                  (if presentp 
    178                      (push object (gethash key hash-table)) 
    179                      (setf (gethash key hash-table) (list object))))))) 
     173               (if (nth-value 1 (gethash key hash-table)) 
     174                   (push object (gethash key hash-table)) 
     175                   (setf (gethash key hash-table) (list object)))))) 
    180176     
    181177    (if (class-index-index-superclasses index) 
     
    213209        (hash-table (slot-index-hash-table index))) 
    214210    (dolist (key keys) 
    215       (multiple-value-bind (value presentp) 
    216           (gethash key hash-table) 
    217         (if presentp 
    218             (push object (gethash key hash-table)) 
    219             (setf (gethash key hash-table) (list object))))))) 
     211      (if (nth-value 1 (gethash key hash-table)) 
     212          (push object (gethash key hash-table)) 
     213          (setf (gethash key hash-table) (list object)))))) 
    220214 
    221215(defmethod index-remove ((index hash-list-index) object) 
     
    407401  (let ((new-list (skip-list-index-skip-list new-index))  
    408402        (old-list (skip-list-index-skip-list old-index))) 
    409     (setf (skip-list-index-skip-list new-index) old-list) 
     403    (setf (skip-list-index-skip-list new-list) old-list) 
    410404    new-index)) 
    411405 
     
    420414   (hash-table :accessor class-skip-index-hash-table))) 
    421415 
    422 (defmethod initialize-instance :after ((index class-skip-index) &key (type 'string) 
    423                                        (test #'eql) 
    424                                        slots index-superclasses &allow-other-keys) 
     416(defmethod initialize-instance :after ((index class-skip-index) 
     417                                       &key (test #'eql) slots index-superclasses) 
    425418  (unless (<= (length slots) 1) 
    426419    (error "Can not create slot-index with more than one slot."))