[ty] equality narrowing on enums that don't override `__eq__` or `__ne__` (#20285)
Add equality narrowing for enums, if they don't override `__eq__` or `__ne__` in an unsafe way.
Follow-up to PR https://github.com/astral-sh/ruff/pull/20164
Fixes https://github.com/astral-sh/ty/issues/939