PHP documentation says:
limit
If specified, then only substrings up to limit are returned with the rest of the string being placed in the last substring. A limit of -1 or 0 means "no limit" and, as is standard across PHP, you can use NULL to skip to the flags parameter.
So $limit should be ?int but in the generated preg_split function it is int only.