1
Fork 0

Removed deprecated functions map and flat_map for vectors and slices.

This commit is contained in:
Marvin Löbel 2014-03-28 20:42:34 +01:00
parent 86890b9e7c
commit c356e3ba6a
58 changed files with 278 additions and 325 deletions

View file

@ -1706,7 +1706,7 @@ impl<A:ToJson,B:ToJson,C:ToJson> ToJson for (A, B, C) {
}
impl<A:ToJson> ToJson for ~[A] {
fn to_json(&self) -> Json { List(self.map(|elt| elt.to_json())) }
fn to_json(&self) -> Json { List(self.iter().map(|elt| elt.to_json()).collect()) }
}
impl<A:ToJson> ToJson for TreeMap<~str, A> {