[plt-scheme] Type scheme annotations and macros

From: David Van Horn (dvanhorn at ccs.neu.edu)
Date: Wed Oct 22 11:53:25 EDT 2008

Robby Findler wrote:
> What about
> 
> (bif e1 e2 e3) => (if (and e1 #t) e2 e3)

But this doesn't force e1 to have type Boolean.

#lang typed-scheme
(if (and "Not a Boolean" #t)
     'a
     'b)

I want a form of if which will reject the following:

(if "Not a Boolean"
     'a
     'b)

David


Posted on the users mailing list.