Passed
Pull Request — master (#506)
by
unknown
04:51 queued 02:06
created
src/Components/ArrayObj.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@
 block discarded – undo
49 49
      *
50 50
      * @return ArrayObj|Component[]
51 51
      */
52
-    public static function parse(Parser $parser, TokensList $list, array $options = []): ArrayObj|array
52
+    public static function parse(Parser $parser, TokensList $list, array $options = []): ArrayObj | array
53 53
     {
54 54
         $ret = empty($options['type']) ? new static() : [];
55 55
 
Please login to merge, or discard this patch.
src/Context.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -358,13 +358,13 @@  discard block
 block discarded – undo
358 358
      *
359 359
      * @param bool $isReserved checks if the keyword is reserved
360 360
      */
361
-    public static function isKeyword(string $string, bool $isReserved = false): int|null
361
+    public static function isKeyword(string $string, bool $isReserved = false): int | null
362 362
     {
363 363
         $upperString = strtoupper($string);
364 364
 
365 365
         if (
366
-            ! isset(static::$keywords[$upperString])
367
-            || ($isReserved && ! (static::$keywords[$upperString] & Token::FLAG_KEYWORD_RESERVED))
366
+            !isset(static::$keywords[$upperString])
367
+            || ($isReserved && !(static::$keywords[$upperString] & Token::FLAG_KEYWORD_RESERVED))
368 368
         ) {
369 369
             return null;
370 370
         }
@@ -375,7 +375,7 @@  discard block
 block discarded – undo
375 375
     /**
376 376
      * Checks if the given string is an operator and returns the appropriate flag for the operator.
377 377
      */
378
-    public static function isOperator(string $string): int|null
378
+    public static function isOperator(string $string): int | null
379 379
     {
380 380
         return static::$operators[$string] ?? null;
381 381
     }
@@ -393,7 +393,7 @@  discard block
 block discarded – undo
393 393
      *
394 394
      * @return int|null the appropriate flag for the comment type
395 395
      */
396
-    public static function isComment(string $string, bool $end = false): int|null
396
+    public static function isComment(string $string, bool $end = false): int | null
397 397
     {
398 398
         if ($string === '') {
399 399
             return null;
@@ -456,7 +456,7 @@  discard block
 block discarded – undo
456 456
      *
457 457
      * @return int|null the appropriate flag for the symbol type
458 458
      */
459
-    public static function isSymbol(string $string): int|null
459
+    public static function isSymbol(string $string): int | null
460 460
     {
461 461
         if ($string === '') {
462 462
             return null;
@@ -484,7 +484,7 @@  discard block
 block discarded – undo
484 484
      *
485 485
      * @return int|null the appropriate flag for the string type
486 486
      */
487
-    public static function isString(string $string): int|null
487
+    public static function isString(string $string): int | null
488 488
     {
489 489
         if ($string === '') {
490 490
             return null;
@@ -538,7 +538,7 @@  discard block
 block discarded – undo
538 538
             $context = self::$contextPrefix . $context;
539 539
         }
540 540
 
541
-        if (! class_exists($context)) {
541
+        if (!class_exists($context)) {
542 542
             return false;
543 543
         }
544 544
 
@@ -560,7 +560,7 @@  discard block
 block discarded – undo
560 560
      *
561 561
      * @return string|null The loaded context. `null` if no context was loaded.
562 562
      */
563
-    public static function loadClosest(string $context = ''): string|null
563
+    public static function loadClosest(string $context = ''): string | null
564 564
     {
565 565
         $length = strlen($context);
566 566
         for ($i = $length; $i > 0;) {
@@ -574,7 +574,7 @@  discard block
 block discarded – undo
574 574
                 $i -= 2;
575 575
                 $part = substr($context, $i, 2);
576 576
                 /* No more numeric parts to strip */
577
-                if (! is_numeric($part)) {
577
+                if (!is_numeric($part)) {
578 578
                     break 2;
579 579
                 }
580 580
             } while (intval($part) === 0 && $i > 0);
@@ -675,7 +675,7 @@  discard block
 block discarded – undo
675 675
     public static function escape(string $str, string $quote = '`'): string
676 676
     {
677 677
         if (
678
-            (static::$mode & self::SQL_MODE_NO_ENCLOSING_QUOTES) && ! (
678
+            (static::$mode & self::SQL_MODE_NO_ENCLOSING_QUOTES) && !(
679 679
                 static::isKeyword($str, true) || self::doesIdentifierRequireQuoting($str)
680 680
             )
681 681
         ) {
@@ -722,7 +722,7 @@  discard block
 block discarded – undo
722 722
      *
723 723
      * @return bool false on empty param, true/false on given constant/int value
724 724
      */
725
-    public static function hasMode(int|null $flag = null): bool
725
+    public static function hasMode(int | null $flag = null): bool
726 726
     {
727 727
         if (empty($flag)) {
728 728
             return false;
Please login to merge, or discard this patch.
src/UtfString.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
     {
79 79
         $this->str = $str;
80 80
         $this->byteLen = mb_strlen($str, '8bit');
81
-        if (! mb_check_encoding($str, 'UTF-8')) {
81
+        if (!mb_check_encoding($str, 'UTF-8')) {
82 82
             $this->charLen = 0;
83 83
         } else {
84 84
             $this->charLen = mb_strlen($str, 'UTF-8');
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
      *
101 101
      * @param int $offset the offset to be returned
102 102
      */
103
-    public function offsetGet($offset): string|null
103
+    public function offsetGet($offset): string | null
104 104
     {
105 105
         if (($offset < 0) || ($offset >= $this->charLen)) {
106 106
             return null;
Please login to merge, or discard this patch.