mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-08 09:09:43 +00:00
LibWeb: Skip dynamic_cast in CSSRGB after we already did a type check
This commit is contained in:
parent
d8188c9f14
commit
57809b1100
Notes:
github-actions[bot]
2025-04-18 12:47:04 +00:00
Author: https://github.com/awesomekling
Commit: 57809b1100
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4395
1 changed files with 1 additions and 1 deletions
|
@ -67,7 +67,7 @@ bool CSSRGB::equals(CSSStyleValue const& other) const
|
||||||
auto const& other_color = other.as_color();
|
auto const& other_color = other.as_color();
|
||||||
if (color_type() != other_color.color_type())
|
if (color_type() != other_color.color_type())
|
||||||
return false;
|
return false;
|
||||||
auto const& other_rgb = as<CSSRGB>(other_color);
|
auto const& other_rgb = static_cast<CSSRGB const&>(other_color);
|
||||||
return m_properties == other_rgb.m_properties;
|
return m_properties == other_rgb.m_properties;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue