-
Notifications
You must be signed in to change notification settings - Fork 1.7k
call to unsafe function is unsafe and requires an unsafe function or block #19557
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
However, it reappears after a while. |
This is probably caused by an outdated version of rust-analyzer you use. See #18842. |
It's not installed locally. It was installed by the VSC plugin. However, I'm not sure if VSC update the package correctly. I've tried reinstalling the plugin, but the problem persists. |
I can't reproduce the problem (with a rust-analyzer prerelease version) on nightly or stable toolchain, so this is probably not a problem in r-a. |
A fresh install of vscode-insiders also gets this error. Interesting. |
Do you also get the same error on a clean project with a call to |
|
Weird, now I get the same error on rust-analyzer invocations of |
This is similar to the situation here. It seems quite unstable, appearing and disappearing randomly. All the solutions that I provided above are only temporary fixes. |
Found that sneaky bug! |
Thanks! I was very confused when Rust-Analyzer started marking functions like |
That bug probably marked half the standard library as unsafe. There is a new nightly release out with the fix now. |
I don't think there is any unsafe code.
This is a serious regression in nightly and it's important to fix it before the next release.
The text was updated successfully, but these errors were encountered: