1: <?php declare(strict_types = 1);
2:
3: namespace PHPStan\Node;
4:
5: use PhpParser\Node\Stmt;
6:
7: /**
8: * @api
9: */
10: final class UnreachableStatementNode extends Stmt implements VirtualNode
11: {
12:
13: /** @param Stmt[] $nextStatements */
14: public function __construct(private Stmt $originalStatement, private array $nextStatements = [])
15: {
16: parent::__construct($originalStatement->getAttributes());
17: }
18:
19: public function getOriginalStatement(): Stmt
20: {
21: return $this->originalStatement;
22: }
23:
24: public function getType(): string
25: {
26: return 'PHPStan_Stmt_UnreachableStatementNode';
27: }
28:
29: /**
30: * @return string[]
31: */
32: public function getSubNodeNames(): array
33: {
34: return [];
35: }
36:
37: /**
38: * @return Stmt[]
39: */
40: public function getNextStatements(): array
41: {
42: return $this->nextStatements;
43: }
44:
45: }
46: