HomePhabricator

* Introduced StringUtils.php, populated it with some generic string functions…

Tags
None
Referenced Files
None
Subscribers
None

Description

  • Introduced StringUtils.php, populated it with some generic string functions, both new and collected from various other files. * Removed some backtracking regexes with an O(N^2) worst case, replaced with StringUtils::delimiterReplace(). There is a beneficial functional difference: /*/ is no longer considered to be a complete CSS comment. * Changed the parser strip state from an array to an object. This should hopefully avoid the PHP bugs with array references. StripState uses the new ReplacementArray to do the replacements, thereby supporting FSS. * Removed DatabaseFunctions.php from the default startup sequence. Moved wfGetDB() to GlobalFunctions.php. * Introduced the SiteStats class, with a collection of cached site stats accessor functions. * Removed all global functions from Parser.php, they don't belong there. * Made LanguageConverter use the new ReplacementArray class instead of managing its own FSS objects.

Details

Provenance
tstarlingAuthored on
Parents
rMW02efcccdbf20: Fixed recently committed error.
Branches
Unknown
Tags
Unknown
ChangeId
None