Implement ForeachStatement for (static) Arrays

I am currently stuck at the semantic analysis.
because depending on the type of the expression that is itterated foreach does diffrent things
how I check If the itterated type has thoose methods ?
-  `popFront()`/`front()`
-  `opApply`

There is an autoBlock function in statementvisitor (I don't remeber the name exactly, but something like that) that will create a block when needed. It is used for other forms of look, scope, if and probably other things.