Better field type checking