I wrote a piece of code like this without thinking:

#lang typed/racket

(: f (All (T) (Number -> T -> T)))
(define ((f x) y)
  (ann y T))

... and then, after a second, was sort of flabbergasted that it worked.  What's 
the scope of the type variable T? Apparently I can use it anywhere in the 
definition of the identifier that it names? That seems really fragile. Am I 
misunderstanding this?

John

Attachment: smime.p7s
Description: S/MIME cryptographic signature

____________________
  Racket Users list:
  http://lists.racket-lang.org/users

Reply via email to