Add parser method to call parser functions
authorBrad Jorsch <bjorsch@wikimedia.org>
Mon, 4 Mar 2013 03:35:05 +0000 (22:35 -0500)
committerGerrit Code Review <gerrit@wikimedia.org>
Wed, 20 Mar 2013 02:52:45 +0000 (02:52 +0000)
commitfc00763f0dc3ef1dbe1021e5e8759991d72c9e5e
tree133c57c8d5f8033df66d69a5430872ee1465c81d
parentcc3ac23c4fec3f85d65563d0a4bb642774cecf7e
Add parser method to call parser functions

There is currently no straightforward way for anything to call a parser
function and get the result. This abstracts out that portion of
braceSubstitution() to allow this.

The immediate motivation for this patch is to close bug 41769 against
Scribunto, see I0138836654b0e34c5c23daaedcdf5d4f9d1c7ab2.

Bug: 41769
Change-Id: I339b882010dedd714e7965e25ad650ed8b8cd48f
includes/parser/Parser.php
tests/phpunit/includes/parser/ParserMethodsTest.php