// File: /workspace/github_cpp_makefile_star2_O2/CoinXu[P]reviser-compiler/src/compiler/typescript/typescript_enum.cpp
// Function: reviser::typescript::TypeScriptEnum::Generate[abi:cxx11]()
string TypeScriptEnum::Generate() {
    string code;

    code = TypeScriptCommon::Indent(node->level) + "enum " + node->id->text + " {\n";

    size_t counter = 0;
    size_t total = node->properties.size();

    for (EnumProperty* p: node->properties) {
      TypeScriptEnumProperty property(p, this);
      counter++;
      code  = code + property.Generate(counter) + (counter >= total ? "\n" : ",\n");
    }

    return code + TypeScriptCommon::Indent(node->level) + "}";
  }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
leaq -0xa8(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movq %rdi, %rbx
movb $0x0, (%rax)
movq %rsi, -0x30(%rbp)
movq 0x20(%rsi), %rax
movl 0x8(%rax), %esi
leaq -0xd8(%rbp), %rdi
callq 0x53b3a
leaq 0x551f(%rip), %rdx      # 0x58d01
leaq -0xf8(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
callq 0x3ccf9
movq -0x30(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x30(%rax), %rdx
addq $0x8, %rdx
leaq -0x98(%rbp), %rdi
leaq -0xf8(%rbp), %rsi
callq 0x38ef6
movq %rbx, -0x68(%rbp)
leaq 0x5358(%rip), %rdx      # 0x58b7b
leaq -0x60(%rbp), %rdi
leaq -0x98(%rbp), %rsi
callq 0x38f1f
leaq -0xb8(%rbp), %rdi
leaq -0x60(%rbp), %rbx
movq %rbx, %rsi
callq 0x35400
movq %rbx, %rdi
callq 0x35180
leaq -0x98(%rbp), %r13
movq %r13, %rdi
callq 0x35180
leaq -0xf8(%rbp), %rbx
movq %rbx, %rdi
callq 0x35180
leaq -0xd8(%rbp), %r12
movq %r12, %rdi
callq 0x35180
movq -0x30(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x38(%rax), %r15
movq 0x40(%rax), %rax
movq %rax, -0x78(%rbp)
subq %r15, %rax
sarq $0x3, %rax
movq %rax, -0x70(%rbp)
pushq $0x1
popq %r14
cmpq -0x78(%rbp), %r15
je 0x53940
movq (%r15), %rax
xorps %xmm0, %xmm0
movaps %xmm0, -0x60(%rbp)
movb $0x0, -0x50(%rbp)
movq -0x30(%rbp), %rcx
movq %rcx, -0x48(%rbp)
movq %rax, -0x40(%rbp)
movq 0x20(%rcx), %rcx
movl 0x8(%rcx), %ecx
incl %ecx
movl %ecx, 0x8(%rax)
movq %r12, %rdi
leaq -0x60(%rbp), %rsi
callq 0x53a28
movq %rbx, %rdi
leaq -0xb8(%rbp), %rsi
movq %r12, %rdx
callq 0x4f6ac
cmpq -0x70(%rbp), %r14
leaq 0x5247(%rip), %rdx      # 0x58b3e
leaq 0x50af(%rip), %rax      # 0x589ad
cmovbq %rax, %rdx
movq %r13, %rdi
movq %rbx, %rsi
callq 0x38f1f
leaq -0xb8(%rbp), %rdi
movq %r13, %rsi
callq 0x35400
movq %r13, %rdi
callq 0x35180
movq %rbx, %rdi
callq 0x35180
movq %r12, %rdi
callq 0x35180
addq $0x8, %r15
incq %r14
jmp 0x5389e
movq -0x30(%rbp), %rax
movq 0x20(%rax), %rax
movl 0x8(%rax), %esi
leaq -0x98(%rbp), %rdi
callq 0x53b3a
leaq -0x60(%rbp), %rdi
leaq -0xb8(%rbp), %rsi
leaq -0x98(%rbp), %rdx
callq 0x42892
movq -0x68(%rbp), %rbx
leaq 0x3913(%rip), %rdx      # 0x5728c
leaq -0x60(%rbp), %rsi
movq %rbx, %rdi
callq 0x38f1f
leaq -0x60(%rbp), %rdi
callq 0x35180
leaq -0x98(%rbp), %rdi
callq 0x35180
leaq -0xb8(%rbp), %rdi
callq 0x35180
movq %rbx, %rax
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
callq 0x35180
jmp 0x539cc
movq %rax, %rbx
leaq -0x98(%rbp), %rdi
jmp 0x53a0e
jmp 0x539ee
movq %rax, %rbx
leaq -0x98(%rbp), %rdi
callq 0x35180
jmp 0x539fb
jmp 0x539f8
jmp 0x539f3
jmp 0x539ee
movq %rax, %rbx
jmp 0x53a13
movq %rax, %rbx
jmp 0x53a07
movq %rax, %rbx
leaq -0xf8(%rbp), %rdi
callq 0x35180
leaq -0xd8(%rbp), %rdi
callq 0x35180
leaq -0xb8(%rbp), %rdi
callq 0x35180
movq %rbx, %rdi
callq 0x355f0
nop