一个新建的项目,多次编译都无法编译成功,提示错误信息:use of unstable library feature 'once_cell',意思是使用了不稳定的功能库。
执行如下命令可以解决:
rustup update
我这里执行上面的命令时出现下面这样的错误信息,解决的办法是把所有vscode全部关闭(我是用vscode编写rust项目的)重新执行即可。
info: cleaning up downloads & tmp directories
thread 'main' panicked at 'Unable to clean up C:\Users\admin\.rustup\tmp: Os { code: 5, kind: PermissionDenied, message: "拒绝访问。" }', src\utils\utils.rs:650:13
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.