diff --git a/.travis.yml b/.travis.yml index b79edcd..bebbc76 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,6 +7,7 @@ php: - 7.1 - 7.2 - 7.3 + - 7.4 cache: directories: diff --git a/Spreadsheet/Excel/Writer/Parser.php b/Spreadsheet/Excel/Writer/Parser.php index 9182f9b..0909969 100644 --- a/Spreadsheet/Excel/Writer/Parser.php +++ b/Spreadsheet/Excel/Writer/Parser.php @@ -1091,7 +1091,7 @@ protected function _cellToRowcol($cell) $col = 0; $col_ref_length = strlen($col_ref); for ($i = 0; $i < $col_ref_length; $i++) { - $col += (ord($col_ref{$i}) - ord('A') + 1) * pow(26, $expn); + $col += (ord($col_ref[$i]) - ord('A') + 1) * pow(26, $expn); $expn--; } @@ -1113,20 +1113,20 @@ protected function _advance() $formula_length = strlen($this->_formula); // eat up white spaces if ($i < $formula_length) { - while ($this->_formula{$i} == " ") { + while ($this->_formula[$i] == " ") { $i++; } if ($i < ($formula_length - 1)) { - $this->_lookahead = $this->_formula{$i+1}; + $this->_lookahead = $this->_formula[$i+1]; } $token = ''; } while ($i < $formula_length) { - $token .= $this->_formula{$i}; + $token .= $this->_formula[$i]; if ($i < ($formula_length - 1)) { - $this->_lookahead = $this->_formula{$i+1}; + $this->_lookahead = $this->_formula[$i+1]; } else { $this->_lookahead = ''; } @@ -1141,7 +1141,7 @@ protected function _advance() } if ($i < ($formula_length - 2)) { - $this->_lookahead = $this->_formula{$i+2}; + $this->_lookahead = $this->_formula[$i+2]; } else { // if we run out of characters _lookahead becomes empty $this->_lookahead = ''; } @@ -1292,7 +1292,7 @@ public function parse($formula) { $this->_current_char = 0; $this->_formula = $formula; - $this->_lookahead = $formula{1}; + $this->_lookahead = $formula[1]; $this->_advance(); $this->_parse_tree = $this->_condition(); if (PEAR::isError($this->_parse_tree)) { diff --git a/Spreadsheet/Excel/Writer/Workbook.php b/Spreadsheet/Excel/Writer/Workbook.php index 3c779ec..c4e66bf 100644 --- a/Spreadsheet/Excel/Writer/Workbook.php +++ b/Spreadsheet/Excel/Writer/Workbook.php @@ -1450,7 +1450,6 @@ protected function _calculateSharedStringsSizes() they must be written before the SST records */ - $tmp_block_sizes = array(); $tmp_block_sizes = $this->_block_sizes; $length = 12; diff --git a/composer.json b/composer.json index 652509f..04869eb 100644 --- a/composer.json +++ b/composer.json @@ -52,7 +52,7 @@ "require": { "pear/pear-core-minimal": "^1.10", "pear/ole": ">=1.0.0RC4", - "php": ">=5.3.3 <7.4" + "php": ">=5.3.3 <7.5" }, "require-dev": { "phpunit/phpunit": "<6.0"