Skip to content

[Issue] Add native_function_invocation rule for phpcs-fixer  #40159

@m2-assistant

Description

@m2-assistant

This issue is automatically created based on existing pull request: #40149: Add native_function_invocation rule for phpcs-fixer


Description (*)

Adds native_function_invocation rule to the php-cs-fixer ONLY for namespaced files
Add leading \ before function invocation to speed up resolving.
see:
https://tideways.com/profiler/blog/compiler-optimized-php-functions
https://dev.to/codeurm/php-tips-how-to-use-optimized-built-it-functions-32be
https://cs.symfony.com/doc/rules/function_notation/native_function_invocation.html

Related Pull Requests

Fixed Issues (if relevant)

  1. Fixes magento/magento2#<issue_number>

Manual testing scenarios (*)

  1. ...
  2. ...

Questions or comments

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • README.md files for modified modules are updated and included in the pull request if any README.md predefined sections require an update
  • All automated tests passed successfully (all builds are green)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Issue: ready for confirmationReported on 2.4.xIndicates original Magento version for the Issue report.Triage: Dev.ExperienceIssue related to Developer Experience and needs help with Triage to Confirm or Reject it

    Type

    No type

    Projects

    Status

    Ready for Confirmation

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions