{{PAGESIZE:{{FULLPAGENAME}}}}, {{{{FULLPAGENAME}}}} not outdated
authorBrian Wolff <bawolff+wn@gmail.com>
Tue, 15 Jan 2013 21:38:29 +0000 (17:38 -0400)
committerBrian Wolff <bawolff+wn@gmail.com>
Sat, 27 Apr 2013 23:45:32 +0000 (20:45 -0300)
commit2d542d3fd5acacf544386417cbef625fa2d2693a
tree9f0e5b7c494b6ea1f5acb03f192bce63e5696816
parenta5f6685cb344904425b253bd0c7f7b559825115a
{{PAGESIZE:{{FULLPAGENAME}}}}, {{{{FULLPAGENAME}}}} not outdated

Previously, when parsing {{PAGESIZE:{{FULLPAGENAME}}}} or
{{ {{FULLPAGENAME}} }} (a self-transclusion), we used the
version currently in the db, which is outdated because
the moment we save the page there will be a new version.

This often causes confusion when testing templates that
often have examples of template use in the doc section
which would be one version out of date.

This change causes those variables to give results for
the most recent version of the page. For self-templates
that's done by reparsing the page after save. For
self page sizes this is done by taking the size
of the input to Parser::parse.

Note that {{subst:PAGESIZE:{{subst:FULLPAGENAME}}}}
will still yield previous revision like before.

bug: 39590
Change-Id: Idfac13de37d05317f65e4131534543e66cf74873
RELEASE-NOTES-1.22
includes/parser/CoreParserFunctions.php
includes/parser/Parser.php