diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/issues/issue-15673.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/test/ui/issues/issue-15673.rs b/src/test/ui/issues/issue-15673.rs new file mode 100644 index 000000000..a8733d7f1 --- /dev/null +++ b/src/test/ui/issues/issue-15673.rs @@ -0,0 +1,9 @@ +// run-pass +#![allow(stable_features)] + +#![feature(iter_arith)] + +fn main() { + let x: [u64; 3] = [1, 2, 3]; + assert_eq!(6, (0..3).map(|i| x[i]).sum::<u64>()); +} |