[racket] Typed Racket vs. Haskell
On Fri, Sep 21, 2012 at 2:29 PM, <thorsopia at lavabit.com> wrote:
> One more question.
>
> I've been told that there are no typeclasses in TR.
> How would you handle this?
>
> foo :: (Ord a) => a -> a -> a
Racket doesn't have a general notion of ordering, so we'd probably
write this function like this:
(: foo : (All (A) (A A -> Boolean) A A -> A))
(define (foo cmp left right) ...)
On the more general question, Racket has struct properties and the
generics system built on them. We would like to integrate Typed
Racket with these facilities, but that has not happened yet.
--
sam th
samth at ccs.neu.edu