Mago 0.0.16 introduces significant enhancements, new features, and improvements to the PHP toolchain, further refining the developer experience. Here's what's new:
🎉 New Features
Deterministic Formatter Testing
- Added deterministic testing for the formatter to ensure formatted code, when re-formatted, remains unchanged. This guarantees stable and predictable results across multiple formatting runs.
New CLI Options
mago lint --semantics-only
: Perform a quick check for semantic correctness without invoking linter rules. Ideal for rapid validation of code correctness.
New Linter Rules
analysis/inheritance
: Detects issues with class inheritance, ensuring valid and proper usage of parent classes and interfaces.analysis/instantiation
: Identifies problems in instantiation nodes, such as using new Foo when Foo does not exist, is abstract, or has a private constructor.
🛠 Improvements
Formatter Logic Overhaul
- Completely re-implemented formatting logic for assignment and binary operations, ensuring consistency and predictability. This update provides a more intuitive formatting experience for these node types.
Documentation
Launched the official documentation site: https://mago.carthage.software/.
Includes guides on installation, configuration, CLI usage, and detailed explanations of formatter and linter settings.
Miscellaneous Changes
Various small tweaks and refinements to enhance usability and performance.