Mago 0.23.0 🪄
This release brings significant internal refactoring and key enhancements, primarily focused on improving the architecture and capabilities of Mago's syntax processing and CLI functionality.
Key Changes:
-
Refactored Syntax Processing Crates (#179):
- Consolidated the functionality of several smaller crates (mago_ast, mago_token, mago_lexer, mago_parser, mago_walker, mago_ast_utils) into a single, unified crate named
mago_syntax
. This simplifies dependency management and reflects the common usage patterns of these components. - Introduced a new crate,
mago_type_syntax
, dedicated to parsing PHP docblock type strings. This provides a reusable component for tools needing to understand docblock types. - Created a new utility crate,
mago_syntax_core
, to hold common, low-level components shared between different lexing/parsing tasks, reducing code duplication. - BREAKING CHANGE: This refactor includes significant changes to the public API of the affected crates. Users may need to adapt to the new crate structure and types.
- Consolidated the functionality of several smaller crates (mago_ast, mago_token, mago_lexer, mago_parser, mago_walker, mago_ast_utils) into a single, unified crate named
-
Improved Linter Rule:
- The
strictness/require-strict-behavior
rule now allows dynamic strictness, enabling more flexible control over strict behavior enforcement.
- The
-
Improved CLI
--exclude
Option Handling (#180):- The
--exclude
CLI option and thesource.excludes
configuration setting now correctly handle relative paths. - Specifically, if an exclusion pattern starts with
./
, it is replaced with the workspace directory, ensuring that exclusions work as expected when Mago is run from different locations within a project.
- The
We hope these changes improve the performance, reliability, and usability of Mago.
Full Changelog: 0.22.2...0.23.0