Closed
Bug 1410765
Opened 7 years ago
Closed 7 years ago
Three tiny libpref tweaks
Categories
(Core :: Preferences: Backend, enhancement)
Core
Preferences: Backend
Tracking
()
RESOLVED
FIXED
mozilla58
Tracking | Status | |
---|---|---|
firefox58 | --- | fixed |
People
(Reporter: n.nethercote, Assigned: n.nethercote)
References
Details
Attachments
(3 files, 1 obsolete file)
1.11 KB,
patch
|
glandium
:
review+
|
Details | Diff | Splinter Review |
2.89 KB,
patch
|
glandium
:
review+
|
Details | Diff | Splinter Review |
1.06 KB,
patch
|
glandium
:
review+
|
Details | Diff | Splinter Review |
A tiny clean-up.
Assignee | ||
Comment 1•7 years ago
|
||
Attachment #8920923 -
Flags: review?(mh+mozilla)
Assignee | ||
Comment 2•7 years ago
|
||
Attachment #8920924 -
Flags: review?(mh+mozilla)
Assignee | ||
Updated•7 years ago
|
Attachment #8920923 -
Attachment is obsolete: true
Attachment #8920923 -
Flags: review?(mh+mozilla)
Assignee | ||
Comment 3•7 years ago
|
||
Attachment #8920926 -
Flags: review?(mh+mozilla)
Assignee | ||
Comment 4•7 years ago
|
||
Attachment #8920933 -
Flags: review?(mh+mozilla)
Assignee | ||
Updated•7 years ago
|
Summary: Remove unused PrefTypeFlags values → Three tiny libpref tweaks
Comment 5•7 years ago
|
||
Comment on attachment 8920924 [details] [diff] [review]
(part 1) - Remove unused PrefTypeFlags values
Review of attachment 8920924 [details] [diff] [review]:
-----------------------------------------------------------------
::: modules/libpref/Preferences.cpp
@@ -244,5 @@
> PREF_FLAG_LOCKED = 4,
> PREF_FLAG_USERSET = 8,
> - PREF_FLAG_CONFIG = 16,
> - PREF_FLAG_REMOTE = 32,
> - PREF_FLAG_LILOCAL = 64,
FWIW, they were effectively removed in bug 99611.
Attachment #8920924 -
Flags: review?(mh+mozilla) → review+
Updated•7 years ago
|
Attachment #8920926 -
Flags: review?(mh+mozilla) → review+
Comment 6•7 years ago
|
||
Comment on attachment 8920933 [details] [diff] [review]
(part 3) - Remove nsPrefBranch::RemoveObserverFromMap declaration
Review of attachment 8920933 [details] [diff] [review]:
-----------------------------------------------------------------
Static analysis for this kind of stuff could be interesting (declared methods that we never define).
Attachment #8920933 -
Flags: review?(mh+mozilla) → review+
Assignee | ||
Comment 7•7 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/69b08044cafb8a2cf2e2426382084bbd9279137f
Bug 1410765 (part 1) - Remove unused PrefTypeFlags values. r=glandium.
https://hg.mozilla.org/integration/mozilla-inbound/rev/37eb7a2fb6ac6c897f8bccbf0e103a3e2b40159c
Bug 1410765 (part 2) - Redo clang-format on libpref/. r=glandium.
https://hg.mozilla.org/integration/mozilla-inbound/rev/71a01e882f44c3143b9b2dd777f988f58e7af862
Bug 1410765 (part 3) - Remove nsPrefBranch::RemoveObserverFromMap declaration. r=glandium.
Assignee | ||
Comment 8•7 years ago
|
||
> Static analysis for this kind of stuff could be interesting (declared
> methods that we never define).
Sylvestre, do you know if a clang static analysis could be written to detect methods that are declared but never defined? (Like the one removed by part 3 above.)
Comment 10•7 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/69b08044cafb
https://hg.mozilla.org/mozilla-central/rev/37eb7a2fb6ac
https://hg.mozilla.org/mozilla-central/rev/71a01e882f44
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
status-firefox58:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla58
Comment 11•7 years ago
|
||
(In reply to Nicholas Nethercote [:njn] from comment #8)
> > Static analysis for this kind of stuff could be interesting (declared
> > methods that we never define).
>
> Sylvestre, do you know if a clang static analysis could be written to detect
> methods that are declared but never defined? (Like the one removed by part 3
> above.)
This would have several issues:
1. Possibility of external addressing of functions, that is resolved only during linkage. So in a compilation unit we would only define functions that would be externally called by other compilation units.
2. The impossibility of clang to match decl and call simultaneously, in an ast tree, this would have to be done only by transvering manually the tree by matching for each declaration all of the funcCalls and then triage them by signature.
3. There is the possibility to also call functions by pointer to functions or pointers to member function that again will complicate the resolution and would generate a lot of false positives.
Having all of this issues I don't see the real gaining of having this kind of checker, only the fact that we might reduce TXT size.
Assignee | ||
Comment 12•7 years ago
|
||
Fair enough!
Updated•7 years ago
|
Blocks: clang-format
You need to log in
before you can comment on or make changes to this bug.
Description
•