WebKit Bugzilla
Attachment 340583 Details for
Bug 185728
: [LFC] Replace ASSERT_NOT_REACHED with ASSERT_NOT_IMPLEMENTED_YET where applicable.
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-185728-20180517074232.patch (text/plain), 9.24 KB, created by
zalan
on 2018-05-17 07:42:33 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
zalan
Created:
2018-05-17 07:42:33 PDT
Size:
9.24 KB
patch
obsolete
>Subversion Revision: 231896 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 04999ee119b1816fd1364b74b9d1ef7cc7e4b9c3..83f9ea1b366612d3def83105466a931e647d4c3e 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,28 @@ >+2018-05-17 Zalan Bujtas <zalan@apple.com> >+ >+ [LFC] Replace ASSERT_NOT_REACHED with ASSERT_NOT_IMPLEMENTED_YET where applicable. >+ https://bugs.webkit.org/show_bug.cgi?id=185728 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * layout/FormattingContext.cpp: >+ (WebCore::Layout::FormattingContext::computeOutOfFlowWidth const): leftover from previous patch. >+ (WebCore::Layout::FormattingContext::computeFloatingWidth const): >+ (WebCore::Layout::FormattingContext::computeOutOfFlowHeight const): >+ (WebCore::Layout::FormattingContext::computeOutOfFlowNonReplacedHeight const): >+ (WebCore::Layout::FormattingContext::computeReplacedWidth const): >+ (WebCore::Layout::FormattingContext::computeOutOfFlowNonReplacedWidth const): >+ (WebCore::Layout::FormattingContext::computeOutOfFlowReplacedWidth const): >+ * layout/LayoutContext.cpp: >+ (WebCore::Layout::LayoutContext::styleChanged): >+ (WebCore::Layout::LayoutContext::formattingContext): >+ * layout/blockformatting/BlockFormattingContext.cpp: >+ (WebCore::Layout::BlockFormattingContext::computeInFlowNonReplacedWidth const): >+ (WebCore::Layout::BlockFormattingContext::computeInFlowHeight const): >+ (WebCore::Layout::BlockFormattingContext::computeInFlowNonReplacedHeight const): >+ * layout/layouttree/LayoutTreeBuilder.cpp: >+ (WebCore::Layout::TreeBuilder::createSubTree): >+ > 2018-05-17 Zalan Bujtas <zalan@apple.com> > > [LFC] Move replaced logic from Layout::Box to Layout::Replaced class >diff --git a/Source/WebCore/layout/FormattingContext.cpp b/Source/WebCore/layout/FormattingContext.cpp >index deb596bec78500daa90a4a15e5c95fa14d81c960..180c0a66b5a7845cd0eef2985821c2d8d11b0b06 100644 >--- a/Source/WebCore/layout/FormattingContext.cpp >+++ b/Source/WebCore/layout/FormattingContext.cpp >@@ -84,13 +84,13 @@ void FormattingContext::computeOutOfFlowWidth(LayoutContext& layoutContext, cons > computeOutOfFlowNonReplacedWidth(layoutContext, layoutBox, displayBox); > return; > } >- ASSERT_NOT_REACHED(); >+ ASSERT_NOT_IMPLEMENTED_YET(); > } > > void FormattingContext::computeFloatingWidth(LayoutContext& layoutContext, const Box& layoutBox, Display::Box& displayBox) const > { > if (!layoutBox.replaced()) { >- ASSERT_NOT_REACHED(); >+ ASSERT_NOT_IMPLEMENTED_YET(); > return; > } > computeReplacedWidth(layoutContext, layoutBox, displayBox); >@@ -102,7 +102,7 @@ void FormattingContext::computeOutOfFlowHeight(LayoutContext& layoutContext, con > computeOutOfFlowNonReplacedHeight(layoutContext, layoutBox, displayBox); > return; > } >- ASSERT_NOT_REACHED(); >+ ASSERT_NOT_IMPLEMENTED_YET(); > } > > void FormattingContext::computeFloatingHeight(const Box&, Display::Box&) const >@@ -154,7 +154,7 @@ void FormattingContext::layoutOutOfFlowDescendants(LayoutContext& layoutContext) > > void FormattingContext::computeOutOfFlowNonReplacedHeight(LayoutContext& layoutContext, const Box& layoutBox, Display::Box& displayBox) const > { >- ASSERT(layoutBox.isOutOfFlowPositioned() && !layoutBox.isReplaced()); >+ ASSERT(layoutBox.isOutOfFlowPositioned() && !layoutBox.replaced()); > > // 10.6.4 Absolutely positioned, non-replaced elements > // >@@ -214,7 +214,7 @@ void FormattingContext::computeOutOfFlowNonReplacedHeight(LayoutContext& layoutC > > void FormattingContext::computeReplacedWidth(LayoutContext&, const Box& layoutBox, Display::Box& displayBox) const > { >- ASSERT((layoutBox.isOutOfFlowPositioned() || layoutBox.isFloatingPositioned() || layoutBox.isInFlow()) && layoutBox.isReplaced()); >+ ASSERT((layoutBox.isOutOfFlowPositioned() || layoutBox.isFloatingPositioned() || layoutBox.isInFlow()) && layoutBox.replaced()); > > // 10.3.4 Block-level, replaced elements in normal flow: The used value of 'width' is determined as for inline replaced elements. > // 10.3.6 Floating, replaced elements: The used value of 'width' is determined as for inline replaced elements. >@@ -254,7 +254,7 @@ void FormattingContext::computeReplacedWidth(LayoutContext&, const Box& layoutBo > } else if (width.isAuto() && height.isAuto() && replaced->hasIntrinsicRatio()) { > // #3 > // FIXME: undefined but surely doable. >- ASSERT_NOT_REACHED(); >+ ASSERT_NOT_IMPLEMENTED_YET(); > } else if (width.isAuto() && replaced->hasIntrinsicWidth()) { > // #4 > computedWidthValue = replaced->intrinsicWidth(); >@@ -297,7 +297,7 @@ LayoutUnit FormattingContext::contentHeightForFormattingContextRoot(LayoutContex > > void FormattingContext::computeOutOfFlowNonReplacedWidth(LayoutContext& layoutContext, const Box& layoutBox, Display::Box& displayBox) const > { >- ASSERT(layoutBox.isOutOfFlowPositioned() && !layoutBox.isReplaced()); >+ ASSERT(layoutBox.isOutOfFlowPositioned() && !layoutBox.replaced()); > > // 10.3.7 Absolutely positioned, non-replaced elements > // >@@ -351,7 +351,7 @@ void FormattingContext::computeOutOfFlowNonReplacedWidth(LayoutContext& layoutCo > > void FormattingContext::computeOutOfFlowReplacedWidth(LayoutContext& layoutContext, const Box& layoutBox, Display::Box& displayBox) const > { >- ASSERT(layoutBox.isOutOfFlowPositioned() && layoutBox.isReplaced()); >+ ASSERT(layoutBox.isOutOfFlowPositioned() && layoutBox.replaced()); > // 10.3.8 Absolutely positioned, replaced elements > // > // The used value of 'width' is determined as for inline replaced elements. >diff --git a/Source/WebCore/layout/LayoutContext.cpp b/Source/WebCore/layout/LayoutContext.cpp >index 7718786bfdcfaff0926b60ac879754246a466513..c6b06a3aef3d78d017983b5cd4d4b915881eece1 100644 >--- a/Source/WebCore/layout/LayoutContext.cpp >+++ b/Source/WebCore/layout/LayoutContext.cpp >@@ -79,7 +79,7 @@ void LayoutContext::styleChanged(const Box& layoutBox, StyleDiff styleDiff) > else if (is<InlineFormattingState>(formattingState)) > invalidationRoot = InlineInvalidation::invalidate(layoutBox, styleDiff, *this, downcast<InlineFormattingState>(formattingState)).root; > else >- ASSERT_NOT_REACHED(); >+ ASSERT_NOT_IMPLEMENTED_YET(); > ASSERT(invalidationRoot); > m_formattingContextRootListForLayout.addVoid(invalidationRoot); > } >@@ -110,7 +110,7 @@ std::unique_ptr<FormattingContext> LayoutContext::formattingContext(const Box& f > if (formattingContextRoot.establishesInlineFormattingContext()) > return std::make_unique<InlineFormattingContext>(formattingContextRoot); > >- ASSERT_NOT_REACHED(); >+ ASSERT_NOT_IMPLEMENTED_YET(); > return nullptr; > } > >diff --git a/Source/WebCore/layout/blockformatting/BlockFormattingContext.cpp b/Source/WebCore/layout/blockformatting/BlockFormattingContext.cpp >index 978dfea04d299487ce84c9ab3b917722c8cb003a..267172acce748a67f5671d1ca27728cc9dccfbd3 100644 >--- a/Source/WebCore/layout/blockformatting/BlockFormattingContext.cpp >+++ b/Source/WebCore/layout/blockformatting/BlockFormattingContext.cpp >@@ -154,7 +154,7 @@ void BlockFormattingContext::computeInFlowWidth(LayoutContext& layoutContext, co > > void BlockFormattingContext::computeInFlowNonReplacedWidth(LayoutContext& layoutContext, const Box& layoutBox, Display::Box& displayBox) const > { >- ASSERT(layoutBox.isInFlow() && !layoutBox.isReplaced()); >+ ASSERT(layoutBox.isInFlow() && !layoutBox.replaced()); > > // 10.3.3 Block-level, non-replaced elements in normal flow > // The following constraints must hold among the used values of the other properties: >@@ -189,7 +189,7 @@ void BlockFormattingContext::computeInFlowHeight(LayoutContext& layoutContext, c > computeInFlowNonReplacedHeight(layoutContext, layoutBox, displayBox); > return; > } >- ASSERT_NOT_REACHED(); >+ ASSERT_NOT_IMPLEMENTED_YET(); > } > > LayoutUnit BlockFormattingContext::marginTop(const Box& layoutBox) const >@@ -204,7 +204,7 @@ LayoutUnit BlockFormattingContext::marginBottom(const Box& layoutBox) const > > void BlockFormattingContext::computeInFlowNonReplacedHeight(LayoutContext& layoutContext, const Box& layoutBox, Display::Box& displayBox) const > { >- ASSERT(layoutBox.isInFlow() && !layoutBox.isReplaced()); >+ ASSERT(layoutBox.isInFlow() && !layoutBox.replaced()); > > // https://www.w3.org/TR/CSS22/visudet.html > // If 'height' is 'auto', the height depends on whether the element has any block-level children and whether it has padding or borders: >diff --git a/Source/WebCore/layout/layouttree/LayoutTreeBuilder.cpp b/Source/WebCore/layout/layouttree/LayoutTreeBuilder.cpp >index e78526905f32ccc1d6612684c03d2a8265de5e30..ee67450a929c0c3a8b74d66fa234f13195e10ba5 100644 >--- a/Source/WebCore/layout/layouttree/LayoutTreeBuilder.cpp >+++ b/Source/WebCore/layout/layouttree/LayoutTreeBuilder.cpp >@@ -63,7 +63,7 @@ void TreeBuilder::createSubTree(const RenderElement& rootRenderer, Container& ro > box = new InlineContainer(RenderStyle::clone(child.style())); > createSubTree(child, downcast<Container>(*box)); > } else >- ASSERT_NOT_REACHED(); >+ ASSERT_NOT_IMPLEMENTED_YET(); > > if (!rootContainer.hasChild()) { > rootContainer.setFirstChild(*box);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 185728
: 340583