aboutsummaryrefslogtreecommitdiffstats
path: root/maintenance/findDeprecated.php
diff options
context:
space:
mode:
authorKunal Mehta <legoktm@member.fsf.org>2016-02-17 01:09:32 -0800
committerKunal Mehta <legoktm@member.fsf.org>2016-02-17 01:33:00 -0800
commit6e9b4f0e9ce4ccd6089c18b205065ef7fa077484 (patch)
tree58645fbce5c12d01b0d0fa87e338d4745e08920d /maintenance/findDeprecated.php
parent2fd379fa95f223c6b3f3c8eff6de068eca9e1a1a (diff)
downloadmediawikicore-6e9b4f0e9ce4ccd6089c18b205065ef7fa077484.tar.gz
mediawikicore-6e9b4f0e9ce4ccd6089c18b205065ef7fa077484.zip
Convert all array() syntax to []
Per wikitech-l consensus: https://lists.wikimedia.org/pipermail/wikitech-l/2016-February/084821.html Notes: * Disabled CallTimePassByReference due to false positives (T127163) Change-Id: I2c8ce713ce6600a0bb7bf67537c87044c7a45c4b
Diffstat (limited to 'maintenance/findDeprecated.php')
-rw-r--r--maintenance/findDeprecated.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/maintenance/findDeprecated.php b/maintenance/findDeprecated.php
index 9022292e2f3a..bc1b34aa67f9 100644
--- a/maintenance/findDeprecated.php
+++ b/maintenance/findDeprecated.php
@@ -53,7 +53,7 @@ class DeprecatedInterfaceFinder extends FileAwareNodeVisitor {
private $currentClass = null;
- private $foundNodes = array();
+ private $foundNodes = [];
public function getFoundNodes() {
// Sort results by version, then by filename, then by name.
@@ -105,12 +105,12 @@ class DeprecatedInterfaceFinder extends FileAwareNodeVisitor {
$name = $node->name;
}
- $this->foundNodes[ $version ][] = array(
+ $this->foundNodes[ $version ][] = [
'filename' => $node->filename,
'line' => $node->getLine(),
'name' => $name,
'hard' => $this->isHardDeprecated( $node ),
- );
+ ];
}
return $retVal;
@@ -158,7 +158,7 @@ class FindDeprecated extends Maintenance {
}
$finder->setCurrentFile( substr( $file->getPathname(), strlen( $IP ) + 1 ) );
- $nodes = $parser->parse( $code, array( 'throwOnError' => false ) );
+ $nodes = $parser->parse( $code, [ 'throwOnError' => false ] );
$traverser->traverse( $nodes );
if ( $i % $chunkSize === 0 ) {