Skip to content

Commit 462e47e

Browse files
brsonpaulstansifer
authored andcommitted
rustc: Pass the correct span to syntax extensions
1 parent b55a99c commit 462e47e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/comp/front/parser.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -933,7 +933,8 @@ fn parse_bottom_expr(&parser p) -> @ast::expr {
933933
some(token::COMMA),
934934
pf, p);
935935
hi = es.span.hi;
936-
ex = expand_syntax_ext(p, es.span, pth, es.node,
936+
auto ext_span = rec(lo=lo, hi=hi);
937+
ex = expand_syntax_ext(p, ext_span, pth, es.node,
937938
none[str]);
938939
} else if (eat_word(p, "fail")) {
939940
ex = ast::expr_fail(p.get_ann());

0 commit comments

Comments
 (0)