Given a sequence is there way to get the "constructor" of the sequence?

(sequence-constructor (list 1 2 3))  = list
(sequence-constructor (vector 1 2 3))  = vector
etc

I'd like to use it for a declare-mappable macro that extends functions
of one argument
to map over sequences. As in (sin (list 1 2 3)) = (list (sin 1) (sin
2) (sin 3)).

The sequence-map function is close, but it produces sequences.
Now I could of course hard code the usual suspects, but it seems
somewhat inelegant.

--
Jens Axel Søgaard

____________________
  Racket Users list:
  http://lists.racket-lang.org/users

Reply via email to