BurntSushi / walkdir

Rust library for walking directories recursively.
The Unlicense
1.27k stars 109 forks source link

Option to stay on same file system #106

Closed agriffis closed 6 years ago

agriffis commented 6 years ago

This is based on #89, to fix #8, with the addition of changes from Andrew's code review.

I'll also try to fix the problems reported by appveyor. Zero prior experience with Rust, so this is all random stabs

agriffis commented 6 years ago

I'll try to keep poking at this, but I'm completely new to rust, so it might take a while to figure out the build errors reported by appveyor

error[E0308]: mismatched types
   --> src\lib.rs:493:39
    |
493 |     windows::windows_file_handle_info(path)
    |                                       ^^^^ expected reference, found type parameter
    |
    = note: expected type `&std::path::PathBuf`
               found type `P`
error[E0308]: mismatched types
   --> src\lib.rs:493:5
    |
492 | fn get_device_num<P: AsRef<Path>>(path: P) -> std::io::Result<i32> {
    |                                               -------------------- expected `std::result::Result<i32, std::io::Error>` because of return type
493 |     windows::windows_file_handle_info(path)
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected i32, found struct `winapi::um::fileapi::BY_HANDLE_FILE_INFORMATION`
    |
    = note: expected type `std::result::Result<i32, _>`
               found type `std::result::Result<winapi::um::fileapi::BY_HANDLE_FILE_INFORMATION, _>`
agriffis commented 6 years ago

Looks like @mckaymatt is working on the build errors in #89 so I'll close this out