Rollup merge of #34368 - petrochenkov:astqpath, r=Manishearth

The AST part of https://github.com/rust-lang/rust/pull/34365

plugin-[breaking-change] cc https://github.com/rust-lang/rust/issues/31645
This commit is contained in:
Jeffrey Seyfried 2016-06-25 22:26:47 +00:00
commit 4e2e31c118
10 changed files with 24 additions and 46 deletions

View file

@ -830,7 +830,7 @@ impl<'a> AstBuilder for ExtCtxt<'a> {
}
fn pat_enum(&self, span: Span, path: ast::Path, subpats: Vec<P<ast::Pat>>) -> P<ast::Pat> {
let pat = if subpats.is_empty() {
PatKind::Path(path)
PatKind::Path(None, path)
} else {
PatKind::TupleStruct(path, subpats, None)
};