www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README

commit 1a327fc8f98e7b045056e1041c03998160128350
parent 820d56cf2a70709eb663c3640bac9f8a9cdcbbc8
Author: Stephen Chang <stchang@ccs.neu.edu>
Date:   Fri, 15 Aug 2014 15:32:54 -0400

add sysf tests

Diffstat:
Asysf-tests.rkt | 10++++++++++
1 file changed, 10 insertions(+), 0 deletions(-)

diff --git a/sysf-tests.rkt b/sysf-tests.rkt @@ -0,0 +1,9 @@ +#lang s-exp "sysf.rkt" + +;; polymorphic tests +(define-type (Maybe X) (variant (None) (Just X))) +(check-type (None {Int}) : (Maybe Int)) +(check-type (Just {Int} 1) : (Maybe Int)) +(check-type-error (Just {Int} #f)) +(check-not-type (Just {Int} 1) : (Maybe Bool)) +(check-type (λ {X} ([x : X]) x) : (∀ (X) (→ X X))) +\ No newline at end of file