Closed Bug 1114267 Opened 10 years ago Closed 10 years ago

Enforce that MOZ_ONLY_USED_TO_AVOID_STATIC_CONSTRUCTORS classes can only have trivial ctors and dtors

Categories

(Developer Infrastructure :: Source Code Analysis, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
mozilla37

People

(Reporter: ehsan.akhgari, Assigned: ehsan.akhgari)

References

Details

Attachments

(2 files)

No description provided.
Assignee: nobody → ehsan.akhgari
Depends on: 773014
Attachment #8539749 - Flags: review?(jmuizelaar)
Comment on attachment 8539749 [details] [diff] [review] Part 1: Add an analysis to force some classes to have trivial ctors and dtors Review of attachment 8539749 [details] [diff] [review]: ----------------------------------------------------------------- ::: build/clang-plugin/tests/TestTrivialCtorDtor.cpp @@ +9,5 @@ > + BadUserDefinedCtor() {} > +}; > + > +struct MOZ_TRIVIAL_CTOR_DTOR BadUserDefinedDtor { // expected-error {{class 'BadUserDefinedDtor' must have trivial constructors and destructors}} > + BadUserDefinedDtor() {} ~BadUserDefinedDtor
Attachment #8539749 - Flags: review?(jmuizelaar) → review+
Attachment #8539751 - Flags: review?(jmuizelaar) → review+
Status: NEW → RESOLVED
Closed: 10 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla37
Product: Core → Firefox Build System
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: