> I have recently been trying out typed/racket with an eye toward using it in > my regular programming. I've hit a snag, and hopefully it's a newbie mistake > that you folks can set right.
There's an escape hatch you can use with require/typed. You can have a function in the untyped world translate your s-expression into the typed structure. For example, something like this: https://github.com/dyoo/whalesong/blob/master/compiler/compiler-helper.rkt >From the typed world, you can then use require/typed to use that function to coerse into the untyped world. It looks something like this: #lang typed/racket/base ... (require/typed "compiler-helper.rkt" [ensure-const-value (Any -> const-value)]) where const-value is some datatype defined elsewhere. Typed Racket should impose runtime contracts to ensure the untyped code isn't doing something silly. ____________________ Racket Users list: http://lists.racket-lang.org/users