Registry / utility / phpunit-php-token-stream

phpunit-php-token-stream

JSON →
library4.0.4phppackagistunverified

Wrapper around PHP's tokenizer extension.

composer require phpunit/php-token-stream
INSTALL
IMPORT
SIG · PHPUNIT-PHP-TOKEN-
P
phpunit-php-token-stream
utilityphpv4.0.4
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Stream
use PHPUnit\TokenStream\Token\Stream;

Parse a PHP file into tokens and iterate over them.

use PHPUnit\TokenStream\Token\Stream; $stream = new Stream(file_get_contents('example.php')); foreach ($stream as $token) { echo $token->getName(); }
Debug
Known issues
breakingThis package is deprecated; use phpunit/php-token-stream is no longer maintained.
fix
Consider using nikic/php-parser or the native tokenizer directly.
affects: >=4.0.0
Upgrade
Version history
4.0.4latest on Packagist
Audit
Dependencies

No dependency data recorded yet.

Agent activity
5 hits · last 30 days
node
4
Amazon
1
Resources
phpunit-php-token-stream — pip install phpunit-php-token-stream · libregistry