Rust 1.29.0 is out!


#21

I’ve had similar issues with network drives on Windows with releases past.
At least for now it’s best to steer clear of doing any development on network drives, for the sake of your own sanity.


#22

As a workaround, maybe you can leave your source on R: and set CARGO_TARGET_DIR to somewhere on C: so the compiler doesn’t need to worry. Your error is from LLVM, which should only need IO to write the output files.


#23

But if there’s an unused variable, how does cargo fix know that I meant to actually use it somewhere (like counter which I should have been doing counter += 1 on but wasn’t)? I guess cargo fix will just go ahead and change that to _counter and at that point the warning vanishes and I miss an opportunity to fix a genuine bug. Or am I understanding this wrongly?


#24

No, you understand correctly.
On the other hand, for how long do you generally leave a variable unused if you were already planning to use it?

Of course unused var is the most trivial of warnings. For the meatier warnings (and perhaps even a few types of errors here and there) cargo fix will be useful. That said, I think it would also be useful for cargo fix to grow a way to opt-out of fixing certain warnings.


#25

Thanks for that suggestion. It works for the example, so I’ve now updated my build .bat files for my main applications to do the builds on C:. This works for 1.28 and 1.29, so I can now upgrade to 1.29. Thanks for your help.


#26

Hmm… Maybe the right workflow to use cargo fix could be the following three steps:

  1. Manually examine all warnings thrown by rustc.
  2. Fix all of them that point to a real bug by hand, i.e. fix the bug.
  3. For the remaining ones run cargo fix.

Then I can see value for it’s saving me the grunt work.

I was just worried about many or perhaps most programmers who even without cargo fix either ignore warnings altogether or “fix” them by suppressing them. I felt cargo fix is strengthening the hand of people like that.


#27

I’m glad Iterator::flatten is now part of the standard library. Now I can delete my (probably subtly wrong) versions.


#28

The 1.30.0 release notes are now getting written here:


#29

Looking forward to using cargo fix, but for now it appears to be failing on MacOS even on fresh projects; cf

[Onyx:~/tmp] cargo new foo
     Created binary (application) `foo` project
[Onyx:~/tmp] cd foo
[Onyx:~/tmp/foo] cargo fix --verbose
    Checking foo v0.1.0 (file:///Users/shrydar/tmp/foo)                                                                                                            
     Running `/Users/shrydar/.rustup/toolchains/stable-x86_64-apple-darwin/bin/cargo rustc --crate-name foo src/main.rs --crate-type bin --emit=dep-info,metadata -C debuginfo=2 -C metadata=864e9f71b58f2a51 -C extra-filename=-864e9f71b58f2a51 --out-dir /Users/shrydar/tmp/foo/target/debug/deps -C incremental=/Users/shrydar/tmp/foo/target/debug/incremental -L dependency=/Users/shrydar/tmp/foo/target/debug/deps`
     Running `/Users/shrydar/.rustup/toolchains/stable-x86_64-apple-darwin/bin/cargo rustc --crate-name foo src/main.rs --emit=dep-info,metadata -C debuginfo=2 --test -C metadata=8b6898dc521f4897 -C extra-filename=-8b6898dc521f4897 --out-dir /Users/shrydar/tmp/foo/target/debug/deps -C incremental=/Users/shrydar/tmp/foo/target/debug/incremental -L dependency=/Users/shrydar/tmp/foo/target/debug/deps`
error: failed to execute compile
caused by: Bad relative path
error: Could not compile `foo`.

Caused by:
  process didn't exit successfully: `/Users/shrydar/.rustup/toolchains/stable-x86_64-apple-darwin/bin/cargo rustc --crate-name foo src/main.rs --crate-type bin --emit=dep-info,metadata -C debuginfo=2 -C metadata=864e9f71b58f2a51 -C extra-filename=-864e9f71b58f2a51 --out-dir /Users/shrydar/tmp/foo/target/debug/deps -C incremental=/Users/shrydar/tmp/foo/target/debug/incremental -L dependency=/Users/shrydar/tmp/foo/target/debug/deps` (exit code: 2)
warning: build failed, waiting for other jobs to finish...
error: failed to execute compile
caused by: Bad relative path
error: Could not compile `foo`.

Caused by:
  process didn't exit successfully: `/Users/shrydar/.rustup/toolchains/stable-x86_64-apple-darwin/bin/cargo rustc --crate-name foo src/main.rs --emit=dep-info,metadata -C debuginfo=2 --test -C metadata=8b6898dc521f4897 -C extra-filename=-8b6898dc521f4897 --out-dir /Users/shrydar/tmp/foo/target/debug/deps -C incremental=/Users/shrydar/tmp/foo/target/debug/incremental -L dependency=/Users/shrydar/tmp/foo/target/debug/deps` (exit code: 2)

(active toolchain is
stable-x86_64-apple-darwin (default)
rustc 1.29.0 (aa3ca1994 2018-09-11)
)