[racket] code review request for LRU code

From: Danny Yoo (dyoo at hashcollision.org)
Date: Tue Mar 12 16:16:02 EDT 2013

On Tue, Mar 12, 2013 at 1:08 PM, Sam Tobin-Hochstadt <samth at ccs.neu.edu> wrote:
> On Tue, Mar 12, 2013 at 1:00 PM, Danny Yoo <dyoo at hashcollision.org> wrote:
>> One thing I'm noticing is that it seems difficult to use my typed code
>> in untyped code, because the container is polymorphic.
>> 'untyped-client.rkt' shows what I mean: I'm hitting a Type Checker
>> error at runtime and I don't know what to do to avoid it yet.  What
>> can I do here?
> What error do you get?

Here's what I see when I execute

slab:lru dyoo$ racket untyped-client.rkt
untyped-client.rkt:10:0: Type Checker: The type of lru-ref cannot be
converted to a contract
  in: (lru-ref l "greeting")
   /Applications/Racket v5.3.2/collects/racket/private/modbeg.rkt:46:4

Posted on the users mailing list.