about summary refs log tree commit diff
path: root/src/libgraphviz
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2015-01-01 23:53:35 -0800
committerAlex Crichton <alex@alexcrichton.com>2015-01-03 23:43:57 -0800
commit7d8d06f86b48520814596bd5363d2b82bc619774 (patch)
treeeda093ca208286fd8679da8de9f3597b7a024c50 /src/libgraphviz
parent470118f3e915cdc8f936aca0640b28a7a3d8dc6c (diff)
Remove deprecated functionality
This removes a large array of deprecated functionality, regardless of how
recently it was deprecated. The purpose of this commit is to clean out the
standard libraries and compiler for the upcoming alpha release.

Some notable compiler changes were to enable warnings for all now-deprecated
command line arguments (previously the deprecated versions were silently
accepted) as well as removing deriving(Zero) entirely (the trait was removed).

The distribution no longer contains the libtime or libregex_macros crates. Both
of these have been deprecated for some time and are available externally.
Diffstat (limited to 'src/libgraphviz')
-rw-r--r--src/libgraphviz/lib.rs6
-rw-r--r--src/libgraphviz/maybe_owned_vec.rs9
2 files changed, 4 insertions, 11 deletions
diff --git a/src/libgraphviz/lib.rs b/src/libgraphviz/lib.rs
index e5a8db54eab..f151102f286 100644
--- a/src/libgraphviz/lib.rs
+++ b/src/libgraphviz/lib.rs
@@ -278,7 +278,7 @@ pub use self::LabelText::*;
 
 use std::borrow::IntoCow;
 use std::io;
-use std::str::CowString;
+use std::string::CowString;
 use std::vec::CowVec;
 
 pub mod maybe_owned_vec;
@@ -589,8 +589,8 @@ mod tests {
     use super::{Id, LabelText, LabelStr, EscStr, Labeller};
     use super::{Nodes, Edges, GraphWalk, render};
     use std::io::IoResult;
-    use std::str;
     use std::borrow::IntoCow;
+    use std::iter::repeat;
 
     /// each node is an index in a vector in the graph.
     type Node = uint;
@@ -638,7 +638,7 @@ mod tests {
         fn to_opt_strs(self) -> Vec<Option<&'static str>> {
             match self {
                 UnlabelledNodes(len)
-                    => Vec::from_elem(len, None).into_iter().collect(),
+                    => repeat(None).take(len).collect(),
                 AllNodesLabelled(lbls)
                     => lbls.into_iter().map(
                         |l|Some(l)).collect(),
diff --git a/src/libgraphviz/maybe_owned_vec.rs b/src/libgraphviz/maybe_owned_vec.rs
index 901dffc04c5..04aa6d16495 100644
--- a/src/libgraphviz/maybe_owned_vec.rs
+++ b/src/libgraphviz/maybe_owned_vec.rs
@@ -12,7 +12,7 @@
 
 pub use self::MaybeOwnedVector::*;
 
-use std::cmp::{Equiv, Ordering};
+use std::cmp::Ordering;
 use std::default::Default;
 use std::fmt;
 use std::iter::FromIterator;
@@ -97,13 +97,6 @@ impl<'a, T: Ord> Ord for MaybeOwnedVector<'a, T> {
     }
 }
 
-#[allow(deprecated)]
-impl<'a, T: PartialEq> Equiv<[T]> for MaybeOwnedVector<'a, T> {
-    fn equiv(&self, other: &[T]) -> bool {
-        self.as_slice() == other
-    }
-}
-
 // The `Vector` trait is provided in the prelude and is implemented on
 // both `&'a [T]` and `Vec<T>`, so it makes sense to try to support it
 // seamlessly.  The other vector related traits from the prelude do