Closed Bug 1729598 Opened 3 years ago Closed 3 years ago

Replace MOZ_MUST_USE_TYPE with [[nodiscard]] class attribute

Categories

(Developer Infrastructure :: Source Code Analysis, task, P3)

Tracking

(firefox-esr78 wontfix, firefox-esr91 wontfix, firefox92 wontfix, firefox93 wontfix, firefox94 fixed)

RESOLVED FIXED
94 Branch
Tracking Status
firefox-esr78 --- wontfix
firefox-esr91 --- wontfix
firefox92 --- wontfix
firefox93 --- wontfix
firefox94 --- fixed

People

(Reporter: cpeterson, Assigned: cpeterson)

References

(Blocks 1 open bug)

Details

Attachments

(3 files)

The custom MOZ_MUST_USE_TYPE annotation and clang plugin can now be replaced with C++17's [[nodiscard]] class attribute.

Here is a green Try build:

https://treeherder.mozilla.org/jobs?repo=try&revision=a21a27031ae32805243e361c7bb05f941869ed7c

The build errors for Linux x64 NoOpt asan Bf and OS X Cross Compiled opt B-gcp are not related to my MOZ_MUST_USE_TYPE changes. Here is a green rebuild of those configurations:

https://treeherder.mozilla.org/jobs?repo=try&revision=048db38f21c0ff7daf7601b20dda8f2437216cbb

Pushed by cpeterson@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/96e1a224dce1
Replace MOZ_MUST_USE_TYPE with [[nodiscard]]. r=static-analysis-reviewers,andi
https://hg.mozilla.org/integration/autoland/rev/d547f788e741
Remove now-unused MustUseChecker and MOZ_MUST_USE_TYPE attribute. r=static-analysis-reviewers,andi
https://hg.mozilla.org/integration/autoland/rev/e40c32b70c7e
Remove unused ReportOutOfMemoryResult() function. r=jandem
Product: Firefox Build System → Developer Infrastructure
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: