Bug 1914682. Downgrade old diagnostic asserts in nsIFrame::SetParent and Init. r=dholbert

There were added in bug 1436505. Nowadays they show up large in profiles, eg bug 1466704.

I checked crash stats, we aren't hitting these.

Differential Revision: https://phabricator.services.mozilla.com/D220052
This commit is contained in:
Timothy Nikkel 2024-08-23 22:08:08 +00:00
parent 4723f37178
commit 3ab31975ef

View File

@ -609,7 +609,7 @@ void nsIFrame::Init(nsIContent* aContent, nsContainerFrame* aParent,
mContent = aContent;
mParent = aParent;
MOZ_DIAGNOSTIC_ASSERT(!mParent || PresShell() == mParent->PresShell());
MOZ_ASSERT(!mParent || PresShell() == mParent->PresShell());
if (aPrevInFlow) {
mWritingMode = aPrevInFlow->GetWritingMode();
@ -11096,7 +11096,7 @@ void nsIFrame::SetParent(nsContainerFrame* aParent) {
// Note that the current mParent may already be destroyed at this point.
mParent = aParent;
MOZ_DIAGNOSTIC_ASSERT(!mParent || PresShell() == mParent->PresShell());
MOZ_ASSERT(!mParent || PresShell() == mParent->PresShell());
if (HasAnyStateBits(NS_FRAME_HAS_VIEW | NS_FRAME_HAS_CHILD_WITH_VIEW)) {
for (nsIFrame* f = aParent;