Skip to content

[[nodiscard]] on return type causes warning on gcc #18

@no-more-secrets

Description

@no-more-secrets

Demonstration of issue: https://godbolt.org/z/ByihAd

It appears that on gcc, if a function_ref has a return type that is declared with [[nodiscard]] then a -Wunused-result warning is emitted (but not on clang). Any way that we can work around this?

Thanks

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