On 2014-02-15 14:31:51 -0500, Greg Hendershott wrote: > And as someone whose predominant static typing experience is C and > C++, I have the instinct that you don't cast unless you know exactly > what you're doing. So when I need to use `ann` or `cast` or `assert`, > I wince. But I'm still trying to learn the appropriate instinct, here.
With Typed Racket, it's always okay to put in more `ann`s to help the typechecker. "Okay" in the sense that if you put in wrong `ann`s you will find out at compile-time. Unlike C, it's also always safe to use `cast` or `assert`. "Safe" in the sense that if there's a type mismatch you will get a run-time error at worst. You won't get undefined behavior or segfaults. (except if you accidentally stumble on a bug in the type system) Cheers, Asumu ____________________ Racket Users list: http://lists.racket-lang.org/users

