fune/testing/web-platform/tests/css/css-layout-api/inside-multicol-crash.https.html
Morten Stenshorne f22eecbc74 Bug 1665481 [wpt PR 25575] - Custom layout needs to force NG layout for the subtree., a=testonly
Automatic update from web-platform-tests
Custom layout needs to force NG layout for the subtree.

Just like for MathML, custom layout (display:layout()) has no legacy
layout engine implementation, so we need to force NG layout, even when
contained by something that requires legacy fallback.

Rewrote the mechanism somewhat; calling ComputedStyle() on an element
isn't the right thing to do within Element::ShouldForceLegacyLayout()
(it called ShouldForceNGLayout(), which did that), since
ShouldForceLegacyLayout() is involved when style is about to change, or
when it has just been changed. ShouldForceLegacyLayout() will now
return true even if the display type requires LayoutNG. Cope with this
by just not setting ForceLegacyLayout on any NG LayoutObjects at all.
And remove a couple of DCHECKs in NG LayoutObject classes that expected
legacy fallback not to be in use on the Element side.
This is rather convoluted. :(

Also update HTMLSlotElement::AttachLayoutTree(), which recently got
modified to support legacy fallback properly.

This fixes one of three DCHECK failures that occur in the fuzzer test
in bug 1127112.

Bug: 1127112
Change-Id: I16b5f5297cb04192056f6c5137c2cefa1bc33298
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2414289
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Reviewed-by: Frédéric Wang <fwang@igalia.com>
Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org>
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Cr-Commit-Position: refs/heads/master@{#808311}

--

wpt-commits: 4811c33c5a6bc404ccbf334fca80d316bb3d916b
wpt-pr: 25575
2020-09-23 09:03:02 +00:00

8 lines
292 B
HTML

<!DOCTYPE html>
<link rel="author" title="Morten Stenshorne" href="mailto:mstensho@chromium.org">
<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=1127112#c7">
<div style="columns:16;">
<div style="display:layout(child-layout);">
<div></div>
</div>
</div>