[racket] Another basic TR question

From: Bloch Stephen (bloch at adelphi.edu)
Date: Thu Feb 13 14:45:08 EST 2014

I've removed a lot of possibly-irrelevant stuff and boiled my current obstacle down to the following:

In #lang racket, the following works fine:

(for/sum [[ii 300]]
  pi)



In #lang typed/racket, I try to do the same thing:

(for/sum: : Flonum [[ii : Index 300]]
  pi)

and I get the type error "Expected Flonum, but got Zero".  Where is there a zero anywhere in this code?  And even if there were a zero, shouldn't Zero be a subtype of Flonum?

Don't tell me the Zero I'm running into is the initial value of for/sum's hidden accumulator....


Stephen Bloch
sbloch at adelphi.edu
GPG  key at http://adelphi.edu/sbloch/sbloch.pubkey.asc

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20140213/2e8d6d7d/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 495 bytes
Desc: This is a digitally signed message part
URL: <http://lists.racket-lang.org/users/archive/attachments/20140213/2e8d6d7d/attachment.sig>

Posted on the users mailing list.