Skip to content

@samth /any-c.rkt
Created

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Why any-wrap/c is needed
#lang racket/load
(module m1 typed/racket
(: f : Integer -> Integer)
(define (f x) (add1 x))
(define: g : Any f) ;; safe by subtyping
(provide g))
(module m2 racket
(require 'm1)
(g "not a number")) ;; fails at runtime
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.