Skip to content

Commit 6f08e91

Browse files
committed
Bugfix: s/FIN/INF
1 parent d9a4d63 commit 6f08e91

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/XML/Assert/FloatTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
*/
1212
trait FloatTrait
1313
{
14-
private static string $float_regex = '/^(([+-]?([0-9]+[.][0-9]*|[.][0-9]+)([e][+-]?[0-9]+)?)|NaN|[-]?FIN)$/D';
14+
private static string $float_regex = '/^(([+-]?([0-9]+[.][0-9]*|[.][0-9]+)([e][+-]?[0-9]+)?)|NaN|[-]?INF)$/D';
1515

1616

1717
/**

tests/XML/Assert/FloatTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ public static function provideValidFloat(): array
4747
'valid leading zeros' => [true, '-0123.456'],
4848
'valid zero' => [true, '0.0'],
4949
'valid NaN' => [true, 'NaN'],
50-
'valid negative FIN' => [true, '-FIN'],
51-
'valid FIN' => [true, 'FIN'],
50+
'valid negative INF' => [true, '-INF'],
51+
'valid FIN' => [true, 'INF'],
5252
];
5353
}
5454

0 commit comments

Comments
 (0)