-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5dbc0b0
commit 2718356
Showing
28 changed files
with
562 additions
and
85 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
<?php | ||
|
||
namespace Phplrt\Grammar { | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\Terminal} instead. | ||
*/ | ||
abstract class Terminal extends \Phplrt\Parser\Grammar\Terminal | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\Repetition} instead. | ||
*/ | ||
class Repetition extends \Phplrt\Parser\Grammar\Repetition | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\Optional} instead. | ||
*/ | ||
class Optional extends \Phplrt\Parser\Grammar\Optional | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\Production} instead. | ||
*/ | ||
abstract class Production extends \Phplrt\Parser\Grammar\Production | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\Concatenation} instead. | ||
*/ | ||
class Concatenation extends \Phplrt\Parser\Grammar\Concatenation | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\Builder} instead. | ||
*/ | ||
class Builder extends \Phplrt\Parser\Grammar\Builder | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\Rule} instead. | ||
*/ | ||
class Rule extends \Phplrt\Parser\Grammar\Rule | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\Lexeme} instead. | ||
*/ | ||
class Lexeme extends \Phplrt\Parser\Grammar\Lexeme | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\Alternation} instead. | ||
*/ | ||
class Alternation extends \Phplrt\Parser\Grammar\Alternation | ||
{ | ||
} | ||
} | ||
|
||
namespace Phplrt\Contracts\Grammar { | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\ProductionInterface} instead. | ||
*/ | ||
interface ProductionInterface extends \Phplrt\Parser\Grammar\ProductionInterface | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\RuleInterface} instead. | ||
*/ | ||
interface RuleInterface extends \Phplrt\Parser\Grammar\RuleInterface | ||
{ | ||
} | ||
|
||
/** | ||
* @deprecated since phplrt 3.2 and will be removed in 4.0, use {@see \Phplrt\Parser\Grammar\TerminalInterface} instead. | ||
*/ | ||
interface TerminalInterface extends \Phplrt\Parser\Grammar\TerminalInterface | ||
{ | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Phplrt\Parser; | ||
|
||
use Phplrt\Buffer\BufferInterface; | ||
use Phplrt\Contracts\Lexer\TokenInterface; | ||
use Phplrt\Contracts\Source\ReadableInterface; | ||
use Phplrt\Parser\Grammar\RuleInterface; | ||
|
||
/** | ||
* Interface provides full information about execution context. | ||
* | ||
* @deprecated since phplrt 3.4 and will be removed in 4.0, please use {@see Context} instead. | ||
*/ | ||
interface ContextInterface extends ContextOptionsInterface | ||
{ | ||
/** | ||
* Returns the source being processed. | ||
*/ | ||
public function getSource(): ReadableInterface; | ||
|
||
/** | ||
* Returns a lexer's buffer. | ||
*/ | ||
public function getBuffer(): BufferInterface; | ||
|
||
/** | ||
* Returns the parser's current state identifier. | ||
* | ||
* Note: Please note that this value is mutable and may change over time. | ||
* | ||
* @return array-key | ||
*/ | ||
public function getState(); | ||
|
||
/** | ||
* Returns the parser's current state rule. | ||
* | ||
* Note: Please note that this value is mutable and may change over time. | ||
*/ | ||
public function getRule(): ?RuleInterface; | ||
|
||
/** | ||
* Returns the parser's current AST node. | ||
* | ||
* If the parser does not contain any nodes of the abstract syntax tree, | ||
* then the method will return NULL. | ||
* | ||
* Note: Please note that this value is mutable and may change over time. | ||
*/ | ||
public function getNode(): ?object; | ||
|
||
/** | ||
* Returns the current parsing token. | ||
* | ||
* Note: Please note that this value is mutable and may change over time. | ||
*/ | ||
public function getToken(): TokenInterface; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Phplrt\Parser; | ||
|
||
use Phplrt\Parser\Context\ContextOptionsProviderInterface; | ||
|
||
/** | ||
* @deprecated since phplrt 3.4 and will be removed in 4.0, please | ||
* use {@see ContextOptionsProviderInterface} instead. | ||
*/ | ||
interface ContextOptionsInterface extends ContextOptionsProviderInterface {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.