percentage
function should throw error if result would be NaN
#2553
Labels
percentage
function should throw error if result would be NaN
#2553
As mentioned by @seven-phases-max on #1880 (comment), a call to
percentage
that would currently returnNaN%
should instead throw an error.This is potentially a breaking change, since it would stop compiling things that currently compile successfully (albeit poorly).
Example:
With
strict-math
on, the following returnsNaN%
, but it should error, likeround
orfloor
do.The text was updated successfully, but these errors were encountered: