From 330a1afae84c7bea583907e5b1f02448a4c7bc20 Mon Sep 17 00:00:00 2001 From: Jakub Bukaj Date: Tue, 18 Nov 2014 00:24:27 +0100 Subject: [PATCH] Fix compilation and tests after the roll-up --- src/libcore/borrow.rs | 1 + src/libgraphviz/lib.rs | 4 ++-- src/librustc/middle/stability.rs | 4 ++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/libcore/borrow.rs b/src/libcore/borrow.rs index 34cf55334ae..f0a14c02382 100644 --- a/src/libcore/borrow.rs +++ b/src/libcore/borrow.rs @@ -47,6 +47,7 @@ use clone::Clone; use kinds::Sized; use ops::Deref; +use self::Cow::*; /// A trait for borrowing data. pub trait BorrowFrom for Sized? { diff --git a/src/libgraphviz/lib.rs b/src/libgraphviz/lib.rs index e3b87e9b9df..44786943676 100644 --- a/src/libgraphviz/lib.rs +++ b/src/libgraphviz/lib.rs @@ -836,7 +836,7 @@ r#"digraph syntax_tree { #[test] fn simple_id_construction() { - let id1 = dot::Id::new("hello"); + let id1 = Id::new("hello"); match id1 { Ok(_) => {;}, Err(_) => panic!("'hello' is not a valid value for id anymore") @@ -845,7 +845,7 @@ r#"digraph syntax_tree { #[test] fn badly_formatted_id() { - let id2 = dot::Id::new("Weird { struct : ure } !!!"); + let id2 = Id::new("Weird { struct : ure } !!!"); match id2 { Ok(_) => panic!("graphviz id suddenly allows spaces, brackets and stuff"), Err(_) => {;} diff --git a/src/librustc/middle/stability.rs b/src/librustc/middle/stability.rs index e3069f54e44..4d0474b68da 100644 --- a/src/librustc/middle/stability.rs +++ b/src/librustc/middle/stability.rs @@ -79,8 +79,8 @@ impl<'v> Visitor<'v> for Annotator { } } - fn visit_fn(&mut self, fk: FnKind<'v>, fd: &'v FnDecl, - b: &'v Block, s: Span, _: NodeId) { + fn visit_fn(&mut self, fk: FnKind<'v>, _: &'v FnDecl, + _: &'v Block, _: Span, _: NodeId) { match fk { FkMethod(_, _, meth) => { // Methods are not already annotated, so we annotate it