smol-rs / smol

A small and fast async runtime for Rust

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Compilation error in async-fs on Windows

mjaakkol opened this issue · comments

I develop my stuff on Windows and MacOS and with the latest update Windows side started to cause troubles when pulling in async-fs. I was wondering if anybody else has seen this.

error[E0053]: method security_qos_flags has an incompatible type for trait
--> C:\Users\XXXX.cargo\registry\src\github.com-1ecc6299db9ec823\async-fs-1.3.0\src\lib.rs:1465:5
|
1465 | fn security_qos_flags(&mut self, flags: u32) -> &mut Self {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected struct std::fs::OpenOptions, found struct OpenOptions
|
= note: expected fn pointer fn(&mut OpenOptions, _) -> &mut std::fs::OpenOptions
found fn pointer fn(&mut OpenOptions, _) -> &mut OpenOptions

This is really strange. What is your rustc --version?

I've encounter this as well, which minimum version of rust do we need?

The PR that fixed this in the standard library: rust-lang/rust#74074