Skip to content

Commit 97469a6

Browse files
committed
Chore: Fix some typos (Probably only part 1)
1 parent 66c6483 commit 97469a6

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

marker_api/src/context.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ impl<'ast> AstContext<'ast> {
198198
/// ```
199199
///
200200
/// 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:
202202
/// ```text
203203
/// warning: <lint message>
204204
/// --> path/file.rs:1:1

marker_api/src/diagnostic.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ impl<'ast> DiagnosticBuilder<'ast> {
4848
}
4949
}
5050

51-
/// This function sets the main message of this diagnostic message.
51+
/// This function sets the main message of the created diagnostic.
5252
///
5353
/// From rustc a lint emission would look like this:
5454
/// ```text
@@ -66,8 +66,8 @@ impl<'ast> DiagnosticBuilder<'ast> {
6666
self
6767
}
6868

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
7171
/// [`EmissionNode`].
7272
///
7373
/// From rustc a lint emission would look like this:
@@ -267,7 +267,7 @@ impl<'ast> DiagnosticBuilder<'ast> {
267267
let span = self
268268
.span
269269
.as_ref()
270-
.expect("always Some, if `DiagnosticBuilder::emit_lint` is true");
270+
.expect("always `Some`, if `DiagnosticBuilder::emit_lint` is true");
271271
let diag = Diagnostic {
272272
lint: self.lint,
273273
msg: self.msg.as_str().into(),
@@ -311,7 +311,7 @@ pub trait EmissionNode<'ast>: Debug + Copy {
311311
/// [`DiagnosticBuilder::set_main_span`].
312312
///
313313
/// The [`AstContext`] can be used to fetch the [`Span`], if this is implemented on
314-
/// a id.
314+
/// an id.
315315
fn emission_span(&self, _cx: &AstContext<'ast>) -> Option<Span<'ast>>;
316316
}
317317

0 commit comments

Comments
 (0)