Cannot impl `std::os::windows::fs::MetadataExt` in stable rust
Open
Nobody has claimed this yet.
A-io
C-bug
T-libs
- Dominant language
- Rust
- Stars
- 119k
- Forks
- 16.1k
- PR merge metrics
- PR metrics pending
Description
The 3 methods added in #63010 makes MetadataExt cannot be implemented in stable rust.
error[E0046]: not all trait items implemented, missing: `volume_serial_number`, `number_of_links`, `file_index`
--> compio-fs\src\metadata\windows.rs:149:1
|
149 | impl MetadataExt for Metadata {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `volume_serial_number`, `number_of_links`, `file_index` in implementation
|
= help: implement the missing item: `fn volume_serial_number(&self) -> Option<u32> { todo!() }`
= help: implement the missing item: `fn number_of_links(&self) -> Option<u32> { todo!() }`
= help: implement the missing item: `fn file_index(&self) -> Option<u64> { todo!() }`
The trait should provide default impls for them.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the std::os::windows::fs::MetadataExt trait and review the three methods added in #63010. Check how the trait is currently defined and confirm that a stable implementation such as the one shown in the report compiles once default implementations are provided for all three methods.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- operating-systems
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100