]> git.lizzy.rs Git - rust.git/commitdiff
Rollup merge of #44745 - alexcrichton:no-delim-none, r=estebank
authorCorey Farwell <coreyf@rwell.org>
Sat, 23 Sep 2017 04:29:16 +0000 (00:29 -0400)
committerGitHub <noreply@github.com>
Sat, 23 Sep 2017 04:29:16 +0000 (00:29 -0400)
rustc: Don't use DelimToken::None if possible

This commit fixes a regression from #44601 where lowering attribute to HIR now
involves expanding interpolated tokens to their actual tokens. In that commit
all interpolated tokens were surrounded with a `DelimToken::None` group of
tokens, but this ended up causing regressions like #44730 where the various
attribute parsers in `syntax/attr.rs` weren't ready to cope with
`DelimToken::None`. Instead of fixing the parser in `attr.rs` this commit
instead opts to just avoid the `DelimToken::None` in the first place, ensuring
that the token stream should look the same as it did before where possible.

Closes #44730


No differences found