UNREACHABLE_CODE in rustc_lint::builtin - Rust
Description: The `unreachable_code` lint detects unreachable code paths.

Skip to main content

## UNREACHABLE_CODE

# Static UNREACHABLE_CODE

Source

    pub static UNREACHABLE_CODE: &'static Lint

Expand description

The `unreachable_code` lint detects unreachable code paths.

#### §Example

    panic!("we never go past here!");

    let x = 5;

{{produces}}

#### §Explanation

Unreachable code may signal a mistake or unfinished code. If the code is no longer in use, consider removing it.