From d93b3871501ce971a88de31ce8f0a659c349f2bd Mon Sep 17 00:00:00 2001 From: Alex Knauth Date: Sat, 24 Jan 2015 10:19:13 -0500 Subject: [PATCH] more useful types for hasheqv and hasheq too Closes #16. --- typed-racket-lib/typed-racket/base-env/base-env.rkt | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/typed-racket-lib/typed-racket/base-env/base-env.rkt b/typed-racket-lib/typed-racket/base-env/base-env.rkt index 711ff441..2288e3eb 100644 --- a/typed-racket-lib/typed-racket/base-env/base-env.rkt +++ b/typed-racket-lib/typed-racket/base-env/base-env.rkt @@ -872,8 +872,16 @@ (a b a b . -> . (-HT a b)) (a b a b a b . -> . (-HT a b)) (a b a b a b a b . -> . (-HT a b))))] -[hasheqv (-poly (a b) (-> (-HT a b)))] -[hasheq (-poly (a b) (-> (-HT a b)))] +[hasheqv (-poly (a b) (cl->* (-> (-HT a b)) + (a b . -> . (-HT a b)) + (a b a b . -> . (-HT a b)) + (a b a b a b . -> . (-HT a b)) + (a b a b a b a b . -> . (-HT a b))))] +[hasheq (-poly (a b) (cl->* (-> (-HT a b)) + (a b . -> . (-HT a b)) + (a b a b . -> . (-HT a b)) + (a b a b a b . -> . (-HT a b)) + (a b a b a b a b . -> . (-HT a b))))] [make-hash (-poly (a b) (->opt [(-lst (-pair a b))] (-HT a b)))] [make-hasheq (-poly (a b) (->opt [(-lst (-pair a b))] (-HT a b)))] [make-hasheqv (-poly (a b) (->opt [(-lst (-pair a b))] (-HT a b)))]