X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2Fbenchmarks%2Fbench_wfIsWindows.php;h=960ef0e8eecafb87e29114e5d707cb65b5e1f74f;hb=ffba23d177d5eee876bdc59cdf1b945281b18041;hp=ac0caf60962e42c2dd7b0c6e0e51e3891c48a993;hpb=a85d1b9d0cd7f02111d3a647d5b91e3b1f334563;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/benchmarks/bench_wfIsWindows.php b/maintenance/benchmarks/bench_wfIsWindows.php index ac0caf6096..960ef0e8ee 100644 --- a/maintenance/benchmarks/bench_wfIsWindows.php +++ b/maintenance/benchmarks/bench_wfIsWindows.php @@ -42,20 +42,19 @@ class BenchWfIsWindows extends Benchmarker { [ 'function' => [ $this, 'wfIsWindows' ] ], [ 'function' => [ $this, 'wfIsWindowsCached' ] ], ] ); - print $this->getFormattedResults(); } - static function is_win() { + protected static function is_win() { return substr( php_uname(), 0, 7 ) == 'Windows'; } // bench function 1 - function wfIsWindows() { + protected function wfIsWindows() { return self::is_win(); } // bench function 2 - function wfIsWindowsCached() { + protected function wfIsWindowsCached() { static $isWindows = null; if ( $isWindows == null ) { $isWindows = self::is_win();