| @@ -26,11 +26,10 @@ | ||
| 26 | 26 | /** |
| 27 | 27 | * Instance of the EvalMath class. |
| 28 | 28 | * |
| 29 | 29 | * @since 1.0.0 |
| 30 | - * @var EvalMath | |
| 31 | 30 | */ |
| 32 | - protected $evalmath; | |
| 31 | + protected \EvalMath $evalmath; | |
| 33 | 32 | |
| 34 | 33 | /** |
| 35 | 34 | * Table data in which formulas shall be evaluated. |
| 36 | 35 | * |
| @@ -36,9 +35,9 @@ | ||
| 36 | 35 | * |
| 37 | 36 | * @since 1.5.0 |
| 38 | 37 | * @var array<int, array<int, string>> |
| 39 | 38 | */ |
| 40 | - protected $table_data; | |
| 39 | + protected array $table_data; | |
| 41 | 40 | |
| 42 | 41 | /** |
| 43 | 42 | * Storage for cell ranges that have been replaced in formulas. |
| 44 | 43 | * |
| @@ -44,9 +43,9 @@ | ||
| 44 | 43 | * |
| 45 | 44 | * @since 1.0.0 |
| 46 | 45 | * @var array<string, string> |
| 47 | 46 | */ |
| 48 | - protected $known_ranges = array(); | |
| 47 | + protected array $known_ranges = array(); | |
| 49 | 48 | |
| 50 | 49 | /** |
| 51 | 50 | * Initialize the Formula Evaluation class, include the EvalMath class. |
| 52 | 51 | * |
| @@ -216,9 +215,9 @@ | ||
| 216 | 215 | } |
| 217 | 216 | |
| 218 | 217 | $result = $this->_evaluate_math_expression( $expression, $row_idx, $col_idx ); |
| 219 | 218 | // Support putting formulas in strings, like =Total: {A3+A4}. |
| 220 | - if ( $formula_in_string ) { // @phpstan-ignore-line | |
| 219 | + if ( $formula_in_string ) { | |
| 221 | 220 | $content = str_replace( $orig_expression, $result, $content ); |
| 222 | 221 | } else { |
| 223 | 222 | $content = $result; |
| 224 | 223 | } |