Skip to content
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

Contents of module with different name gets overwritten on other platform #3956

Closed
JoNil opened this issue Dec 7, 2019 · 0 comments · Fixed by #3971
Closed

Contents of module with different name gets overwritten on other platform #3956

JoNil opened this issue Dec 7, 2019 · 0 comments · Fixed by #3971
Labels
bug Panic, non-idempotency, invalid code, etc.

Comments

@JoNil
Copy link

JoNil commented Dec 7, 2019

I have a file with

#[cfg_attr(target_vendor = "nintendo64", path = "graphics.rs")]
#[cfg_attr(not(target_vendor = "nintendo64"), path = "graphics_emu.rs")]
pub mod graphics;

So when i run cargo fmt the contents of the file graphics_emu.rs is written to the file graphics.rs.

I would expect them both to be formatted and kept in their separate files.

@topecongiro topecongiro added the bug Panic, non-idempotency, invalid code, etc. label Dec 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Panic, non-idempotency, invalid code, etc.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants