Code Duplication    Length = 6-6 lines in 2 locations

lib/classes/Swift/CharacterStream/ArrayCharacterStream.php 2 locations

@@ 190-195 (lines=6) @@
187
        // Don't use array slice
188
        $arrays = array();
189
        $end = $length + $this->_offset;
190
        for ($i = $this->_offset; $i < $end; ++$i) {
191
            if (!isset($this->_array[$i])) {
192
                break;
193
            }
194
            $arrays[] = $this->_array[$i];
195
        }
196
197
        $this->_offset += $i - $this->_offset; // Limit function calls
198
@@ 223-228 (lines=6) @@
220
221
        $arrays = array();
222
        $end = $length + $this->_offset;
223
        for ($i = $this->_offset; $i < $end; ++$i) {
224
            if (!isset($this->_array[$i])) {
225
                break;
226
            }
227
            $arrays[] = $this->_array[$i];
228
        }
229
230
        $this->_offset += ($i - $this->_offset); // Limit function calls
231