-
Notifications
You must be signed in to change notification settings - Fork 13.4k
Add timers to core #6435
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I think it change from std::timer to core::timer, |
This was referenced Jun 10, 2013
All the above issues are ones I think will be deprecated when the old stuff in |
I'm taking this |
flip1995
pushed a commit
to flip1995/rust
that referenced
this issue
Dec 20, 2020
…gle-binding, r=ebroto Fixing a false positive for the `match_single_binding` lint rust-lang#5552 This is a fix for a false positive in the `match_single_binding` lint when using `#[cfg()]` on a branch. It is sadly a bit hacky but maybe the best solution as rust removes the other branch from the AST before we can even validate it. This fix looks at the code snippet itself and returns if it includes another thick arrow `=>` besides the one matching arm we found. This can again cause false negatives if someone has the following code: ```rust match x { // => <-- Causes a false negative _ => 1, } ``` I thought about making the code more complex and maybe validating against other things like the `#[cfg()]` macro but I believe that this is the best solution. This has basically switched the issue from a false positive to a false negative in a very specific case. I'm happy to make some changes if you have any suggestions 🙃. --- Fixes rust-lang#5552 changelog: Fixed a false positive in the `match_single_binding` lint with `#[cfg()]` macro
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Timers are provided by the runtime, specifically by uv. We will want a
core::unstable::timer
(to be promoted tocore::timer
) module with an API that can be backed either by libuv or by blocking implementations.The text was updated successfully, but these errors were encountered: