Avoid ambiguities with any user-defined tracing modules by globally qualifying types used in the attribute-generated code e.g., ::tracing::Level.
Fixes: #3119 for the v0.1.x crate versions.
Motivation
We need to define helper functions for tracing within our own crates, and tracing is too good a name to pass up. Our helpers will mostly wrap and otherwise "hide" the tracing crate, but when using #[instrument] the generated code conflicts with our tracing module.
Solution
Globally qualify any token paths e.g., ::tracing to avoid ambiguities.
Avoid ambiguities with any user-defined
tracing
modules by globally qualifying types used in the attribute-generated code e.g.,::tracing::Level
.Fixes: #3119 for the v0.1.x crate versions.
Motivation
We need to define helper functions for tracing within our own crates, and
tracing
is too good a name to pass up. Our helpers will mostly wrap and otherwise "hide" thetracing
crate, but when using#[instrument]
the generated code conflicts with ourtracing
module.Solution
Globally qualify any token paths e.g.,
::tracing
to avoid ambiguities.