From 7b141ad99b620e6b2e7879875f0672f1c634752c Mon Sep 17 00:00:00 2001 From: Huon Wilson Date: Sun, 17 Aug 2014 09:48:40 +1000 Subject: [PATCH] collections: deprecate BTree. This is very half-baked at the moment and very inefficient, e.g. inappropriate use of by-value `self` (and thus being forced into an overuse of `clone`). People get the wrong impression about Rust when using it, e.g. that Rust cannot express what other languages can because the implementation is inefficient. --- src/libcollections/btree.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/libcollections/btree.rs b/src/libcollections/btree.rs index 4c5f8ef09879e..2a9d722d16a0c 100644 --- a/src/libcollections/btree.rs +++ b/src/libcollections/btree.rs @@ -11,6 +11,13 @@ // btree.rs // +// NB. this is not deprecated for removal, just deprecating the +// current implementation. If the major pain-points are addressed +// (overuse of by-value self and .clone), this can be removed. +#![deprecated = "the current implementation is extremely inefficient, \ + prefer a HashMap, TreeMap or TrieMap"] +#![allow(deprecated)] + //! Starting implementation of a btree for rust. //! Structure inspired by github user davidhalperin's gist.