Create for-loop-unconstrained-element-type-i32-fallback.rs

This commit is contained in:
Niko Matsakis 2017-06-15 12:31:45 -04:00 committed by Brian Anderson
parent b568ab6abb
commit 202263d7dc

View file

@ -8,6 +8,10 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// Test that the type of `sum` falls back to `i32` here,
// and that the for loop desugaring doesn't inferfere with
// that.
fn main() {
let mut sum = 0;
for i in Vec::new() {