[Mediawiki-l] parserfunctions question: evaluate vs. display?
Brion Vibber
brion at wikimedia.org
Wed Apr 9 01:52:06 UTC 2008
Daniel Barrett wrote:
> In a parserfunctions statement like this:
>
> {{#if: {{#some-condition:}} | {{#some-big-computation:}} }}
>
> if #some-condition is false, which of the following should happen?
>
> 1. #some-big-computation gets fully evaluated, but results are not
> displayed
> 2. #some-big-computation is not evaluated at all
#2 (logical shortcut).
I can confirm this is how it works in both 1.12 and trunk (1.13 dev branch).
> Looks like choice #1 is happening in MW 1.12.0, which is bad if
> #some-big-computation has side-effects or is very expensive. Is this
> correct behavior?
Are you perhaps running with the old parser enabled?
-- brion vibber (brion @ wikimedia.org)
More information about the MediaWiki-l
mailing list