Completed
Pull Request — master (#240)
by Alexander
03:13
created
src/Core/GoAspectContainer.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,6 @@
 block discarded – undo
16 16
 use Go\Aop\Pointcut\PointcutLexer;
17 17
 use Go\Aop\Pointcut\PointcutGrammar;
18 18
 use Go\Aop\Pointcut\PointcutParser;
19
-use Go\Instrument\RawAnnotationReader;
20 19
 use Go\Instrument\ClassLoading\CachePathManager;
21 20
 use Doctrine\Common\Annotations\AnnotationReader;
22 21
 
Please login to merge, or discard this patch.
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
     public function __construct()
46 46
     {
47 47
         // Register all services in the container
48
-        $this->share('aspect.loader', function (Container $container) {
48
+        $this->share('aspect.loader', function(Container $container) {
49 49
             $aspectLoader = new AspectLoader(
50 50
                 $container,
51 51
                 $container->get('aspect.annotation.reader')
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
             return $aspectLoader;
61 61
         });
62 62
 
63
-        $this->share('aspect.cached.loader', function (Container $container) {
63
+        $this->share('aspect.cached.loader', function(Container $container) {
64 64
             $cachedAspectLoader = new CachedAspectLoader(
65 65
                 $container,
66 66
                 'aspect.loader',
@@ -70,25 +70,25 @@  discard block
 block discarded – undo
70 70
             return $cachedAspectLoader;
71 71
         });
72 72
 
73
-        $this->share('aspect.advisor.accessor', function (Container $container) {
73
+        $this->share('aspect.advisor.accessor', function(Container $container) {
74 74
             return new LazyAdvisorAccessor(
75 75
                 $container,
76 76
                 $container->get('aspect.cached.loader')
77 77
             );
78 78
         });
79 79
 
80
-        $this->share('aspect.advice_matcher', function (Container $container) {
80
+        $this->share('aspect.advice_matcher', function(Container $container) {
81 81
             return new AdviceMatcher(
82 82
                 $container->get('aspect.loader'),
83 83
                 $container->get('kernel.interceptFunctions')
84 84
             );
85 85
         });
86 86
 
87
-        $this->share('aspect.annotation.reader', function (Container $container) {
87
+        $this->share('aspect.annotation.reader', function(Container $container) {
88 88
             $options = $container->get('kernel.options');
89 89
             $reader  = new AnnotationReader();
90 90
             if (!empty($options['cacheDir'])) {
91
-                $reader  = new FileCacheReader(
91
+                $reader = new FileCacheReader(
92 92
                     $reader,
93 93
                     $options['cacheDir'] . DIRECTORY_SEPARATOR . '_annotations' . DIRECTORY_SEPARATOR,
94 94
                     $options['debug']
@@ -97,15 +97,15 @@  discard block
 block discarded – undo
97 97
 
98 98
             return $reader;
99 99
         });
100
-        $this->share('aspect.cache.path.manager', function (Container $container) {
100
+        $this->share('aspect.cache.path.manager', function(Container $container) {
101 101
             return new CachePathManager($container->get('kernel'));
102 102
         });
103 103
 
104 104
         // Pointcut services
105
-        $this->share('aspect.pointcut.lexer', function () {
105
+        $this->share('aspect.pointcut.lexer', function() {
106 106
             return new PointcutLexer();
107 107
         });
108
-        $this->share('aspect.pointcut.parser', function (Container $container) {
108
+        $this->share('aspect.pointcut.parser', function(Container $container) {
109 109
             return new PointcutParser(
110 110
                 new PointcutGrammar(
111 111
                     $container,
Please login to merge, or discard this patch.
src/Instrument/Transformer/WeavingTransformer.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,6 @@
 block discarded – undo
18 18
 use Go\Core\AspectKernel;
19 19
 use Go\Core\AspectLoader;
20 20
 use Go\Instrument\ClassLoading\CachePathManager;
21
-use Go\Instrument\CleanableMemory;
22 21
 use Go\ParserReflection\ReflectionFile;
23 22
 use Go\ParserReflection\ReflectionFileNamespace;
24 23
 use Go\Proxy\ClassProxy;
Please login to merge, or discard this patch.
src/Proxy/AbstractProxy.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@
 block discarded – undo
88 88
     /**
89 89
      * Returns list of string representation of parameters
90 90
      *
91
-     * @param array|ReflectionParameter[] $parameters List of parameters
91
+     * @param ReflectionParameter[] $parameters List of parameters
92 92
      *
93 93
      * @return array
94 94
      */
Please login to merge, or discard this patch.
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -1,12 +1,12 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Go! AOP framework
4
- *
5
- * @copyright Copyright 2012, Lisachenko Alexander <[email protected]>
6
- *
7
- * This source file is subject to the license that is bundled
8
- * with this source code in the file LICENSE.
9
- */
3
+     * Go! AOP framework
4
+     *
5
+     * @copyright Copyright 2012, Lisachenko Alexander <[email protected]>
6
+     *
7
+     * This source file is subject to the license that is bundled
8
+     * with this source code in the file LICENSE.
9
+     */
10 10
 
11 11
 namespace Go\Proxy;
12 12
 
@@ -126,7 +126,7 @@  discard block
 block discarded – undo
126 126
         $defaultValue = null;
127 127
         $isDefaultValueAvailable = $parameter->isDefaultValueAvailable();
128 128
         if ($isDefaultValueAvailable) {
129
-             $defaultValue = var_export($parameter->getDefaultValue(), true);
129
+                $defaultValue = var_export($parameter->getDefaultValue(), true);
130 130
         } elseif ($parameter->isOptional()) {
131 131
             $defaultValue = 'null';
132 132
         }
Please login to merge, or discard this patch.
src/Proxy/ClassProxy.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -416,7 +416,7 @@  discard block
 block discarded – undo
416 416
         $scope    = $isStatic ? $this->staticLsbExpression : '$this';
417 417
         $prefix   = $isStatic ? AspectContainer::STATIC_METHOD_PREFIX : AspectContainer::METHOD_PREFIX;
418 418
 
419
-        $args = join(', ', array_map(function (ReflectionParameter $param) {
419
+        $args = join(', ', array_map(function(ReflectionParameter $param) {
420 420
             $byReference = $param->isPassedByReference() ? '&' : '';
421 421
 
422 422
             return $byReference . '$' . $param->name;
@@ -468,11 +468,11 @@  discard block
 block discarded – undo
468 468
             ($prefix ? "$prefix " : '') . // List of class modifiers
469 469
             'class ' . // 'class' keyword with one space
470 470
             $this->name . // Name of the class
471
-            ' extends '. // 'extends' keyword with
471
+            ' extends ' . // 'extends' keyword with
472 472
             $this->parentClassName . // Name of the parent class
473 473
             ($this->interfaces ? ' implements ' . join(', ', $this->interfaces) : '') . "\n" . // Interfaces list
474 474
             "{\n" . // Start of class definition
475
-            ($this->traits ? $this->indent('use ' . join(', ', $this->traits) .';'."\n") : '') . "\n" . // Traits list
475
+            ($this->traits ? $this->indent('use ' . join(', ', $this->traits) . ';' . "\n") : '') . "\n" . // Traits list
476 476
             $this->indent(join("\n", $this->propertiesCode)) . "\n" . // Property definitions
477 477
             $this->indent(join("\n", $this->methodsCode)) . "\n" . // Method definitions
478 478
             "}" // End of class definition
Please login to merge, or discard this patch.
src/Proxy/TraitProxy.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
         $scope    = $isStatic ? $this->staticLsbExpression : '$this';
93 93
         $prefix   = $isStatic ? AspectContainer::STATIC_METHOD_PREFIX : AspectContainer::METHOD_PREFIX;
94 94
 
95
-        $args = join(', ', array_map(function (ReflectionParameter $param) {
95
+        $args = join(', ', array_map(function(ReflectionParameter $param) {
96 96
             $byReference = $param->isPassedByReference() ? '&' : '';
97 97
 
98 98
             return $byReference . '$' . $param->name;
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
                 'use ' . join(', ', array(-1 => $this->parentClassName) + $this->traits) .
124 124
                 $this->getMethodAliasesCode()
125 125
             ) . "\n" . // Use traits and aliases section
126
-            $this->indent(join("\n", $this->methodsCode)) . "\n". // Method definitions
126
+            $this->indent(join("\n", $this->methodsCode)) . "\n" . // Method definitions
127 127
             "}" // End of trait body
128 128
         );
129 129
 
Please login to merge, or discard this patch.