Bugfix in type checking functions with polymorphic array parameters.