;; -*-theme-d-*-

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

;; Expected results: translation error because of
;;   purity mismatch


(define-proper-program (tests test98)


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


  (define-param-proc proc (%type) (((obj %type)) %type pure)
    (let*-mutable ((var1 <integer> 0))
		  (let ((proc2 (lambda (() <none> nonpure)
				 (set! var1 obj))))
		    (proc2)
		    var1)))


  (define-simple-proc main (() <none> nonpure)
    (let ((result? (proc 1)))
      (console-display result?)
      (console-newline))))
