aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/brick/math/src/Internal/Calculator.php
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/brick/math/src/Internal/Calculator.php')
-rw-r--r--vendor/brick/math/src/Internal/Calculator.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/vendor/brick/math/src/Internal/Calculator.php b/vendor/brick/math/src/Internal/Calculator.php
index 44795acbb..99b478193 100644
--- a/vendor/brick/math/src/Internal/Calculator.php
+++ b/vendor/brick/math/src/Internal/Calculator.php
@@ -677,6 +677,9 @@ abstract class Calculator
}
/**
+ * @psalm-suppress InvalidOperand
+ * @see https://github.com/vimeo/psalm/issues/4456
+ *
* @param string $number A positive, binary number.
*
* @return string
@@ -685,7 +688,7 @@ abstract class Calculator
{
$xor = \str_repeat("\xff", \strlen($number));
- $number = $number ^ $xor;
+ $number ^= $xor;
for ($i = \strlen($number) - 1; $i >= 0; $i--) {
$byte = \ord($number[$i]);