Added #%expression to inst to order it correctly with ann.

This commit is contained in:
Eric Dobson 2013-05-26 18:12:38 -07:00
parent 55e9043679
commit c24afb09d9
2 changed files with 5 additions and 2 deletions

View File

@ -388,9 +388,9 @@ This file defines two sorts of primitives. All of them are provided into any mod
(syntax/loc stx (inst arg . tys))]
[(_ arg tys ... ty ddd b:id)
#:when (eq? (syntax-e #'ddd) '...)
(type-inst-property #'arg #'(tys ... (ty . b)))]
(type-inst-property (syntax/loc #'arg (#%expression arg)) #'(tys ... (ty . b)))]
[(_ arg tys ...)
(type-inst-property #'arg #'(tys ...))]))
(type-inst-property (syntax/loc #'arg (#%expression arg)) #'(tys ...))]))
(define-syntax (define: stx)
(syntax-parse stx #:literals (:)

View File

@ -1695,6 +1695,9 @@
(opt-lambda: ((x : Symbol 'a)) x)
#:ret (ret (t:-> -Symbol -Symbol) (-FS -top -bot))
#:expected (ret (t:-> -Symbol -Symbol) (-FS -top -bot))]
[tc-e/t (inst (ann (lambda (a) a) (All (a) (a -> a))) Symbol)
(t:-> -Symbol -Symbol)]
)
(test-suite
"check-type tests"