Closed
Description
- Background: Experimentation with addition of a
const
generic parameter tolibrary/alloc
and usingmacro_rules!
for default values of thoseconst
generic params and also in newwhere
bounds. Daring, of course. - checkout coop-rs@17d14cc
library/alloc
builds well:RUST_BACKTRACE=full x build --stage 0 library/alloc
. (Some (default) implementations are incorrect and they make 3rd party crates not build (whenRUST_BACKTRACE=full x build --stage 0
). It's work in progress. But that shouldn't affect the issue being reported here.)- run
x test tidy --bless
git diff
shows this incorrect change:
git diff
diff --git a/library/alloc/src/vec/mod.rs b/library/alloc/src/vec/mod.rs
index 9d78818fdb5..a8b7d3b8cd7 100644
--- a/library/alloc/src/vec/mod.rs
+++ b/library/alloc/src/vec/mod.rs
@@ -1880,6 +1880,8 @@ struct FillGapOnDrop<'a, T, A: core::alloc::Allocator, const CO_ALLOC_PREF: CoAl
where
[(); { crate::meta_num_slots!(A, CO_ALLOC_PREF) }]:,
{
+ crate::meta_num_slots!(A, CO_ALLOC_PREF) }]:,
+ {
/* Offset of the element we want to check if it is duplicate */
read: usize,
- Now
RUST_BACKTRACE=full x build --stage 0 library/alloc
fails. The above code (beforetidy
) is at https://github.com/coop-rs/rust/blob/17d14cca54391bc87b014976add4fb3ff59ef685/library/alloc/src/vec/mod.rs#L1878. - Unfortunately, I don't have skills, nor capacity, to "minimize" this. I admit I haven't run
x test tidy --bless
frequently. If I notice anything related, I'll update you. - This issue showed up only today (Feb 2, 2023) when I rebased my code on current
master
. However, I don't know if it's caused by anything new inmaster
, or it only showed up by some constellation of my code, or a combination of both... My previous rebase onmaster
was max. 30 hours earlier (but I don't have the previous commits, because Igit push --force
since I'm the only developer on this for now).