Closed Bug 1469210 Opened 3 years ago Closed 3 years ago

[wpt-sync] Sync PR 11542 - Revert "Floats and out-of-flow objects may not be adjacent to anonymous blocks."

Categories

(Testing :: web-platform-tests, enhancement, P4)

enhancement

Tracking

(firefox63 fixed)

RESOLVED FIXED
mozilla63
Tracking Status
firefox63 --- fixed

People

(Reporter: mozilla.org, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 11542 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/11542
Details from upstream follow.

Abhishek Arya <inferno@chromium.org> wrote:
>  Revert "Floats and out-of-flow objects may not be adjacent to anonymous blocks."
>  
>  This reverts commit 2394d0acf8bf0b0236b2646e4c823a57de7bd941.
>  
>  Reason for revert: Caused ClusterFuzz regressions - 853522, 853537, 853538, 853540.
>  
>  Original change's description:
>  > Floats and out-of-flow objects may not be adjacent to anonymous blocks.
>  > 
>  > Floats and out-of-flow objects need to be true layout siblings of the
>  > inlines, or rendering will be wrong. This means that such objects should
>  > never be siblings of anonymous blocks, but rather inside them. This
>  > already works correctly for initial layout tree building, and also for
>  > many DOM manipulations. However, code was missing to satisfy this
>  > requirement if we removed a regular block that was a sibling of an
>  > anonymous block and either a float or out-of-flow positioned object.
>  > 
>  > This even caused a crash triggered by ruby code, which ended up mixing
>  > inline and block children within the same container. That is not
>  > allowed. This happened in the MoveAllChildrenIncludingFloatsTo() call
>  > inside LayoutRubyBase::MoveBlockChildren(). Added a DCHECK to
>  > MoveAllChildrenIncludingFloatsTo() (which could fail prior to this fix);
>  > When moving children from one container to another, either both or none
>  > of the containers must have inline children.
>  > 
>  > Bug: 852640
>  > Change-Id: I51d3de12c73ddd07d6b4c1aa55221b4f92359ca7
>  > Reviewed-on: https://chromium-review.googlesource.com/1102690
>  > Reviewed-by: Emil A Eklund <eae@chromium.org>
>  > Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
>  > Cr-Commit-Position: refs/heads/master@{#567882}
>  
>  TBR=eae@chromium.org,mstensho@chromium.org
>  
>  # Not skipping CQ checks because original CL landed > 1 day ago.
>  
>  Bug: 852640
>  Change-Id: I0af60d9eac770f21b6a0fbeccf88bb43d5efd6fb
>  
>  Reviewed-on: https://chromium-review.googlesource.com/1103503
>  WPT-Export-Revision: 2bc0d2e79b34706e5555dd90853dc50ee75532ef
PR 11542 applied with additional changes from upstream: ab2182ad1005c11556cf3c0c1ee063d57d13f63e
Pushed by james@hoppipolla.co.uk:
https://hg.mozilla.org/integration/mozilla-inbound/rev/e2f393089662
[wpt PR 11542] - Revert "Floats and out-of-flow objects may not be adjacent to anonymous blocks.", a=testonly
https://hg.mozilla.org/mozilla-central/rev/e2f393089662
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
You need to log in before you can comment on or make changes to this bug.