Skip to content

Conversation

@mvorisek
Copy link
Contributor

@mvorisek mvorisek commented Jul 7, 2022

The inconsistency was introduced in 0818fae by a mistake as found out by @emkey08.

mb_str_split behaves properly and empty input is covered by a test already.

As some algorithms might rely on the bad - always non-empty array - behaviour, targetting master only.

@mvorisek mvorisek marked this pull request as ready for review July 7, 2022 08:25
Copy link
Member

@cmb69 cmb69 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR! In my opinion, this is okay for master.

@devnexen
Copy link
Member

devnexen commented Jul 8, 2022

Should the change be documented ?

@cmb69
Copy link
Member

cmb69 commented Jul 8, 2022

Should the change be documented ?

Besides the usual entry in NEWS, there should be a brief note in UPGRADING, so that the doc team can later put that into the migration guide.

@devnexen devnexen closed this in e809254 Jul 8, 2022
@mvorisek mvorisek deleted the fix_str_split branch July 8, 2022 16:54
iluuu1994 added a commit to iluuu1994/php-src that referenced this pull request Jul 14, 2022
Introduced in phpGH-8945

With RETURN_EMPTY_ARRAY this function can now return an interned array which
has refcount 2.
iluuu1994 added a commit that referenced this pull request Jul 15, 2022
Introduced in GH-8945

With RETURN_EMPTY_ARRAY this function can now return an interned array which
has refcount 2.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants