The following annotation makes it work for me.
#lang typed/racket
(require plot/typed plot/typed/utils)
(: vsum ((Listof (Vectorof Real)) -> (Vectorof Real)))
(define (vsum vs)
(apply (ann vector-map (-> (-> Real * Real) (Vectorof Real) *
(Vectorof Real))) + vs))
I'm not sure why apply is g
Here’s the program:
#lang typed/racket
(require plot/typed plot/typed/utils)
(: vsum ((Listof (Vectorof Real)) -> (Vectorof Real)))
(define (vsum vs)
(apply vector-map + vs))
It’s giving me this error:
. Type Checker: Bad arguments to polymorphic function in apply:
Domain: (a b ... b -> c) (
2 matches
Mail list logo