@@ -14,14 +14,14 @@ |
||
14 | 14 | |
15 | 15 | public function isPossible(): bool |
16 | 16 | { |
17 | - if (str_starts_with($this->value, '*int8')){ |
|
17 | + if (str_starts_with($this->value, '*int8')) { |
|
18 | 18 | $this->value = preg_replace('/^(\*int8\s*)/', '', $this->value); |
19 | 19 | return true; |
20 | 20 | } |
21 | 21 | return false; |
22 | 22 | } |
23 | 23 | |
24 | - public function getCastedValue(): int|float |
|
24 | + public function getCastedValue(): int | float |
|
25 | 25 | { |
26 | 26 | return octdec($this->value); |
27 | 27 | } |
@@ -14,7 +14,7 @@ |
||
14 | 14 | |
15 | 15 | public function isPossible(): bool |
16 | 16 | { |
17 | - if (str_starts_with($this->value, '*string')){ |
|
17 | + if (str_starts_with($this->value, '*string')) { |
|
18 | 18 | $this->value = preg_replace('/^(\*string\s*)/', '', $this->value); |
19 | 19 | return true; |
20 | 20 | } |
@@ -6,5 +6,5 @@ |
||
6 | 6 | { |
7 | 7 | public function isPossible(): bool; |
8 | 8 | |
9 | - public function getCastedValue(): string|bool|int|float|null; |
|
9 | + public function getCastedValue(): string | bool | int | float | null; |
|
10 | 10 | } |
@@ -15,7 +15,7 @@ |
||
15 | 15 | |
16 | 16 | public function isPossible(): bool |
17 | 17 | { |
18 | - if (str_starts_with($this->value, '*true')){ |
|
18 | + if (str_starts_with($this->value, '*true')) { |
|
19 | 19 | return true; |
20 | 20 | } |
21 | 21 | return strtolower($this->value) === 'true'; |
@@ -15,7 +15,7 @@ |
||
15 | 15 | |
16 | 16 | public function isPossible(): bool |
17 | 17 | { |
18 | - if (str_starts_with($this->value, '*false')){ |
|
18 | + if (str_starts_with($this->value, '*false')) { |
|
19 | 19 | return true; |
20 | 20 | } |
21 | 21 | return strtolower($this->value) === 'false'; |
@@ -14,7 +14,7 @@ |
||
14 | 14 | |
15 | 15 | public function isPossible(): bool |
16 | 16 | { |
17 | - if (str_starts_with($this->value, '*bool')){ |
|
17 | + if (str_starts_with($this->value, '*bool')) { |
|
18 | 18 | $this->value = preg_replace('/^(\*bool\s*)/', '', $this->value); |
19 | 19 | return true; |
20 | 20 | } |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | |
9 | 9 | final class Helper |
10 | 10 | { |
11 | - public static function scalarValueToString(string|bool|int|float|null $value): string |
|
11 | + public static function scalarValueToString(string | bool | int | float | null $value): string |
|
12 | 12 | { |
13 | 13 | if (gettype($value) === 'boolean') { |
14 | 14 | return $value ? 'true' : 'false'; |
@@ -16,7 +16,7 @@ discard block |
||
16 | 16 | return (string)$value; |
17 | 17 | } |
18 | 18 | |
19 | - public static function castType(string|bool|int|float|null $value): string|bool|int|float|null |
|
19 | + public static function castType(string | bool | int | float | null $value): string | bool | int | float | null |
|
20 | 20 | { |
21 | 21 | if (gettype($value) !== 'string') { |
22 | 22 | return $value; |