Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add rules for trailing commas in function declarations #268

Merged
merged 1 commit into from Jun 21, 2022

Conversation

simPod
Copy link
Contributor

@simPod simPod commented Jun 19, 2022

Removes trailing commas on single line declarations

- function foo(int $x,): void
+ function foo(int $x): void
{
}

Requires comma in multiline declarations

function foo(
    $bar,
    $baz,
)

so extending args produces nice diff (one line modified)

function foo(
    $bar,
    $baz,
+   $bam,
)

@simPod simPod force-pushed the trailing-commas branch 4 times, most recently from 27054ef to f3cd3a4 Compare June 19, 2022 16:08
@simPod simPod marked this pull request as ready for review June 19, 2022 16:09
@simPod simPod requested a review from a team as a code owner June 19, 2022 16:09
@ostrolucky
Copy link
Member

Hopefully trailing commas in function calls are incoming too? :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants