Skip to content

Commit

Permalink
rebase
Browse files Browse the repository at this point in the history
  • Loading branch information
TomasVotruba committed Sep 25, 2022
1 parent 2316791 commit 4602e8b
Show file tree
Hide file tree
Showing 16 changed files with 13 additions and 133 deletions.
5 changes: 0 additions & 5 deletions lib/PhpParser/Internal/PrintableNewAnonClassNode.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,7 @@
*
* @internal
*/
<<<<<<< HEAD
class PrintableNewAnonClassNode extends Expr {
=======
class PrintableNewAnonClassNode extends Expr implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
/** @var Node\AttributeGroup[] PHP attribute groups */
public $attrGroups;
/** @var Node\Arg[] Arguments */
Expand Down
7 changes: 1 addition & 6 deletions lib/PhpParser/Node/Expr/Closure.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,7 @@
use PhpParser\Node\Expr;
use PhpParser\Node\FunctionLike;

<<<<<<< HEAD
class Closure extends Expr implements FunctionLike {
=======
class Closure extends Expr implements FunctionLike, Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class Closure extends Expr implements FunctionLike, Node\StmtsIterable {
/** @var bool Whether the closure is static */
public $static;
/** @var bool Whether to return by reference */
Expand Down
11 changes: 1 addition & 10 deletions lib/PhpParser/Node/Stmt/Case_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class Case_ extends Node\Stmt {
=======
class Case_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class Case_ extends Node\Stmt implements Node\StmtsIterable {
/** @var null|Node\Expr Condition (null for default) */
public $cond;
/** @var Node\Stmt[] Statements */
Expand All @@ -32,11 +27,7 @@ public function getSubNodeNames(): array {
return ['cond', 'stmts'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_Case';
}
}
7 changes: 1 addition & 6 deletions lib/PhpParser/Node/Stmt/Catch_.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,7 @@
use PhpParser\Node;
use PhpParser\Node\Expr;

<<<<<<< HEAD
class Catch_ extends Node\Stmt {
=======
class Catch_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class Catch_ extends Node\Stmt implements Node\StmtsIterable {
/** @var Node\Name[] Types of exceptions to catch */
public $types;
/** @var Expr\Variable|null Variable for exception */
Expand Down
7 changes: 1 addition & 6 deletions lib/PhpParser/Node/Stmt/ClassMethod.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,7 @@
use PhpParser\Node;
use PhpParser\Node\FunctionLike;

<<<<<<< HEAD
class ClassMethod extends Node\Stmt implements FunctionLike {
=======
class ClassMethod extends Node\Stmt implements FunctionLike, Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
/** @var int Flags */
public $flags;
/** @var bool Whether to return by reference */
Expand All @@ -22,7 +17,7 @@ class ClassMethod extends Node\Stmt implements FunctionLike, Node\StmtsIterable
public $params;
/** @var null|Node\Identifier|Node\Name|Node\ComplexType Return type */
public $returnType;
/** @var Node\Stmt[] Statements */
/** @var Node\Stmt[]|null Statements */
public $stmts;
/** @var Node\AttributeGroup[] PHP attribute groups */
public $attrGroups;
Expand Down
11 changes: 1 addition & 10 deletions lib/PhpParser/Node/Stmt/Do_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class Do_ extends Node\Stmt {
=======
class Do_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class Do_ extends Node\Stmt implements Node\StmtsIterable {
/** @var Node\Stmt[] Statements */
public $stmts;
/** @var Node\Expr Condition */
Expand All @@ -32,11 +27,7 @@ public function getSubNodeNames(): array {
return ['stmts', 'cond'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_Do';
}
}
11 changes: 1 addition & 10 deletions lib/PhpParser/Node/Stmt/ElseIf_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class ElseIf_ extends Node\Stmt {
=======
class ElseIf_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class ElseIf_ extends Node\Stmt implements Node\StmtsIterable {
/** @var Node\Expr Condition */
public $cond;
/** @var Node\Stmt[] Statements */
Expand All @@ -32,11 +27,7 @@ public function getSubNodeNames(): array {
return ['cond', 'stmts'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_ElseIf';
}
}
11 changes: 1 addition & 10 deletions lib/PhpParser/Node/Stmt/Else_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class Else_ extends Node\Stmt {
=======
class Else_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class Else_ extends Node\Stmt implements Node\StmtsIterable {
/** @var Node\Stmt[] Statements */
public $stmts;

Expand All @@ -28,11 +23,7 @@ public function getSubNodeNames(): array {
return ['stmts'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_Else';
}
}
11 changes: 1 addition & 10 deletions lib/PhpParser/Node/Stmt/Finally_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class Finally_ extends Node\Stmt {
=======
class Finally_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class Finally_ extends Node\Stmt implements Node\StmtsIterable {
/** @var Node\Stmt[] Statements */
public $stmts;

Expand All @@ -28,11 +23,7 @@ public function getSubNodeNames(): array {
return ['stmts'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_Finally';
}
}
11 changes: 1 addition & 10 deletions lib/PhpParser/Node/Stmt/For_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class For_ extends Node\Stmt {
=======
class For_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class For_ extends Node\Stmt implements Node\StmtsIterable {
/** @var Node\Expr[] Init expressions */
public $init;
/** @var Node\Expr[] Loop conditions */
Expand Down Expand Up @@ -41,11 +36,7 @@ public function getSubNodeNames(): array {
return ['init', 'cond', 'loop', 'stmts'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_For';
}
}
9 changes: 0 additions & 9 deletions lib/PhpParser/Node/Stmt/Foreach_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class Foreach_ extends Node\Stmt {
=======
class Foreach_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
/** @var Node\Expr Expression to iterate */
public $expr;
/** @var null|Node\Expr Variable to assign key to */
Expand Down Expand Up @@ -45,11 +40,7 @@ public function getSubNodeNames(): array {
return ['expr', 'keyVar', 'byRef', 'valueVar', 'stmts'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_Foreach';
}
}
5 changes: 0 additions & 5 deletions lib/PhpParser/Node/Stmt/Function_.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,7 @@
use PhpParser\Node;
use PhpParser\Node\FunctionLike;

<<<<<<< HEAD
class Function_ extends Node\Stmt implements FunctionLike {
=======
class Function_ extends Node\Stmt implements FunctionLike, Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
/** @var bool Whether function returns by reference */
public $byRef;
/** @var Node\Identifier Name */
Expand Down
11 changes: 1 addition & 10 deletions lib/PhpParser/Node/Stmt/If_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class If_ extends Node\Stmt {
=======
class If_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class If_ extends Node\Stmt implements Node\StmtsIterable {
/** @var Node\Expr Condition expression */
public $cond;
/** @var Node\Stmt[] Statements */
Expand Down Expand Up @@ -41,11 +36,7 @@ public function getSubNodeNames(): array {
return ['cond', 'stmts', 'elseifs', 'else'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_If';
}
}
11 changes: 1 addition & 10 deletions lib/PhpParser/Node/Stmt/Namespace_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class Namespace_ extends Node\Stmt {
=======
class Namespace_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class Namespace_ extends Node\Stmt implements Node\StmtsIterable {
/* For use in the "kind" attribute */
public const KIND_SEMICOLON = 1;
public const KIND_BRACED = 2;
Expand All @@ -36,11 +31,7 @@ public function getSubNodeNames(): array {
return ['name', 'stmts'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_Namespace';
}
}
7 changes: 1 addition & 6 deletions lib/PhpParser/Node/Stmt/TryCatch.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class TryCatch extends Node\Stmt {
=======
class TryCatch extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class TryCatch extends Node\Stmt implements Node\StmtsIterable {
/** @var Node\Stmt[] Statements */
public $stmts;
/** @var Catch_[] Catches */
Expand Down
11 changes: 1 addition & 10 deletions lib/PhpParser/Node/Stmt/While_.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@

use PhpParser\Node;

<<<<<<< HEAD
class While_ extends Node\Stmt {
=======
class While_ extends Node\Stmt implements Node\StmtsIterable
{
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
class While_ extends Node\Stmt implements Node\StmtsIterable {
/** @var Node\Expr Condition */
public $cond;
/** @var Node\Stmt[] Statements */
Expand All @@ -32,11 +27,7 @@ public function getSubNodeNames(): array {
return ['cond', 'stmts'];
}

<<<<<<< HEAD
public function getType(): string {
=======
public function getType() : string {
>>>>>>> 920aae4f (add StmtsIterable interface to mark nodes that contain iterable stmts to improve hooking in node visitors)
return 'Stmt_While';
}
}

0 comments on commit 4602e8b

Please sign in to comment.