[REG2.064a] Issue 11261 - Can't infer types without explicit slice in foreach

http://d.puremagic.com/issues/show_bug.cgi?id=11261

This is an insufficient implementation issue in compiler, which has been appeared by the Phobos change (https://github.com/D-Programming-Language/phobos/pull/1308).