Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Tolerant Php Parser Laravel Package

microsoft/tolerant-php-parser

Tolerant PHP parser from Microsoft that builds an AST even from incomplete or syntactically invalid code. Ideal for IDEs, refactoring tools, and static analysis, with error recovery and precise source positions for tokens and nodes.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Enables building developer tools (IDEs, code editors) that require parsing incomplete or erroneous PHP code for features like real-time linting, code completion, and refactoring.
  • Supports "build vs buy" decisions by eliminating the need to develop a custom parser from scratch, reducing time-to-market for PHP-focused developer tools.
  • Ideal for static analysis tools, code quality checkers, or internal tooling where tolerance for syntax errors is critical during development workflows.

When to Consider This Package

  • Adopt when building IDE-like tools or development environments where code may be syntactically invalid (e.g., during active editing), and graceful error handling is required.
  • Use when prioritizing rapid prototyping of PHP tooling with minimal engineering effort, especially for scenarios involving incomplete code structures.
  • Avoid for production compilation pipelines, strict syntax validation, or non-PHP projects. If absolute stability is required, consider mature alternatives like nikic/php-parser, though they lack the same tolerance for malformed code.

How to Pitch It (Stakeholders)

Executives: "This MIT-licensed package accelerates our ability to deliver developer productivity tools that handle real-time code analysis—even with incomplete or broken code—reducing development time by months and positioning us to capture market share in the growing developer tooling space. Its proven adoption (896+ stars) ensures reliability with zero legal overhead."

Engineering: "We can leverage this battle-tested, tolerant PHP parser to skip months of low-value work building a custom solution. It’s purpose-built for IDE scenarios, handling edge

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport