framework
framework copied to clipboard
[9.x] Added generic typing to EnumeratesValues::flatMap method.
Improves the generic typing of EnumeratesValues by providing them for the flatMap() method.
Using flatMap right now causes all type information to be lost, and explicitly states there will only be integer keys, when collapse() can produce both string and int keys thanks to it's use of array_merge().
ref: https://github.com/nunomaduro/larastan/discussions/1427
Enumerable interface needs to be changed also.
@nunomaduro can you take a look at this?