diff options
| author | Laurenz <laurmaedje@gmail.com> | 2021-01-13 23:19:44 +0100 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2021-01-13 23:19:44 +0100 |
| commit | 272a4c228976466e9fa6cc100ad89f93dc5cc371 (patch) | |
| tree | ad02a6e57b07da061432d58ff0ca46d6777bdb97 /src/geom/length.rs | |
| parent | 1b53e27f270e3c040ee095573af9a5243980191a (diff) | |
Unbounded pages 🌌
Diffstat (limited to 'src/geom/length.rs')
| -rw-r--r-- | src/geom/length.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/geom/length.rs b/src/geom/length.rs index f4d8682e..bfb1d668 100644 --- a/src/geom/length.rs +++ b/src/geom/length.rs @@ -81,6 +81,16 @@ impl Length { Self { raw: self.raw.max(other.raw) } } + /// Whether the length is finite. + pub fn is_finite(self) -> bool { + self.raw.is_finite() + } + + /// Whether the length is infinite. + pub fn is_infinite(self) -> bool { + self.raw.is_infinite() + } + /// Whether the length is `NaN`. pub fn is_nan(self) -> bool { self.raw.is_nan() |
