Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: ad3c1ab54438f924e55d6727caad0c24d70f5d3d
      
https://github.com/WebKit/WebKit/commit/ad3c1ab54438f924e55d6727caad0c24d70f5d3d
  Author: Ahmad Saleem <[email protected]>
  Date:   2026-06-30 (Tue, 30 Jun 2026)

  Changed paths:
    M Source/WebCore/rendering/RenderHighlight.cpp

  Log Message:
  -----------
  Remove redundant m_renderRange.start() null checks in 
RenderHighlight::highlightStateForRenderer
https://bugs.webkit.org/show_bug.cgi?id=318175
rdar://180977788

Reviewed by Alan Baradlay.

The branch is entered only when `&renderer == m_renderRange.start()`. Since
renderer is a reference, &renderer is never null, so m_renderRange.start() is
guaranteed non-null inside the block. The two further m_renderRange.start()
checks were therefore always true: the leading term of the Both test and the
guard on the Start return.

Drop both dead checks. The Start return becomes the unconditional fall-through
after the Both case, and the end() null check is retained since end() can
legitimately be null. No change in behavior.

* Source/WebCore/rendering/RenderHighlight.cpp:
(WebCore::RenderHighlight::highlightStateForRenderer):

Canonical link: https://commits.webkit.org/316115@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to