There are four kinds of exceptions:
Fatal. They aren't your fault and there's nothing you can do about it. Let the program crash.
Vexing. They are the result of unfortunate design decisions. Avoid them if you can. If you can't, catch is vexing exceptions.
Exogenous. They are the result of untidy external realities impinging upon your beautiful, crisp program logic. Try it and be prepared to handle the unfortunate realities.
Boneheaded. These are your own damn fault. These are bugs. Never catch these. Fix your code so that it never triggers a boneheaded exception.
A ClassCastException is #4