// File: /workspace/github_cpp_makefile_star2_O3/iZhangHui[P]CppPrimer/CH12_DynamicMemory/exercises/ex12_02_test.cc
// Function: main
int main(int argc, char const *argv[])
{
	StrBlob sb = { "Hello", "C++ Primer" };

	std::cout << sb.front() << " " << sb.back() << std::endl;
	sb.back() = "C++ Primer 5th";
	std::cout << sb.front() << " " << sb.back() << std::endl;

	const StrBlob csb = { "StrBlob", "Test" };
	std::cout << csb.front() << " " << csb.back() << std::endl;
	// csb.back() = "error";
	// std::cout << csb.front() << " " << csb.back() << std::endl;

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x78, %rsp
leaq -0x70(%rbp), %r14
movq %r14, -0x10(%r14)
leaq 0xc6c(%rip), %rsi       # 0x3004
leaq 0xc6a(%rip), %rdx       # 0x3009
leaq -0x80(%rbp), %rbx
movq %rbx, %rdi
callq 0x2d86
leaq -0x60(%rbp), %rdi
leaq -0x50(%rbp), %r15
movq %r15, -0x10(%r15)
leaq 0xc4c(%rip), %rsi       # 0x300a
leaq 0xc4f(%rip), %rdx       # 0x3014
callq 0x2d86
leaq -0x90(%rbp), %rcx
movq %rbx, (%rcx)
movq $0x2, 0x8(%rcx)
leaq -0x28(%rbp), %rdi
movq $0x0, -0x8(%rdi)
leaq -0x30(%rbp), %rsi
leaq -0x40(%rbp), %rdx
callq 0x28fe
movq $-0x40, %rbx
movq -0x10(%r15), %rdi
cmpq %rdi, %r15
je 0x2410
movq (%r15), %rsi
incq %rsi
callq 0x2110
addq $-0x20, %r15
addq $0x20, %rbx
jne 0x23fc
leaq -0x30(%rbp), %rdi
callq 0x26de
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq 0x2b97(%rip), %rdi      # 0x4fc8
callq 0x2120
movq %rax, %rbx
leaq 0xbd5(%rip), %rsi       # 0x3015
movl $0x1, %edx
movq %rax, %rdi
callq 0x2120
leaq -0x30(%rbp), %rdi
callq 0x2764
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq %rbx, %rdi
callq 0x2120
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2090
leaq -0x30(%rbp), %rdi
callq 0x2764
movq 0x8(%rax), %rdx
leaq 0xb74(%rip), %rcx       # 0x3017
movl $0xe, %r8d
movq %rax, %rdi
xorl %esi, %esi
callq 0x2170
leaq -0x30(%rbp), %rdi
callq 0x26de
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq 0x2afe(%rip), %rdi      # 0x4fc8
callq 0x2120
movq %rax, %rbx
leaq 0xb3c(%rip), %rsi       # 0x3015
movl $0x1, %edx
movq %rax, %rdi
callq 0x2120
leaq -0x30(%rbp), %rdi
callq 0x2764
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq %rbx, %rdi
callq 0x2120
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2090
leaq -0x80(%rbp), %rbx
movq %r14, (%rbx)
leaq 0xb5f(%rip), %rsi       # 0x3095
leaq 0xb5f(%rip), %rdx       # 0x309c
movq %rbx, %rdi
callq 0x2d86
leaq -0x60(%rbp), %rdi
leaq -0x50(%rbp), %r15
movq %r15, -0x10(%r15)
leaq 0xace(%rip), %rsi       # 0x3026
leaq 0xacb(%rip), %rdx       # 0x302a
callq 0x2d86
leaq -0x90(%rbp), %rcx
movq %rbx, (%rcx)
movq $0x2, 0x8(%rcx)
leaq -0x38(%rbp), %rdi
movq $0x0, -0x8(%rdi)
leaq -0x40(%rbp), %rsi
leaq -0x19(%rbp), %rdx
callq 0x28fe
movq $-0x40, %rbx
movq -0x10(%r15), %rdi
cmpq %rdi, %r15
je 0x25aa
movq (%r15), %rsi
incq %rsi
callq 0x2110
addq $-0x20, %r15
addq $0x20, %rbx
jne 0x2596
leaq -0x40(%rbp), %rdi
callq 0x27ee
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq 0x29fd(%rip), %rdi      # 0x4fc8
callq 0x2120
movq %rax, %rbx
leaq 0xa3b(%rip), %rsi       # 0x3015
movl $0x1, %edx
movq %rax, %rdi
callq 0x2120
leaq -0x40(%rbp), %rdi
callq 0x2874
movq (%rax), %rsi
movq 0x8(%rax), %rdx
movq %rbx, %rdi
callq 0x2120
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2090
movq -0x38(%rbp), %rdi
testq %rdi, %rdi
je 0x2637
callq 0x2d1a
movq -0x28(%rbp), %rdi
testq %rdi, %rdi
je 0x2645
callq 0x2d1a
xorl %eax, %eax
addq $0x78, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x40(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x220a
jmp 0x26c7
movq %rax, %rbx
movq -0x80(%rbp), %rdi
cmpq %r14, %rdi
je 0x26c7
movq -0x70(%rbp), %rsi
incq %rsi
callq 0x2110
jmp 0x26c7
jmp 0x26c4
movq %rax, %rbx
leaq -0x40(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x21d0
jmp 0x26d5
movq %rax, %rbx
movq -0x80(%rbp), %rdi
cmpq %r14, %rdi
je 0x26d5
movq -0x70(%rbp), %rsi
incq %rsi
callq 0x2110
jmp 0x26d5
movq %rax, %rbx
jmp 0x26d5
movq %rax, %rbx
movq -0x38(%rbp), %rdi
testq %rdi, %rdi
je 0x26c7
callq 0x2d1a
jmp 0x26c7
movq %rax, %rbx
movq -0x28(%rbp), %rdi
testq %rdi, %rdi
je 0x26d5
callq 0x2d1a
movq %rbx, %rdi
callq 0x21a0
nop