aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Execution/Ref.php
blob: a5682d3aae100f06a01819ab7a7c49fd84a15f63 (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
<?php

declare(strict_types=1);

namespace Nsfisis\Waddiwasi\Execution;

use Nsfisis\Waddiwasi\Structure\Types\RefType;

abstract readonly class Ref
{
    final public static function RefNull(RefType $type): Refs\RefNull
    {
        return new Refs\RefNull($type);
    }

    final public static function RefFunc(int $addr): Refs\RefFunc
    {
        return new Refs\RefFunc($addr);
    }

    final public static function RefExtern(int $addr): Refs\RefExtern
    {
        return new Refs\RefExtern($addr);
    }
}