;; -*-theme-d-*-

;; Copyright (C) 2016 Tommi Höynälänmaa
;; Distributed under GNU General Public License version 3,
;; see file doc/GPL-3.

;; Expected results: translation and running OK

(define-proper-program (tests test452)


  (import (standard-library core)
	  (standard-library stream)
	  (standard-library console-io))

  (define-simple-proc main (() <none> nonpure)
    (let* ((l (:uniform-list <integer>) '(10 20 30 40 50))
	   (stm (list->stream l)))
      (do ((stm-cur (:stream <integer>) stm (stream-next stm-cur))
	   (i <integer> 0 (+ i 1)))
	  ((stream-empty? stm-cur))
	(console-display i)
	(console-display " ")
	(console-display-line (stream-value stm-cur))))))

