-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Open
Labels
A-tokio-macrosArea: The tokio-macros crateArea: The tokio-macros crateC-requestCategory: A non-feature request, e.g.: metadata updates, optimization suggestion, etc.Category: A non-feature request, e.g.: metadata updates, optimization suggestion, etc.E-help-wantedCall for participation: Help is requested to fix this issue.Call for participation: Help is requested to fix this issue.E-mediumCall for participation: Experience needed to fix: Medium / intermediateCall for participation: Experience needed to fix: Medium / intermediate
Description
Version
tokio-macros 1.8.2
Platform
n/a
Description
In the following code, the variable;
statement has incorrect spans attached to itself:
#[tokio::main]
async fn main() {
let variable = "";
variable;
}
The spans of variable;
point to tokio::runtime::Builder::new_multi_thread()
in the output of the macro. This causes rust-analyzer to (correctly) highlight variable
as a function call and to show the new_multi_thread
function on hover.
Please consider not doing this, as it degrades IDE functionality.
Metadata
Metadata
Assignees
Labels
A-tokio-macrosArea: The tokio-macros crateArea: The tokio-macros crateC-requestCategory: A non-feature request, e.g.: metadata updates, optimization suggestion, etc.Category: A non-feature request, e.g.: metadata updates, optimization suggestion, etc.E-help-wantedCall for participation: Help is requested to fix this issue.Call for participation: Help is requested to fix this issue.E-mediumCall for participation: Experience needed to fix: Medium / intermediateCall for participation: Experience needed to fix: Medium / intermediate