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

Require trailing comma in multiline fcn declaration #56

Merged
merged 1 commit into from
Dec 2, 2021
Merged

Conversation

simPod
Copy link
Contributor

@simPod simPod commented Nov 29, 2021

Requires this

function foo(
    $bar,
    $baz,
)

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

https://github.com/slevomat/coding-standard#slevomatcodingstandardfunctionsrequiretrailingcommaindeclaration-

Closes #53

@grongor
Copy link
Contributor

grongor commented Nov 29, 2021

Bad example :D Otherwise 👍

@simPod simPod merged commit de5f2ad into master Dec 2, 2021
@simPod simPod deleted the allow-comma branch December 2, 2021 14:27
@p4veI
Copy link

p4veI commented Dec 2, 2021

sorry for belated input - but could we disallow this:

function ($bar, $baz,)

but allow this:

function(
  $bar,
  $baz,
)

forget it if it already does that 😄

@simPod
Copy link
Contributor Author

simPod commented Dec 2, 2021 via email

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

Successfully merging this pull request may close these issues.

3 participants