Task #102877
closedRemove todo for intExplode function in GeneralUtility
100%
Description
A todo added for the GeneralUtility::intExplode()
function suggests refactor the function by using array_filter
and array_walk
. This refactoring may be good in terms of readability, but has negative impact on the performance of the function when used with large strings containing many comma separated values.
Example php script for a performance comparison: https://gist.github.com/derhansen/e0751d896ba0d48917dccd44bd4e4d1e
Result in seconds for 1.000.000 comma separated numbers in a string:
Old: 0.16220808029175 New: 0.68774104118347
I would therefore prefer to keep the function as it is and remove the todo.
Updated by Gerrit Code Review 10 months ago
- Status changed from New to Under Review
Patch set 1 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/82534
Updated by Torben Hansen 10 months ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 2d9479c950c6ac53511ee9b31b8d4de62d85e330.