Code Duplication    Length = 19-19 lines in 2 locations

PHPCompatibility/Sniffs/PHP/NewConstantsSniff.php 1 location

@@ 2676-2694 (lines=19) @@
2673
     *
2674
     * @return void
2675
     */
2676
    public function process(\PHP_CodeSniffer_File $phpcsFile, $stackPtr)
2677
    {
2678
        $tokens       = $phpcsFile->getTokens();
2679
        $constantName = $tokens[$stackPtr]['content'];
2680
2681
        if (isset($this->newConstants[$constantName]) === false) {
2682
            return;
2683
        }
2684
2685
        if ($this->isUseOfGlobalConstant($phpcsFile, $stackPtr) === false) {
2686
            return;
2687
        }
2688
2689
        $itemInfo = array(
2690
            'name' => $constantName,
2691
        );
2692
        $this->handleFeature($phpcsFile, $stackPtr, $itemInfo);
2693
2694
    }//end process()
2695
2696
2697
    /**

PHPCompatibility/Sniffs/PHP/RemovedConstantsSniff.php 1 location

@@ 91-109 (lines=19) @@
88
     *
89
     * @return void
90
     */
91
    public function process(\PHP_CodeSniffer_File $phpcsFile, $stackPtr)
92
    {
93
        $tokens       = $phpcsFile->getTokens();
94
        $constantName = $tokens[$stackPtr]['content'];
95
96
        if (isset($this->removedConstants[$constantName]) === false) {
97
            return;
98
        }
99
100
        if ($this->isUseOfGlobalConstant($phpcsFile, $stackPtr) === false) {
101
            return;
102
        }
103
104
        $itemInfo = array(
105
            'name' => $constantName,
106
        );
107
        $this->handleFeature($phpcsFile, $stackPtr, $itemInfo);
108
109
    }//end process()
110
111
112
    /**