function isReferenceError( value ) {
	if ( typeof value !== 'object' || value === null ) {
		return false;
	}
	// Check for `ReferenceError` objects from the same realm (same Node.js `vm` or same `Window` object)...
	if ( value instanceof ReferenceError ) {
		return true;
	}
	// All `ReferenceError` objects are `Error` objects...
	if ( isError( value ) ) {
		// Walk the prototype tree until we find the desired constructor...
		while ( value ) {
			if ( typeOf( value ) === 'referenceerror' ) {
				return true;
			}
			value = getPrototypeOf( value );
		}
	}
	return false;
}
Tests if a value is a `ReferenceError` object.

@param {*} value - value to test
@returns {boolean} boolean indicating whether a value is a `ReferenceError` object

@example
var bool = isReferenceError( new ReferenceError( 'beep' ) );
// returns true

@example
var bool = isReferenceError( {} );
// returns false