diff options
| author | nsfisis <nsfisis@gmail.com> | 2025-10-31 21:47:57 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2025-10-31 21:47:57 +0900 |
| commit | 76ca754957d3feaa2410ea327e36d56c07233e77 (patch) | |
| tree | 55b722efcf69974181745586a1c97855cd9ae353 /src | |
| parent | 906d4ed33a4c0d7fe470133854ae714799f28d84 (diff) | |
| download | php-next-after-main.tar.gz php-next-after-main.tar.zst php-next-after-main.zip | |
Diffstat (limited to 'src')
| -rw-r--r-- | src/NextAfter.php | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/NextAfter.php b/src/NextAfter.php index d985e6f..8bd6adc 100644 --- a/src/NextAfter.php +++ b/src/NextAfter.php @@ -84,9 +84,7 @@ final class NextAfter return self::minValue(); } $u = self::floatToInt($x); - return $x > 0.0 ? self::intToFloat($u + 1) : - self::intToFloat($u - 1); - + return $x > 0.0 ? self::intToFloat($u + 1) : self::intToFloat($u - 1); } /** @@ -120,9 +118,7 @@ final class NextAfter return -self::minValue(); } $u = self::floatToInt($x); - return $x > 0.0 ? self::intToFloat($u - 1) : - self::intToFloat($u + 1); - + return $x > 0.0 ? self::intToFloat($u - 1) : self::intToFloat($u + 1); } /** |
