aboutsummaryrefslogtreecommitdiff
path: root/src/comp/front/token.rs
diff options
context:
space:
mode:
authorGraydon Hoare <[email protected]>2011-03-16 14:58:02 -0700
committerGraydon Hoare <[email protected]>2011-03-16 14:58:02 -0700
commit54587bdccb7b6771cfc704a30fc0ef2c65824a15 (patch)
tree6f154f9b038e9542b364e87ae887858a96bdb4a9 /src/comp/front/token.rs
parentAdd some more dlopen-related suppressions for the Mac (diff)
downloadrust-54587bdccb7b6771cfc704a30fc0ef2c65824a15.tar.xz
rust-54587bdccb7b6771cfc704a30fc0ef2c65824a15.zip
Switch all vases of vec += elt to vec += vec. Prohibit former in rustboot. Tweak std lib vec fns in process.
Diffstat (limited to 'src/comp/front/token.rs')
-rw-r--r--src/comp/front/token.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/comp/front/token.rs b/src/comp/front/token.rs
index 8c594054..62c6406a 100644
--- a/src/comp/front/token.rs
+++ b/src/comp/front/token.rs
@@ -3,6 +3,7 @@ import util.common.ty_mach_to_str;
import util.common.new_str_hash;
import std._int;
import std._uint;
+import std._str;
tag binop {
PLUS;
@@ -302,8 +303,8 @@ fn to_str(token t) -> str {
case (LIT_CHAR(?c)) {
// FIXME: escape and encode.
auto tmp = "'";
- tmp += c as u8;
- tmp += '\'' as u8;
+ _str.push_byte(tmp, c as u8);
+ _str.push_byte(tmp, '\'' as u8);
ret tmp;
}