Simple methods in one line bug?

I'm not sure if this is by design or a bug...

When I select to "Keep when reformatting -> Simple methods in one line" but also set "Braces placement -> In function declaration" to "Next line shifted" then simple methods do not end up on one line.

I would consider this a bug because the function is still simple no matter what the brace placement. I could possibly see the logic that I've told it I want braces on the next line but it seems to me that Keep on one line is an exception case already so shouldn't it "win"? Whereas the brace placement is for the default setting and the default should lose to the exception?

If this is really a bug I can file one but I'm new to PhpStorm and wanted to make sure first. Also, there might be some other thing I'm missing.

Thanks!

Matt

P.S. Related: Is there any way to get "Keep simple control structure on one line" so something like... "if($X==$Y) { return false; }" stays on one line?

1 comment
Comment actions Permalink

The first one seems to be a bug. By the way, please don't hesitate to report an issue even if you are not sure if it's a bug or not. We'll figure it out in any case.
For the second one there is a feature request: https://youtrack.jetbrains.com/issue/WI-14522. You can vote for it.

0

Please sign in to leave a comment.