diff options
| author | flip1995 <hello@philkrones.com> | 2019-11-06 18:15:04 +0100 |
|---|---|---|
| committer | flip1995 <hello@philkrones.com> | 2019-11-06 18:15:04 +0100 |
| commit | 073dbd42182febdf35f5193e891c4e24722dbca9 (patch) | |
| tree | c0c32c359e5b098913350a52ad04fbadba3d6fc6 /tests | |
| parent | d3e88a58b9fad8c68e19c7603ec2725ee26bac29 (diff) | |
| download | rust-073dbd42182febdf35f5193e891c4e24722dbca9.tar.gz rust-073dbd42182febdf35f5193e891c4e24722dbca9.zip | |
Add regression test for ICE #4775
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/ui/ice-4775.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/ui/ice-4775.rs b/tests/ui/ice-4775.rs new file mode 100644 index 00000000000..31e53e846d5 --- /dev/null +++ b/tests/ui/ice-4775.rs @@ -0,0 +1,14 @@ +#![feature(const_generics)] +#![allow(incomplete_features)] + +pub struct ArrayWrapper<const N: usize>([usize; N]); + +impl<const N: usize> ArrayWrapper<{ N }> { + pub fn ice(&self) { + for i in self.0.iter() { + println!("{}", i); + } + } +} + +fn main() {} |
