Passed
Push — master ( ab19ac...5fc55b )
by Kirill
02:55
created
src/helpers.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -5,10 +5,10 @@
 block discarded – undo
5 5
  * For the full copyright and license information, please view the LICENSE
6 6
  * file that was distributed with this source code.
7 7
  */
8
-declare(strict_types=1);
8
+declare(strict_types = 1);
9 9
 
10 10
 
11
-if (! \function_exists('\\class_basename')) {
11
+if (!\function_exists('\\class_basename')) {
12 12
     /**
13 13
      * Get the class "basename" of the given object / class.
14 14
      *
Please login to merge, or discard this patch.
src/ParserInterface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@
 block discarded – undo
5 5
  * For the full copyright and license information, please view the LICENSE
6 6
  * file that was distributed with this source code.
7 7
  */
8
-declare(strict_types=1);
8
+declare(strict_types = 1);
9 9
 
10 10
 namespace Railt\Compiler;
11 11
 
Please login to merge, or discard this patch.
src/Iterator/BufferInterface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@
 block discarded – undo
5 5
  * For the full copyright and license information, please view the LICENSE
6 6
  * file that was distributed with this source code.
7 7
  */
8
-declare(strict_types=1);
8
+declare(strict_types = 1);
9 9
 
10 10
 namespace Railt\Compiler\Iterator;
11 11
 
Please login to merge, or discard this patch.
src/Iterator/RegexIterator.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@  discard block
 block discarded – undo
5 5
  * For the full copyright and license information, please view the LICENSE
6 6
  * file that was distributed with this source code.
7 7
  */
8
-declare(strict_types=1);
8
+declare(strict_types = 1);
9 9
 
10 10
 namespace Railt\Compiler\Iterator;
11 11
 
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
     {
52 52
         $result = new \SplQueue();
53 53
 
54
-        $status = @\preg_replace_callback($this->pattern, function (array $matches) use ($result): void {
54
+        $status = @\preg_replace_callback($this->pattern, function(array $matches) use ($result): void {
55 55
             $result->push($matches);
56 56
         }, $this->subject);
57 57
 
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
             case \PREG_BAD_UTF8_OFFSET_ERROR:
100 100
                 return self::PREG_BAD_UTF8_OFFSET_ERROR;
101 101
         }
102
-        return 'Unexpected PCRE error (Code ' . $code . ')';
102
+        return 'Unexpected PCRE error (Code '.$code.')';
103 103
     }
104 104
 
105 105
     /**
Please login to merge, or discard this patch.
src/Iterator/Buffer.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@  discard block
 block discarded – undo
5 5
  * For the full copyright and license information, please view the LICENSE
6 6
  * file that was distributed with this source code.
7 7
  */
8
-declare(strict_types=1);
8
+declare(strict_types = 1);
9 9
 
10 10
 namespace Railt\Compiler\Iterator;
11 11
 
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
     public function __construct(\Traversable $iterator, int $size = 10)
40 40
     {
41 41
         \assert($size > 0, 'Buffer size must be greater than 0');
42
-        \assert($size <= \PHP_INT_MAX, 'Buffer size must less than ' . \PHP_INT_MAX);
42
+        \assert($size <= \PHP_INT_MAX, 'Buffer size must less than '.\PHP_INT_MAX);
43 43
 
44 44
         $this->size     = $size;
45 45
         $this->iterator = $iterator;
Please login to merge, or discard this patch.
src/Iterator/RegexNamedGroupsIterator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@  discard block
 block discarded – undo
5 5
  * For the full copyright and license information, please view the LICENSE
6 6
  * file that was distributed with this source code.
7 7
  */
8
-declare(strict_types=1);
8
+declare(strict_types = 1);
9 9
 
10 10
 namespace Railt\Compiler\Iterator;
11 11
 
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
             $context = [];
26 26
 
27 27
             foreach (\array_reverse($result) as $index => $body) {
28
-                if (! \is_string($index)) {
28
+                if (!\is_string($index)) {
29 29
                     $context[] = $body;
30 30
                     continue;
31 31
                 }
Please login to merge, or discard this patch.
src/Generator/CodeGenerator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@
 block discarded – undo
5 5
  * For the full copyright and license information, please view the LICENSE
6 6
  * file that was distributed with this source code.
7 7
  */
8
-declare(strict_types=1);
8
+declare(strict_types = 1);
9 9
 
10 10
 namespace Railt\Compiler\Generator;
11 11
 
Please login to merge, or discard this patch.
src/Generator/GeneratedResult.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@  discard block
 block discarded – undo
5 5
  * For the full copyright and license information, please view the LICENSE
6 6
  * file that was distributed with this source code.
7 7
  */
8
-declare(strict_types=1);
8
+declare(strict_types = 1);
9 9
 
10 10
 namespace Railt\Compiler\Generator;
11 11
 
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
     public function __construct(string $body, string $class)
37 37
     {
38 38
         $this->body = $body;
39
-        $this->as($class . '.php');
39
+        $this->as($class.'.php');
40 40
     }
41 41
 
42 42
     /**
@@ -65,14 +65,14 @@  discard block
 block discarded – undo
65 65
      */
66 66
     public function saveTo(string $directory): Readable
67 67
     {
68
-        $path = $directory . \DIRECTORY_SEPARATOR . $this->file;
68
+        $path = $directory.\DIRECTORY_SEPARATOR.$this->file;
69 69
 
70
-        if (\is_file($path) && ! @\unlink($path)) {
71
-            throw new NotReadableException('Could not save a new source into ' . $path);
70
+        if (\is_file($path) && !@\unlink($path)) {
71
+            throw new NotReadableException('Could not save a new source into '.$path);
72 72
         }
73 73
 
74
-        if (! @\file_put_contents($path, $this->body)) {
75
-            throw new NotReadableException('Could not save a new source into ' . $path);
74
+        if (!@\file_put_contents($path, $this->body)) {
75
+            throw new NotReadableException('Could not save a new source into '.$path);
76 76
         }
77 77
 
78 78
         return File::fromPathname($path);
Please login to merge, or discard this patch.
src/Generator/Renderer/TwigRenderer.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@  discard block
 block discarded – undo
5 5
  * For the full copyright and license information, please view the LICENSE
6 6
  * file that was distributed with this source code.
7 7
  */
8
-declare(strict_types=1);
8
+declare(strict_types = 1);
9 9
 
10 10
 namespace Railt\Compiler\Generator\Renderer;
11 11
 
@@ -48,19 +48,19 @@  discard block
 block discarded – undo
48 48
      */
49 49
     private function bootFilters(): \Generator
50 50
     {
51
-        yield new TwigFilter('string', function (string $string): string {
51
+        yield new TwigFilter('string', function(string $string): string {
52 52
             $generator = new ValueGenerator($string, ValueGenerator::TYPE_STRING);
53 53
 
54 54
             return $generator->generate();
55 55
         });
56 56
 
57
-        yield new TwigFilter('boolean', function (string $string): string {
57
+        yield new TwigFilter('boolean', function(string $string): string {
58 58
             $generator = new ValueGenerator($string, ValueGenerator::TYPE_BOOL);
59 59
 
60 60
             return $generator->generate();
61 61
         });
62 62
 
63
-        yield new TwigFilter('array', function (array $items, int $depth = 0): string {
63
+        yield new TwigFilter('array', function(array $items, int $depth = 0): string {
64 64
             $generator = new ValueGenerator($items, ValueGenerator::TYPE_ARRAY_SHORT);
65 65
 
66 66
             $generator->setArrayDepth($depth);
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
             return $generator->generate();
69 69
         });
70 70
 
71
-        yield new TwigFilter('class', function ($object): string {
71
+        yield new TwigFilter('class', function($object): string {
72 72
             if (\is_object($object)) {
73 73
                 return \get_class($object);
74 74
             }
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
             return \json_encode($object);
77 77
         });
78 78
 
79
-        yield new TwigFilter('value', function ($value): string {
79
+        yield new TwigFilter('value', function($value): string {
80 80
             return (new ValueGenerator($value))->generate();
81 81
         });
82 82
     }
Please login to merge, or discard this patch.