[php-src] Issue #8308: The return value of mb_list_encodings() doesn't contain 'SJIS-win'
| From: | alexdowad | Date: | Wed, 06 Apr 2022 06:22:48 +0000 |
| Subject: | [php-src] Issue #8308: The return value of mb_list_encodings() doesn't contain 'SJIS-win' | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-240688@lists.php.net to get a copy of this message | ||
Issue: https://github.com/php/php-src/issues/8308
Comment Author: alexdowad
@sji-il, thank you for the report.
This change actually dates back to 2020; see e2459857af. Before that commit,
SJIS-win
was indeed treated as a separate encoding from CP932, but testing revealed that the
behavior of SJIS-win and CP932 was exactly the same (i.e. all the same
mappings).
I think the first question here is: Was there actually some difference between SJIS-win
and CP932 which I missed? Perhaps more importantly, *should there have been* some
difference?
If indeed there is no difference, do you still feel that mb_list_encodings should list
the same legacy text encoding twice, under two different names? Or perhaps SJIS-win
should be the primary name, and CP932 should be an alias?
Regarding the BC issue, I'm sorry that this was not documented as a backwards-incompatible
change. I think this is actually a change from PHP 7.4 to 8.0, not from 8.0 to 8.1 (but please
correct me if that is wrong).