Add more tests for PR 14380

Related to 07bde5063b5a3a83f61e85f00a1c6ce6e0a097d2

original commit: d2a3849c6ff39e3c68ce0d1e7fc531352c0086e9
This commit is contained in:
Asumu Takikawa 2014-03-01 13:41:55 -05:00
parent 6ade61f913
commit 9efd61102d

View File

@ -0,0 +1,27 @@
#;#;
#<<END
TR info: pr14380.rkt 11:15 foo -- struct constructor
END
#<<END
#<procedure:unbox>
#<procedure:magnitude>
#<procedure:list-ref>
#<procedure:+>
#<procedure:car>
#<procedure:string-length>
#<procedure:foo-x>
END
#lang typed/racket
#reader tests/typed-racket/optimizer/reset-port
;; Test for PR14380. None of these should get optimized.
(begin0 unbox (box 3))
(begin0 magnitude 3.0+5.0i)
(begin0 list-ref '(a b c) 0)
(begin0 + 3)
(begin0 car '(a b))
(begin0 string-length "foo")
(struct foo ([x : String]))
(begin0 foo-x (foo "foo"))