@@ -6,11 +6,11 @@ |
||
6 | 6 | |
7 | 7 | class Dir extends MagicConst |
8 | 8 | { |
9 | - public function getName() : string { |
|
10 | - return '__DIR__'; |
|
11 | - } |
|
9 | + public function getName() : string { |
|
10 | + return '__DIR__'; |
|
11 | + } |
|
12 | 12 | |
13 | - public function getType() : string { |
|
14 | - return 'Scalar_MagicConst_Dir'; |
|
15 | - } |
|
13 | + public function getType() : string { |
|
14 | + return 'Scalar_MagicConst_Dir'; |
|
15 | + } |
|
16 | 16 | } |
@@ -4,8 +4,7 @@ |
||
4 | 4 | |
5 | 5 | use PhpParser\Node\Scalar\MagicConst; |
6 | 6 | |
7 | -class Dir extends MagicConst |
|
8 | -{ |
|
7 | +class Dir extends MagicConst { |
|
9 | 8 | public function getName() : string { |
10 | 9 | return '__DIR__'; |
11 | 10 | } |
@@ -6,11 +6,11 @@ |
||
6 | 6 | |
7 | 7 | class Trait_ extends MagicConst |
8 | 8 | { |
9 | - public function getName() : string { |
|
10 | - return '__TRAIT__'; |
|
11 | - } |
|
9 | + public function getName() : string { |
|
10 | + return '__TRAIT__'; |
|
11 | + } |
|
12 | 12 | |
13 | - public function getType() : string { |
|
14 | - return 'Scalar_MagicConst_Trait'; |
|
15 | - } |
|
13 | + public function getType() : string { |
|
14 | + return 'Scalar_MagicConst_Trait'; |
|
15 | + } |
|
16 | 16 | } |
@@ -4,8 +4,7 @@ |
||
4 | 4 | |
5 | 5 | use PhpParser\Node\Scalar\MagicConst; |
6 | 6 | |
7 | -class Trait_ extends MagicConst |
|
8 | -{ |
|
7 | +class Trait_ extends MagicConst { |
|
9 | 8 | public function getName() : string { |
10 | 9 | return '__TRAIT__'; |
11 | 10 | } |
@@ -6,11 +6,11 @@ |
||
6 | 6 | |
7 | 7 | class Namespace_ extends MagicConst |
8 | 8 | { |
9 | - public function getName() : string { |
|
10 | - return '__NAMESPACE__'; |
|
11 | - } |
|
9 | + public function getName() : string { |
|
10 | + return '__NAMESPACE__'; |
|
11 | + } |
|
12 | 12 | |
13 | - public function getType() : string { |
|
14 | - return 'Scalar_MagicConst_Namespace'; |
|
15 | - } |
|
13 | + public function getType() : string { |
|
14 | + return 'Scalar_MagicConst_Namespace'; |
|
15 | + } |
|
16 | 16 | } |
@@ -4,8 +4,7 @@ |
||
4 | 4 | |
5 | 5 | use PhpParser\Node\Scalar\MagicConst; |
6 | 6 | |
7 | -class Namespace_ extends MagicConst |
|
8 | -{ |
|
7 | +class Namespace_ extends MagicConst { |
|
9 | 8 | public function getName() : string { |
10 | 9 | return '__NAMESPACE__'; |
11 | 10 | } |
@@ -6,11 +6,11 @@ |
||
6 | 6 | |
7 | 7 | class Line extends MagicConst |
8 | 8 | { |
9 | - public function getName() : string { |
|
10 | - return '__LINE__'; |
|
11 | - } |
|
9 | + public function getName() : string { |
|
10 | + return '__LINE__'; |
|
11 | + } |
|
12 | 12 | |
13 | - public function getType() : string { |
|
14 | - return 'Scalar_MagicConst_Line'; |
|
15 | - } |
|
13 | + public function getType() : string { |
|
14 | + return 'Scalar_MagicConst_Line'; |
|
15 | + } |
|
16 | 16 | } |
@@ -4,8 +4,7 @@ |
||
4 | 4 | |
5 | 5 | use PhpParser\Node\Scalar\MagicConst; |
6 | 6 | |
7 | -class Line extends MagicConst |
|
8 | -{ |
|
7 | +class Line extends MagicConst { |
|
9 | 8 | public function getName() : string { |
10 | 9 | return '__LINE__'; |
11 | 10 | } |
@@ -11,7 +11,7 @@ |
||
11 | 11 | */ |
12 | 12 | class VarLikeIdentifier extends Identifier |
13 | 13 | { |
14 | - public function getType() : string { |
|
15 | - return 'VarLikeIdentifier'; |
|
16 | - } |
|
14 | + public function getType() : string { |
|
15 | + return 'VarLikeIdentifier'; |
|
16 | + } |
|
17 | 17 | } |
@@ -9,8 +9,7 @@ |
||
9 | 9 | * Examples: Names in property declarations are formatted as variables. Names in static property |
10 | 10 | * lookups are also formatted as variables. |
11 | 11 | */ |
12 | -class VarLikeIdentifier extends Identifier |
|
13 | -{ |
|
12 | +class VarLikeIdentifier extends Identifier { |
|
14 | 13 | public function getType() : string { |
15 | 14 | return 'VarLikeIdentifier'; |
16 | 15 | } |
@@ -2,6 +2,5 @@ |
||
2 | 2 | |
3 | 3 | namespace PhpParser\Node; |
4 | 4 | |
5 | -abstract class Scalar extends Expr |
|
6 | -{ |
|
5 | +abstract class Scalar extends Expr { |
|
7 | 6 | } |
@@ -6,25 +6,25 @@ |
||
6 | 6 | |
7 | 7 | class IntersectionType extends ComplexType |
8 | 8 | { |
9 | - /** @var (Identifier|Name)[] Types */ |
|
10 | - public $types; |
|
9 | + /** @var (Identifier|Name)[] Types */ |
|
10 | + public $types; |
|
11 | 11 | |
12 | - /** |
|
13 | - * Constructs an intersection type. |
|
14 | - * |
|
15 | - * @param (Identifier|Name)[] $types Types |
|
16 | - * @param array $attributes Additional attributes |
|
17 | - */ |
|
18 | - public function __construct(array $types, array $attributes = []) { |
|
19 | - $this->attributes = $attributes; |
|
20 | - $this->types = $types; |
|
21 | - } |
|
12 | + /** |
|
13 | + * Constructs an intersection type. |
|
14 | + * |
|
15 | + * @param (Identifier|Name)[] $types Types |
|
16 | + * @param array $attributes Additional attributes |
|
17 | + */ |
|
18 | + public function __construct(array $types, array $attributes = []) { |
|
19 | + $this->attributes = $attributes; |
|
20 | + $this->types = $types; |
|
21 | + } |
|
22 | 22 | |
23 | - public function getSubNodeNames() : array { |
|
24 | - return ['types']; |
|
25 | - } |
|
23 | + public function getSubNodeNames() : array { |
|
24 | + return ['types']; |
|
25 | + } |
|
26 | 26 | |
27 | - public function getType() : string { |
|
28 | - return 'IntersectionType'; |
|
29 | - } |
|
27 | + public function getType() : string { |
|
28 | + return 'IntersectionType'; |
|
29 | + } |
|
30 | 30 | } |
@@ -4,8 +4,7 @@ |
||
4 | 4 | |
5 | 5 | use PhpParser\NodeAbstract; |
6 | 6 | |
7 | -class IntersectionType extends ComplexType |
|
8 | -{ |
|
7 | +class IntersectionType extends ComplexType { |
|
9 | 8 | /** @var (Identifier|Name)[] Types */ |
10 | 9 | public $types; |
11 | 10 |
@@ -8,20 +8,20 @@ |
||
8 | 8 | * Represents the "..." in "foo(...)" of the first-class callable syntax. |
9 | 9 | */ |
10 | 10 | class VariadicPlaceholder extends NodeAbstract { |
11 | - /** |
|
12 | - * Create a variadic argument placeholder (first-class callable syntax). |
|
13 | - * |
|
14 | - * @param array $attributes Additional attributes |
|
15 | - */ |
|
16 | - public function __construct(array $attributes = []) { |
|
17 | - $this->attributes = $attributes; |
|
18 | - } |
|
11 | + /** |
|
12 | + * Create a variadic argument placeholder (first-class callable syntax). |
|
13 | + * |
|
14 | + * @param array $attributes Additional attributes |
|
15 | + */ |
|
16 | + public function __construct(array $attributes = []) { |
|
17 | + $this->attributes = $attributes; |
|
18 | + } |
|
19 | 19 | |
20 | - public function getType(): string { |
|
21 | - return 'VariadicPlaceholder'; |
|
22 | - } |
|
20 | + public function getType(): string { |
|
21 | + return 'VariadicPlaceholder'; |
|
22 | + } |
|
23 | 23 | |
24 | - public function getSubNodeNames(): array { |
|
25 | - return []; |
|
26 | - } |
|
24 | + public function getSubNodeNames(): array { |
|
25 | + return []; |
|
26 | + } |
|
27 | 27 | } |
28 | 28 | \ No newline at end of file |
@@ -9,6 +9,5 @@ |
||
9 | 9 | * |
10 | 10 | * It does not provide any shared behavior and exists only for type-checking purposes. |
11 | 11 | */ |
12 | -abstract class ComplexType extends NodeAbstract |
|
13 | -{ |
|
12 | +abstract class ComplexType extends NodeAbstract { |
|
14 | 13 | } |