You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Good find, that should probably read: If the next key in the left-hand operand does not exist in the right-hand operand, the arrays cannot be compared and are considered not equal.
The spaceship operator is designed to do a bi-directional comparison. Meaning not only does it report if they are equal or not, it also specifies whether it's greater than or less than. The spaceship operator always returns an integer representing those details (similar to strcmp).
Activity
bradynpoulsen commentedon Feb 21, 2017
Good find, that should probably read:
If the next key in the left-hand operand does not exist in the right-hand operand, the arrays cannot be compared and are considered not equal.
The spaceship operator is designed to do a bi-directional comparison. Meaning not only does it report if they are equal or not, it also specifies whether it's greater than or less than. The spaceship operator always returns an integer representing those details (similar to strcmp).
See: http://php.net/manual/en/language.operators.comparison.php