Skip to content

Commit b64c0e8

Browse files
committed
---
yaml --- r: 15674 b: refs/heads/try c: 8ab9efe h: refs/heads/master v: v3
1 parent 2f7ef49 commit b64c0e8

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
refs/heads/master: 61b1875c16de39c166b0f4d54bba19f9c6777d1a
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 4a81779abd786ff22d71434c6d9a5917ea4cdfff
5-
refs/heads/try: beece25abefb50cb2db91e5cde1f54e239d6e20a
5+
refs/heads/try: 8ab9efe262d20be8efc90535aeaf4ed9af47f400
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105

branches/try/src/librustsyntax/parse/parser.rs

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -511,9 +511,18 @@ fn parse_path_without_tps(p: parser) -> @ast::path {
511511
let lo = p.span.lo;
512512
let global = eat(p, token::MOD_SEP);
513513
let mut ids = [];
514-
do {
514+
loop {
515+
let is_not_last =
516+
p.look_ahead(2u) != token::LT
517+
&& p.look_ahead(1u) == token::MOD_SEP;
518+
515519
ids += [parse_ident(p)];
516-
} while p.look_ahead(1u) != token::LT && eat(p, token::MOD_SEP);
520+
if is_not_last {
521+
expect(p, token::MOD_SEP);
522+
} else {
523+
break;
524+
}
525+
}
517526
@{span: mk_sp(lo, p.last_span.hi), global: global,
518527
idents: ids, rp: none, types: []}
519528
}

0 commit comments

Comments
 (0)