Closed
Bug 1633809
Opened 5 years ago
Closed 5 years ago
Warnings spam while building Firefox with clang
Categories
(Core :: XPCOM, defect, P2)
Core
XPCOM
Tracking
()
RESOLVED
FIXED
mozilla77
Tracking | Status | |
---|---|---|
firefox-esr68 | --- | unaffected |
firefox75 | --- | unaffected |
firefox76 | --- | unaffected |
firefox77 | --- | fixed |
People
(Reporter: mikokm, Assigned: sg)
References
(Regression)
Details
(Keywords: regression)
Attachments
(1 file)
Building on my Macbook gives me around 15k lines of warnings similar to:
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h:213:154: warning: nonnull parameter 'aBasePtr' will evaluate to 'true' on first encounter [-Wpointer-bool-conversion]
2:40.21 do { static_assert( mozilla::detail::AssertionConditionType<decltype(aBasePtr)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(aBasePtr))), 0))) { MOZ_ReportAssertionFailure("aBasePtr", "/Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h", 213); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aBasePtr" ")"); do { *((volatile int*)__null) = 213; ::abort(); } while (false); } } while (false);
2:40.21 ~ ^~~~~~~~
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/nsTArray.h:2755:21: note: in instantiation of function template specialization 'mozilla::WrapNotNullUnchecked<nsIMutationObserver *>' requested here
2:40.21 return mozilla::WrapNotNullUnchecked(
2:40.21 ^
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/nsTObserverArray.h:187:12: note: in instantiation of function template specialization 'nsTArray<nsIMutationObserver *>::AppendElement<nsIMutationObserver *&>' requested here
2:40.21 mArray.AppendElement(std::forward<Item>(aItem));
2:40.21 ^
2:40.21 /Users/miko/Code/mu/dom/base/nsINode.h:1053:27: note: in instantiation of function template specialization 'nsAutoTObserverArray<nsIMutationObserver *, 1>::AppendElement<nsIMutationObserver *&>' requested here
2:40.21 s->mMutationObservers.AppendElement(aMutationObserver);
2:40.21 ^
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h:207:16: note: declared 'nonnull' here
2:40.21 __attribute__((nonnull(1)))
2:40.21 ^
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h:213:154: warning: nonnull parameter 'aBasePtr' will evaluate to 'true' on first encounter [-Wpointer-bool-conversion]
2:40.21 do { static_assert( mozilla::detail::AssertionConditionType<decltype(aBasePtr)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(aBasePtr))), 0))) { MOZ_ReportAssertionFailure("aBasePtr", "/Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h", 213); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aBasePtr" ")"); do { *((volatile int*)__null) = 213; ::abort(); } while (false); } } while (false);
2:40.21 ~ ^~~~~~~~
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/nsTArray.h:2755:21: note: in instantiation of function template specialization 'mozilla::WrapNotNullUnchecked<regiondetails::Strip>' requested here
2:40.21 return mozilla::WrapNotNullUnchecked(
2:40.21 ^
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/nsRegion.h:112:13: note: in instantiation of function template specialization 'nsTArray<regiondetails::Strip>::AppendElement<regiondetails::Strip>' requested here
2:40.21 mStrips.AppendElement(Strip{aRect.X(), aRect.XMost()});
2:40.21 ^
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h:207:16: note: declared 'nonnull' here
2:40.21 __attribute__((nonnull(1)))
2:40.21 ^
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h:213:154: warning: nonnull parameter 'aBasePtr' will evaluate to 'true' on first encounter [-Wpointer-bool-conversion]
2:40.21 do { static_assert( mozilla::detail::AssertionConditionType<decltype(aBasePtr)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(aBasePtr))), 0))) { MOZ_ReportAssertionFailure("aBasePtr", "/Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h", 213); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aBasePtr" ")"); do { *((volatile int*)__null) = 213; ::abort(); } while (false); } } while (false);
2:40.21 ~ ^~~~~~~~
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/nsTArray.h:2755:21: note: in instantiation of function template specialization 'mozilla::WrapNotNullUnchecked<regiondetails::Band>' requested here
2:40.21 return mozilla::WrapNotNullUnchecked(
2:40.21 ^
2:40.21 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/nsRegion.h:606:16: note: in instantiation of function template specialization 'nsTArray<regiondetails::Band>::AppendElement<regiondetails::Band>' requested here
2:40.21 aOut.AppendElement(std::move(newBand));
2:40.21 ^
2:40.22 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h:207:16: note: declared 'nonnull' here
2:40.22 __attribute__((nonnull(1)))
2:40.22 ^
2:40.22 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h:213:154: warning: nonnull parameter 'aBasePtr' will evaluate to 'true' on first encounter [-Wpointer-bool-conversion]
2:40.22 do { static_assert( mozilla::detail::AssertionConditionType<decltype(aBasePtr)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(aBasePtr))), 0))) { MOZ_ReportAssertionFailure("aBasePtr", "/Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h", 213); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aBasePtr" ")"); do { *((volatile int*)__null) = 213; ::abort(); } while (false); } } while (false);
2:40.22 ~ ^~~~~~~~
2:40.22 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/nsTArray.h:2755:21: note: in instantiation of function template specialization 'mozilla::WrapNotNullUnchecked<nsCOMPtr<nsIObserver> >' requested here
2:40.22 return mozilla::WrapNotNullUnchecked(
2:40.22 ^
2:40.22 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/dom/Document.h:318:18: note: in instantiation of function template specialization 'nsTArray<nsCOMPtr<nsIObserver> >::AppendElement<nsIObserver *&>' requested here
2:40.22 mObservers.AppendElement(aObserver);
2:40.22 ^
2:40.22 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h:207:16: note: declared 'nonnull' here
2:40.22 __attribute__((nonnull(1)))
2:40.22 ^
2:40.22 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h:213:154: warning: nonnull parameter 'aBasePtr' will evaluate to 'true' on first encounter [-Wpointer-bool-conversion]
2:40.22 do { static_assert( mozilla::detail::AssertionConditionType<decltype(aBasePtr)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(aBasePtr))), 0))) { MOZ_ReportAssertionFailure("aBasePtr", "/Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/mozilla/NotNull.h", 213); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aBasePtr" ")"); do { *((volatile int*)__null) = 213; ::abort(); } while (false); } } while (false);
2:40.22 ~ ^~~~~~~~
2:40.22 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/nsTArray.h:2755:21: note: in instantiation of function template specialization 'mozilla::WrapNotNullUnchecked<mozilla::dom::Document::SelectorCacheKey *>' requested here
2:40.22 return mozilla::WrapNotNullUnchecked(
2:40.22 ^
2:40.22 /Users/miko/Code/mu/obj-ff-dbg-dist/dist/include/nsExpirationTracker.h:167:16: note: in instantiation of function template specialization 'nsTArray<mozilla::dom::Document::SelectorCacheKey *>::AppendElement<mozilla::dom::Document::SelectorCacheKey *&>' requested here
This was regressed by 1628715 - Part 12: Add WrapNotNullUnchecked for NotNull<T*>.
There is already a suppression for warnings, but it only works for GCC1.
Assignee | ||
Updated•5 years ago
|
Assignee: nobody → sgiesecke
Updated•5 years ago
|
Updated•5 years ago
|
Has Regression Range: --- → yes
Assignee | ||
Comment 1•5 years ago
|
||
Pushed by sgiesecke@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/878dc21be211
Suppress -Wpointer-bool-conversion in WrapNotNullUnchecked. r=miko
Comment 3•5 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 5 years ago
status-firefox77:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla77
Updated•5 years ago
|
Keywords: regression
Comment 4•5 years ago
|
||
Set release status flags based on info from the regressing bug 1628715
status-firefox75:
--- → unaffected
status-firefox76:
--- → unaffected
Updated•5 years ago
|
status-firefox-esr68:
--- → unaffected
You need to log in
before you can comment on or make changes to this bug.
Description
•