// File: /workspace/github_c_makefile_star2_O0/mirth-lang[P]mirth/bin/mirth1.c
// Function: mw_mirth_elab_zaTypeElab_elabzeimplicitzevarzx
static struct std_maybe_Maybe_1 mw_mirth_elab_zaTypeElab_elabzeimplicitzevarzx (struct mirth_mirth_zaMirth* in_zaMirth_1, struct mirth_elab_zaTypeElab* in_zaTypeElab_2, uint64_t in_Name_3, struct mirth_type_Type in_Type_4, struct mirth_mirth_zaMirth* *out_zaMirth_5, struct mirth_elab_zaTypeElab* *out_zaTypeElab_6) {
	uint64_t v8 = in_zaTypeElab_2->mtoken;
	struct mirth_mirth_zaMirth* v9;
	mw_mirth_mirth_zaMirth_errorzetokenzx(in_zaMirth_1, v8, &v9);
	struct std_list_List_1 v10 = in_zaTypeElab_2->mctx;
	incref(MK_std_list_List_1(v10));
	struct mirth_mirth_zaMirth* v11;
	struct std_maybe_Maybe_1 v12 = mw_mirth_var_Ctx_lookup(v9, in_Name_3, v10, &v11);
	struct mirth_mirth_zaMirth* branch_zaMirth_13;
	struct mirth_elab_zaTypeElab* branch_zaTypeElab_14;
	struct std_maybe_Maybe_1 branch_Maybe_15;
	switch ((v12).tag) {
		case std_maybe_Maybe_1_Some: {
			VAL v16 = mtp_std_maybe_Maybe_1_Some(v12);
			incref(v16);
			struct mirth_mirth_zaMirth* v17;
			struct mirth_type_Type v18 = mw_mirth_var_Var_type(v11, V_mirth_var_Var(v16), &v17);
			struct mirth_mirth_zaMirth* v19;
			struct mirth_type_Type v20 = mw_mirth_type_Type_unifyzx(v17, in_Type_4, v18, &v19);
			decref(MK_mirth_type_Type(v20));
			struct std_maybe_Maybe_1 v21 = mtw_std_maybe_Maybe_1_Some(v16);
			branch_Maybe_15 = v21;
			branch_zaTypeElab_14 = in_zaTypeElab_2;
			branch_zaMirth_13 = v19;
		} break;
		case std_maybe_Maybe_1_None: {
			bool v22 = in_zaTypeElab_2->mallowzeimplicitzetypezevars;
			struct mirth_mirth_zaMirth* branch_zaMirth_23;
			struct mirth_elab_zaTypeElab* branch_zaTypeElab_24;
			struct std_maybe_Maybe_1 branch_Maybe_25;
			if (v22) {
				struct std_list_List_1 v26 = in_zaTypeElab_2->mctx;
				incref(MK_std_list_List_1(v26));
				struct mirth_mirth_zaMirth* v27;
				uint64_t v28 = mw_mirth_var_Var_Newzx(v11, in_Type_4, in_Name_3, &v27);
				struct std_list_List_1 v29 = mw_mirth_var_Ctx_new(v26, v28);
				struct std_list_List_1 v30 = in_zaTypeElab_2->mctx;
				decref(MK_std_list_List_1(v30));
				in_zaTypeElab_2->mctx = v29;
				struct std_maybe_Maybe_1 v31 = mtw_std_maybe_Maybe_1_Some(MK_mirth_var_Var(v28));
				branch_Maybe_25 = v31;
				branch_zaTypeElab_24 = in_zaTypeElab_2;
				branch_zaMirth_23 = v27;
			} else {
				STR* v32;
				STRLIT(v32, "Implicit type variable not allowed here.", 40);
				struct mirth_mirth_zaMirth* v33;
				mw_mirth_mirth_zaMirth_errorzx(v11, v32, &v33);
				decref(MK_mirth_type_Type(in_Type_4));
				struct std_maybe_Maybe_1 v34 = { .tag=std_maybe_Maybe_1_None };
				branch_Maybe_25 = v34;
				branch_zaTypeElab_24 = in_zaTypeElab_2;
				branch_zaMirth_23 = v33;
			}
			branch_Maybe_15 = branch_Maybe_25;
			branch_zaTypeElab_14 = branch_zaTypeElab_24;
			branch_zaMirth_13 = branch_zaMirth_23;
		} break;
		default: {
			do_panic(str_make("unexpected fallthrough in match\n", 32));
		}
	}
	uint64_t v35 = branch_zaTypeElab_14->mtoken;
	struct mirth_mirth_zaMirth* v36;
	mw_mirth_token_Token_argsze0(branch_zaMirth_13, v35, &v36);
	uint64_t v37 = branch_zaTypeElab_14->mtoken;
	struct mirth_mirth_zaMirth* v38;
	uint64_t v39 = mw_mirth_token_Token_succ(v36, v37, &v38);
	branch_zaTypeElab_14->mtoken = v39;
	*out_zaTypeElab_6 = branch_zaTypeElab_14;
	*out_zaMirth_5 = v38;
	return branch_Maybe_15;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x360, %rsp            # imm = 0x360
movq 0x10(%rbp), %rax
movl %ecx, -0x20(%rbp)
movq %r8, -0x18(%rbp)
movq %rdi, -0x28(%rbp)
movq %rsi, -0x30(%rbp)
movq %rdx, -0x38(%rbp)
movq %r9, -0x40(%rbp)
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x48(%rbp)
movq -0x28(%rbp), %rdi
movq -0x48(%rbp), %rsi
leaq -0x50(%rbp), %rdx
callq 0x9fa30
movq -0x30(%rbp), %rax
movq (%rax), %rcx
movq %rcx, -0x60(%rbp)
movq 0x8(%rax), %rax
movq %rax, -0x58(%rbp)
movl -0x60(%rbp), %edi
movq -0x58(%rbp), %rsi
callq 0x12780
movq %rax, -0x70(%rbp)
movq %rdx, -0x68(%rbp)
movq -0x68(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xb1541
movl -0x60(%rbp), %edi
movq -0x58(%rbp), %rsi
callq 0x12780
movq %rax, -0x80(%rbp)
movq %rdx, -0x78(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x80(%rbp), %rax
cmpq $0x0, %rax
je 0xb1541
movl -0x60(%rbp), %edi
movq -0x58(%rbp), %rsi
callq 0x12780
movq %rax, -0x90(%rbp)
movq %rdx, -0x88(%rbp)
movq -0x90(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xb1541
movl -0x60(%rbp), %edi
movq -0x58(%rbp), %rsi
callq 0x12780
movq %rax, -0xa0(%rbp)
movq %rdx, -0x98(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0xa0(%rbp), %rax
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
jmp 0xb1543
movq -0x50(%rbp), %rdi
movq -0x38(%rbp), %rsi
movl -0x60(%rbp), %edx
movq -0x58(%rbp), %rcx
leaq -0xa8(%rbp), %r8
callq 0xb1ec0
movl %eax, -0xb8(%rbp)
movq %rdx, -0xb0(%rbp)
movl -0xb8(%rbp), %eax
movl %eax, -0x35c(%rbp)
testl %eax, %eax
je 0xb17c9
jmp 0xb1581
movl -0x35c(%rbp), %eax
subl $0x1, %eax
jne 0xb1d75
jmp 0xb1592
movl -0xb8(%rbp), %edi
movq -0xb0(%rbp), %rsi
callq 0x174a0
movq %rax, -0xd8(%rbp)
movq %rdx, -0xd0(%rbp)
movq -0xd0(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xb1603
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0xd8(%rbp), %rax
cmpq $0x0, %rax
je 0xb1603
movq -0xd8(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xb1603
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0xd8(%rbp), %rax
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
jmp 0xb1605
movq -0xa8(%rbp), %rdi
movq -0xd8(%rbp), %rsi
leaq -0xe0(%rbp), %rdx
callq 0xb2770
movl %eax, -0xf0(%rbp)
movq %rdx, -0xe8(%rbp)
movq -0xe0(%rbp), %rdi
movl -0x20(%rbp), %esi
movq -0x18(%rbp), %rdx
movl -0xf0(%rbp), %ecx
movq -0xe8(%rbp), %r8
leaq -0xf8(%rbp), %r9
callq 0xb27e0
movl %eax, -0x108(%rbp)
movq %rdx, -0x100(%rbp)
movl -0x108(%rbp), %edi
movq -0x100(%rbp), %rsi
callq 0x6e780
movq %rax, -0x118(%rbp)
movq %rdx, -0x110(%rbp)
movq -0x110(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xb1773
movl -0x108(%rbp), %edi
movq -0x100(%rbp), %rsi
callq 0x6e780
movq %rax, -0x128(%rbp)
movq %rdx, -0x120(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x128(%rbp), %rax
cmpq $0x0, %rax
je 0xb1773
movl -0x108(%rbp), %edi
movq -0x100(%rbp), %rsi
callq 0x6e780
movq %rax, -0x138(%rbp)
movq %rdx, -0x130(%rbp)
movq -0x138(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xb1773
movl -0x108(%rbp), %edi
movq -0x100(%rbp), %rsi
callq 0x6e780
movq %rax, -0x148(%rbp)
movq %rdx, -0x140(%rbp)
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq -0x148(%rbp), %rcx
movl (%rcx), %eax
addl $-0x1, %eax
movl %eax, (%rcx)
cmpl $0x0, %eax
jne 0xb1771
movl -0x108(%rbp), %edi
movq -0x100(%rbp), %rsi
callq 0x6e780
movq %rax, -0x158(%rbp)
movq %rdx, -0x150(%rbp)
movq -0x158(%rbp), %rdi
movq -0x150(%rbp), %rsi
callq 0x127c0
jmp 0xb1773
jmp 0xb1775
movq -0xd8(%rbp), %rdi
movq -0xd0(%rbp), %rsi
callq 0xca10
movl %eax, -0x168(%rbp)
movq %rdx, -0x160(%rbp)
movq -0x168(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x160(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0xc8(%rbp)
movq -0xf8(%rbp), %rax
movq %rax, -0xc0(%rbp)
jmp 0xb1d8e
movq -0x30(%rbp), %rax
movb 0x19(%rax), %al
andb $0x1, %al
movb %al, -0x169(%rbp)
testb $0x1, -0x169(%rbp)
je 0xb1add
movq -0x30(%rbp), %rax
movq (%rax), %rcx
movq %rcx, -0x1a0(%rbp)
movq 0x8(%rax), %rax
movq %rax, -0x198(%rbp)
movl -0x1a0(%rbp), %edi
movq -0x198(%rbp), %rsi
callq 0x12780
movq %rax, -0x1b0(%rbp)
movq %rdx, -0x1a8(%rbp)
movq -0x1a8(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xb18d3
movl -0x1a0(%rbp), %edi
movq -0x198(%rbp), %rsi
callq 0x12780
movq %rax, -0x1c0(%rbp)
movq %rdx, -0x1b8(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x1c0(%rbp), %rax
cmpq $0x0, %rax
je 0xb18d3
movl -0x1a0(%rbp), %edi
movq -0x198(%rbp), %rsi
callq 0x12780
movq %rax, -0x1d0(%rbp)
movq %rdx, -0x1c8(%rbp)
movq -0x1d0(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xb18d3
movl -0x1a0(%rbp), %edi
movq -0x198(%rbp), %rsi
callq 0x12780
movq %rax, -0x1e0(%rbp)
movq %rdx, -0x1d8(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x1e0(%rbp), %rax
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
jmp 0xb18d5
movq -0xa8(%rbp), %rdi
movq -0x38(%rbp), %rcx
movl -0x20(%rbp), %esi
movq -0x18(%rbp), %rdx
leaq -0x1e8(%rbp), %r8
callq 0x6da30
movq %rax, -0x1f0(%rbp)
movq -0x1f0(%rbp), %rdx
movl -0x1a0(%rbp), %edi
movq -0x198(%rbp), %rsi
callq 0xb2880
movl %eax, -0x200(%rbp)
movq %rdx, -0x1f8(%rbp)
movq -0x30(%rbp), %rax
movq (%rax), %rcx
movq %rcx, -0x210(%rbp)
movq 0x8(%rax), %rax
movq %rax, -0x208(%rbp)
movl -0x210(%rbp), %edi
movq -0x208(%rbp), %rsi
callq 0x12780
movq %rax, -0x220(%rbp)
movq %rdx, -0x218(%rbp)
movq -0x218(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xb1a4c
movl -0x210(%rbp), %edi
movq -0x208(%rbp), %rsi
callq 0x12780
movq %rax, -0x230(%rbp)
movq %rdx, -0x228(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x230(%rbp), %rax
cmpq $0x0, %rax
je 0xb1a4c
movl -0x210(%rbp), %edi
movq -0x208(%rbp), %rsi
callq 0x12780
movq %rax, -0x240(%rbp)
movq %rdx, -0x238(%rbp)
movq -0x240(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xb1a4c
movl -0x210(%rbp), %edi
movq -0x208(%rbp), %rsi
callq 0x12780
movq %rax, -0x250(%rbp)
movq %rdx, -0x248(%rbp)
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq -0x250(%rbp), %rcx
movl (%rcx), %eax
addl $-0x1, %eax
movl %eax, (%rcx)
cmpl $0x0, %eax
jne 0xb1a4a
movl -0x210(%rbp), %edi
movq -0x208(%rbp), %rsi
callq 0x12780
movq %rax, -0x260(%rbp)
movq %rdx, -0x258(%rbp)
movq -0x260(%rbp), %rdi
movq -0x258(%rbp), %rsi
callq 0x127c0
jmp 0xb1a4c
jmp 0xb1a4e
movq -0x30(%rbp), %rax
movq -0x200(%rbp), %rcx
movq %rcx, (%rax)
movq -0x1f8(%rbp), %rcx
movq %rcx, 0x8(%rax)
movq -0x1f0(%rbp), %rax
movq %rax, -0x280(%rbp)
leaq 0x2e00b4(%rip), %rax    # 0x391b30
movq %rax, -0x278(%rbp)
movq -0x280(%rbp), %rdi
movq -0x278(%rbp), %rsi
callq 0xca10
movl %eax, -0x270(%rbp)
movq %rdx, -0x268(%rbp)
movq -0x270(%rbp), %rax
movq %rax, -0x190(%rbp)
movq -0x268(%rbp), %rax
movq %rax, -0x188(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x180(%rbp)
movq -0x1e8(%rbp), %rax
movq %rax, -0x178(%rbp)
jmp 0xb1d41
jmp 0xb1adf
cmpq $0x0, 0x12e3dc9(%rip)   # 0x13958b0
jne 0xb1b01
leaq 0x2a6bd5(%rip), %rdi    # 0x3586c5
movl $0x28, %esi
callq 0xb6c0
movq %rax, 0x12e3daf(%rip)   # 0x13958b0
jmp 0xb1b03
movq 0x12e3da6(%rip), %rax   # 0x13958b0
movq %rax, -0x298(%rbp)
leaq 0x2df640(%rip), %rax    # 0x391158
orq $0x1, %rax
movq %rax, -0x290(%rbp)
movq -0x290(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xb1bd8
movq 0x12e3d71(%rip), %rax   # 0x13958b0
movq %rax, -0x2a8(%rbp)
leaq 0x2df60b(%rip), %rax    # 0x391158
orq $0x1, %rax
movq %rax, -0x2a0(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x2a8(%rbp), %rax
cmpq $0x0, %rax
je 0xb1bd8
movq 0x12e3d3a(%rip), %rax   # 0x13958b0
movq %rax, -0x2b8(%rbp)
leaq 0x2df5d4(%rip), %rax    # 0x391158
orq $0x1, %rax
movq %rax, -0x2b0(%rbp)
movq -0x2b8(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xb1bd8
movq 0x12e3d09(%rip), %rax   # 0x13958b0
movq %rax, -0x2c8(%rbp)
leaq 0x2df5a3(%rip), %rax    # 0x391158
orq $0x1, %rax
movq %rax, -0x2c0(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x2c8(%rbp), %rax
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
jmp 0xb1bda
movq 0x12e3ccf(%rip), %rax   # 0x13958b0
movq %rax, -0x288(%rbp)
movq -0xa8(%rbp), %rdi
movq -0x288(%rbp), %rsi
leaq -0x2d0(%rbp), %rdx
callq 0xb2900
movl -0x20(%rbp), %edi
movq -0x18(%rbp), %rsi
callq 0x6e780
movq %rax, -0x2e0(%rbp)
movq %rdx, -0x2d8(%rbp)
movq -0x2d8(%rbp), %rax
andq $0x1, %rax
cmpq $0x0, %rax
je 0xb1cf7
movl -0x20(%rbp), %edi
movq -0x18(%rbp), %rsi
callq 0x6e780
movq %rax, -0x2f0(%rbp)
movq %rdx, -0x2e8(%rbp)
movabsq $0xfffffffffffc, %rax   # imm = 0xFFFFFFFFFFFC
andq -0x2f0(%rbp), %rax
cmpq $0x0, %rax
je 0xb1cf7
movl -0x20(%rbp), %edi
movq -0x18(%rbp), %rsi
callq 0x6e780
movq %rax, -0x300(%rbp)
movq %rdx, -0x2f8(%rbp)
movq -0x300(%rbp), %rax
andq $0x3, %rax
cmpq $0x0, %rax
jne 0xb1cf7
movl -0x20(%rbp), %edi
movq -0x18(%rbp), %rsi
callq 0x6e780
movq %rax, -0x310(%rbp)
movq %rdx, -0x308(%rbp)
movabsq $0xfffffffffffc, %rcx   # imm = 0xFFFFFFFFFFFC
andq -0x310(%rbp), %rcx
movl (%rcx), %eax
addl $-0x1, %eax
movl %eax, (%rcx)
cmpl $0x0, %eax
jne 0xb1cf5
movl -0x20(%rbp), %edi
movq -0x18(%rbp), %rsi
callq 0x6e780
movq %rax, -0x320(%rbp)
movq %rdx, -0x318(%rbp)
movq -0x320(%rbp), %rdi
movq -0x318(%rbp), %rsi
callq 0x127c0
jmp 0xb1cf7
jmp 0xb1cf9
leaq -0x330(%rbp), %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x5080
movq -0x330(%rbp), %rax
movq %rax, -0x190(%rbp)
movq -0x328(%rbp), %rax
movq %rax, -0x188(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x180(%rbp)
movq -0x2d0(%rbp), %rax
movq %rax, -0x178(%rbp)
movq -0x190(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x188(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x180(%rbp), %rax
movq %rax, -0xc8(%rbp)
movq -0x178(%rbp), %rax
movq %rax, -0xc0(%rbp)
jmp 0xb1d8e
leaq 0x2a2105(%rip), %rdi    # 0x353e81
movl $0x20, %esi
callq 0xb6c0
movq %rax, %rdi
callq 0xc620
movq -0xc8(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x338(%rbp)
movq -0xc0(%rbp), %rdi
movq -0x338(%rbp), %rsi
leaq -0x340(%rbp), %rdx
callq 0x78300
movq -0xc8(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x348(%rbp)
movq -0x340(%rbp), %rdi
movq -0x348(%rbp), %rsi
leaq -0x350(%rbp), %rdx
callq 0x78490
movq %rax, -0x358(%rbp)
movq -0x358(%rbp), %rcx
movq -0xc8(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0xc8(%rbp), %rcx
movq 0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x350(%rbp), %rcx
movq -0x40(%rbp), %rax
movq %rcx, (%rax)
movl -0x10(%rbp), %eax
movq -0x8(%rbp), %rdx
addq $0x360, %rsp            # imm = 0x360
popq %rbp
retq
nopl (%rax,%rax)