Skip to content

Modules with path still can't be formatted on Windows #3688

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

Closed
95th opened this issue Jul 15, 2019 · 6 comments
Closed

Modules with path still can't be formatted on Windows #3688

95th opened this issue Jul 15, 2019 · 6 comments

Comments

@95th
Copy link

95th commented Jul 15, 2019

#1754 issue is still occuring.

I tried cargo fmt on my tokio checkout and I get several errors like following:

error: couldn't read \\?\D:\tokio\tokio-sync\tests\..\src\mpsc\list.rs: The filename, directory name, or volume label syntax is incorrect. (os error 123)
  --> \\?\D:\tokio\tokio-sync\tests\fuzz_list.rs:14:5
   |
14 | mod list;
   |     ^^^^

code for above is:

#[path = "../src/mpsc/list.rs"]
#[allow(warnings)]
mod list;
@scampi
Copy link
Contributor

scampi commented Jul 15, 2019

Can you try the changes in #3590 and see if that fixes your problem ? Looks like it doesn't for some users...

@95th
Copy link
Author

95th commented Aug 9, 2019

It is not building:

   --> /home/95th/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_target-407.0.0/abi/mod.rs:112:62
    |
112 |                 ["a", ref a..] => dl.aggregate_align = align(a, "a")?,
    |                                                              ^ expected slice, found &str
    |
    = note: expected type `&[&str]`
               found type `&&str`

error[E0308]: mismatched types
   --> /home/95th/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_target-407.0.0/abi/mod.rs:113:58
    |
113 |                 ["f32", ref a..] => dl.f32_align = align(a, "f32")?,
    |                                                          ^ expected slice, found &str
    |
    = note: expected type `&[&str]`
               found type `&&str`

error[E0308]: mismatched types
   --> /home/95th/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_target-407.0.0/abi/mod.rs:114:58
    |
114 |                 ["f64", ref a..] => dl.f64_align = align(a, "f64")?,
    |                                                          ^ expected slice, found &str
    |
    = note: expected type `&[&str]`
               found type `&&str`

error[E0308]: mismatched types
   --> /home/95th/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_target-407.0.0/abi/mod.rs:117:46
    |
117 |                     dl.pointer_align = align(a, p)?;
    |                                              ^ expected slice, found &str
    |
    = note: expected type `&[&str]`
               found type `&&str`

error[E0308]: mismatched types
   --> /home/95th/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_target-407.0.0/abi/mod.rs:127:35
    |
127 |                     let a = align(a, s)?;
    |                                   ^ expected slice, found &str
    |
    = note: expected type `&[&str]`
               found type `&&str`

error[E0308]: mismatched types
   --> /home/95th/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_target-407.0.0/abi/mod.rs:145:35
    |
145 |                     let a = align(a, s)?;
    |                                   ^ expected slice, found &str
    |
    = note: expected type `&[&str]`
               found type `&&str`

error: aborting due to 13 previous errors

@95th
Copy link
Author

95th commented Aug 15, 2019

Hi @scampi, is there any update on this issue please?

@LPGhatguy
Copy link

I just hit this issue today in my repository. The repository and commit that is failing to rustfmt is:

https://github.com/rojo-rbx/rbx-dom/tree/3448e528766b1558ac76addf5e636df797f180ed

@scampi
Copy link
Contributor

scampi commented Sep 20, 2019

@95th Sorry for the delay, I had little time available for this. The branch is now compiling. Thanks for giving it a try!

@topecongiro
Copy link
Contributor

This will be fixed in the 2.0 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants