You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ cargo fix --prepare-for 2018 --allow-dirty
Checking cargo-fix-test v0.1.0 (file:///home/jtgeibel/repos/localhost/tmp/cargo-fix-test)
warning: error applying suggestions to `src/lib.rs`
The full error message was:
> Could not replace range 140...162 in file -- maybe parts of it were already replaced?This likely indicates a bug in either rustc or cargo itself,
and we would appreciate a bug report! You're likely to see
a number of compiler warnings after this message which cargo
attempted to fix but failed. If you could open an issue at
https://github.com/rust-lang/cargo/issues
quoting the full output of this command we'd be very appreciative!
warning: absolute paths must start with `self`, `super`, `crate`, or an external crate name in the 2018 edition
--> src/lib.rs:11:9
|
11 | ::generic_return::<::B>();
| ^^^^^^^^^^^^^^^^^^^^^^^ help: use `crate`: `crate::generic_return::<::B>`
|
= note: `-W absolute-paths-not-starting-with-crate` implied by `-W rust-2018-compatibility`
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in the 2018 edition!
= note: for more information, see issue TBD
warning: absolute paths must start with `self`, `super`, `crate`, or an external crate name in the 2018 edition
--> src/lib.rs:11:28
|
11 | ::generic_return::<::B>();
| ^^^ help: use `crate`: `crate::B`
|
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in the 2018 edition!
= note: for more information, see issue TBD
Finished dev [unoptimized + debuginfo] target(s) in 0.18s
Manual patches
Either of the following patches allows cargo fix to prefix both (now decoupled) paths with crate and exit succesfully.
The following example code is not automatically fixed on the most recent nightly (
cargo 1.29.0-nightly (506eea76e 2018-07-17)
).The issue only occurs when both the outer path and the path inside the turbofish need to be adjusted.
Code
Output
Manual patches
Either of the following patches allows
cargo fix
to prefix both (now decoupled) paths withcrate
and exit succesfully.The text was updated successfully, but these errors were encountered: