summary refs log tree commit diff
path: root/src/libsyntax/parse/token.rs
diff options
context:
space:
mode:
authorRicho Healey <richo@psych0tik.net>2014-05-22 16:57:53 -0700
committerRicho Healey <richo@psych0tik.net>2014-05-24 21:48:10 -0700
commit553074506ecd139eb961fb91eb33ad9fd0183acb (patch)
tree01682cf8147183250713acf5e8a77265aab7153c /src/libsyntax/parse/token.rs
parentbbb70cdd9cd982922cf7390459d53bde409699ae (diff)
downloadrust-553074506ecd139eb961fb91eb33ad9fd0183acb.tar.gz
rust-553074506ecd139eb961fb91eb33ad9fd0183acb.zip
core: rename strbuf::StrBuf to string::String
[breaking-change]
Diffstat (limited to 'src/libsyntax/parse/token.rs')
-rw-r--r--src/libsyntax/parse/token.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/libsyntax/parse/token.rs b/src/libsyntax/parse/token.rs
index 17ce03ba213..e3788801293 100644
--- a/src/libsyntax/parse/token.rs
+++ b/src/libsyntax/parse/token.rs
@@ -21,7 +21,7 @@ use std::fmt;
 use std::path::BytesContainer;
 use std::mem;
 use std::rc::Rc;
-use std::strbuf::StrBuf;
+use std::string::String;
 
 #[allow(non_camel_case_types)]
 #[deriving(Clone, Encodable, Decodable, Eq, TotalEq, Hash, Show)]
@@ -136,7 +136,7 @@ impl fmt::Show for Nonterminal {
     }
 }
 
-pub fn binop_to_str(o: BinOp) -> StrBuf {
+pub fn binop_to_str(o: BinOp) -> String {
     match o {
       PLUS => "+".to_strbuf(),
       MINUS => "-".to_strbuf(),
@@ -151,7 +151,7 @@ pub fn binop_to_str(o: BinOp) -> StrBuf {
     }
 }
 
-pub fn to_str(t: &Token) -> StrBuf {
+pub fn to_str(t: &Token) -> String {
     match *t {
       EQ => "=".to_strbuf(),
       LT => "<".to_strbuf(),
@@ -194,7 +194,7 @@ pub fn to_str(t: &Token) -> StrBuf {
 
       /* Literals */
       LIT_CHAR(c) => {
-          let mut res = StrBuf::from_str("'");
+          let mut res = String::from_str("'");
           c.escape_default(|c| {
               res.push_char(c);
           });
@@ -207,7 +207,7 @@ pub fn to_str(t: &Token) -> StrBuf {
                                                  ast_util::ForceSuffix),
       LIT_INT_UNSUFFIXED(i) => { (i as u64).to_str().to_strbuf() }
       LIT_FLOAT(s, t) => {
-        let mut body = StrBuf::from_str(get_ident(s).get());
+        let mut body = String::from_str(get_ident(s).get());
         if body.as_slice().ends_with(".") {
             body.push_char('0');  // `10.f` is not a float literal
         }
@@ -215,7 +215,7 @@ pub fn to_str(t: &Token) -> StrBuf {
         body
       }
       LIT_FLOAT_UNSUFFIXED(s) => {
-        let mut body = StrBuf::from_str(get_ident(s).get());
+        let mut body = String::from_str(get_ident(s).get());
         if body.as_slice().ends_with(".") {
             body.push_char('0');  // `10.f` is not a float literal
         }