Skip to content

statement with no effect warning #42280

@leonardo-m

Description

@leonardo-m

This is an enhancement request. This little program currently compiles with no warnings:

fn main() {
    "sss";
    10;
    10 == 10;
}

Clippy gives three "statement with no effect" warnings. I think such warning should be raised by the rustc compiler too.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions