.. _unreachable:

unreachable / W0101
===================

**Message emitted:**

Unreachable code

**Description:**

*Used when there is some code behind a "return" or "raise" statement, which will never be accessed.*

**Problematic code:**

.. literalinclude:: /data/messages/u/unreachable/bad.py
   :language: python

**Correct code:**

.. literalinclude:: /data/messages/u/unreachable/good.py
   :language: python



Created by the `basic <https://github.com/PyCQA/pylint/blob/main/pylint/checkers/base/basic_checker.py>`__ checker.