There are 2 RenderBox::hasTrimmedMargin methods. They take in either a PhysicalDirection or std::optional<MarginTrimType>. The version that takes in a physicalDirection simply maps the physical direction to a MarginTrimType and then calls the other version to perform the actual logic. There are pieces of debug code in here that are shared/redundant and will make it tedious to modify as future margin trim patches are landed. Since the version that takes in a PhysicalDirection just performs a mapping and calls the other, we can remove the debug code from it and keep it in the other.
<rdar://problem/107713529>
Actually it's not just strictly debug code. There is also a !isInFlow() check that can be removed too
Pull request: https://github.com/WebKit/WebKit/pull/12464
Committed 262684@main (0c3876d9cb24): <https://commits.webkit.org/262684@main> Reviewed commits have been landed. Closing PR #12464 and removing active labels.