aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/WebAssembly/Structure/Instructions/Instrs/Control/BrTable.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/WebAssembly/Structure/Instructions/Instrs/Control/BrTable.php')
-rw-r--r--src/WebAssembly/Structure/Instructions/Instrs/Control/BrTable.php24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/WebAssembly/Structure/Instructions/Instrs/Control/BrTable.php b/src/WebAssembly/Structure/Instructions/Instrs/Control/BrTable.php
new file mode 100644
index 0000000..2841814
--- /dev/null
+++ b/src/WebAssembly/Structure/Instructions/Instrs/Control/BrTable.php
@@ -0,0 +1,24 @@
+<?php
+
+declare(strict_types=1);
+
+namespace Nsfisis\Waddiwasi\WebAssembly\Structure\Instructions\Instrs\Control;
+
+use Nsfisis\Waddiwasi\WebAssembly\Structure\Instructions\Instr;
+
+final readonly class BrTable extends Instr
+{
+ /**
+ * @param list<int> $labelTable
+ */
+ protected function __construct(
+ public array $labelTable,
+ public int $defaultLabel,
+ ) {
+ }
+
+ public static function opName(): string
+ {
+ return "br_table";
+ }
+}