;; -*-theme-d-*-

;; Copyright (C) 2019  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 test762)

  (import (standard-library core)
	  (standard-library object-string-conversion)
	  (standard-library real-math)
	  (standard-library console-io))

  (define-simple-proc main (() <none> nonpure)
    (console-display-line (string->integer "123"))
    (guard-without-result
     (exc (else
	   (console-display-line "conversion error")))
     (console-display-line (string->integer "abc")))
    (console-display-line (string->real "5.5"))
    (console-display-line (string->real "5"))
    (console-display-line (string->real "2/3"))
    (guard-without-result
     (exc (else
	   (console-display-line "conversion error")))
     (console-display-line (string->real "abc")))
    (console-display-line (string->real-number "5.5"))
    (console-display-line (string->real-number "5"))
    (console-display-line (string->real-number "2/3"))
    (guard-without-result
     (exc (else
	   (console-display-line "conversion error")))
     (console-display-line (string->real-number "abc")))))
