1#!/usr/bin/env php
2<?php
3
4declare(strict_types=1);
5
6use Hoa\Compiler\Llk\Llk;
7use Hoa\File\Read;
8
9require __DIR__ . '/../../vendor/autoload.php';
10
11$compiler = Llk::load(new Read(__DIR__ . '/grammar.pp'));
12
13file_put_contents(
14    __DIR__ . '/InnerParser.php',
15    <<<EOS
16<?php
17
18declare(strict_types=1);
19
20namespace JMS\Serializer\Type;
21
22/**
23 * @internal
24 * @generated Use regenerate-parser.php to refresh this class.
25 */
26
27EOS
28    . 'final ' . Llk::save($compiler, 'InnerParser')
29);
30