diff --git a/extlib/benz b/extlib/benz index 8c174cd5..dd80aff0 160000 --- a/extlib/benz +++ b/extlib/benz @@ -1 +1 @@ -Subproject commit 8c174cd505aa4fc3b7937819506423b39b405216 +Subproject commit dd80aff03ab36fea0633e0e449c71fd489bc738a diff --git a/piclib/picrin/base.scm b/piclib/picrin/base.scm index 92180e92..ead1be72 100644 --- a/piclib/picrin/base.scm +++ b/piclib/picrin/base.scm @@ -441,8 +441,7 @@ dictionary-ref dictionary-set! dictionary-delete - dictionary-size - dictionary-for-each) + dictionary-size) (export make-record record? diff --git a/piclib/picrin/dictionary.scm b/piclib/picrin/dictionary.scm index 4ad679e9..c5205711 100644 --- a/piclib/picrin/dictionary.scm +++ b/piclib/picrin/dictionary.scm @@ -1,22 +1,6 @@ (define-library (picrin dictionary) (import (picrin base)) - (define (dictionary-map proc dict) - (let ((kvs '())) - (dictionary-for-each - (lambda (key val) - (set! kvs (cons (proc key val) kvs))) - dict) - (reverse kvs))) - - (define (dictionary->plist dict) - (let ((kvs '())) - (dictionary-for-each - (lambda (key val) - (set! kvs (cons val (cons key kvs)))) - dict) - (reverse kvs))) - (define (plist->dictionary plist) (let ((dict (make-dictionary))) (do ((kv plist (cddr kv))) @@ -24,12 +8,6 @@ dict) (dictionary-set! dict (car kv) (cadr kv))))) - (define (dictionary->alist dict) - (dictionary-map - (lambda (key val) - (cons key val)) - dict)) - (define (alist->dictionary alist) (let ((dict (make-dictionary))) (do ((kv alist (cdr kv))) @@ -40,9 +18,12 @@ (define (dictionary . plist) (plist->dictionary plist)) - (export dictionary - dictionary-map - dictionary->plist + (export dictionary? + dictionary + make-dictionary + dictionary-ref + dictionary-set! + dictionary-delete + dictionary-size plist->dictionary - dictionary->alist alist->dictionary))