diff options
| author | Aleksey Kladov <aleksey.kladov@gmail.com> | 2020-07-27 14:04:54 +0200 |
|---|---|---|
| committer | Aleksey Kladov <aleksey.kladov@gmail.com> | 2020-08-02 14:09:25 +0200 |
| commit | 2595d75ea98e6bede1a6c847fe22c8abe3a9401e (patch) | |
| tree | f57df0b05414a96442dc90894acb44993a629027 /src/librustc_parse/parser/path.rs | |
| parent | dfe1e3b641abbede6230e3931d14f0d43e5b8e54 (diff) | |
| download | rust-2595d75ea98e6bede1a6c847fe22c8abe3a9401e.tar.gz rust-2595d75ea98e6bede1a6c847fe22c8abe3a9401e.zip | |
Introduce NonterminalKind
It encapsulate the (part of) the interface between the parser and macro by example (macro_rules) parser. The second bit is somewhat more general `parse_ast_fragment`, which is the reason why we keep some `parse_xxx` functions as public.
Diffstat (limited to 'src/librustc_parse/parser/path.rs')
| -rw-r--r-- | src/librustc_parse/parser/path.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_parse/parser/path.rs b/src/librustc_parse/parser/path.rs index 3dcefd36257..d4e44c54b12 100644 --- a/src/librustc_parse/parser/path.rs +++ b/src/librustc_parse/parser/path.rs @@ -125,7 +125,7 @@ impl<'a> Parser<'a> { /// `a::b::C::<D>` (with disambiguator) /// `Fn(Args)` (without disambiguator) /// `Fn::(Args)` (with disambiguator) - pub fn parse_path(&mut self, style: PathStyle) -> PResult<'a, Path> { + pub(super) fn parse_path(&mut self, style: PathStyle) -> PResult<'a, Path> { maybe_whole!(self, NtPath, |path| { if style == PathStyle::Mod && path.segments.iter().any(|segment| segment.args.is_some()) { |
