diff --git a/VariableAnalysis/Lib/Helpers.php b/VariableAnalysis/Lib/Helpers.php index 9b03bcd..b05917e 100644 --- a/VariableAnalysis/Lib/Helpers.php +++ b/VariableAnalysis/Lib/Helpers.php @@ -69,6 +69,9 @@ public static function findContainingOpeningBracket(File $phpcsFile, $stackPtr) { $tokens = $phpcsFile->getTokens(); if (isset($tokens[$stackPtr]['nested_parenthesis'])) { + /** + * @var array + */ $openPtrs = array_keys($tokens[$stackPtr]['nested_parenthesis']); return (int)end($openPtrs); } @@ -1081,6 +1084,9 @@ public static function getFunctionIndexForFunctionCallArgument(File $phpcsFile, if (empty($token['nested_parenthesis'])) { return null; } + /** + * @var array + */ $startingParenthesis = array_keys($token['nested_parenthesis']); $startOfArguments = end($startingParenthesis); if (! is_int($startOfArguments)) {