@stdlib/assert
Version:
Standard assertion utilities.
37 lines (28 loc) • 672 B
Plain Text
{{alias}}( a, b )
Tests if two arguments are the same value.
The function differs from the `===` operator in that the function treats
`NaNs` as the same.
Parameters
----------
a: any
First input value.
b: any
Second input value.
Returns
-------
bool: boolean
Boolean indicating whether two arguments are the same value.
Examples
--------
> var bool = {{alias}}( true, true )
true
> bool = {{alias}}( {}, {} )
false
> bool = {{alias}}( -0.0, -0.0 )
true
> bool = {{alias}}( -0.0, 0.0 )
true
> bool = {{alias}}( NaN, NaN )
true
See Also
--------