+2000-11-26 Gary Houston <ghouston@arglist.com>
+
+ * boot-9.scm: values?, get-values, values, call-with-values:
+ removed. values and call-with-values are now primitives and
+ the other two were only exported by accident. don't define
+ *values-rtd* record type or handle multiple values in
+ scm-style-repl.
+
2000-11-07 Gary Houston <ghouston@arglist.com>
* popen.scm (open-output-pipe): added docstrings for open-input-pipe
answer
(loop (cons init answer) (- n 1)))))
-
-\f
-;;; {Multiple return values}
-
-(define *values-rtd*
- (make-record-type "values"
- '(values)))
-
-;;; These two are needed internally in boot-9.scm.
-;;; They shouldn't be visible outside this module.
-(define values? (record-predicate *values-rtd*))
-(define get-values (record-accessor *values-rtd* 'values))
-
-(define values
- (let ((make-values (record-constructor *values-rtd*)))
- (lambda x
- (if (and (not (null? x))
- (null? (cdr x)))
- (car x)
- (make-values x)))))
-
-(define call-with-values
- (lambda (producer consumer)
- (let ((result (producer)))
- (if (values? result)
- (apply consumer (get-values result))
- (consumer result)))))
-
-(provide 'values)
-
\f
;;; {and-map and or-map}
;;;
(lambda (result)
(if (not scm-repl-silent)
(begin
- (if (values? result)
- (for-each maybe-print (get-values result))
- (maybe-print result))
+ (maybe-print result)
(if scm-repl-verbose
(repl-report))
(force-output))))))