This repository was archived by the owner on Nov 24, 2023. It is now read-only.
This repository was archived by the owner on Nov 24, 2023. It is now read-only.
When a crate name conflicts with a macro, 2015 -> 2018 #153
Closed
Description
in lib.rs:
#[macro_use]
extern crate toml;
In another file:
use toml;
After running cargo fix --edition, it tells me that my code is valid for rust 2015 and rust 2018. When I switch the edition to "2018", I get the following error on the use line:
error[E0658]: imports can only refer to extern crate names passed with `--extern` on stable channel (see issue #53130)
--> xxx.rs:33:5
|
33 | use toml;
| ^^^^ not an extern crate passed with `--extern`
|
note: this import refers to the macro imported here
--> xxx.rs:33:5
|
33 | use toml;
| ^^^^
I guess it's because there is a toml macro that's conflicting with the crate name. I'm not sure what cargo fix can do about that, but I thought I'd report it.
Metadata
Metadata
Assignees
Labels
No labels