// File: /workspace/github_cpp_makefile_star2_O2/CoinXu[P]reviser-compiler/src/compiler/typescript/typescript_struct.cpp
// Function: reviser::typescript::TypeScriptStructProperty::Generate[abi:cxx11]()
string TypeScriptStructProperty::Generate() {
    string code_decorater;
    for (Decorater* d: node->decoraters) {
      TypeScriptDecorater decorater(d, parent);
      code_decorater += decorater.Generate();
    }

    vector<string> revisers;
    vector<ReviserSyntaxDefinition> defs = TypeScriptCommon::FindReviserSyntaxDefinitionByDataType(node->declare->type);

    // 如果是数组类型数据，将translator放在TypeArray装饰器中
    if (node->declare->array_type) {
      switch (node->declare->type) {
        case TYPE_BOOL:
        case TYPE_FLOAT:
        case TYPE_DOUBLE:
        case TYPE_INT32:
        case TYPE_INT64:
        case TYPE_UINT32:
        case TYPE_UINT64:
        case TYPE_STRING: {
          vector<string> args;
          for (ReviserSyntaxDefinition d : defs) {
            args.push_back(TypeScriptCommon::DecoraterDefinition(d));
          }
          vector<DecoraterArg> v({{ ARG_ARRAY, args }});
          revisers.push_back(TypeScriptCommon::DecoraterDefinition(ReviserMethodMap[REVISER_TYPE_ARRAY], &v));
          break;
        }

        case TYPE_ENUM:
          break;

        case TYPE_STRUCT: {
          vector<DecoraterArg> v({{ ARG_STRING, vector<string>({ node->declare->type_id->text }) }});
          revisers.push_back(TypeScriptCommon::DecoraterDefinition(ReviserMethodMap[REVISER_TYPE_ARRAY_STRUCT], &v));
          break;
        }

        default:
          break;
      }
    } else {
      switch (node->declare->type) {
        case TYPE_BOOL:
        case TYPE_FLOAT:
        case TYPE_DOUBLE:
        case TYPE_INT32:
        case TYPE_INT64:
        case TYPE_UINT32:
        case TYPE_UINT64:
        case TYPE_STRING: {
          for (int i = defs.size() - 1; i >= 0; i--) {
            revisers.push_back(TypeScriptCommon::DecoraterDefinition(defs.at(i)));
          }
          break;
        }

        case TYPE_ENUM:
          break;

        case TYPE_STRUCT: {
          vector<DecoraterArg> v({{ ARG_STRING, vector<string>({ node->declare->type_id->text }) }});
          revisers.push_back(TypeScriptCommon::DecoraterDefinition(ReviserMethodMap[REVISER_TYPE_STRUCT], &v));
          break;
        }

        default:
          break;
      }
    }

    string indent = TypeScriptCommon::Indent(node->level + 1);
    return (
        revisers.size() > 0
        ? indent + ("@" + TypeScriptCommon::JoinVector(revisers, "\n" + indent + "@") + "\n")
        : ""
      )
      + code_decorater + indent + TypeScriptDeclare(node->declare).Generate() + ";";
  }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x358, %rsp            # imm = 0x358
