2 ms·
The key type changing is generally not a problem per se, but it's definitely odd with the default re-indexing behaviour depending on whether something is intege
by bwoebi 5mo ago
The key type changing is generally not a problem per se, but it's definitely odd with the default re-indexing behaviour depending on whether something is integer keys only or not.
That's exactly what I've been complaining in my post above. If there were no automatic reindexing, then this wouldn't be a problem either.
- asddubs 4mo agoIt's surprisingly rare that it becomes a problem, but I've definitely been bit by it before when getting array keys, expecting them to be strings and doing === comparisons.