Fixed cast to subclass method call.
Implemented field initialising. Allow sublasses to have fields with the same name.
Implemented type globals generation.
Added hierarchy 2 test.