On Wed, Nov 3, 2010 at 3:10 AM, Tim Starling tstarling@wikimedia.org wrote:
I don't think JSON support is particularly important since it can easily be simulated, and I don't think you should use the filter extension in MediaWiki, regardless of whether it is supported.
I agree about filter. Having native JSON support is a nicety though, it's faster than a userland implementation.
However, I can think of a good argument for moving to PHP 5.2, which is to stop the high rate of bit rot in 5.1 support. In particular, support for callbacks with double-colons to indicate static method calls:
call_user_func( 'Foo::bar' )
was added in PHP 5.2.3. Developers often use these, and don't realise that they are breaking PHP 5.1 support. So I think there's a good argument for making 5.2.3 the minimum.
+1 here. a::b syntax is less keystrokes having to use an array. Also lets us remove the stupid hack from r68760[0] (probably similar things elsewhere in the code)
Another example of bit rot: the trunk has 3 calls to array_fill_keys(), with no simulation in GlobalFunctions.php; it was added in 5.2.0. Developers should really check the versions in the manual when they use a function, otherwise 5.2.x will soon be broken as well, in favour of 5.3.x. But in theory we can weed out calls to newly-added functions with grep. The 5.2.3 callback change was more subtle.
Other reasons 5.2 is cool: - setcookie() allows httponly cookies (we conditionally support this) - __toString() works properly - Memory management improved - Lots of other stuff here [1]
The consensus last time we brought this up (November) was fairly strong that we can start phasing out 5.1 support. After talking again on IRC with people today, I think we can safely break 5.1 in trunk (although lets not backport it).
Once the 1.17 release is out, we should find a way to better update [2] so we can indicate that 1.17 will be the last release with 5.1 support.
-Chad
[0] http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68760 [1] http://php.net/migration52 [2] http://www.mediawiki.org/wiki/Manual:Installation_requirements