Changeset 14486 in project


Ignore:
Timestamp:
04/28/09 05:35:52 (10 years ago)
Author:
Kon Lovett
Message:

Save.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • release/4/lookup-table/trunk/lookup-table.scm

    r14485 r14486  
    245245                (let ((res (let/cc return
    246246                 (hash-table-walk ht
    247                    (lambda (key val)
    248                      (when (proc key val)
    249                        (set! ret #t)
    250                        (return val)))))))
     247                   (lambda (key val) (when (proc key val) (set! ret #t) (return val)))))))
    251248                        (if ret res def) ) ) )
    252249
     
    257254(define (htable-dict-values data) (hash-table-values (%htable-dict-htable data)))
    258255
    259 (define (htable-dict-exists? data key)
    260         (hash-table-exists? (%htable-dict-htable data) key) )
     256(define (htable-dict-exists? data key) (hash-table-exists? (%htable-dict-htable data) key))
    261257
    262258(define (make-htable-dict test ht)
     
    352348        (%dict-values dict) )
    353349
    354 (define (dict-ref dict key . def)
     350(define (dict-ref dict key #!optional def)
    355351  (when *dict-safe-mode* (%check-dict 'dict-ref dict))
    356         (%dict-ref dict key (optional def #f)) )
     352        (%dict-ref dict key def) )
    357353
    358354(define (dict-set! dict key obj)
     
    387383        (%dict-for-each dict proc) )
    388384
    389 (define (dict-search dict proc . def)
     385(define (dict-search dict proc #!optional def)
    390386  (when *dict-safe-mode*
    391387    (%check-dict 'dict-search dict)
    392388    (%check-procedure 'dict-search proc) )
    393         (%dict-search dict proc (optional def #f)) )
     389        (%dict-search dict proc def) )
    394390
    395391(define (dict-merge! dict . dicts)
Note: See TracChangeset for help on using the changeset viewer.