You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description
{
handle.enter(); // IMO Never makes sense to immediately drop the handle.
foo..
}
[short summary of the bug]
For "some" reason we ended up creating 2 runtimes in a project.
We used .enter() to specifically tie some code down to one of specific runtimes.
Missing the ```let _guard = `` part didn't get flagged by the compiler.
Overall caused some confusion as the code rightly didn't work as executed.
runtime {
let nested_runtime = runtime::new
nested_runtime::enter(); // missed the let binding. Intention was to use the nested runtime.
}
I expected to see this happen:
The compiler should have warned, linter should have warned. Code should not have compiled.
Instead, this happened:
Code compiled and didn't worked as intended.
The text was updated successfully, but these errors were encountered:
**Version
tokio v1.3.0 (*)
Platform
all
Description
{
handle.enter(); // IMO Never makes sense to immediately drop the handle.
foo..
}
[short summary of the bug]
For "some" reason we ended up creating 2 runtimes in a project.
We used .enter() to specifically tie some code down to one of specific runtimes.
Missing the ```let _guard = `` part didn't get flagged by the compiler.
Overall caused some confusion as the code rightly didn't work as executed.
I expected to see this happen:
The compiler should have warned, linter should have warned. Code should not have compiled.
Instead, this happened:
Code compiled and didn't worked as intended.
The text was updated successfully, but these errors were encountered: