Deprecation: #78670 - Deprecated CharsetConverter methods

See Issue #78670

Description

The symfony/polyfill-mbstring package provides us with mb_string functionality in all installations. Therefore some methods of CharsetConverter have been marked as deprecated, since the equivalent mb_string functions can be used directly:

  • strlen(): use mb_strlen() directly
  • substr(): use mb_substr() directly
  • strtrunc(): use mb_strcut() directly
  • convCapitalize(): use mb_convert_case() directly
  • conv_case(): use mb_strtolower() or mb_strtoupper() directly
  • utf8_substr(): use mb_substr() directly
  • utf8_strlen(): use mb_strlen() directly
  • utf8_strtrunc(): use mb_strcut() directly
  • utf8_strpos(): use mb_strpos() directly
  • utf8_strrpos(): use mb_strrpos() directly
  • utf8_byte2char_pos(): no replacement
  • euc_strtrunc(): use mb_strcut() directly
  • euc_substr(): use mb_substr() directly
  • euc_strlen(): use mb_strlen() directly
  • euc_char2byte_pos(): no replacement
  • $fourByteSets: no replacement

Impact

Calling the deprecated CharsetConverter methods will trigger a deprecation log entry.

Affected Installations

Any installation using third party extensions leveraging the mentioned CharsetConverter functionality.

Migration

Use the equivalent mb_string methods directly as denoted above.