about summary refs log tree commit diff
path: root/src/libsyntax/print
diff options
context:
space:
mode:
authorBen Blum <bblum@andrew.cmu.edu>2013-06-20 18:23:25 -0400
committerBen Blum <bblum@andrew.cmu.edu>2013-06-26 18:14:43 -0400
commit7b968783d79301af2305c0b1052092f9d31fd622 (patch)
tree5249ec3d32b5ecfeb7e20c91c66406246a5b68d2 /src/libsyntax/print
parent12e09afd6d7bb4ca30e572a5214c11284ea1965b (diff)
downloadrust-7b968783d79301af2305c0b1052092f9d31fd622.tar.gz
rust-7b968783d79301af2305c0b1052092f9d31fd622.zip
Infer default static/Owned bounds for unbounded heap fns/traits (#7264)
Diffstat (limited to 'src/libsyntax/print')
-rw-r--r--src/libsyntax/print/pprust.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/libsyntax/print/pprust.rs b/src/libsyntax/print/pprust.rs
index 277cc6208fb..0be8c31647f 100644
--- a/src/libsyntax/print/pprust.rs
+++ b/src/libsyntax/print/pprust.rs
@@ -1488,7 +1488,7 @@ pub fn print_for_decl(s: @ps, loc: @ast::local, coll: @ast::expr) {
 }
 
 fn print_path_(s: @ps, path: @ast::Path, colons_before_params: bool,
-               opt_bounds: Option<@OptVec<ast::TyParamBound>>) {
+               opt_bounds: &Option<OptVec<ast::TyParamBound>>) {
     maybe_print_comment(s, path.span.lo);
     if path.global { word(s.s, "::"); }
     let mut first = true;
@@ -1496,7 +1496,7 @@ fn print_path_(s: @ps, path: @ast::Path, colons_before_params: bool,
         if first { first = false; } else { word(s.s, "::"); }
         print_ident(s, *id);
     }
-    do opt_bounds.map_consume |bounds| {
+    do opt_bounds.map |bounds| {
         print_bounds(s, bounds);
     };
     if path.rp.is_some() || !path.types.is_empty() {
@@ -1520,12 +1520,12 @@ fn print_path_(s: @ps, path: @ast::Path, colons_before_params: bool,
 }
 
 pub fn print_path(s: @ps, path: @ast::Path, colons_before_params: bool) {
-    print_path_(s, path, colons_before_params, None)
+    print_path_(s, path, colons_before_params, &None)
 }
 
 pub fn print_bounded_path(s: @ps, path: @ast::Path,
-                          bounds: @OptVec<ast::TyParamBound>) {
-    print_path_(s, path, false, Some(bounds))
+                          bounds: &Option<OptVec<ast::TyParamBound>>) {
+    print_path_(s, path, false, bounds)
 }
 
 pub fn print_irrefutable_pat(s: @ps, pat: @ast::pat) {
@@ -1737,7 +1737,7 @@ pub fn print_fn_block_args(s: @ps, decl: &ast::fn_decl) {
     maybe_print_comment(s, decl.output.span.lo);
 }
 
-pub fn print_bounds(s: @ps, bounds: @OptVec<ast::TyParamBound>) {
+pub fn print_bounds(s: @ps, bounds: &OptVec<ast::TyParamBound>) {
     if !bounds.is_empty() {
         word(s.s, ":");
         let mut first = true;