Abstract array access refactor

This pull request makes the array access resolution consider abstract field casts for keys and values. It also allows using constrained type parameter.

Fields are now consistently checked from top to bottom, which might be perceived as a regression in rare cases. I'll make sure to document that properly.