// File: /workspace/github_cpp_makefile_star2_O1/CoinXu[P]reviser-compiler/src/compiler/typescript/typescript_generator.cpp
// Function: reviser::typescript::TypeScriptGenerator::Generate[abi:cxx11]()
string TypeScriptGenerator::Generate() {
    string block_separetor = "\n\n";
    string code(
      "//\n"
      "// language: TypeScript\n"
      "// generated by reviser-comiper\n"
      "// do not change this file\n"
      "// see https://github.com/CoinXu/reviser-compiler\n\n\n"
    );
    code += Import() + block_separetor;

    for (StmtSeqItem it: seq) {
      switch(it.type) {
        case STMT_TYPE_STRUCT:
          code += StmtStruct(structures.at(it.index)) + block_separetor;
          break;

        case STMT_TYPE_ENUM:
          code += StmtEnum(enums.at(it.index)) + block_separetor;
          break;

        default:
          break;
      }
    }

    return code + Export() + block_separetor;
  }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %rsi, %r14
movq %rdi, %r15
leaq -0x78(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x4e61(%rip), %rsi      # 0x51b52
leaq 0x4e5c(%rip), %rdx      # 0x51b54
leaq -0x88(%rbp), %rdi
callq 0x2a2fe
leaq -0x98(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x4f27(%rip), %rsi      # 0x51c3d
leaq 0x4faa(%rip), %rdx      # 0x51cc7
leaq -0xa8(%rbp), %rdi
callq 0x2a2fe
leaq -0x68(%rbp), %rdi
movq %r14, %rsi
callq 0x4b7a8
movq -0x88(%rbp), %rsi
movq -0x80(%rbp), %rdx
leaq -0x68(%rbp), %rdi
callq 0x250f0
leaq -0x38(%rbp), %rbx
movq %rbx, -0x10(%rbx)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x4cd6d
movq %rdx, -0x48(%rbp)
movq (%rcx), %rdx
movq %rdx, -0x38(%rbp)
jmp 0x4cd73
movups (%rcx), %xmm0
movups %xmm0, (%rbx)
movq 0x8(%rax), %rdx
movq %rdx, -0x40(%rbp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq -0x48(%rbp), %rsi
movq -0x40(%rbp), %rdx
leaq -0xa8(%rbp), %rdi
callq 0x250f0
movq -0x48(%rbp), %rdi
cmpq %rbx, %rdi
je 0x4cdac
callq 0x25320
movq %r15, -0xb0(%rbp)
leaq -0x58(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4cdc5
callq 0x25320
movq 0x8(%r14), %r13
movq 0x10(%r14), %r12
cmpq %r12, %r13
je 0x4cf35
leaq -0x68(%rbp), %r15
movl (%r13), %eax
movq 0x8(%r13), %rsi
testl %eax, %eax
je 0x4ce49
cmpl $0x1, %eax
jne 0x4cf28
movq 0x20(%r14), %rax
movq 0x28(%r14), %rdx
subq %rax, %rdx
sarq $0x3, %rdx
cmpq %rsi, %rdx
jbe 0x4d063
movq (%rax,%rsi,8), %rdx
movq (%r14), %rax
movq %r15, %rdi
movq %r14, %rsi
callq *(%rax)
movq -0x88(%rbp), %rsi
movq -0x80(%rbp), %rdx
movq %r15, %rdi
callq 0x250f0
movq %rbx, -0x48(%rbp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x4cea4
movq %rdx, -0x48(%rbp)
movq (%rcx), %rdx
movq %rdx, -0x38(%rbp)
jmp 0x4ceaa
movq 0x38(%r14), %rax
movq 0x40(%r14), %rdx
subq %rax, %rdx
sarq $0x3, %rdx
cmpq %rsi, %rdx
jbe 0x4d055
movq (%rax,%rsi,8), %rdx
movq (%r14), %rax
movq %r15, %rdi
movq %r14, %rsi
callq *0x8(%rax)
movq -0x88(%rbp), %rsi
movq -0x80(%rbp), %rdx
movq %r15, %rdi
callq 0x250f0
movq %rbx, -0x48(%rbp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x4ced7
movq %rdx, -0x48(%rbp)
movq (%rcx), %rdx
movq %rdx, -0x38(%rbp)
jmp 0x4cedd
movups (%rcx), %xmm0
movups %xmm0, (%rbx)
movq 0x8(%rax), %rdx
movq %rdx, -0x40(%rbp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq -0x48(%rbp), %rsi
movq -0x40(%rbp), %rdx
leaq -0xa8(%rbp), %rdi
callq 0x250f0
jmp 0x4cf08
movups (%rcx), %xmm0
movups %xmm0, (%rbx)
movq 0x8(%rax), %rdx
movq %rdx, -0x40(%rbp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq -0x48(%rbp), %rsi
movq -0x40(%rbp), %rdx
leaq -0xa8(%rbp), %rdi
callq 0x250f0
movq -0x48(%rbp), %rdi
cmpq %rbx, %rdi
je 0x4cf16
callq 0x25320
movq -0x68(%rbp), %rdi
leaq -0x58(%rbp), %rax
cmpq %rax, %rdi
je 0x4cf28
callq 0x25320
addq $0x10, %r13
cmpq %r12, %r13
jne 0x4cdda
leaq -0x68(%rbp), %rdi
movq %r14, %rsi
callq 0x4c4fa
movq -0xa8(%rbp), %rcx
movq -0xa0(%rbp), %r8
leaq -0x68(%rbp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x253a0
movq -0xb0(%rbp), %r14
movq %rbx, -0x48(%rbp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x4cf83
movq %rdx, -0x48(%rbp)
movq (%rcx), %rdx
movq %rdx, -0x38(%rbp)
jmp 0x4cf89
movups (%rcx), %xmm0
movups %xmm0, (%rbx)
movq 0x8(%rax), %rdx
leaq -0x48(%rbp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq -0x88(%rbp), %rsi
movq -0x80(%rbp), %rdx
callq 0x250f0
leaq 0x10(%r14), %rdx
movq %rdx, (%r14)
movq (%rax), %rsi
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rsi
je 0x4cfd6
movq %rsi, (%r14)
movq (%rcx), %rdx
movq %rdx, 0x10(%r14)
jmp 0x4cfdc
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq 0x8(%rax), %rdx
movq %rdx, 0x8(%r14)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq -0x48(%rbp), %rdi
cmpq %rbx, %rdi
je 0x4d001
callq 0x25320
movq -0x68(%rbp), %rdi
leaq -0x58(%rbp), %rax
cmpq %rax, %rdi
leaq -0x78(%rbp), %rbx
je 0x4d017
callq 0x25320
movq -0xa8(%rbp), %rdi
leaq -0x98(%rbp), %rax
cmpq %rax, %rdi
je 0x4d02f
callq 0x25320
movq -0x88(%rbp), %rdi
cmpq %rbx, %rdi
je 0x4d040
callq 0x25320
movq %r14, %rax
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x326e(%rip), %rdi      # 0x502ca
xorl %eax, %eax
callq 0x25510
leaq 0x3260(%rip), %rdi      # 0x502ca
xorl %eax, %eax
callq 0x25510
jmp 0x4d0a6
jmp 0x4d0bb
jmp 0x4d0d2
movq %rax, %r14
movq -0x48(%rbp), %rdi
cmpq %rbx, %rdi
je 0x4d08d
callq 0x25320
jmp 0x4d08d
movq %rax, %r14
leaq -0x58(%rbp), %rax
movq -0x10(%rax), %rdi
jmp 0x4d0c6
jmp 0x4d0d2
movq %rax, %r14
jmp 0x4d0ed
jmp 0x4d0d2
jmp 0x4d0d2
jmp 0x4d0d2
jmp 0x4d0a6
movq %rax, %r14
movq -0x48(%rbp), %rdi
cmpq %rbx, %rdi
je 0x4d0be
callq 0x25320
jmp 0x4d0be
jmp 0x4d0bb
movq %rax, %r14
movq -0x68(%rbp), %rdi
leaq -0x58(%rbp), %rax
cmpq %rax, %rdi
je 0x4d0d5
callq 0x25320
jmp 0x4d0d5
movq %rax, %r14
movq -0xa8(%rbp), %rdi
leaq -0x98(%rbp), %rax
cmpq %rax, %rdi
je 0x4d0ed
callq 0x25320
movq -0x88(%rbp), %rdi
leaq -0x78(%rbp), %rax
cmpq %rax, %rdi
je 0x4d102
callq 0x25320
movq %r14, %rdi
callq 0x255f0