Closed
Bug 773014
Opened 11 years ago
Closed 9 years ago
Add static analysis assertion that Static{Auto,Ref}Ptr is used only in global scope
Categories
(Developer Infrastructure :: Source Code Analysis, defect)
Developer Infrastructure
Source Code Analysis
Tracking
(Not tracked)
RESOLVED
FIXED
mozilla37
People
(Reporter: justin.lebar+bug, Assigned: ehsan.akhgari)
References
Details
Attachments
(2 files, 3 obsolete files)
15.57 KB,
patch
|
jrmuizel
:
review+
|
Details | Diff | Splinter Review |
6.39 KB,
patch
|
jrmuizel
:
review+
|
Details | Diff | Splinter Review |
See bug 772987 -- Static{Auto,Ref}Ptr should be used only in global scope (where its mRawPtr is automatically initialized to 0). Ehsan suggests enforcing this via static analysis.
Assignee | ||
Updated•10 years ago
|
Assignee: nobody → ehsan
Assignee | ||
Comment 1•9 years ago
|
||
Attachment #8536096 -
Flags: review?(jmuizelaar)
Assignee | ||
Comment 2•9 years ago
|
||
Attachment #8536097 -
Flags: review?(jmuizelaar)
Assignee | ||
Updated•9 years ago
|
Attachment #8536096 -
Attachment is obsolete: true
Attachment #8536096 -
Flags: review?(jmuizelaar)
Assignee | ||
Comment 3•9 years ago
|
||
Attachment #8536098 -
Flags: review?(jmuizelaar)
Comment 4•9 years ago
|
||
Comment on attachment 8536098 [details] [diff] [review] Part 1: Add an analysis for marking classes as global-only Review of attachment 8536098 [details] [diff] [review]: ----------------------------------------------------------------- ::: build/clang-plugin/clang-plugin.cpp @@ +38,5 @@ > return astMatcher.newASTConsumer(); > } > > private: > + class LocalGlobalClassChecker : public MatchFinder::MatchCallback { LocalGlobal is a poor name. ScopeClassChecker would be better or even maybe just ScopeChecker.
Attachment #8536098 -
Flags: review?(jmuizelaar) → review+
Assignee | ||
Comment 5•9 years ago
|
||
Note to self: jrmuizel voted for MOZ_ONLY_USED_TO_AVOID_STATIC_CONSTRUCTORS.
Assignee | ||
Updated•9 years ago
|
Attachment #8536098 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8536097 -
Attachment is obsolete: true
Attachment #8536097 -
Flags: review?(jmuizelaar)
Assignee | ||
Comment 6•9 years ago
|
||
Attachment #8539747 -
Flags: review?(jmuizelaar)
Assignee | ||
Comment 7•9 years ago
|
||
Attachment #8539748 -
Flags: review?(jmuizelaar)
Updated•9 years ago
|
Attachment #8539747 -
Flags: review?(jmuizelaar) → review+
Updated•9 years ago
|
Attachment #8539748 -
Flags: review?(jmuizelaar) → review+
Comment 8•9 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/baf97266ac9b https://hg.mozilla.org/mozilla-central/rev/6b3f00c078b1
Status: NEW → RESOLVED
Closed: 9 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla37
Updated•6 years ago
|
Product: Core → Firefox Build System
Updated•1 year ago
|
Product: Firefox Build System → Developer Infrastructure
You need to log in
before you can comment on or make changes to this bug.
Description
•