diff --git a/collects/tests/typed-scheme/xfail/xmodule-mutation.rkt b/collects/tests/typed-scheme/xfail/xmodule-mutation.rkt new file mode 100644 index 00000000..fb8dfc4f --- /dev/null +++ b/collects/tests/typed-scheme/xfail/xmodule-mutation.rkt @@ -0,0 +1,19 @@ +#lang racket/load + +(module m typed/racket + (: x Any) + (define x "foo") + (: f (-> Void)) + (define (f) (set! x 1)) + (provide f x)) + +(module n typed/racket + (require 'm) + (if (string? x) + (begin + (f) + ;; this should be a type error! + (string-append x "foo")) + 0)) + +(require 'n)