Fix a crash for Enum class decorated with dataclass (#9104) (#9112)

* Fix a crash when an enum class which is also decorated with a ``dataclasses.dataclass`` decorator is defined.

Closes #9100

* Update test to mention the `astroid` issue that addresses the missing ``__members__`` object.

* Use an `if` instead of the `try/except` block.

* Update pylint/checkers/utils.py

Co-authored-by: Daniël van Noord <13665637+DanielNoord@users.noreply.github.com>

---------

Co-authored-by: Daniël van Noord <13665637+DanielNoord@users.noreply.github.com>
(cherry picked from commit 2c3425dc429293a77a86cd11361a8b268aa8fc91)

Co-authored-by: Mark Byrne <31762852+mbyrnepr2@users.noreply.github.com>
Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
4 files changed