title-casing type names

This commit is contained in:
Alex Shinn 2011-11-04 15:08:22 +09:00
parent 78c7eac033
commit 395d5be5ad
7 changed files with 14 additions and 14 deletions

View file

@ -24,7 +24,7 @@
(define maximum-history-size 128) (define maximum-history-size 128)
(define-record-type history (define-record-type History
(%make-history remaining past future) (%make-history remaining past future)
history? history?
(remaining history-remaining history-remaining-set!) (remaining history-remaining history-remaining-set!)
@ -117,7 +117,7 @@
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; buffers ;; buffers
(define-record-type buffer (define-record-type Buffer
(%make-buffer refresh? min pos row max-row col gap width string history) (%make-buffer refresh? min pos row max-row col gap width string history)
buffer? buffer?
(refresh? buffer-refresh? buffer-refresh?-set!) (refresh? buffer-refresh? buffer-refresh?-set!)

View file

@ -6,7 +6,7 @@
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; URI representation ;; URI representation
(define-record-type uri (define-record-type Uri
(%make-uri scheme user host port path query fragment) (%make-uri scheme user host port path query fragment)
uri? uri?
(scheme uri-scheme) (scheme uri-scheme)

View file

@ -557,8 +557,8 @@ sexp sexp_init_library (sexp ctx sexp_api_params(self, n), sexp env) {
sexp_gc_var1(name); sexp_gc_var1(name);
sexp_gc_preserve1(ctx, name); sexp_gc_preserve1(ctx, name);
sexp_mutex_id = sexp_lookup_named_type(ctx, env, "mutex"); sexp_mutex_id = sexp_lookup_named_type(ctx, env, "Mutex");
sexp_condvar_id = sexp_lookup_named_type(ctx, env, "condition-variable"); sexp_condvar_id = sexp_lookup_named_type(ctx, env, "Condition-Variable");
name = sexp_c_string(ctx, "pollfds", -1); name = sexp_c_string(ctx, "pollfds", -1);
t = sexp_register_type(ctx, name, SEXP_FALSE, SEXP_FALSE, t = sexp_register_type(ctx, name, SEXP_FALSE, SEXP_FALSE,
SEXP_ZERO, SEXP_ZERO, SEXP_ZERO, SEXP_ZERO, SEXP_ZERO, SEXP_ZERO, SEXP_ZERO, SEXP_ZERO,

View file

@ -1,8 +1,8 @@
;; types.scm -- thread types ;; types.scm -- thread types
;; Copyright (c) 2010 Alex Shinn. All rights reserved. ;; Copyright (c) 2010-2011 Alex Shinn. All rights reserved.
;; BSD-style license: http://synthcode.com/license.txt ;; BSD-style license: http://synthcode.com/license.txt
(define-record-type mutex (define-record-type Mutex
(%make-mutex name specific thread lock) (%make-mutex name specific thread lock)
mutex? mutex?
(name mutex-name) (name mutex-name)
@ -13,7 +13,7 @@
(define (make-mutex . o) (define (make-mutex . o)
(%make-mutex (and (pair? o) (car o)) #f #f #f)) (%make-mutex (and (pair? o) (car o)) #f #f #f))
(define-record-type condition-variable (define-record-type Condition-Variable
(%make-condition-variable name specific threads) (%make-condition-variable name specific threads)
condition-variable? condition-variable?
(name condition-variable-name) (name condition-variable-name)

View file

@ -186,8 +186,9 @@ static sexp sexp_hash_table_cell (sexp ctx sexp_api_params(self, n), sexp ht, se
sexp buckets, eq_fn, hash_fn, i; sexp buckets, eq_fn, hash_fn, i;
sexp_uint_t size; sexp_uint_t size;
sexp_gc_var1(res); sexp_gc_var1(res);
if (! sexp_pointerp(ht)) /* XXXX check the real type id */ /* extra check - exact type should be checked by the calling procedure */
return sexp_xtype_exception(ctx, self, "not a hash-table", ht); if (! sexp_pointerp(ht))
return sexp_xtype_exception(ctx, self, "not a Hash-Table", ht);
buckets = sexp_hash_table_buckets(ht); buckets = sexp_hash_table_buckets(ht);
eq_fn = sexp_hash_table_eq_fn(ht); eq_fn = sexp_hash_table_eq_fn(ht);
hash_fn = sexp_hash_table_hash_fn(ht); hash_fn = sexp_hash_table_hash_fn(ht);
@ -241,4 +242,3 @@ sexp sexp_init_library (sexp ctx sexp_api_params(self, n), sexp env) {
return SEXP_VOID; return SEXP_VOID;
} }

View file

@ -31,7 +31,7 @@
(syntax-rules () (syntax-rules ()
((assert-hash-table from obj) ((assert-hash-table from obj)
(if (not (hash-table? obj)) (if (not (hash-table? obj))
(error (string-append from ": not a hash-table") obj))))) (error (string-append from ": not a Hash-Table") obj)))))
(define (hash-table-ref table key . o) (define (hash-table-ref table key . o)
(assert-hash-table "hash-table-ref" table) (assert-hash-table "hash-table-ref" table)

View file

@ -1,8 +1,8 @@
;; types.scm -- the hash-table record type ;; types.scm -- the hash-table record type
;; Copyright (c) 2009 Alex Shinn. All rights reserved. ;; Copyright (c) 2009-2011 Alex Shinn. All rights reserved.
;; BSD-style license: http://synthcode.com/license.txt ;; BSD-style license: http://synthcode.com/license.txt
(define-record-type hash-table (define-record-type Hash-Table
(%make-hash-table buckets size hash-fn eq-fn) (%make-hash-table buckets size hash-fn eq-fn)
hash-table? hash-table?
(buckets hash-table-buckets hash-table-buckets-set!) (buckets hash-table-buckets hash-table-buckets-set!)