Make TR tests pass with contracts on again
original commit: 6b954be2c798d092e12b949442ea0ac49f796045
This commit is contained in:
parent
e3fcab3105
commit
b5c485863d
|
@ -42,7 +42,7 @@
|
|||
|
||||
(provide/cond-contract
|
||||
[add-struct-fn! (identifier? StructPE? boolean? . c:-> . c:any/c)]
|
||||
[add-struct-constructor! (identifier? . c:-> . any)]
|
||||
[add-struct-constructor! (identifier? . c:-> . c:any)]
|
||||
[struct-constructor? (identifier? . c:-> . boolean?)]
|
||||
[struct-accessor? (identifier? . c:-> . (c:or/c #f StructPE?))]
|
||||
[struct-mutator? (identifier? . c:-> . (c:or/c #f StructPE?))]
|
||||
|
|
|
@ -240,7 +240,7 @@
|
|||
;; List[(cons Number Number)] type type -> List[(cons Number Number)] or #f
|
||||
;; is s a subtype of t, taking into account previously seen pairs A
|
||||
(define/cond-contract (subtype* A s t)
|
||||
(c:-> (listof (cons/c fixnum? fixnum?)) Type? Type? c:any/c)
|
||||
(c:-> (c:listof (c:cons/c fixnum? fixnum?)) Type? Type? c:any/c)
|
||||
(define ss (unsafe-Rep-seq s))
|
||||
(define st (unsafe-Rep-seq t))
|
||||
(early-return
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
(provide/cond-contract
|
||||
[tc-error/expr ((string?) (#:return c:any/c #:stx syntax?) #:rest (c:listof c:any/c)
|
||||
. c:->* . c:any/c)]
|
||||
[tc-error/expr/fields ((string?) (#:more string? #:return c:any/c #:stx syntax?)
|
||||
[tc-error/expr/fields ((string?) (#:more (c:or/c string? #f) #:return c:any/c #:stx syntax?)
|
||||
#:rest (c:listof c:any/c) . c:->* . c:any/c)]
|
||||
|
||||
[lookup-fail (identifier? . c:-> . Type/c)]
|
||||
|
|
|
@ -57,11 +57,11 @@
|
|||
(t (-Number . -> . -Number))
|
||||
(t (-Promise -Number))
|
||||
(t (-set Univ))
|
||||
(t (-> Univ -Boolean : -Symbol))
|
||||
(t (make-pred-ty -Symbol))
|
||||
(t (->key -Symbol #:key -Boolean #t Univ))
|
||||
(t (make-Function
|
||||
(list (make-arr* (list Univ) -Boolean #:kws (list (make-Keyword '#:key Univ #t))
|
||||
#:filters -Symbol))))
|
||||
#:filters (-FS (-filter -Symbol 0 null) (-not-filter -Symbol 0 null))))))
|
||||
(t (-struct #'struct-name #f (list (make-fld -Symbol #'acc #f))))
|
||||
;; Adapted from PR 13815
|
||||
(t (-poly (a) (-> a a)))
|
||||
|
@ -98,7 +98,7 @@
|
|||
(list (make-arr* (list) -Boolean #:kws (list (make-Keyword '#:key Univ #f)))
|
||||
(make-arr* (list Univ) -Boolean #:kws (list (make-Keyword '#:key2 Univ #f)))))
|
||||
"case function type with optional keyword arguments")
|
||||
(t/fail (-> (-> Univ -Boolean : -Symbol) -Symbol)
|
||||
(t/fail (-> (make-pred-ty -Symbol)-Symbol)
|
||||
"function type with filters or objects")
|
||||
(t/fail (cl->*
|
||||
(-> -Boolean -Boolean)
|
||||
|
|
Loading…
Reference in New Issue
Block a user