3 declare(strict_types=1);
5 namespace CuyZ\Valinor\Type\Parser\Factory\Specifications;
7 use CuyZ\Valinor\Type\Parser\Lexer\TypeAliasLexer;
8 use CuyZ\Valinor\Type\Parser\Lexer\TypeLexer;
9 use CuyZ\Valinor\Type\Type;
12 final class TypeAliasAssignerSpecification implements TypeParserSpecification
14 public function __construct(
15 /** @var array<string, Type> */
16 private array $aliases
19 public function transform(TypeLexer $lexer): TypeLexer
21 return new TypeAliasLexer($lexer, $this->aliases);