// File: iZhangHui[P]CppPrimer/CH06_Functions/examples/mk_plural.cc
// Function: main
int main()
{
	size_t cnt = 1;
	cout << make_plural(cnt, "success", "es") << endl;

	cnt = 2;
	cout << make_plural(cnt, "failure", "s") << endl;

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x140, %rsp            # imm = 0x140
movl $0x0, -0x4(%rbp)
movq $0x1, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x110(%rbp)
leaq -0x51(%rbp), %rdi
movq %rdi, -0x108(%rbp)
callq 0x10c0
movq -0x108(%rbp), %rdx
leaq 0xda1(%rip), %rsi       # 0x2004
leaq -0x50(%rbp), %rdi
callq 0x1090
jmp 0x126e
leaq -0x89(%rbp), %rdi
movq %rdi, -0x118(%rbp)
callq 0x10c0
movq -0x118(%rbp), %rdx
leaq 0xd7d(%rip), %rsi       # 0x200c
leaq -0x88(%rbp), %rdi
callq 0x1090
jmp 0x129d
movq -0x110(%rbp), %rsi
leaq -0x30(%rbp), %rdi
leaq -0x50(%rbp), %rdx
leaq -0x88(%rbp), %rcx
callq 0x1510
jmp 0x12ba
movq 0x2d17(%rip), %rdi      # 0x3fd8
leaq -0x30(%rbp), %rsi
callq 0x1060
movq %rax, -0x120(%rbp)
jmp 0x12d3
movq -0x120(%rbp), %rdi
movq 0x2ce7(%rip), %rsi      # 0x3fc8
callq 0x1070
jmp 0x12e8
leaq -0x30(%rbp), %rdi
callq 0x1040
leaq -0x88(%rbp), %rdi
callq 0x1040
leaq -0x89(%rbp), %rdi
callq 0x1080
leaq -0x50(%rbp), %rdi
callq 0x1040
leaq -0x51(%rbp), %rdi
callq 0x1080
movq $0x2, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x130(%rbp)
leaq -0xd1(%rbp), %rdi
movq %rdi, -0x128(%rbp)
callq 0x10c0
movq -0x128(%rbp), %rdx
leaq 0xcc0(%rip), %rsi       # 0x200f
leaq -0xd0(%rbp), %rdi
callq 0x1090
jmp 0x135d
leaq -0xf9(%rbp), %rdi
movq %rdi, -0x138(%rbp)
callq 0x10c0
movq -0x138(%rbp), %rdx
leaq 0xc8f(%rip), %rsi       # 0x200d
leaq -0xf8(%rbp), %rdi
callq 0x1090
jmp 0x138c
movq -0x130(%rbp), %rsi
leaq -0xb0(%rbp), %rdi
leaq -0xd0(%rbp), %rdx
leaq -0xf8(%rbp), %rcx
callq 0x1510
jmp 0x13af
movq 0x2c22(%rip), %rdi      # 0x3fd8
leaq -0xb0(%rbp), %rsi
callq 0x1060
movq %rax, -0x140(%rbp)
jmp 0x13cb
movq -0x140(%rbp), %rdi
movq 0x2bef(%rip), %rsi      # 0x3fc8
callq 0x1070
jmp 0x13e0
leaq -0xb0(%rbp), %rdi
callq 0x1040
leaq -0xf8(%rbp), %rdi
callq 0x1040
leaq -0xf9(%rbp), %rdi
callq 0x1080
leaq -0xd0(%rbp), %rdi
callq 0x1040
leaq -0xd1(%rbp), %rdi
callq 0x1080
xorl %eax, %eax
addq $0x140, %rsp            # imm = 0x140
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x1487
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x1472
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x1466
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x1040
leaq -0x88(%rbp), %rdi
callq 0x1040
leaq -0x89(%rbp), %rdi
callq 0x1080
leaq -0x50(%rbp), %rdi
callq 0x1040
leaq -0x51(%rbp), %rdi
callq 0x1080
jmp 0x1504
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x14f8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x14e0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
jmp 0x14d4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0x1040
leaq -0xf8(%rbp), %rdi
callq 0x1040
leaq -0xf9(%rbp), %rdi
callq 0x1080
leaq -0xd0(%rbp), %rdi
callq 0x1040
leaq -0xd1(%rbp), %rdi
callq 0x1080
movq -0x60(%rbp), %rdi
callq 0x10b0
nopl (%rax)