Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / vendor / psy / psysh / src / Formatter / DocblockFormatter.php
similarity index 93%
rename from vendor/psy/psysh/src/Psy/Formatter/DocblockFormatter.php
rename to vendor/psy/psysh/src/Formatter/DocblockFormatter.php
index c1e8af9c1a8fc1d34e0509640eba4fc4f9261555..33f450e1af50d5af6286301c94e2d2ef82372eeb 100644 (file)
@@ -3,7 +3,7 @@
 /*
  * This file is part of Psy Shell.
  *
- * (c) 2012-2017 Justin Hileman
+ * (c) 2012-2018 Justin Hileman
  *
  * For the full copyright and license information, please view the LICENSE
  * file that was distributed with this source code.
@@ -19,10 +19,10 @@ use Symfony\Component\Console\Formatter\OutputFormatter;
  */
 class DocblockFormatter implements Formatter
 {
-    private static $vectorParamTemplates = array(
+    private static $vectorParamTemplates = [
         'type' => 'info',
         'var'  => 'strong',
-    );
+    ];
 
     /**
      * Format a docblock.
@@ -34,7 +34,7 @@ class DocblockFormatter implements Formatter
     public static function format(\Reflector $reflector)
     {
         $docblock = new Docblock($reflector);
-        $chunks   = array();
+        $chunks   = [];
 
         if (!empty($docblock->desc)) {
             $chunks[] = '<comment>Description:</comment>';
@@ -73,7 +73,7 @@ class DocblockFormatter implements Formatter
      */
     private static function formatVector(array $vector, array $lines)
     {
-        $template = array(' ');
+        $template = [' '];
         foreach ($vector as $type) {
             $max = 0;
             foreach ($lines as $line) {
@@ -89,7 +89,7 @@ class DocblockFormatter implements Formatter
         $template = implode(' ', $template);
 
         return implode("\n", array_map(function ($line) use ($template) {
-            $escaped = array_map(array('Symfony\Component\Console\Formatter\OutputFormatter', 'escape'), $line);
+            $escaped = array_map(['Symfony\Component\Console\Formatter\OutputFormatter', 'escape'], $line);
 
             return rtrim(vsprintf($template, $escaped));
         }, $lines));
@@ -105,7 +105,7 @@ class DocblockFormatter implements Formatter
      */
     private static function formatTags(array $skip, array $tags)
     {
-        $chunks = array();
+        $chunks = [];
 
         foreach ($tags as $name => $values) {
             if (in_array($name, $skip)) {