[regression] Can no longer ignore Drupal.Commenting.FunctionComment.MissingReturnComment

Created on 9 May 2025, 1 day ago

Problem/Motivation

This line to ignore a rule is no longer ignored.
// phpcs:ignore Drupal.Commenting.FunctionComment.MissingReturnComment

📌 fix(FunctionComment): Allow PHPCS ignore directives before functions Active States "This will trip up a lot of excludes in Drupal core, but they are all fixable." . I am not sure of the intention here but in core we want to maintain the ability to ignore the missing return comment in these cases. It also seems reasonable to expect to be able to ignore the sniff in the future.

If there is a way to ignore the sniff I was not able to figure it out.

Steps to reproduce

In Drupal core, update coder to the latest and run phpcs composer

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Active

Version

8.3

Component

Coder Sniffer

Created by

🇳🇿New Zealand quietone

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024