// File: /workspace/github_c_makefile_star2_O1/info-telecom-strasbourg[P]code-generator/src/other_flags.cpp
// Function: create_file(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int)
void create_file (string name, string ext, string dir, int type) {
	int exit_code;
	vector<char*> cmd;
	
	string new_file = type == IS_SOURCE 
		? dir + "/" + name + "." + ext
		: name + "." + ext;

	LOAD_CMD ("bash");	
	
	if (type == IS_SOURCE) {
		LOAD_CMD (CPY_FILES_SCRIPT_PATH);

		if ( ext == "c" )
			LOAD_CMD (STANDARD_C_FILE);
		if ( ext == "cpp" )
			LOAD_CMD (STANDARD_CPP_FILE);
		if ( ext == "cc" )
			LOAD_CMD (STANDARD_CC_FILE);

		LOAD_CMD (new_file.c_str());

	}

	if (type == IS_INCLUDE) {
		LOAD_CMD (ADD_HEADER_SCRIPT_PATH);
		LOAD_CMD ("0");
		LOAD_CMD (new_file.c_str());
		LOAD_CMD (dir.c_str());
	}

	execute (exit_code, BASH_PATH, cmd);
	if ( !exit_code )
		cout << "\033[1;32minfo\033[0m: created a new standard file at \"" 
			<< new_file << "\".\n"; 
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movl %ecx, %ebx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r12
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movq $0x0, 0x20(%rsp)
testl %ecx, %ecx
sete %bpl
je 0x4384
leaq 0x38(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%r12), %rsi
movq 0x8(%r12), %rdx
addq %rsi, %rdx
leaq 0x28(%rsp), %rdi
callq 0x3f04
leaq 0x3601(%rip), %rsi      # 0x7965
leaq 0x28(%rsp), %rdi
callq 0x2380
movq (%r15), %rsi
movq 0x8(%r15), %rdx
leaq 0x28(%rsp), %rdi
callq 0x2070
jmp 0x447e
leaq 0x80(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
leaq 0x70(%rsp), %rdi
callq 0x3f04
leaq 0x2e86(%rip), %rsi      # 0x7231
leaq 0x70(%rsp), %rdi
callq 0x2380
movq (%r12), %rsi
movq 0x8(%r12), %rdx
leaq 0x70(%rsp), %rdi
callq 0x2070
leaq 0xb8(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rsi
je 0x43f8
movq %rsi, 0xa8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0xb8(%rsp)
jmp 0x43fe
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq 0x8(%rax), %rdx
leaq 0xa8(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x3541(%rip), %rsi      # 0x7965
callq 0x2380
leaq 0x38(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rsi
je 0x4450
movq %rsi, 0x28(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x38(%rsp)
jmp 0x4456
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq 0x8(%rax), %rdx
leaq 0x28(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
callq 0x2070
leaq 0x58(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
leaq 0x10(%rax), %rcx
cmpq %rcx, %rsi
je 0x44a2
movq %rsi, 0x48(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x58(%rsp)
jmp 0x44a8
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq %rax, %rdx
addq $0x8, %rdx
movq 0x8(%rax), %rsi
movq %rsi, 0x50(%rsp)
movq %rcx, (%rax)
movq $0x0, (%rdx)
movb $0x0, (%rcx)
leaq 0x38(%rsp), %rax
testl %ebx, %ebx
je 0x44de
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4536
movq 0x38(%rsp), %rsi
jmp 0x452e
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x44f4
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x21d0
leaq 0xb8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4515
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x21d0
leaq 0x80(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4536
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x21d0
leaq 0x2bbc(%rip), %rax      # 0x70f9
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
testl %ebx, %ebx
jne 0x460b
leaq 0x2aa6(%rip), %rax      # 0x7004
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
leaq 0x2ae6(%rip), %rsi      # 0x705d
movq %r15, %rdi
callq 0x2060
testl %eax, %eax
jne 0x459c
leaq 0x2fc3(%rip), %rax      # 0x754d
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
leaq 0x2aea(%rip), %rsi      # 0x708d
movq %r15, %rdi
callq 0x2060
testl %eax, %eax
jne 0x45c8
leaq 0x2fc6(%rip), %rax      # 0x757c
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
leaq 0x2af0(%rip), %rsi      # 0x70bf
movq %r15, %rdi
callq 0x2060
testl %eax, %eax
jne 0x45f4
leaq 0x2fcb(%rip), %rax      # 0x75ad
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
movq 0x48(%rsp), %rax
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
cmpl $0x1, %ebx
jne 0x466e
leaq 0x2b51(%rip), %rax      # 0x7168
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
leaq 0x2b64(%rip), %rax      # 0x7194
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
movq 0x48(%rsp), %rax
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
movq (%r14), %rax
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
leaq 0x10(%rsp), %rdi
callq 0x3f94
leaq 0x90(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x3dea
leaq 0x2a69(%rip), %rdx      # 0x70f0
leaq 0xc8(%rsp), %rdi
leaq 0x6c(%rsp), %rsi
leaq 0x90(%rsp), %rcx
callq 0x5e87
leaq 0xd8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x46c2
movq 0xd8(%rsp), %rsi
incq %rsi
callq 0x21d0
movq 0x90(%rsp), %rdi
testq %rdi, %rdi
je 0x46df
movq 0xa0(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
cmpl $0x0, 0x6c(%rsp)
jne 0x4728
movq 0x58db(%rip), %rdi      # 0x9fc8
leaq 0x2ee9(%rip), %rsi      # 0x75dd
movl $0x31, %edx
callq 0x2210
movq 0x48(%rsp), %rsi
movq 0x50(%rsp), %rdx
movq 0x58b9(%rip), %rdi      # 0x9fc8
callq 0x2210
leaq 0x2b11(%rip), %rsi      # 0x722c
movl $0x3, %edx
movq %rax, %rdi
callq 0x2210
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4743
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x21d0
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x475a
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x488d
jmp 0x488d
jmp 0x488d
jmp 0x488d
jmp 0x488d
jmp 0x47f3
movq %rax, %r14
movb $0x1, %bpl
jmp 0x4818
movq %rax, %r14
movb $0x1, %bpl
jmp 0x483e
movq %rax, %r14
movq 0x70(%rsp), %rdi
movb $0x1, %bpl
cmpq %r13, %rdi
jne 0x4854
jmp 0x4864
movq %rax, %r14
movb $0x1, %bpl
jmp 0x4864
jmp 0x488d
jmp 0x488d
jmp 0x488d
jmp 0x488d
jmp 0x47d7
movq %rax, %r14
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x47f6
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x21d0
jmp 0x47f6
movq %rax, %r14
testl %ebx, %ebx
jne 0x4818
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
movb $0x1, %bpl
cmpq %rax, %rdi
je 0x4818
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x21d0
testb %bpl, %bpl
je 0x483e
leaq 0xb8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x483e
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x21d0
testb %bpl, %bpl
je 0x4864
leaq 0x80(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4864
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x21d0
testb %bpl, %bpl
jmp 0x48ab
movq %rax, %r14
movq 0x90(%rsp), %rdi
testq %rdi, %rdi
je 0x4890
movq 0xa0(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
jmp 0x4890
jmp 0x488d
movq %rax, %r14
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x48ab
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x21d0
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x48c2
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x21d0
movq %r14, %rdi
callq 0x2340