With this program:
#lang racket
(module m racket
(provide
(contract-out
[f (-> (or/c slow? (or/c "x" "y")) any)]))
(define (f x) x)
(define (slow? x) (sleep 10) #t))
(require (submod "." m))
(void (f "x"))
when running the contract profiler, I see this output:
$ raco contract-profile x.rkt
Running time is 24.98% contracts
377/1509 ms
(-> (or/c slow? (or/c x y)) any) 377 ms
x.rkt:6:5
f 377 ms
but the contract name is wrong. There should be quotes around x and y.
The contract's name, however, is correct:
> (contract-name (value-contract f))
'(-> (or/c slow? (or/c "x" "y")) any)