Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / vendor / nikic / php-parser / lib / PhpParser / Node / Expr / ArrayItem.php
index de73ef467e7cf0077528de962c7688af7dc13564..bf9c7fdef440bf1914b185e730dc70b4737e725f 100644 (file)
@@ -1,4 +1,4 @@
-<?php
+<?php declare(strict_types=1);
 
 namespace PhpParser\Node\Expr;
 
@@ -21,14 +21,18 @@ class ArrayItem extends Expr
      * @param bool      $byRef      Whether to assign by reference
      * @param array     $attributes Additional attributes
      */
-    public function __construct(Expr $value, Expr $key = null, $byRef = false, array $attributes = array()) {
+    public function __construct(Expr $value, Expr $key = null, bool $byRef = false, array $attributes = []) {
         parent::__construct($attributes);
         $this->key = $key;
         $this->value = $value;
         $this->byRef = $byRef;
     }
 
-    public function getSubNodeNames() {
-        return array('key', 'value', 'byRef');
+    public function getSubNodeNames() : array {
+        return ['key', 'value', 'byRef'];
+    }
+    
+    public function getType() : string {
+        return 'Expr_ArrayItem';
     }
 }