diff options
| author | bors <bors@rust-lang.org> | 2019-08-15 00:32:05 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2019-08-15 00:32:05 +0000 |
| commit | 9e9a136fcec5eb78f09a14dfd072a51ae2550269 (patch) | |
| tree | b193fe082d78583740df368de6f546ca35890cbb /src/libsyntax/parse/parser/item.rs | |
| parent | 082cf2f9d136166cd1d552d3fb5abb1c46c99a14 (diff) | |
| parent | 78cd9d1fd5cd59fbab62325b1bcb4bb21c2cb30a (diff) | |
| download | rust-9e9a136fcec5eb78f09a14dfd072a51ae2550269.tar.gz rust-9e9a136fcec5eb78f09a14dfd072a51ae2550269.zip | |
Auto merge of #63575 - Centril:rollup-anlv9g5, r=Centril
Rollup of 11 pull requests Successful merges: - #62984 (Add lint for excess trailing semicolons) - #63075 (Miri: Check that a ptr is aligned and inbounds already when evaluating `*`) - #63490 (libsyntax: cleanup and refactor `pat.rs`) - #63507 (When needing type annotations in local bindings, account for impl Trait and closures) - #63509 (Point at the right enclosing scope when using `await` in non-async fn) - #63528 (syntax: Remove `DummyResult::expr_only`) - #63537 (expand: Unimplement `MutVisitor` on `MacroExpander`) - #63542 (Add NodeId for Arm, Field and FieldPat) - #63543 (Merge Variant and Variant_) - #63560 (move test that shouldn't be in test/run-pass/) - #63570 (Adjust tracking issues for `MaybeUninit<T>` gates) Failed merges: r? @ghost
Diffstat (limited to 'src/libsyntax/parse/parser/item.rs')
| -rw-r--r-- | src/libsyntax/parse/parser/item.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/libsyntax/parse/parser/item.rs b/src/libsyntax/parse/parser/item.rs index e85ef9cc974..60873ecb134 100644 --- a/src/libsyntax/parse/parser/item.rs +++ b/src/libsyntax/parse/parser/item.rs @@ -1564,14 +1564,15 @@ impl<'a> Parser<'a> { None }; - let vr = ast::Variant_ { + let vr = ast::Variant { ident, id: ast::DUMMY_NODE_ID, attrs: variant_attrs, data: struct_def, disr_expr, + span: vlo.to(self.prev_span), }; - variants.push(respan(vlo.to(self.prev_span), vr)); + variants.push(vr); if !self.eat(&token::Comma) { if self.token.is_ident() && !self.token.is_reserved_ident() { |
