Skip to content
This repository was archived by the owner on Jul 6, 2019. It is now read-only.

Commit 54c8484

Browse files
committed
ioreg::parser: Give correct span to top level group
1 parent bb0939d commit 54c8484

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ioreg/parser.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ impl<'a, 'b> Parser<'a, 'b> {
7979
return None;
8080
}
8181

82+
let sp_lo = self.span.lo;
8283
if !self.expect(&token::LBRACE) {
8384
return None;
8485
}
@@ -94,7 +95,7 @@ impl<'a, 'b> Parser<'a, 'b> {
9495
offset: 0,
9596
name: name,
9697
ty: node::RegUnion(box(GC) regs),
97-
count: dummy_spanned(1),
98+
count: respan(mk_sp(sp_lo, self.span.hi), 1),
9899
docstring: docstring,
99100
};
100101

0 commit comments

Comments
 (0)