Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upRemove `extern crate` when migrating to Rust 2018 #52829
Comments
johnthagen
referenced this issue
Jul 29, 2018
Closed
cargo fix: Remove `extern crate` when migrating to Rust 2018 #5829
alexcrichton
added
the
A-edition-2018-lints
label
Jul 29, 2018
alexcrichton
added this to the Rust 2018 RC milestone
Jul 31, 2018
Mark-Simulacrum
modified the milestones:
Rust 2018 RC,
Edition RC 2
Jul 31, 2018
Mark-Simulacrum
added
the
A-rust-2018-preview
label
Jul 31, 2018
This was referenced Aug 24, 2018
alexcrichton
modified the milestones:
Edition RC 2,
Rust 2018 RC
Aug 24, 2018
This comment has been minimized.
This comment has been minimized.
|
I'm moving this forward up on the milestone list due to just having closed #52451 in favor of this issue, which was itself on the RC milestone. |
alexcrichton
self-assigned this
Aug 24, 2018
This comment has been minimized.
This comment has been minimized.
|
Ok so I've some triaging of
I'm testing out some ideas locally as well. |
alexcrichton
added a commit
to alexcrichton/rust
that referenced
this issue
Aug 24, 2018
alexcrichton
referenced this issue
Aug 24, 2018
Merged
rustc: Suggest removing `extern crate` in 2018 #53684
This comment has been minimized.
This comment has been minimized.
|
I believe this should be fixed by #53684, I think the naive solution actually works well! |
alexcrichton
added a commit
to alexcrichton/rust
that referenced
this issue
Aug 27, 2018
Mark-Simulacrum
added a commit
to Mark-Simulacrum/rust
that referenced
this issue
Aug 28, 2018
bors
added a commit
that referenced
this issue
Aug 29, 2018
bors
closed this
in
#53684
Aug 29, 2018
dvc94ch
added a commit
to dvc94ch/rust
that referenced
this issue
Aug 30, 2018
This was referenced Dec 3, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
johnthagen commentedJul 29, 2018
•
edited
Migrated from rust-lang/cargo#5829
It's been mentioned/requested multiple times on the internals thread that
cargo fixshould remove theextern cratestatements when moving to Rust 2018.Motivation
One of the big draws of Rust 2018's module system is that all of the "redundant"
extern cratelines can finally be removed. It took some of the excitement away when I went through all of thecargo fixsteps and still saw them there. I think it will just be a better experience for users to see one of the tangible benefits of this change. As it is right now, they just see thecrate::in front of all of their local imports and they might not realize what a nice change the module system updates really are.After I manually removed the😄 , but let's give this to users on the first go around.
extern crate's I did get my satisfying resultImplementation
If I understand correctly this should be implemented in the compiler under the
#![warn(rust_2018_idioms)]lints, rather thancargo fixitself.cc @alexcrichton