Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Helpers.php

function Helpers::isTokenFunctionParameter

*

Parameters

File $phpcsFile: * @param int $stackPtr * * @return bool

3 calls to Helpers::isTokenFunctionParameter()
Helpers::findVariableScopeExceptArrowFunctions in vendor/sirbrillig/phpcs-variable-analysis/VariableAnalysis/Lib/Helpers.php
* Return the token index of the scope start for a token * * For a variable within a function body, or a variable within a function * definition argument list, this will return the function keyword's index. * * For a variable within a…
VariableAnalysisSniff::processVariable in vendor/sirbrillig/phpcs-variable-analysis/VariableAnalysis/Sniffs/CodeAnalysis/VariableAnalysisSniff.php
* Process a normal variable in the code. * * Most importantly, this function determines if the variable use is a "read" * (using the variable for something) or a "write" (an assignment) or, * sometimes, both at once. * …
VariableAnalysisSniff::processVariableAsStaticDeclaration in vendor/sirbrillig/phpcs-variable-analysis/VariableAnalysis/Sniffs/CodeAnalysis/VariableAnalysisSniff.php
* Process a variable as a static declaration within a function. * * Specifically, this looks for variable definitions of the form `static * $foo = 'hello';` or `static int $foo;` inside a function definition. * * This will not…

File

vendor/sirbrillig/phpcs-variable-analysis/VariableAnalysis/Lib/Helpers.php, line 184

Class

Helpers

Namespace

VariableAnalysis\Lib

Code

public static function isTokenFunctionParameter(File $phpcsFile, $stackPtr) {
    return is_int(self::getFunctionIndexForFunctionParameter($phpcsFile, $stackPtr));
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal