Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 291341

Clean up Unicode function names

$
0
0

#1938670: Convert unicode.inc to \Drupal\Component\Utility\Unicode comes with some PHP function wrappers. Unicode::truncate(), Unicode::mimeHeaderEncode(), etc. Some of them arn't living under the naming conventions:

  • Unicode::ucfirst()
  • Unicode::substr()

Although it is nice to have PHP wrappers be similarly named to the PHP functions, it's even nicer to have consistent coding standards.

Possible solutions:

  1. Fix the case of the functions: Unicode::ucFirst(), Unicode::subStr(), etc.
  2. Rename the functions entirely: Unicode::upperCaseFirst(), Unicode::subString(), etc.
  3. Leave as is and live with the broken coding standards

Viewing all articles
Browse latest Browse all 291341

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>