aboutsummaryrefslogtreecommitdiff
path: root/src/NXP/Classes/Calculator.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/NXP/Classes/Calculator.php')
-rw-r--r--src/NXP/Classes/Calculator.php10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/NXP/Classes/Calculator.php b/src/NXP/Classes/Calculator.php
index 6b63503..80dee36 100644
--- a/src/NXP/Classes/Calculator.php
+++ b/src/NXP/Classes/Calculator.php
@@ -20,22 +20,14 @@ use NXP\Exception\UnknownVariableException;
*/
class Calculator
{
- /** @var array<string, CustomFunction> */
- private array $functions = [];
-
- /** @var array<Operator> */
- private array $operators = [];
-
/**
* @todo PHP8: Use constructor property promotion -> public function __construct(private array $functions, private array $operators)
*
* @param array<string, CustomFunction> $functions
* @param array<Operator> $operators
*/
- public function __construct(array $functions, array $operators)
+ public function __construct(private array $functions, private array $operators)
{
- $this->functions = $functions;
- $this->operators = $operators;
}
/**