Improve not-a-class error message