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
{{ message }}
Repository navigation
unstable alloc crate can be used without feature gates on the 2018 edition #54006
@alexcrichton Uhhhh this is because we can't stability-check intermediary path components. alloc::vecis stable, it's just alloc that's not - this is the same as std::intrinsics::transmute.
OTOH, I do have a branch where you have to use extern crate alloc; or pass --extern alloc to the compiler, that I'm working on right now. Would that alleviate the issue for now?
The "intermediary path components stability doesn't work" has never been high priority because the root crate always had to be listed as extern crate foo. I would agree that if you don't have to write extern crate foo this is definitely much higher priority now
@nikomatsakis The only way you can access the sysroot crate without knowing its path is the new --extern alloc (without a path), that's being added in #54116, which is unstable.
We can't check stability when we load the crate, because that happens before the query engine is set up, and it's a pretty messy right now to get any useful information across.
What we could do is try to get a stability check into #54145.
Activity
Centril commentedon Sep 7, 2018
Marking as P-high due to edition urgency.
alexcrichton commentedon Sep 10, 2018
This sounds the same as #52489, curious! cc @eddyb
eddyb commentedon Sep 10, 2018
@alexcrichton Uhhhh this is because we can't stability-check intermediary path components.
alloc::vecis stable, it's justallocthat's not - this is the same asstd::intrinsics::transmute.cc @petrochenkov This seems much worse than usual.
OTOH, I do have a branch where you have to use
extern crate alloc;or pass--extern allocto the compiler, that I'm working on right now. Would that alleviate the issue for now?alexcrichton commentedon Sep 10, 2018
Ah yes, indeed!
The "intermediary path components stability doesn't work" has never been high priority because the root crate always had to be listed as
extern crate foo. I would agree that if you don't have to writeextern crate foothis is definitely much higher priority nownikomatsakis commentedon Sep 13, 2018
Can't we check the stability when we do the lazy path resolution?
nikomatsakis commentedon Sep 13, 2018
Sorry, that's not very clear. What I meant is:
Can we do the stability checking when we first load the crate?
pnkfelix commentedon Sep 13, 2018
Visited for triage. Assigning to @eddyb, who sounds like they are on the case.
nikomatsakis commentedon Sep 13, 2018
Another question:
Can you specify
--externto accessallocwithout a feature gate?nikomatsakis commentedon Sep 13, 2018
(If you invoke rustc manually, or maybe by cajoling cargo sufficiently)
eddyb commentedon Sep 13, 2018
@nikomatsakis The only way you can access the sysroot crate without knowing its path is the new
--extern alloc(without a path), that's being added in #54116, which is unstable.We can't check stability when we load the crate, because that happens before the query engine is set up, and it's a pretty messy right now to get any useful information across.
What we could do is try to get a stability check into #54145.