Skip to content

Commit 78b8f11

Browse files
committed
---
yaml --- r: 175987 b: refs/heads/try c: 6cfbcca h: refs/heads/master i: 175985: de21e3a 175983: 06afd00 v: v3
1 parent 9d398b9 commit 78b8f11

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: a530cc9706324ad44dba464d541a807eb5afdb08
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 777435990e0e91df6b72ce80c9b6fa485eeb5daa
5-
refs/heads/try: d397a3e6545b7ac22c9bce383465e0b3c595587f
5+
refs/heads/try: 6cfbcca41e259ddf93fb86a54e8d5f5bbcd3e6f1
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
88
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596

branches/try/src/grammar/verify.rs

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11-
#![feature(globs, plugin)]
11+
#![feature(plugin)]
1212

1313
extern crate syntax;
1414
extern crate rustc;
@@ -114,7 +114,7 @@ fn parse_token_list(file: &str) -> HashMap<String, token::Token> {
114114
res.insert(num.to_string(), tok);
115115
}
116116

117-
debug!("Token map: {}", res);
117+
debug!("Token map: {:?}", res);
118118
res
119119
}
120120

@@ -162,7 +162,7 @@ fn fixchar(mut lit: &str) -> ast::Name {
162162
parse::token::intern(lit.slice(1, lit.len() - 1))
163163
}
164164

165-
fn count(lit: &str) -> uint {
165+
fn count(lit: &str) -> usize {
166166
lit.chars().take_while(|c| *c == '#').count()
167167
}
168168

@@ -177,12 +177,12 @@ fn parse_antlr_token(s: &str, tokens: &HashMap<String, token::Token>) -> TokenAn
177177
let toknum = m.name("toknum").unwrap_or("");
178178
let content = m.name("content").unwrap_or("");
179179

180-
let proto_tok = tokens.get(toknum).expect(format!("didn't find token {} in the map",
180+
let proto_tok = tokens.get(toknum).expect(format!("didn't find token {:?} in the map",
181181
toknum).as_slice());
182182

183183
let nm = parse::token::intern(content);
184184

185-
debug!("What we got: content (`{}`), proto: {}", content, proto_tok);
185+
debug!("What we got: content (`{}`), proto: {:?}", content, proto_tok);
186186

187187
let real_tok = match *proto_tok {
188188
token::BinOp(..) => token::BinOp(str_to_binop(content)),
@@ -266,7 +266,7 @@ fn main() {
266266
continue
267267
}
268268

269-
assert!(rustc_tok.sp == antlr_tok.sp, "{} and {} have different spans", rustc_tok,
269+
assert!(rustc_tok.sp == antlr_tok.sp, "{:?} and {:?} have different spans", rustc_tok,
270270
antlr_tok);
271271

272272
macro_rules! matches {
@@ -277,12 +277,12 @@ fn main() {
277277
if !tok_cmp(&rustc_tok.tok, &antlr_tok.tok) {
278278
// FIXME #15677: needs more robust escaping in
279279
// antlr
280-
warn!("Different names for {} and {}", rustc_tok, antlr_tok);
280+
warn!("Different names for {:?} and {:?}", rustc_tok, antlr_tok);
281281
}
282282
}
283-
_ => panic!("{} is not {}", antlr_tok, rustc_tok)
283+
_ => panic!("{:?} is not {:?}", antlr_tok, rustc_tok)
284284
},)*
285-
ref c => assert!(c == &antlr_tok.tok, "{} is not {}", rustc_tok, antlr_tok)
285+
ref c => assert!(c == &antlr_tok.tok, "{:?} is not {:?}", rustc_tok, antlr_tok)
286286
}
287287
)
288288
}

0 commit comments

Comments
 (0)