Re: [racket-dev] typed/racket for loops?

2011-06-07 Thread Vincent St-Amour
At Tue, 7 Jun 2011 15:49:05 -0700, John Clements wrote: > In that case, it appears that there's also a doc bug; the docs say: > > (for/list: : u (for:-clause ...) expr ...+) > > ... "The last expr of the body must have type u." > > This would suggest that the type annotation used for 'u' above s

Re: [racket-dev] typed/racket for loops?

2011-06-07 Thread John Clements
On Jun 7, 2011, at 12:24 PM, Hari Prashanth wrote: > Its a bad error message I believe. > > (: p (Listof Fixnum)) > (define p > (for/list: : (Listof Fixnum) ([i : Fixnum (in-range 30)]) i)) In that case, it appears that there's also a doc bug; the docs say: (for/list: : u (for:-clause ...) e

Re: [racket-dev] typed/racket for loops?

2011-06-07 Thread Sam Tobin-Hochstadt
t;dev" > Sent: Tuesday, June 7, 2011 3:10:58 PM (GMT-0500) Auto-Detected > Subject: [racket-dev] typed/racket for loops? > > I can't get typed racket to work with for loops, e.g.: > > #lang typed/racket > > (: p (Listof Natural)) > (define p >  (for/list: : Natural

Re: [racket-dev] typed/racket for loops?

2011-06-07 Thread Hari Prashanth
MT-0500) Auto-Detected Subject: [racket-dev] typed/racket for loops? I can't get typed racket to work with for loops, e.g.: #lang typed/racket (: p (Listof Natural)) (define p (for/list: : Natural ([i (in-range 30)]) i)) ==> Type Checker: Error in macro expansion -- untyped variable:

[racket-dev] typed/racket for loops?

2011-06-07 Thread John Clements
I can't get typed racket to work with for loops, e.g.: #lang typed/racket (: p (Listof Natural)) (define p (for/list: : Natural ([i (in-range 30)]) i)) ==> Type Checker: Error in macro expansion -- untyped variable: for-loop in: (for/list: : Natural ((i (in-range 30))) i) Am I doing someth