extensions/felixfbecker.php-intellisense-0.0.12/vendor/squizlabs/php_codesniffer/src/Standards/Squiz/Sniffs/Objects/ObjectMemberCommaSniff.php
/**
     * Process the tokens that this sniff is listening for.
     *
     * @param PHP_CodeSniffer_File $phpcsFile The file where the token was found.
     * @param int                  $stackPtr  The position in the stack where
     *                                        the token was found.
     *
     * @return void
     */
Process the tokens that this sniff is listening for.
@param PHP_CodeSniffer_File $phpcsFile The file where the token was found.
@param int                  $stackPtr  The position in the stack where
the token was found.

@return void
Process the tokens that this sniff is listening for . @param PHP_CodeSniffer_File $phpcsFile The file where the token was found . @param int $stackPtr The position in the stack where the token was found . @return void
public function process(File $phpcsFile, $stackPtr)
    {
        $tokens = $phpcsFile->getTokens();
        $prev = $phpcsFile->findPrevious(Tokens::$emptyTokens, ($stackPtr - 1), null, true);
        if ($tokens[$prev]['code'] === T_COMMA) {
            $error = 'Last member of object must not be followed by a comma';
            $fix   = $phpcsFile->addFixableError($error, $prev, 'Missing');
            if ($fix === true) {
                $phpcsFile->fixer->replaceToken($prev, '');
            }
        }
    }
public function process ( File $ phpcsFile , $ stackPtr ) { $ tokens = $ phpcsFile -> getTokens ( ) ; $ prev = $ phpcsFile -> findPrevious ( Tokens :: $ emptyTokens , ( $ stackPtr - 1 ) , null , true ) ; if ( $ tokens [ $ prev ] [ 'code' ] === T_COMMA ) { $ error = 'Last member of object must not be followed by a comma' ; $ fix = $ phpcsFile -> addFixableError ( $ error , $ prev , 'Missing' ) ; if ( $ fix === true ) { $ phpcsFile -> fixer -> replaceToken ( $ prev , '' ) ; } } }
Process the tokens that this sniff is listening for.
Process the tokens that this sniff is listening for .