diff options
| author | Alex Burka <alex@alexburka.com> | 2017-04-02 19:06:40 +0000 |
|---|---|---|
| committer | Alex Burka <alex@alexburka.com> | 2017-04-15 19:06:19 +0000 |
| commit | 37459e13fc6118eaf0a01a6dae96908414f02a23 (patch) | |
| tree | 4d7b440c5768d0009949651ec47930b44411a30c /src/libsyntax | |
| parent | 06d32335e893a1b5af5dd3f6a8a53dcae266a016 (diff) | |
| download | rust-37459e13fc6118eaf0a01a6dae96908414f02a23.tar.gz rust-37459e13fc6118eaf0a01a6dae96908414f02a23.zip | |
widen :vis follow set
Diffstat (limited to 'src/libsyntax')
| -rw-r--r-- | src/libsyntax/ext/tt/macro_rules.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libsyntax/ext/tt/macro_rules.rs b/src/libsyntax/ext/tt/macro_rules.rs index 84c909284a8..00623dabec4 100644 --- a/src/libsyntax/ext/tt/macro_rules.rs +++ b/src/libsyntax/ext/tt/macro_rules.rs @@ -795,12 +795,12 @@ fn is_in_follow(tok: "ed::TokenTree, frag: &str) -> Result<bool, (String, &' match *tok { TokenTree::Token(_, ref tok) => match *tok { Comma => Ok(true), - ModSep => Ok(true), Ident(i) if i.name != "priv" => Ok(true), - _ => Ok(false) + ref tok => Ok(tok.can_begin_type()) }, - TokenTree::MetaVarDecl(_, _, frag) - if frag.name =="ident" || frag.name == "ty" => Ok(true), + TokenTree::MetaVarDecl(_, _, frag) if frag.name == "ident" + || frag.name == "ty" + || frag.name == "path" => Ok(true), _ => Ok(false) } }, |
