From 84d2a48f81b1acffe744cb54dada157a7b376591 Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Sat, 15 Feb 2020 07:45:22 +0900 Subject: [PATCH] Update section following current state --- src/macro-expansion.md | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/macro-expansion.md b/src/macro-expansion.md index 0c7a7a2e..bc3b9dc5 100644 --- a/src/macro-expansion.md +++ b/src/macro-expansion.md @@ -69,14 +69,13 @@ defined in [`src/librustc_expand/mbe/macro_parser.rs`][code_mp]. The interface of the macro parser is as follows (this is slightly simplified): ```rust,ignore -fn parse( - sess: ParserSession, - tts: TokenStream, - ms: &[TokenTree] +fn parse_tt( + parser: &mut Cow, + ms: &[TokenTree], ) -> NamedParseResult ``` -In this interface: +We use these items in macro parser: - `sess` is a "parsing session", which keeps track of some metadata. Most notably, this is used to keep track of errors that are generated so they can