Skip to content

Confusing message (empty attribute) in double_must_use #13003

@ChrisJefferson

Description

@ChrisJefferson

Summary

The double_must_use message is:

warning: this function has an empty `#[must_use]` attribute, but returns a type already marked as `#[must_use]`

However, I don't know what an 'empty attribute' is. I tried googling for the term, and nothing came up.

Reproducer

No response

Version

rustc 1.79.0 (129f3b996 2024-06-10)
binary: rustc
commit-hash: 129f3b9964af4d4a709d1383930ade12dfe7c081
commit-date: 2024-06-10
host: x86_64-unknown-linux-gnu
release: 1.79.0
LLVM version: 18.1.7

Additional Labels

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: Clippy is not doing the correct thing

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions