Changeset View
Changeset View
Standalone View
Standalone View
src/parser/aast/api/AASTToken.php
| <?php | <?php | ||||
| abstract class AASTToken { | abstract class AASTToken extends Phobject { | ||||
| protected $id; | protected $id; | ||||
| protected $typeID; | protected $typeID; | ||||
| protected $typeName; | protected $typeName; | ||||
| protected $value; | protected $value; | ||||
| protected $offset; | protected $offset; | ||||
| protected $tree; | protected $tree; | ||||
| ▲ Show 20 Lines • Show All 62 Lines • ▼ Show 20 Lines | public function getNonsemanticTokensAfter() { | ||||
| $ii = $this->id + 1; | $ii = $this->id + 1; | ||||
| while ($ii < count($tokens) && !$tokens[$ii]->isSemantic()) { | while ($ii < count($tokens) && !$tokens[$ii]->isSemantic()) { | ||||
| $result[$ii] = $tokens[$ii]; | $result[$ii] = $tokens[$ii]; | ||||
| ++$ii; | ++$ii; | ||||
| } | } | ||||
| return $result; | return $result; | ||||
| } | } | ||||
| final public function getLineNumber() { | |||||
| return idx($this->tree->getOffsetToLineNumberMap(), $this->getOffset()); | |||||
| } | |||||
| } | } | ||||