File tree 2 files changed +6
-6
lines changed 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -198,7 +198,7 @@ impl<'ast> AstContext<'ast> {
198
198
/// ```
199
199
///
200
200
/// This will create the same help message as in example 2, but it will be faster
201
- /// if the lint is enabled . The emitted message would look like this:
201
+ /// if the lint is allowed . The emitted message would look like this:
202
202
/// ```text
203
203
/// warning: <lint message>
204
204
/// --> path/file.rs:1:1
Original file line number Diff line number Diff line change @@ -48,7 +48,7 @@ impl<'ast> DiagnosticBuilder<'ast> {
48
48
}
49
49
}
50
50
51
- /// This function sets the main message of this diagnostic message .
51
+ /// This function sets the main message of the created diagnostic .
52
52
///
53
53
/// From rustc a lint emission would look like this:
54
54
/// ```text
@@ -66,8 +66,8 @@ impl<'ast> DiagnosticBuilder<'ast> {
66
66
self
67
67
}
68
68
69
- /// This function sets the main [`Span`] of this diagnostic message .
70
- /// [`AstContext::emit_lint`] will by default use the span of the given
69
+ /// This function sets the main [`Span`] of the created diagnostic .
70
+ /// [`AstContext::emit_lint`] will by default use the [`Span`] of the given
71
71
/// [`EmissionNode`].
72
72
///
73
73
/// From rustc a lint emission would look like this:
@@ -267,7 +267,7 @@ impl<'ast> DiagnosticBuilder<'ast> {
267
267
let span = self
268
268
. span
269
269
. as_ref ( )
270
- . expect ( "always Some, if `DiagnosticBuilder::emit_lint` is true" ) ;
270
+ . expect ( "always ` Some` , if `DiagnosticBuilder::emit_lint` is true" ) ;
271
271
let diag = Diagnostic {
272
272
lint : self . lint ,
273
273
msg : self . msg . as_str ( ) . into ( ) ,
@@ -311,7 +311,7 @@ pub trait EmissionNode<'ast>: Debug + Copy {
311
311
/// [`DiagnosticBuilder::set_main_span`].
312
312
///
313
313
/// The [`AstContext`] can be used to fetch the [`Span`], if this is implemented on
314
- /// a id.
314
+ /// an id.
315
315
fn emission_span ( & self , _cx : & AstContext < ' ast > ) -> Option < Span < ' ast > > ;
316
316
}
317
317
You can’t perform that action at this time.
0 commit comments