aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/WebAssembly/Structure/Types
diff options
context:
space:
mode:
Diffstat (limited to 'src/WebAssembly/Structure/Types')
-rw-r--r--src/WebAssembly/Structure/Types/FuncType.php2
-rw-r--r--src/WebAssembly/Structure/Types/Limits.php2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/WebAssembly/Structure/Types/FuncType.php b/src/WebAssembly/Structure/Types/FuncType.php
index 9ea2434..7932eb5 100644
--- a/src/WebAssembly/Structure/Types/FuncType.php
+++ b/src/WebAssembly/Structure/Types/FuncType.php
@@ -18,7 +18,7 @@ final readonly class FuncType
) {
}
- public function equals(FuncType $other): bool
+ public function equals(self $other): bool
{
if (count($this->params) !== count($other->params)) {
return false;
diff --git a/src/WebAssembly/Structure/Types/Limits.php b/src/WebAssembly/Structure/Types/Limits.php
index e60b842..74a3409 100644
--- a/src/WebAssembly/Structure/Types/Limits.php
+++ b/src/WebAssembly/Structure/Types/Limits.php
@@ -18,7 +18,7 @@ final readonly class Limits
public function isValid(): bool
{
- return 0 <= $this->min &&
+ return $this->min >= 0 &&
($this->max === null || $this->min <= $this->max);
}
}