mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 05:47:34 +00:00
LibWeb/Layout: Replace isfinite()
with might_be_saturated()
Since we switched to using fixed-point math for CSSPixels, it cannot represent infinite values, so we need to check if the value is saturated instead.
This commit is contained in:
parent
c40e441894
commit
f2a15ecea7
2 changed files with 5 additions and 5 deletions
|
@ -11,7 +11,7 @@ namespace Web::Layout {
|
|||
|
||||
AvailableSize AvailableSize::make_definite(CSSPixels value)
|
||||
{
|
||||
VERIFY(isfinite(value.to_double()));
|
||||
VERIFY(!value.might_be_saturated());
|
||||
return AvailableSize { Type::Definite, value };
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue