]> git.lizzy.rs Git - rust.git/commitdiff
Auto merge of #37290 - petrochenkov:pnp, r=jseyfried
authorbors <bors@rust-lang.org>
Fri, 21 Oct 2016 13:41:45 +0000 (06:41 -0700)
committerGitHub <noreply@github.com>
Fri, 21 Oct 2016 13:41:45 +0000 (06:41 -0700)
syntax: Tweak path parsing logic

Associated paths starting with `<<` are parsed in patterns.

Paths like `self::foo::bar` are interpreted as paths and not as `self` arguments in methods (cc @matklad).
Now, I believe, *all* paths are consistently parsed greedily in case of ambiguity.
Detection of `&'a mut self::` requires pretty large (but still fixed) lookahead, so I had to increase the size of parser's lookahead buffer.
Curiously, if `lookahead_distance >= lookahead_buffer_size` was used previously, the parser hung forever, I fixed this as well, now it ICEs.

r? @jseyfried


Trivial merge