From 626f807f00760cd32c446f66c3cc73fc485f676c Mon Sep 17 00:00:00 2001 From: Eric Dobson Date: Sat, 18 Aug 2012 14:25:38 -0700 Subject: [PATCH] Removed cert value. --- collects/typed-racket/typecheck/tc-structs.rkt | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/collects/typed-racket/typecheck/tc-structs.rkt b/collects/typed-racket/typecheck/tc-structs.rkt index 22caa51e99..6db3b89ea5 100644 --- a/collects/typed-racket/typecheck/tc-structs.rkt +++ b/collects/typed-racket/typecheck/tc-structs.rkt @@ -160,15 +160,12 @@ ;; the type name that is used in all the types (define name (type-wrapper (make-Name nm))) ;; is this structure covariant in *all* arguments? - (define covariant? (if (and setters? (list? poly?)) - #f - (if poly? - (for*/and ([var (in-list poly?)] - [t (in-list external-fld-types)]) - (let ([variance (hash-ref (free-vars* t) var Constant)]) - (or (eq? variance Constant) - (eq? variance Covariant)))) - #t))) + (define covariant? + (for*/and ([var (in-list poly?)] + [t (in-list external-fld-types)]) + (let ([variance (hash-ref (free-vars* t) var Constant)]) + (or (eq? variance Constant) + (and (not setters?) (eq? variance Covariant)))))) (define parent-count (- (length external-fld-types) (length external-fld-types/no-parent))) ;; the list of names w/ types (register-type struct-type-id (make-StructType sty))