1.2.667. Manipulates NaN¶
This code handles Not-a-Number
situations. Not-a-Number
, also called NaN
, happens when a calculation can’t return an actual float.
<?php
// acos returns a float, unless it is not possible.
$a = acos(8);
var_dump(is_nan($a));
?>
See also Floats.
1.2.667.1. Connex PHP features¶
1.2.667.1.1. Suggestions¶
Add the third argument, and set it to true
1.2.667.1.2. Specs¶
Short name |
Php/IsNAN |
Rulesets |
|
Exakat since |
0.10.6 |
PHP Version |
All |
Severity |
Minor |
Time To Fix |
Quick (30 mins) |
Precision |
Very high |
Available in |