Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 uid=33(www-data) gid=33(www-data) groups=33(www-data) Safe-mode: OFF (not secure) /var/www/html/node-red/node_modules/@sinonjs/samsam/lib/ drwxr-xr-x | |
| Viewing file: Select action/file-type: "use strict";
var isNaN = require("./is-nan");
var isNegZero = require("./is-neg-zero");
/**
* Strict equality check according to EcmaScript Harmony's `egal`.
*
* **From the Harmony wiki:**
* > An `egal` function simply makes available the internal `SameValue` function
* > from section 9.12 of the ES5 spec. If two values are egal, then they are not
* > observably distinguishable.
*
* `identical` returns `true` when `===` is `true`, except for `-0` and
* `+0`, where it returns `false`. Additionally, it returns `true` when
* `NaN` is compared to itself.
*
* @alias module:samsam.identical
* @param {*} obj1 The first value to compare
* @param {*} obj2 The second value to compare
* @returns {boolean} Returns `true` when the objects are *egal*, `false` otherwise
*/
function identical(obj1, obj2) {
if (obj1 === obj2 || (isNaN(obj1) && isNaN(obj2))) {
return obj1 !== 0 || isNegZero(obj1) === isNegZero(obj2);
}
return false;
}
module.exports = identical;
|
:: Command execute :: | |
--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0303 ]-- |