davidvarga / davidvarga/MBeautifier
Unexpected/Inconsistent behavior for if one liner
- Dominant language
- MATLAB
- Stars
- 519
- Forks
- 80
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
thanks for addressing my last issue. Since this is so actively maintained, I thought you may be interested in another issue that is, however, not as critical.
I'll explain it on MWEs.
`if 0 == 0, a = 1 + 1, end`
is kept as it is by the tool. However,
`if 0 == 0, a = 1 + 1; end`
is turned into
`if 0 == 0, a = 1 + 1;`
`end`
I think these cases should behave identically. I personally prefer the former behavior because it does allow one liners. However, I can also understand if one liners are eliminated - in this case, however, the `a = 1 + 1;` expression should also put in a separate line.
Anyways, thanks again. And it's not an important issue because it does not break the code after all.
Contributor guide
Assessment
This issue has not been assessed yet.