Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 1a4dfd5

Browse files
random: Fix error message formatting for Randomizer::getFloat() (#19008)
Error messages should not end with a `.`.
1 parent ec8b016 commit 1a4dfd5

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

‎ext/random/randomizer.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ PHP_METHOD(Random_Randomizer, getFloat)
196196
RETVAL_DOUBLE(php_random_gammasection_open_open(randomizer->engine, min, max));
197197

198198
if (UNEXPECTED(isnan(Z_DVAL_P(return_value)))) {
199-
zend_value_error("The given interval is empty, there are no floats between argument #1 ($min) and argument #2 ($max).");
199+
zend_value_error("The given interval is empty, there are no floats between argument #1 ($min) and argument #2 ($max)");
200200
RETURN_THROWS();
201201
}
202202

‎ext/random/tests/03_randomizer/methods/getFloat_error.phpt‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,4 +127,4 @@ Random\Randomizer::getFloat(): Argument #2 ($max) must be finite
127127
Random\Randomizer::getFloat(): Argument #2 ($max) must be greater than argument #1 ($min)
128128
Random\Randomizer::getFloat(): Argument #2 ($max) must be greater than argument #1 ($min)
129129
Random\Randomizer::getFloat(): Argument #2 ($max) must be greater than argument #1 ($min)
130-
The given interval is empty, there are no floats between argument #1 ($min) and argument #2 ($max).
130+
The given interval is empty, there are no floats between argument #1 ($min) and argument #2 ($max)

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /