kokororin / vscode-phpfmt

Integrates phpfmt into VS Code
https://marketplace.visualstudio.com/items?itemName=kokororin.vscode-phpfmt
BSD 3-Clause "New" or "Revised" License
129 stars 30 forks source link

argument type "?int" will be changed to "int ? " #150

Open rainbar opened 3 days ago

rainbar commented 3 days ago

my function is defined as function throwError(string $message, ?int $status = null, array $data = []), the argument "?int $status" will accept either null or int, but when formatting the file with phpfmt, the type ?int will be automatically changed to int ? which ErrorLen will display as error.

image

image

driade commented 1 day ago

Hi @rainbar good night.

I'm sorry I cannot reproduce the bug, the extension perfectly format the code on my side. May you share you config?

Thanks.