@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types = 1); |
|
| 2 | +declare(strict_types=1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Innmind\Immutable; |
| 5 | 5 | |
@@ -214,7 +214,7 @@ discard block |
||
| 214 | 214 | * |
| 215 | 215 | * @param callable(T, S): void $function |
| 216 | 216 | */ |
| 217 | - public function foreach(callable $function): void |
|
| 217 | + public function foreach (callable $function): void |
|
| 218 | 218 | { |
| 219 | 219 | $this->implementation->foreach($function); |
| 220 | 220 | } |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types = 1); |
|
| 2 | +declare(strict_types=1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Innmind\Immutable\Set; |
| 5 | 5 | |
@@ -168,7 +168,7 @@ discard block |
||
| 168 | 168 | /** |
| 169 | 169 | * @param callable(T): void $function |
| 170 | 170 | */ |
| 171 | - public function foreach(callable $function): void |
|
| 171 | + public function foreach (callable $function): void |
|
| 172 | 172 | { |
| 173 | 173 | $this->values->foreach($function); |
| 174 | 174 | } |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types = 1); |
|
| 2 | +declare(strict_types=1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Innmind\Immutable; |
| 5 | 5 | |
@@ -239,7 +239,7 @@ discard block |
||
| 239 | 239 | * |
| 240 | 240 | * @param callable(T): void $function |
| 241 | 241 | */ |
| 242 | - public function foreach(callable $function): void |
|
| 242 | + public function foreach (callable $function): void |
|
| 243 | 243 | { |
| 244 | 244 | $this->implementation->foreach($function); |
| 245 | 245 | } |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types = 1); |
|
| 2 | +declare(strict_types=1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Innmind\Immutable\Set; |
| 5 | 5 | |
@@ -168,7 +168,7 @@ discard block |
||
| 168 | 168 | /** |
| 169 | 169 | * @param callable(T): void $function |
| 170 | 170 | */ |
| 171 | - public function foreach(callable $function): void |
|
| 171 | + public function foreach (callable $function): void |
|
| 172 | 172 | { |
| 173 | 173 | $this->values->foreach($function); |
| 174 | 174 | } |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types = 1); |
|
| 2 | +declare(strict_types=1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Innmind\Immutable\Sequence; |
| 5 | 5 | |
@@ -182,7 +182,7 @@ discard block |
||
| 182 | 182 | /** |
| 183 | 183 | * @param callable(T): void $function |
| 184 | 184 | */ |
| 185 | - public function foreach(callable $function): void |
|
| 185 | + public function foreach (callable $function): void |
|
| 186 | 186 | { |
| 187 | 187 | foreach ($this->values as $value) { |
| 188 | 188 | $function($value); |
@@ -546,7 +546,7 @@ discard block |
||
| 546 | 546 | public function toSequenceOf(string $type, callable $mapper = null): Sequence |
| 547 | 547 | { |
| 548 | 548 | /** @psalm-suppress MissingParamType */ |
| 549 | - $mapper ??= static fn($v): \Generator => yield $v; |
|
| 549 | + $mapper ?? = static fn($v): \Generator => yield $v; |
|
| 550 | 550 | |
| 551 | 551 | /** @psalm-suppress MissingClosureParamType */ |
| 552 | 552 | return Sequence::defer( |
@@ -573,7 +573,7 @@ discard block |
||
| 573 | 573 | public function toSetOf(string $type, callable $mapper = null): Set |
| 574 | 574 | { |
| 575 | 575 | /** @psalm-suppress MissingParamType */ |
| 576 | - $mapper ??= static fn($v): \Generator => yield $v; |
|
| 576 | + $mapper ?? = static fn($v): \Generator => yield $v; |
|
| 577 | 577 | |
| 578 | 578 | /** @psalm-suppress MissingClosureParamType */ |
| 579 | 579 | return Set::defer( |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types = 1); |
|
| 2 | +declare(strict_types=1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Innmind\Immutable\Sequence; |
| 5 | 5 | |
@@ -154,7 +154,7 @@ discard block |
||
| 154 | 154 | /** |
| 155 | 155 | * @param callable(T): void $function |
| 156 | 156 | */ |
| 157 | - public function foreach(callable $function): void |
|
| 157 | + public function foreach (callable $function): void |
|
| 158 | 158 | { |
| 159 | 159 | foreach ($this->values as $value) { |
| 160 | 160 | $function($value); |
@@ -480,7 +480,7 @@ discard block |
||
| 480 | 480 | public function toSequenceOf(string $type, callable $mapper = null): Sequence |
| 481 | 481 | { |
| 482 | 482 | /** @psalm-suppress MissingParamType */ |
| 483 | - $mapper ??= static fn($v): \Generator => yield $v; |
|
| 483 | + $mapper ?? = static fn($v): \Generator => yield $v; |
|
| 484 | 484 | |
| 485 | 485 | /** @var Sequence<ST> */ |
| 486 | 486 | $sequence = Sequence::of($type); |
@@ -504,7 +504,7 @@ discard block |
||
| 504 | 504 | public function toSetOf(string $type, callable $mapper = null): Set |
| 505 | 505 | { |
| 506 | 506 | /** @psalm-suppress MissingParamType */ |
| 507 | - $mapper ??= static fn($v): \Generator => yield $v; |
|
| 507 | + $mapper ?? = static fn($v): \Generator => yield $v; |
|
| 508 | 508 | |
| 509 | 509 | /** @var Set<ST> */ |
| 510 | 510 | $set = Set::of($type); |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types = 1); |
|
| 2 | +declare(strict_types=1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Innmind\Immutable\Map; |
| 5 | 5 | |
@@ -182,7 +182,7 @@ discard block |
||
| 182 | 182 | /** |
| 183 | 183 | * @param callable(T, S): void $function |
| 184 | 184 | */ |
| 185 | - public function foreach(callable $function): void |
|
| 185 | + public function foreach (callable $function): void |
|
| 186 | 186 | { |
| 187 | 187 | foreach ($this->values as $k) { |
| 188 | 188 | /** @var T $key */ |
@@ -471,7 +471,7 @@ discard block |
||
| 471 | 471 | public function toMapOf(string $key, string $value, callable $mapper = null): Map |
| 472 | 472 | { |
| 473 | 473 | /** @psalm-suppress MissingParamType */ |
| 474 | - $mapper ??= static fn($k, $v): \Generator => yield $k => $v; |
|
| 474 | + $mapper ?? = static fn($k, $v): \Generator => yield $k => $v; |
|
| 475 | 475 | |
| 476 | 476 | /** @var Map<MT, MS> */ |
| 477 | 477 | $map = Map::of($key, $value); |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types = 1); |
|
| 2 | +declare(strict_types=1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Innmind\Immutable\Map; |
| 5 | 5 | |
@@ -184,7 +184,7 @@ discard block |
||
| 184 | 184 | /** |
| 185 | 185 | * @param callable(T, S): void $function |
| 186 | 186 | */ |
| 187 | - public function foreach(callable $function): void |
|
| 187 | + public function foreach (callable $function): void |
|
| 188 | 188 | { |
| 189 | 189 | foreach ($this->pairs->iterator() as $pair) { |
| 190 | 190 | $function($pair->key(), $pair->value()); |
@@ -429,7 +429,7 @@ discard block |
||
| 429 | 429 | public function toMapOf(string $key, string $value, callable $mapper = null): Map |
| 430 | 430 | { |
| 431 | 431 | /** @psalm-suppress MissingParamType */ |
| 432 | - $mapper ??= static fn($k, $v): \Generator => yield $k => $v; |
|
| 432 | + $mapper ?? = static fn($k, $v): \Generator => yield $k => $v; |
|
| 433 | 433 | |
| 434 | 434 | /** @var Map<MT, MS> */ |
| 435 | 435 | $map = Map::of($key, $value); |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types = 1); |
|
| 2 | +declare(strict_types=1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Innmind\Immutable\Map; |
| 5 | 5 | |
@@ -167,7 +167,7 @@ discard block |
||
| 167 | 167 | /** |
| 168 | 168 | * @param callable(T, S): void $function |
| 169 | 169 | */ |
| 170 | - public function foreach(callable $function): void |
|
| 170 | + public function foreach (callable $function): void |
|
| 171 | 171 | { |
| 172 | 172 | foreach ($this->values as $k => $v) { |
| 173 | 173 | $function($this->normalizeKey($k), $v); |
@@ -446,7 +446,7 @@ discard block |
||
| 446 | 446 | public function toMapOf(string $key, string $value, callable $mapper = null): Map |
| 447 | 447 | { |
| 448 | 448 | /** @psalm-suppress MissingParamType */ |
| 449 | - $mapper ??= static fn($k, $v): \Generator => yield $k => $v; |
|
| 449 | + $mapper ?? = static fn($k, $v): \Generator => yield $k => $v; |
|
| 450 | 450 | |
| 451 | 451 | /** @var Map<MT, MS> */ |
| 452 | 452 | $map = Map::of($key, $value); |