Skip to content

Overwriting "-Aunused" does not work any more #216

Closed
@RalfJung

Description

@RalfJung

In Miri, we'd like tests to fail when they contain unused code (as that usually indicates a bug in the test). To achieve this, I have set target_rustcflags to contain -Dwarnings -Dunused. I am pretty sure that when I introduced this (years ago), it worked fine.

However, by pure accident, I just noticed that this does not work any more, and a test with a dead_code warning passes. Now I am worried we might have plenty of bugs in our test suite that got missed due to this. I tried strengthening the flags to include -Fwarnings -Funused -Fdead_code, to no avail.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions