aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Structure/Types/ExternType.php
blob: 404f7555d05e9b20b1b726de03b0925da5540271 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?php

declare(strict_types=1);

namespace Nsfisis\Waddiwasi\Structure\Types;

abstract readonly class ExternType
{
    final public static function Func(FuncType $type): ExternTypes\Func
    {
        return new ExternTypes\Func($type);
    }

    final public static function Table(TableType $type): ExternTypes\Table
    {
        return new ExternTypes\Table($type);
    }

    final public static function Mem(MemType $type): ExternTypes\Mem
    {
        return new ExternTypes\Mem($type);
    }

    final public static function Global(GlobalType $type): ExternTypes\Global_
    {
        return new ExternTypes\Global_($type);
    }
}