* librecords librarified

This commit is contained in:
Abdulaziz Ghuloum 2007-04-30 00:47:37 -04:00
parent 56f3d05a6e
commit e953fff362
3 changed files with 6 additions and 14 deletions

Binary file not shown.

View File

@ -1,5 +1,8 @@
(library (ikarus records)
(export)
(import (scheme))
(let ()
@ -48,22 +51,10 @@
(lambda (rtd symbol)
($record-set! rtd 4 symbol)))
; (define make-rtd
; (lambda (name fields printer symbol)
; (let ([rtd ($make-record $base-rtd 5)])
; ($record-set! rtd 0 name)
; ($record-set! rtd 1 (length fields))
; ($record-set! rtd 2 fields)
; ($record-set! rtd 3 printer)
; ($record-set! rtd 4 symbol)
; rtd)))
(define make-rtd
(lambda (name fields printer symbol)
($record $base-rtd name (length fields) fields printer symbol)))
(define verify-field
(lambda (x)
(unless (symbol? x)
@ -275,5 +266,4 @@
(display (rtd-name x) p)
(display " rtd>" p)))
)
))

View File

@ -789,7 +789,9 @@
[$base-rtd $base-rtd-label (core-prim . $base-rtd)]
[$record-set! $record-set!-label (core-prim . $record-set!)]
[$record-ref $record-ref-label (core-prim . $record-ref)]
[$record-rtd $record-rtd-label (core-prim . $record-rtd)]
[$record $record-label (core-prim . $record)]
[$make-record $make-record-label (core-prim . $make-record)]
[$record? $record?-label (core-prim . $record?)]
[$record/rtd? $record/rtd?-label (core-prim . $record/rtd?)]
;;; codes