about summary refs log tree commit diff
path: root/src/libsyntax/print/pp.rs
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2013-05-12 00:25:31 -0400
committerAlex Crichton <alex@alexcrichton.com>2013-05-14 12:24:43 -0400
commit92d39fe4d5e5ad3d2c2dcafe45eaf6e23edddfd7 (patch)
tree817ebba2489c228d8494662b4ce188e0782b321a /src/libsyntax/print/pp.rs
parent2951527528b39dbf47c02b3d329129d677ddcdfd (diff)
downloadrust-92d39fe4d5e5ad3d2c2dcafe45eaf6e23edddfd7.tar.gz
rust-92d39fe4d5e5ad3d2c2dcafe45eaf6e23edddfd7.zip
syntax: Remove #[allow(vecs_implicitly_copyable)]
Diffstat (limited to 'src/libsyntax/print/pp.rs')
-rw-r--r--src/libsyntax/print/pp.rs16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/libsyntax/print/pp.rs b/src/libsyntax/print/pp.rs
index 43f62d72a9f..7944469cb96 100644
--- a/src/libsyntax/print/pp.rs
+++ b/src/libsyntax/print/pp.rs
@@ -457,9 +457,9 @@ pub impl Printer {
             }
         }
     }
-    fn print_str(&mut self, s: ~str) {
+    fn print_str(&mut self, s: &str) {
         while self.pending_indentation > 0 {
-            (*self.out).write_str(~" ");
+            (*self.out).write_str(" ");
             self.pending_indentation -= 1;
         }
         (*self.out).write_str(s);
@@ -562,16 +562,16 @@ pub fn end(p: @mut Printer) { p.pretty_print(END); }
 
 pub fn eof(p: @mut Printer) { p.pretty_print(EOF); }
 
-pub fn word(p: @mut Printer, wrd: ~str) {
-    p.pretty_print(STRING(@/*bad*/ copy wrd, wrd.len() as int));
+pub fn word(p: @mut Printer, wrd: &str) {
+    p.pretty_print(STRING(@/*bad*/ wrd.to_owned(), wrd.len() as int));
 }
 
-pub fn huge_word(p: @mut Printer, wrd: ~str) {
-    p.pretty_print(STRING(@/*bad*/ copy wrd, size_infinity));
+pub fn huge_word(p: @mut Printer, wrd: &str) {
+    p.pretty_print(STRING(@/*bad*/ wrd.to_owned(), size_infinity));
 }
 
-pub fn zero_word(p: @mut Printer, wrd: ~str) {
-    p.pretty_print(STRING(@/*bad*/ copy wrd, 0));
+pub fn zero_word(p: @mut Printer, wrd: &str) {
+    p.pretty_print(STRING(@/*bad*/ wrd.to_owned(), 0));
 }
 
 pub fn spaces(p: @mut Printer, n: uint) { break_offset(p, n, 0); }