public static function getLastTokenPointer(PHP_CodeSniffer_File $phpcsFile)
{
$tokenCount = count($phpcsFile->getTokens());
if ($tokenCount === 0) {
throw new \SlevomatCodingStandard\Helpers\EmptyFileException($phpcsFile->getFilename());
}
return $tokenCount - 1;
}