You are here

public function GlobalConstantSniff::register in Coder 8.3.x

Same name and namespace in other branches
  1. 8.3 coder_sniffer/DrupalPractice/Sniffs/Constants/GlobalConstantSniff.php \DrupalPractice\Sniffs\Constants\GlobalConstantSniff::register()
  2. 8.2 coder_sniffer/DrupalPractice/Sniffs/Constants/GlobalConstantSniff.php \DrupalPractice\Sniffs\Constants\GlobalConstantSniff::register()

Returns an array of tokens this test wants to listen for.

Return value

array<int|string>

File

coder_sniffer/DrupalPractice/Sniffs/Constants/GlobalConstantSniff.php, line 32

Class

GlobalConstantSniff
Checks that globally defined constants are not used in Drupal 8 and higher.

Namespace

DrupalPractice\Sniffs\Constants

Code

public function register() {
  return [
    T_CONST,
  ];
}