-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cherry-pick 267815.359@safari-7617-branch (1f4ca4f). https://bugs.web…
…kit.org/show_bug.cgi?id=264327 [Hardening] Introduce checkedDowncast<>() and use it in a few places where the type is not obvious https://bugs.webkit.org/show_bug.cgi?id=263463 rdar://117247122 Reviewed by Darin Adler and Ryosuke Niwa. Introduce checkedDowncast<>() and use it in a few places where the type is not obvious (no earlier is<>() check). checkedDowncast<>() is just like downcast<>() but its internal type check is a RELEASE_ASSERT() instead of a debug ASSERT(). In the future, we may want to promote using either dynamicDowncast<>() or checkedDowncast<>() and maybe phasing out downcast<>() (in which case we could rename checkedDowncast<>() to downcast()). * Source/WTF/wtf/Ref.h: (WTF::checkedDowncast): * Source/WTF/wtf/RefPtr.h: (WTF::checkedDowncast): * Source/WTF/wtf/TypeCasts.h: (WTF::checkedDowncast): * Source/WebCore/html/shadow/DateTimeEditElement.cpp: (WebCore::DateTimeEditElement::fieldsWrapperElement const): * Source/WebCore/html/shadow/DateTimeFieldElement.cpp: (WebCore::DateTimeFieldElement::updateVisibleValue): * Source/WebCore/html/shadow/DetailsMarkerControl.cpp: (WebCore::DetailsMarkerControl::rendererIsNeeded): * Source/WebCore/html/shadow/ProgressShadowElement.cpp: (WebCore::ProgressShadowElement::progressElement const): * Source/WebCore/html/shadow/SliderThumbElement.cpp: (WebCore::RenderSliderContainer::computeLogicalHeight const): (WebCore::RenderSliderContainer::layout): (WebCore::SliderThumbElement::hostInput const): * Source/WebCore/html/shadow/TextControlInnerElements.cpp: (WebCore::isStrongPasswordTextField): (WebCore::TextControlInnerTextElement::renderer const): (WebCore::TextControlInnerTextElement::resolveCustomStyle): (WebCore::TextControlPlaceholderElement::resolveCustomStyle): (WebCore::SearchFieldResultsButtonElement::defaultEventHandler): (WebCore::SearchFieldCancelButtonElement::resolveCustomStyle): (WebCore::SearchFieldCancelButtonElement::defaultEventHandler): (WebCore::SearchFieldCancelButtonElement::willRespondToMouseClickEventsWithEditability const): Canonical link: https://commits.webkit.org/267815.359@safari-7617-branch Canonical link: https://commits.webkit.org/266719.162@webkitglib/2.42
- Loading branch information
1 parent
c3ca39c
commit 53cf2a6
Showing
9 changed files
with
57 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters