Skip to content

Commit 24fa710

Browse files
tracing: fix docs typos and warnings(#2581)
## Motivation When reading the docs I noticed some typo's and while fixing them I noticed warnings from cargo doc ## Solution Fixed the typos and the doc warnings in tracing Co-authored-by: Neulichedl, Patrick - D0E05450 <[email protected]>
1 parent 3de7f8c commit 24fa710

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

tracing/src/field.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
//! `Span` and `Event` key-value data.
22
//!
3-
//! Spans and events may be annotated with key-value data, referred to as known
4-
//! as _fields_. These fields consist of a mapping from a key (corresponding to
3+
//! Spans and events may be annotated with key-value data, referred to as _fields_.
4+
//! These fields consist of a mapping from a key (corresponding to
55
//! a `&str` but represented internally as an array index) to a [`Value`].
66
//!
77
//! # `Value`s and `Subscriber`s
88
//!
99
//! `Subscriber`s consume `Value`s as fields attached to [span]s or [`Event`]s.
10-
//! The set of field keys on a given span or is defined on its [`Metadata`].
10+
//! The set of field keys on a given span or event is defined on its [`Metadata`].
1111
//! When a span is created, it provides [`Attributes`] to the `Subscriber`'s
1212
//! [`new_span`] method, containing any fields whose values were provided when
1313
//! the span was created; and may call the `Subscriber`'s [`record`] method
@@ -126,7 +126,6 @@ use crate::Metadata;
126126
/// string comparisons. Thus, if possible, once the key for a field is known, it
127127
/// should be used whenever possible.
128128
/// </pre>
129-
/// </div>
130129
pub trait AsField: crate::sealed::Sealed {
131130
/// Attempts to convert `&self` into a `Field` with the specified `metadata`.
132131
///

tracing/src/span.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -824,7 +824,7 @@ impl Span {
824824
///
825825
/// <pre class="ignore" style="white-space:normal;font:inherit;">
826826
/// <strong>Note</strong>: The returned <a href="../struct.EnteredSpan.html">
827-
/// <code>EnteredSpan</a></code> guard does not implement <code>Send</code>.
827+
/// <code>EnteredSpan</code></a> guard does not implement <code>Send</code>.
828828
/// Dropping the guard will exit <em>this</em> span, and if the guard is sent
829829
/// to another thread and dropped there, that thread may never have entered
830830
/// this span. Thus, <code>EnteredSpan</code>s should not be sent between threads.

0 commit comments

Comments
 (0)