Parameters can overlap with procedure types.
Closes PR 11993.
This commit is contained in:
parent
fd7235f94a
commit
d0fbe825e6
7
collects/tests/typed-racket/succeed/parameter-proc.rkt
Normal file
7
collects/tests/typed-racket/succeed/parameter-proc.rkt
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
#lang typed/racket
|
||||||
|
(require/typed racket
|
||||||
|
(current-directory (-> Path)))
|
||||||
|
|
||||||
|
(unless (equal? (parameter? current-directory)
|
||||||
|
(if (parameter? current-directory) #t #f))
|
||||||
|
(error 'unsound!))
|
|
@ -366,7 +366,7 @@
|
||||||
;; in : Type
|
;; in : Type
|
||||||
;; out : Type
|
;; out : Type
|
||||||
(def-type Param ([in Type/c] [out Type/c])
|
(def-type Param ([in Type/c] [out Type/c])
|
||||||
[#:key 'parameter]
|
[#:key 'procedure]
|
||||||
[#:frees (λ (f) (combine-frees (list (f out) (flip-variances (f in)))))])
|
[#:frees (λ (f) (combine-frees (list (f out) (flip-variances (f in)))))])
|
||||||
|
|
||||||
;; key : Type
|
;; key : Type
|
||||||
|
|
Loading…
Reference in New Issue
Block a user