Fixes
Overview
In this release, we've addressed a critical bug in the formatter that affected the parsing of closure creations in PHP code. Specifically, the formatter was removing parentheses around the left-hand side (lhs) of a closure creation node when it was necessary, leading to parse errors.
Bug Details:
Before the fix:
$a = (function(): void {})(...);
After the formatter incorrectly processed it:
$a = function(): void {}(...);
This removal of parentheses caused the PHP parser to throw an error, disrupting the intended functionality.
What’s Fixed:
- The formatter now correctly preserves the parentheses around the lhs of closure creation nodes. This ensures that the following code is formatted correctly and parses without errors:
$a = (function(): void {})(...);
What's Next
We continue working diligently towards achieving a stable 1.0.0 release. Stay tuned for more updates, features, and fixes in upcoming versions!
We have skipped the release version
0.0.3
due to a minor issue.