This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
When You have an array with an anonymous function which contains an array the formatting gets all messed up. Take this: <pre> class MyObject{ public function func(){ [ 'func' => function(){ $array = []; } ]; } } </pre> When formatted, it looks like this: <pre> class MyObject{ public function func(){ [ 'func' => function(){ $array = []; } ]; } } </pre>
Sorry I added <pre> tags, as I didn't know it formatted it already. If you comment out $array = []; Then formatting works fine. This also applies to array() as well not just the short hand.
*** This bug has been marked as a duplicate of bug 247047 ***