mirror of
https://github.com/phabelio/PHP-Parser.git
synced 2024-11-26 20:14:46 +01:00
Remove NodeTraverser dependency on parent::__construct() (#528)
A parent::__construct() call is now optional when extending NodeTraverser.
This commit is contained in:
parent
1973b6633a
commit
d7d581c1d2
@ -31,16 +31,13 @@ class NodeTraverser implements NodeTraverserInterface
|
||||
const REMOVE_NODE = 3;
|
||||
|
||||
/** @var NodeVisitor[] Visitors */
|
||||
protected $visitors;
|
||||
protected $visitors = [];
|
||||
|
||||
/** @var bool Whether traversal should be stopped */
|
||||
protected $stopTraversal;
|
||||
|
||||
/**
|
||||
* Constructs a node traverser.
|
||||
*/
|
||||
public function __construct() {
|
||||
$this->visitors = [];
|
||||
// for BC
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user