Fix case-lambda type printing.
Closes PR 12188.
This commit is contained in:
parent
3c3e5902e5
commit
7e9e500818
|
@ -1,6 +1,6 @@
|
||||||
#lang racket/base
|
#lang racket/base
|
||||||
|
|
||||||
(require racket/require racket/match unstable/sequence
|
(require racket/require racket/match unstable/sequence racket/string
|
||||||
(prefix-in s: srfi/1)
|
(prefix-in s: srfi/1)
|
||||||
(path-up "rep/type-rep.rkt" "rep/filter-rep.rkt" "rep/object-rep.rkt"
|
(path-up "rep/type-rep.rkt" "rep/filter-rep.rkt" "rep/object-rep.rkt"
|
||||||
"rep/rep-utils.rkt" "types/abbrev.rkt" "types/subtype.rkt"
|
"rep/rep-utils.rkt" "types/abbrev.rkt" "types/subtype.rkt"
|
||||||
|
@ -167,12 +167,12 @@
|
||||||
[(Function: arities)
|
[(Function: arities)
|
||||||
(let ()
|
(let ()
|
||||||
(match arities
|
(match arities
|
||||||
[(list) "(case-lambda)"]
|
[(list) "(case->)"]
|
||||||
[(list a) (format-arr a)]
|
[(list a) (format-arr a)]
|
||||||
[(list a b ...)
|
[(list a b ...)
|
||||||
(format "(case-lambda ~a~a)"
|
(format "(case-> ~a ~a)"
|
||||||
(format-arr a)
|
(format-arr a)
|
||||||
(apply string-append (map format-arr b)))]))]))
|
(string-join (map format-arr b) " "))]))]))
|
||||||
|
|
||||||
;; print out a type
|
;; print out a type
|
||||||
;; print-type : Type Port Boolean -> Void
|
;; print-type : Type Port Boolean -> Void
|
||||||
|
|
Loading…
Reference in New Issue
Block a user