From 33fda1751600fb94b52de0cd059287d014d036a5 Mon Sep 17 00:00:00 2001 From: Eric Dobson Date: Wed, 3 Apr 2013 22:34:52 -0700 Subject: [PATCH] Fix contracts in TR. original commit: 2b8efd66769258c006fd08b571027cdb4fd89a69 --- collects/typed-racket/rep/filter-rep.rkt | 13 +------------ collects/typed-racket/typecheck/signatures.rkt | 2 +- 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/collects/typed-racket/rep/filter-rep.rkt b/collects/typed-racket/rep/filter-rep.rkt index ed022724..5c722cae 100644 --- a/collects/typed-racket/rep/filter-rep.rkt +++ b/collects/typed-racket/rep/filter-rep.rkt @@ -42,18 +42,7 @@ [#:fold-rhs (*OrFilter (map filter-rec-id fs))] [#:frees (λ (f) (combine-frees (map f fs)))]) -(def-filter FilterSet (thn els) - [#:contract (->i ([t any/c] - [e any/c]) - (#:syntax [stx #f]) - #:pre (t e) - (and (cond [(Bot? t) #t] - [(Bot? e) (Top? t)] - [else (Filter/c-predicate? t)]) - (cond [(Bot? e) #t] - [(Bot? t) (Top? e)] - [else (Filter/c-predicate? e)])) - [result FilterSet?])] +(def-filter FilterSet ([thn Filter/c] [els Filter/c]) [#:fold-rhs (*FilterSet (filter-rec-id thn) (filter-rec-id els))]) ;; represents no info about the filters of this expression diff --git a/collects/typed-racket/typecheck/signatures.rkt b/collects/typed-racket/typecheck/signatures.rkt index 44c4211c..d344ccf8 100644 --- a/collects/typed-racket/typecheck/signatures.rkt +++ b/collects/typed-racket/typecheck/signatures.rkt @@ -25,7 +25,7 @@ (define-signature tc-lambda^ ([cond-contracted tc/lambda (syntax? syntax? syntax? . -> . tc-results/c)] [cond-contracted tc/lambda/check (syntax? syntax? syntax? tc-results/c . -> . tc-results/c)] - [cond-contracted tc/rec-lambda/check (syntax? syntax? syntax? syntax? (listof Type/c) tc-results/c . -> . tc-results/c)])) + [cond-contracted tc/rec-lambda/check (syntax? syntax? syntax? (listof Type/c) tc-results/c . -> . tc-results/c)])) (define-signature tc-app^ ([cond-contracted tc/app (syntax? . -> . tc-results/c)]