isEqualWithTypeCoercion(to:)
Compares the value to another for equivalence, allowing type conversion.
Declaration
func isEqualWithTypeCoercion(to value: Any!) -> BoolParameters
- value:
The value to be compared against.
Return Value
Discussion
This method is analogous to the equality operator == in JavaScript: it first converts its operands to the same type (if they are not already of the same type), then applies a strict equality comparison to the result. JavaScript object values are equal if and only if they refer to the same object instance.