// File: /workspace/github_cpp_makefile_star2_O2/ixchow[P]http-tweak/./http.hpp
// Function: http::response::~response()
inline response::~response() {
	//does the message slot still exist?
	std::shared_ptr< message > shared_message = weak_message.lock();
	if (!shared_message) return;

	//if so, build the message:
	std::string message;
	message += "HTTP/1.1 " + std::to_string(status.code) + " " + status.message + "\r\n";
	for (auto const &kv : headers) {
		message += kv.first + ": " + kv.second + "\r\n";
	}
	message += "Content-Length: " + std::to_string(body.size()) + "\r\n";
	message += "\r\n";
	message += body;

	{ //mark ready to send:
		shared_message->data = std::move(message);
		shared_message->ready.store(true, std::memory_order_release);
	}

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rdi, %r14
leaq 0x60(%rdi), %rsi
leaq -0x40(%rbp), %rbx
movq %rbx, %rdi
callq 0x6614
cmpq $0x0, (%rbx)
je 0x64c1
leaq -0x50(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movq %r14, -0x30(%rbp)
movl (%r14), %esi
leaq -0xe0(%rbp), %rdi
callq 0x650d
leaq 0x3f6e(%rip), %rsi      # 0xa255
leaq -0x100(%rbp), %rdi
leaq -0xe0(%rbp), %rdx
callq 0x60c6
leaq 0x3f5c(%rip), %rdx      # 0xa25d
leaq -0x80(%rbp), %rdi
leaq -0x100(%rbp), %rsi
callq 0x602c
movq -0x30(%rbp), %rax
leaq 0x8(%rax), %rdx
leaq -0xa0(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x617f
leaq 0x3f2f(%rip), %rdx      # 0xa25f
leaq -0xc0(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
callq 0x602c
leaq -0x60(%rbp), %rdi
leaq -0xc0(%rbp), %rsi
callq 0x35a0
leaq -0xc0(%rbp), %r14
movq %r14, %rdi
callq 0x31c0
leaq -0xa0(%rbp), %r15
movq %r15, %rdi
callq 0x31c0
leaq -0x80(%rbp), %r12
movq %r12, %rdi
callq 0x31c0
leaq -0x100(%rbp), %rdi
callq 0x31c0
leaq -0xe0(%rbp), %rdi
callq 0x31c0
movq -0x30(%rbp), %rax
movq 0x28(%rax), %r13
movq 0x30(%rax), %rbx
cmpq %rbx, %r13
je 0x6406
movq %r12, %rdi
movq %r13, %rsi
leaq 0x3c85(%rip), %rdx      # 0xa038
callq 0x656d
addq $0x20, %r13
movq %r15, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x617f
movq %r14, %rdi
movq %r15, %rsi
leaq 0x3e88(%rip), %rdx      # 0xa25f
callq 0x602c
leaq -0x60(%rbp), %rdi
movq %r14, %rsi
callq 0x35a0
movq %r14, %rdi
callq 0x31c0
movq %r15, %rdi
callq 0x31c0
movq %r12, %rdi
callq 0x31c0
addq $0x20, %r13
jmp 0x63a1
movq -0x30(%rbp), %rax
movq 0x48(%rax), %rsi
leaq -0x80(%rbp), %rdi
callq 0x65a5
leaq 0x3e44(%rip), %rsi      # 0xa262
leaq -0xa0(%rbp), %rdi
leaq -0x80(%rbp), %rdx
callq 0x60c6
leaq 0x3e2a(%rip), %rdx      # 0xa25f
leaq -0xc0(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
callq 0x602c
leaq -0x60(%rbp), %rdi
leaq -0xc0(%rbp), %rsi
callq 0x35a0
leaq -0xc0(%rbp), %rdi
callq 0x31c0
leaq -0xa0(%rbp), %rdi
callq 0x31c0
leaq -0x80(%rbp), %rdi
callq 0x31c0
leaq 0x3ddf(%rip), %rsi      # 0xa25f
leaq -0x60(%rbp), %rdi
callq 0x3580
movq -0x30(%rbp), %rax
leaq 0x40(%rax), %rsi
leaq -0x60(%rbp), %rdi
callq 0x35a0
movq -0x40(%rbp), %rdi
addq $0x8, %rdi
leaq -0x60(%rbp), %rbx
movq %rbx, %rsi
callq 0x33d0
movq -0x40(%rbp), %rax
movb $0x1, (%rax)
movq %rbx, %rdi
callq 0x31c0
movq -0x30(%rbp), %r14
leaq -0x38(%rbp), %rdi
callq 0x67ec
leaq 0x68(%r14), %rdi
callq 0x687c
leaq 0x40(%r14), %rdi
callq 0x31c0
leaq 0x28(%r14), %rdi
callq 0x65e8
addq $0x8, %r14
movq %r14, %rdi
callq 0x31c0
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x6505
movq %rax, %rdi
callq 0x3c4e