movq %rdi, -0xd8(%rbp)
leaq -0x188(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movq %rsi, -0xb8(%rbp)
movq 0x20(%rsi), %rax
movq 0x30(%rax), %r12
movq 0x38(%rax), %r13
leaq -0x48(%rbp), %rbx
leaq -0x90(%rbp), %r14
leaq -0x198(%rbp), %r15
cmpq %r13, %r12
je 0x55c6a
movq (%r12), %rax
movq -0xb8(%rbp), %rcx
movq 0x18(%rcx), %rcx
xorps %xmm0, %xmm0
movaps %xmm0, -0x90(%rbp)
movb $0x0, -0x80(%rbp)
movq %rcx, -0x78(%rbp)
movq %rax, -0x70(%rbp)
movq 0x20(%rcx), %rcx
movl 0x98(%rcx), %ecx
incl %ecx
movl %ecx, 0x8(%rax)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x56550
movq %r15, %rdi
movq %rbx, %rsi
callq 0x35670
movq %rbx, %rdi
callq 0x35180
addq $0x8, %r12
jmp 0x55c0d
xorps %xmm0, %xmm0
andq $0x0, -0xc0(%rbp)
movaps %xmm0, -0xd0(%rbp)
movq -0xb8(%rbp), %rbx
movq 0x20(%rbx), %rax
movq 0x48(%rax), %rax
movl (%rax), %esi
leaq -0x120(%rbp), %rdi
callq 0x55564
movq 0x20(%rbx), %rax
movq 0x48(%rax), %rax
movl (%rax), %ecx
cmpb $0x1, 0x4(%rax)
jne 0x55d41
cmpl $0x8, %ecx
jae 0x55e8d
xorps %xmm0, %xmm0
leaq -0xb0(%rbp), %rax
movaps %xmm0, (%rax)
andq $0x0, 0x10(%rax)
movq -0x120(%rbp), %r12
movq -0x118(%rbp), %r15
leaq -0x90(%rbp), %r13
leaq -0x378(%rbp), %rbx
leaq -0x48(%rbp), %r14
cmpq %r15, %r12
je 0x55dc9
movq %r13, %rdi
movq %r12, %rsi
callq 0x406a8
movq %rbx, %rdi
movq %r13, %rsi
callq 0x406a8
movq %r14, %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x56a74
leaq -0xb0(%rbp), %rdi
movq %r14, %rsi
callq 0x38f8a
movq %r14, %rdi
callq 0x35180
movq %rbx, %rdi
callq 0x4062c
movq %r13, %rdi
callq 0x4062c
addq $0x40, %r12
jmp 0x55ce8
cmpl $0x8, %ecx
jae 0x55f67
leaq -0x120(%rbp), %r15
movq 0x8(%r15), %rax
subq (%r15), %rax
shrq $0x6, %rax
movl %eax, %r14d
decq %r14
leaq -0x338(%rbp), %r12
leaq -0x90(%rbp), %r13
leaq -0xd0(%rbp), %rbx
testl %r14d, %r14d
js 0x56050
movl %r14d, %esi
andl $0x7fffffff, %esi       # imm = 0x7FFFFFFF
movq %r15, %rdi
callq 0x53102
movq %r12, %rdi
movq %rax, %rsi
callq 0x406a8
movq %r13, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0x56a74
movq %rbx, %rdi
movq %r13, %rsi
callq 0x38f8a
movq %r13, %rdi
callq 0x35180
movq %r12, %rdi
callq 0x4062c
decq %r14
jmp 0x55d77
leaq -0x88(%rbp), %rdi
movl $0x3, -0x8(%rdi)
leaq -0xb0(%rbp), %rsi
callq 0x41758
leaq -0x48(%rbp), %rdi
leaq -0x90(%rbp), %rsi
pushq $0x1
popq %rdx
leaq -0x108(%rbp), %rcx
callq 0x53062
leaq -0x88(%rbp), %rdi
callq 0x38d68
leaq -0x108(%rbp), %rsi
movl $0x1, (%rsi)
leaq 0x16ce3(%rip), %rdi     # 0x6cb00
callq 0x50d54
leaq -0x2f8(%rbp), %rdi
movq %rax, %rsi
callq 0x406a8
leaq -0x90(%rbp), %rdi
leaq -0x2f8(%rbp), %rsi
leaq -0x48(%rbp), %rdx
callq 0x56a74
leaq -0xd0(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0x38f8a
leaq -0x90(%rbp), %rdi
callq 0x35180
leaq -0x2f8(%rbp), %rdi
callq 0x4062c
leaq -0x48(%rbp), %rdi
callq 0x5309c
leaq -0xb0(%rbp), %rdi
callq 0x38d68
jmp 0x56050
cmpl $0xa, %ecx
jne 0x56050
movl $0x1, -0x90(%rbp)
movq 0x10(%rax), %rsi
addq $0x8, %rsi
leaq -0x48(%rbp), %rdi
callq 0x35470
leaq -0x88(%rbp), %rdi
leaq -0x48(%rbp), %rsi
pushq $0x1
popq %rdx
leaq -0x108(%rbp), %rcx
callq 0x530c8
leaq -0xb0(%rbp), %rdi
leaq -0x90(%rbp), %rsi
pushq $0x1
popq %rdx
leaq -0x140(%rbp), %rcx
callq 0x53062
leaq -0x88(%rbp), %rdi
callq 0x38d68
leaq -0x48(%rbp), %rbx
movq %rbx, %rdi
callq 0x35180
andl $0x0, (%rbx)
leaq 0x16bf6(%rip), %rdi     # 0x6cb00
leaq -0x48(%rbp), %rsi
callq 0x50d54
leaq -0x2b8(%rbp), %rdi
movq %rax, %rsi
callq 0x406a8
leaq -0x90(%rbp), %rdi
leaq -0x2b8(%rbp), %rsi
leaq -0xb0(%rbp), %rdx
callq 0x56a74
leaq -0xd0(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0x38f8a
leaq -0x90(%rbp), %rdi
callq 0x35180
leaq -0x2b8(%rbp), %rdi
jmp 0x5603f
cmpl $0xa, %ecx
jne 0x56050
movl $0x1, -0x90(%rbp)
movq 0x10(%rax), %rsi
addq $0x8, %rsi
leaq -0x48(%rbp), %rdi
callq 0x35470
leaq -0x88(%rbp), %rdi
leaq -0x48(%rbp), %rsi
pushq $0x1
popq %rdx
leaq -0x108(%rbp), %rcx
callq 0x530c8
leaq -0xb0(%rbp), %rdi
leaq -0x90(%rbp), %rsi
pushq $0x1
popq %rdx
leaq -0x140(%rbp), %rcx
callq 0x53062
leaq -0x88(%rbp), %rdi
callq 0x38d68
leaq -0x48(%rbp), %rbx
movq %rbx, %rdi
callq 0x35180
movl $0x2, (%rbx)
leaq 0x16b19(%rip), %rdi     # 0x6cb00
leaq -0x48(%rbp), %rsi
callq 0x50d54
leaq -0x278(%rbp), %rdi
movq %rax, %rsi
callq 0x406a8
leaq -0x90(%rbp), %rdi
leaq -0x278(%rbp), %rsi
leaq -0xb0(%rbp), %rdx
callq 0x56a74
leaq -0xd0(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0x38f8a
leaq -0x90(%rbp), %rdi
callq 0x35180
leaq -0x278(%rbp), %rdi
callq 0x4062c
leaq -0xb0(%rbp), %rdi
callq 0x5309c
movq -0xb8(%rbp), %r12
movq 0x20(%r12), %rax
movl 0x8(%rax), %esi
incl %esi
leaq -0x90(%rbp), %rdi
callq 0x53b3a
movq -0xd0(%rbp), %r14
movq -0xc8(%rbp), %r15
cmpq %r14, %r15
movq -0xd8(%rbp), %rbx
je 0x5613c
leaq -0x158(%rbp), %rdi
leaq -0xd0(%rbp), %rsi
callq 0x41758
leaq 0x2a99(%rip), %rsi      # 0x58b3e
leaq -0x1d8(%rbp), %rdi
leaq -0x90(%rbp), %rdx
callq 0x3aa1e
leaq 0x2ae5(%rip), %rdx      # 0x58ba4
leaq -0x1f8(%rbp), %rdi
leaq -0x1d8(%rbp), %rsi
callq 0x38f1f
leaq -0x218(%rbp), %rdi
leaq -0x158(%rbp), %rsi
leaq -0x1f8(%rbp), %rdx
callq 0x5449c
leaq 0x2ab1(%rip), %rsi      # 0x58ba4
leaq -0x238(%rbp), %rdi
leaq -0x218(%rbp), %rdx
callq 0x3aa1e
leaq 0x2a31(%rip), %rdx      # 0x58b3e
leaq -0x178(%rbp), %rdi
leaq -0x238(%rbp), %rsi
callq 0x38f1f
leaq -0x140(%rbp), %rdi
leaq -0x90(%rbp), %rsi
leaq -0x178(%rbp), %rdx
callq 0x4f6ac
jmp 0x56156
leaq 0x29fc(%rip), %rsi      # 0x58b3f
leaq -0x140(%rbp), %rdi
leaq -0x178(%rbp), %rdx
callq 0x35130
leaq -0x108(%rbp), %rdi
leaq -0x140(%rbp), %rsi
leaq -0x198(%rbp), %rdx
callq 0x38ef6
leaq -0xb0(%rbp), %rdi
leaq -0x108(%rbp), %rsi
leaq -0x90(%rbp), %rdx
callq 0x38ef6
movq 0x20(%r12), %rax
movq 0x48(%rax), %rsi
leaq -0xe8(%rbp), %rdi
callq 0x54264
leaq -0x1b8(%rbp), %rdi
leaq -0xe8(%rbp), %rsi
callq 0x54278
leaq -0x48(%rbp), %rdi
leaq -0xb0(%rbp), %rsi
leaq -0x1b8(%rbp), %rdx
callq 0x3a9ad
leaq 0x28d9(%rip), %rdx      # 0x58aa9
leaq -0x48(%rbp), %rsi
movq %rbx, %rdi
callq 0x38f1f
leaq -0x48(%rbp), %rdi
callq 0x35180
leaq -0x1b8(%rbp), %rdi
callq 0x35180
leaq -0xe8(%rbp), %rdi
callq 0x54272
leaq -0xb0(%rbp), %rdi
callq 0x35180
leaq -0x108(%rbp), %rdi
callq 0x35180
leaq -0x140(%rbp), %rdi
callq 0x35180
cmpq %r14, %r15
je 0x5626e
leaq -0x178(%rbp), %rdi
callq 0x35180
leaq -0x238(%rbp), %rdi
callq 0x35180
leaq -0x218(%rbp), %rdi
callq 0x35180
leaq -0x1f8(%rbp), %rdi
callq 0x35180
leaq -0x1d8(%rbp), %rdi
callq 0x35180
leaq -0x158(%rbp), %rdi
callq 0x38d68
leaq -0x90(%rbp), %rdi
callq 0x35180
leaq -0x120(%rbp), %rdi
callq 0x50ede
leaq -0xd0(%rbp), %rdi
callq 0x38d68
leaq -0x198(%rbp), %rdi
callq 0x35180
movq %rbx, %rax
addq $0x358, %rsp            # imm = 0x358
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x90(%rbp), %rdi
callq 0x35180
jmp 0x562d8
movq %rax, %rbx
leaq -0x90(%rbp), %rdi
callq 0x35180
jmp 0x562e4
movq %rax, %rbx
leaq -0x278(%rbp), %rdi
jmp 0x562eb
movq %rax, %rbx
leaq -0x2b8(%rbp), %rdi
callq 0x4062c
jmp 0x56322
jmp 0x562f4
movq %rax, %rbx
leaq -0x88(%rbp), %rdi
callq 0x38d68
jmp 0x5630a
jmp 0x56307
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
jmp 0x56469
jmp 0x564df
jmp 0x564df
jmp 0x5631f
movq %rax, %rbx
leaq -0xb0(%rbp), %rdi
callq 0x5309c
jmp 0x564e2
jmp 0x563a0
movq %rax, %rbx
leaq -0x90(%rbp), %rdi
callq 0x35180
jmp 0x56349
movq %rax, %rbx
leaq -0x2f8(%rbp), %rdi
callq 0x4062c
jmp 0x563ab
movq %rax, %rbx
leaq -0x88(%rbp), %rdi
callq 0x38d68
jmp 0x564d1
jmp 0x5647c
movq %rax, %rbx
jmp 0x5641a
movq %rax, %rbx
jmp 0x56426
movq %rax, %rbx
jmp 0x56432
movq %rax, %rbx
jmp 0x5643e
movq %rax, %rbx
jmp 0x5644a
movq %rax, %rbx
jmp 0x56456
movq %rax, %rbx
jmp 0x56462
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x5309c
jmp 0x564d1
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x35180
jmp 0x563ca
movq %rax, %rbx
leaq -0x1b8(%rbp), %rdi
callq 0x35180
jmp 0x563db
movq %rax, %rbx
leaq -0xe8(%rbp), %rdi
callq 0x54272
jmp 0x563ec
movq %rax, %rbx
leaq -0xb0(%rbp), %rdi
callq 0x35180
jmp 0x563fd
movq %rax, %rbx
leaq -0x108(%rbp), %rdi
callq 0x35180
leaq -0x140(%rbp), %rdi
callq 0x35180
cmpq %r14, %r15
je 0x56462
leaq -0x178(%rbp), %rdi
callq 0x35180
leaq -0x238(%rbp), %rdi
callq 0x35180
leaq -0x218(%rbp), %rdi
callq 0x35180
leaq -0x1f8(%rbp), %rdi
callq 0x35180
leaq -0x1d8(%rbp), %rdi
callq 0x35180
leaq -0x158(%rbp), %rdi
callq 0x38d68
leaq -0x90(%rbp), %rdi
callq 0x35180
jmp 0x564e2
movq %rax, %rbx
jmp 0x56409
jmp 0x564df
movq %rax, %rbx
jmp 0x564ee
movq %rax, %rbx
jmp 0x564d1
movq %rax, %rbx
jmp 0x564c5
movq %rax, %rbx
jmp 0x5649f
movq %rax, %rbx
jmp 0x564b9
movq %rax, %rbx
leaq -0x90(%rbp), %rdi
callq 0x35180
leaq -0x338(%rbp), %rdi
callq 0x4062c
jmp 0x564e2
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x35180
leaq -0x378(%rbp), %rdi
callq 0x4062c
leaq -0x90(%rbp), %rdi
callq 0x4062c
leaq -0xb0(%rbp), %rdi
callq 0x38d68
jmp 0x564e2
movq %rax, %rbx
leaq -0x120(%rbp), %rdi
callq 0x50ede
leaq -0xd0(%rbp), %rdi
callq 0x38d68
jmp 0x5650d
movq %rax, %rbx
jmp 0x5650d
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x35180
leaq -0x198(%rbp), %rdi
callq 0x35180
movq %rbx, %rdi
callq 0x355f0
nop