diff --git a/ices/98016.sh b/ices/98016.sh new file mode 100644 index 00000000..efc7955b --- /dev/null +++ b/ices/98016.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +rustc --edition=2021 -Zmir-opt-level=3 -Zvalidate-mir - <) -> u16 { + // CHECK: zext <8 x i8> + // CHECK-SAME: to <8 x i16> + // CHECK: call i16 @llvm.vector.reduce.add.v8i16(<8 x i16> + x.to_array().into_iter().map(u16::from).sum() +} + +EOF diff --git a/ices/98171.sh b/ices/98171.sh new file mode 100755 index 00000000..4a5b0ffc --- /dev/null +++ b/ices/98171.sh @@ -0,0 +1,36 @@ +#!/bin/bash + +cat > out.rs <<'EOF' + +// Issue 22443: Reject code using non-regular types that would +// otherwise cause dropck to loop infinitely. + +use std::marker::PhantomData; + +struct Digit { + elem: T +} + +struct Node { m: PhantomData<&'static T> } + + +enum FingerTree { + Single(T), + // Bug report said Digit after Box would stack overflow (versus + // Digit before Box; see dropck_no_diverge_on_nonregular_2). + Deep( + Box>>, + Digit, + ) +} + +fn main() { + let ft = //~ ERROR overflow while adding drop-check rules for FingerTree + FingerTree::Single(1); + //~^ ERROR overflow while adding drop-check rules for FingerTree +} + + +EOF + +rustdoc out.rs diff --git a/ices/98250.sh b/ices/98250.sh new file mode 100755 index 00000000..9baa4c75 --- /dev/null +++ b/ices/98250.sh @@ -0,0 +1,27 @@ +#!/bin/bash + +cat > out.rs <<'EOF' + +#![feature(type_alias_impl_trait)] + +type Foo = impl PartialEq<(Foo, i32)>; + +struct Bar; + +impl PartialEq<(Foo, i32)> for Bar { +//~^ ERROR cannot implement trait on type alias impl trait + fn eq(&self, _other: &(Foo, i32)) -> bool { + true + } +} + +fn foo() -> Foo { + Bar +} + +fn main() {} + + +EOF + +rustdoc out.rs diff --git a/ices/98432.rs b/ices/98432.rs new file mode 100644 index 00000000..e68fbbd9 --- /dev/null +++ b/ices/98432.rs @@ -0,0 +1,12 @@ +struct Struct(T); + +impl Struct { + const CONST: fn() = || { + struct _Obligation + where + T:; + }; +} + +fn main() {} +