Should a string, when converted to an integer, become 1, not 0? (Unless it is a string of only digits, like "567". Then it should become 567.)
(bool) 'x' // true
(int) true // 1
If a string is truthy in a boolean situation, shouldn't it also be truthy in a numeric one?The types form a hierarchy in my mind, from simple to complex: from boolean to integer, to float, to string, to compound types like arrays and objects. It seems like values should cast up and down the chain uniformly.