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

[Feature/59] Add rules against arrow function feature #62

Closed
wants to merge 20 commits into from

Conversation

antonioeatgoat
Copy link
Contributor

Please check if the PR fulfills these requirements

  • The commit message follows our guidelines
  • Tests for the changes have been added (for bug fixes/features)
  • Docs have been added/updated (for bug fixes/features)

What kind of change does this PR introduce?
Feature

What is the current behavior?
There is no rules against arrow function feature.

What is the new behavior?
Rules are being added

Does this PR introduce a breaking change?
No

@tangrufus
Copy link
Member

Question:
Does this rule checks for the static keyword or another rule is responsible?

// This should be disallowed.
add_action('foo', fn ($foo) => 'x');

// Because we want:
add_action('foo', static fn ($foo) => 'x');

@gmazzap gmazzap mentioned this pull request Aug 25, 2023
3 tasks
@gmazzap
Copy link
Contributor

gmazzap commented Aug 25, 2023

Question: Does this rule checks for the static keyword or another rule is responsible?

I added support tot is as well @tangrufus

@thefrosty
Copy link

Looks like this was the final PR into master which has since been deleted? I can open an issue if needed.

@gmazzap
Copy link
Contributor

gmazzap commented Aug 30, 2023

@thefrosty the branch development has been created off feature/59 branch, which was the source of this PR.

And then, the development branch was used to created this PR: #69 which then has been merged into version/2.

So all the changes in this PR are already both in version/2 and development branch.

For forward compatibility, if you plan to test the changes, please require the package via ^2@dev, this will ensure you can not have any breakage in the case we rename/delete branches.

But please be aware that v2 is a work in progress for now, bugs are expected, and we would appreciate help in testing.

@thefrosty
Copy link

That's fine, I know previously there was some issues with v1 and maybe composer api v2, so we discussed using dev-master. Since it was deleted that is no longer an option. Just wanted to call it out. Thanks.

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.

None yet

4 participants