Module CList.Smart
When returning a list of same type as the input, maximally shares the suffix of the output which is physically equal to the corresponding suffix of the input
val map : ('a -> 'a) -> 'a list -> 'a list
Like
List.map
but sharing with the input the longest suffix of the output which is physically the same as the input; in particular,Smart.map f l == l
(physically) iff a == a
(physically) for all members of the list