Fix typo in section '6.10. Macro Expansions' of the Clippy Book
The struct returned by the `Span::ctxt` method was listed as `SpanContext`. The correct struct is currently named `SyntaxContext`.
This commit is contained in:
parent
870e016b65
commit
d66a0ec714
@ -52,7 +52,7 @@ if expr.span.from_expansion() {
|
||||
|
||||
### `Span.ctxt` method
|
||||
|
||||
The `span`'s context, given by the method [`ctxt`] and returning [SpanContext],
|
||||
The `span`'s context, given by the method [`ctxt`] and returning [SyntaxContext],
|
||||
represents if the span is from a macro expansion and, if it is, which
|
||||
macro call expanded this span.
|
||||
|
||||
@ -155,4 +155,4 @@ if in_external_macro(cx.sess(), foo_span) {
|
||||
[`from_expansion`]: https://doc.rust-lang.org/stable/nightly-rustc/rustc_span/struct.Span.html#method.from_expansion
|
||||
[`in_external_macro`]: https://doc.rust-lang.org/stable/nightly-rustc/rustc_middle/lint/fn.in_external_macro.html
|
||||
[Span]: https://doc.rust-lang.org/stable/nightly-rustc/rustc_span/struct.Span.html
|
||||
[SpanContext]: https://doc.rust-lang.org/stable/nightly-rustc/rustc_span/hygiene/struct.SyntaxContext.html
|
||||
[SyntaxContext]: https://doc.rust-lang.org/stable/nightly-rustc/rustc_span/hygiene/struct.SyntaxContext.html
|
||||
|
Loading…
Reference in New Issue
Block a user