Add #%expression around annotations.

original commit: 49b983ca2e2e147f975923fac93e1eb48399a1eb
This commit is contained in:
Eric Dobson 2013-05-27 12:28:20 -07:00
parent d31ffab99d
commit f23e278f31
3 changed files with 9 additions and 6 deletions

View File

@ -418,7 +418,10 @@ This file defines two sorts of primitives. All of them are provided into any mod
(add-ann #'arg #'ty)]))
(define-for-syntax (add-ann expr-stx ty-stx)
(type-ascription-property expr-stx ty-stx))
(type-ascription-property
(quasisyntax/loc expr-stx
(#%expression #,expr-stx))
ty-stx))
(define-syntax (inst stx)

View File

@ -18,8 +18,8 @@ TR opt: pr13468.rkt 33:5 (magnitude (ann -6.0 Negative-Flonum)) -- unary float
TR opt: pr13468.rkt 34:5 (magnitude (ann 6.0 Flonum)) -- unary float
TR opt: pr13468.rkt 38:5 (real-part (ann 0 Zero)) -- unary number
TR opt: pr13468.rkt 39:5 (real-part (ann 1 One)) -- unary number
TR opt: pr13468.rkt 3:13 6.0+2.3i -- unboxed literal
TR opt: pr13468.rkt 3:13 6.0+2.3i -- unboxed literal
TR opt: pr13468.rkt 3:13 6.0+2.3i -- unbox float-complex
TR opt: pr13468.rkt 3:13 6.0+2.3i -- unbox float-complex
TR opt: pr13468.rkt 3:5 (- (ann 6.0+2.3i Float-Complex)) -- unboxed unary float complex
TR opt: pr13468.rkt 40:5 (real-part (ann 6 Byte)) -- unary number
TR opt: pr13468.rkt 41:5 (real-part (ann 6 Index)) -- unary number
@ -29,8 +29,8 @@ TR opt: pr13468.rkt 45:5 (real-part (ann -6 Nonpositive-Fixnum)) -- unary number
TR opt: pr13468.rkt 46:5 (real-part (ann -6 Negative-Fixnum)) -- unary number
TR opt: pr13468.rkt 47:5 (real-part (ann 6 Fixnum)) -- unary number
TR opt: pr13468.rkt 49:5 (real-part (ann 6 Positive-Integer)) -- unary number
TR opt: pr13468.rkt 4:13 6.0+2.3i -- unboxed literal
TR opt: pr13468.rkt 4:13 6.0+2.3i -- unboxed literal
TR opt: pr13468.rkt 4:13 6.0+2.3i -- unbox float-complex
TR opt: pr13468.rkt 4:13 6.0+2.3i -- unbox float-complex
TR opt: pr13468.rkt 4:5 (/ (ann 6.0+2.3i Float-Complex)) -- unboxed unary float complex
TR opt: pr13468.rkt 50:5 (real-part (ann 6 Nonnegative-Integer)) -- unary number
TR opt: pr13468.rkt 51:5 (real-part (ann -6 Nonpositive-Integer)) -- unary number

View File

@ -1,7 +1,7 @@
#;#;
#<<END
TR opt: vector-length.rkt 2:0 (vector-length (vector 1 2 3)) -- known-length vector-length
TR opt: vector-length.rkt 3:0 (vector-length (ann (vector 4 5 6) (Vectorof Integer))) -- known-length vector-length
TR opt: vector-length.rkt 3:0 (vector-length (ann (vector 4 5 6) (Vectorof Integer))) -- vector-length
END
#<<END
3