Skip to content

Commit 47c8189

Browse files
authored
remove incorrect info (#1435)
1 parent 8ee1ff5 commit 47c8189

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

Diff for: src/the-parser.md

+7-6
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,10 @@ The main entrypoint to the parser is via the various `parse_*` functions and oth
3535
the token stream, and then execute the parser to get a `Crate` (the root AST
3636
node).
3737

38-
To minimise the amount of copying that is done, both the `StringReader` and
39-
`Parser` have lifetimes which bind them to the parent `ParseSess`. This contains
40-
all the information needed while parsing, as well as the `SourceMap` itself.
38+
To minimise the amount of copying that is done,
39+
both [`StringReader`] and [`Parser`] have lifetimes which bind them to the parent `ParseSess`.
40+
This contains all the information needed while parsing,
41+
as well as the [`SourceMap`] itself.
4142

4243
Note that while parsing, we may encounter macro definitions or invocations. We
4344
set these aside to be expanded (see [this chapter](./macro-expansion.md)).
@@ -52,9 +53,9 @@ Code for lexical analysis is split between two crates:
5253
constituting tokens. Although it is popular to implement lexers as generated
5354
finite state machines, the lexer in `rustc_lexer` is hand-written.
5455

55-
- [`StringReader`] from [`rustc_ast`][rustc_ast] integrates `rustc_lexer` with `rustc`
56-
specific data structures. Specifically, it adds `Span` information to tokens
57-
returned by `rustc_lexer` and interns identifiers.
56+
- [`StringReader`] integrates `rustc_lexer` with data structures specific to `rustc`.
57+
Specifically,
58+
it adds `Span` information to tokens returned by `rustc_lexer` and interns identifiers.
5859

5960
[rustc_ast]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_ast/index.html
6061
[rustc_errors]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_errors/index.html

0 commit comments

Comments
 (0)