docs: Add doc comments to `std.math.isNan`
what is this adding over the name of the function?
This function returns whether the given value is a NaN. This pull request adds documentation explaining this behavior. We can guess what this function does from the function name and examples, but I think it would be easier to understand if there is documentation.
This pull request adds documentation explaining this behavior. We can guess what this function does from the function name and examples, but I think it would be easier to understand if there is documentation.
Something along the lines of
/// Returns true if x is not a number, and false otherwise
would be better because NaN is not being used to describe the isNan function.
@saurabh-mish suggestion:
/// Returns `true` if `x` is not a number (NaN), and `false` otherwise.
or
/// Returns `true` if `x` is NaN (not a number), and `false` otherwise.