// File: /workspace/github_c_makefile_star2_O1/enzo1982[P]smooth/classes/system/dynamicloader.cpp
// Function: smooth::System::DynamicLoader::ParseDirectoryList(smooth::String const&, smooth::Array<smooth::String, smooth::String>&)
S::Void S::System::DynamicLoader::ParseDirectoryList(const String &pattern, Array<String> &directories)
{
#ifndef __WIN32__
	Directory		 directory(File(pattern).GetFilePath());
	const Array<File>	&files = directory.GetFilesByPattern(File(pattern).GetFileName());

	foreach (const File &file, files)
	{
		IO::InStream	 in(IO::STREAM_FILE, file);

		while (in.GetPos() < in.Size())
		{
			String	 line = in.InputLine();

			if	(line == NIL)			continue;
			else if (line.StartsWith("#"))		continue;
			else if (line.StartsWith("include "))	ParseDirectoryList(line.Tail(line.Length() - 8), directories);
			else					directories.Add(line);
		}
	}
#endif
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x238, %rsp            # imm = 0x238
movq %rdx, 0x20(%rsp)
movq %rsi, %r14
movq %rdi, 0x48(%rsp)
leaq 0x8(%rsp), %rbx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x58e20
leaq 0x50(%rsp), %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x56800
leaq 0x50(%rsp), %rdi
callq 0x580e0
movq %rax, %r15
leaq 0x28(%rsp), %rdi
xorl %esi, %esi
callq 0x58e20
leaq 0x158(%rsp), %rdi
leaq 0x28(%rsp), %rdx
movq %r15, %rsi
callq 0x58c60
leaq 0x28(%rsp), %rdi
callq 0x59200
leaq 0x50(%rsp), %rdi
callq 0x59178
leaq 0x8(%rsp), %rdi
callq 0x59200
leaq 0x8(%rsp), %rdi
xorl %esi, %esi
callq 0x58e20
leaq 0x50(%rsp), %rdi
leaq 0x8(%rsp), %rdx
movq %r14, %rsi
callq 0x56800
leaq 0x50(%rsp), %rdi
callq 0x580b0
leaq 0x158(%rsp), %rdi
movq %rax, %rsi
callq 0x56d30
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x59178
leaq 0x8(%rsp), %rdi
callq 0x59200
cmpl $0x0, 0x8(%rbx)
jle 0xb1b79
movq %rbx, %rdi
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
leaq 0x8(%rsp), %r12
leaq 0x50(%rsp), %r13
leaq 0x6bd6b(%rip), %r15     # 0x11d792
leaq 0x28(%rsp), %r14
movq %rbx, 0x40(%rsp)
incl %ebp
movl %ebp, %esi
callq 0x9dd2e
movq %r12, %rdi
movq %rax, %rsi
callq 0x58fa0
movq %r13, %rdi
movl $0x3, %esi
movq %r12, %rdx
movl $0x2, %ecx
callq 0x58730
movq %r12, %rdi
callq 0x59200
movzwl 0x58(%rsp), %ecx
testw %cx, %cx
je 0xb1a76
movq 0x98(%rsp), %rax
jmp 0xb1a87
movw $0x5, 0x148(%rsp)
movq $-0x1, %rax
testw %cx, %cx
je 0xb1a93
movq 0x60(%rsp), %rcx
jmp 0xb1aa4
movw $0x5, 0x148(%rsp)
movq $-0x1, %rcx
cmpq %rcx, %rax
jge 0xb1b5f
movq %r12, %rdi
movq %r13, %rsi
callq 0x57310
movq %r12, %rdi
xorl %esi, %esi
callq 0x55260
testb %al, %al
jne 0xb1a5a
movq %r14, %rdi
movq %r15, %rsi
callq 0x579f0
movq %r12, %rdi
movq %r14, %rsi
callq 0x577d0
movl %eax, %ebx
movq %r14, %rdi
callq 0x59200
testb %bl, %bl
jne 0xb1a5a
movq %r14, %rdi
leaq 0x61884(%rip), %rsi     # 0x11337c
callq 0x579f0
movq %r12, %rdi
movq %r14, %rsi
callq 0x577d0
movl %eax, %ebx
movq %r14, %rdi
callq 0x59200
testb %bl, %bl
je 0xb1b4d
movq %r12, %rdi
callq 0x57180
addl $-0x8, %eax
movq %r14, %rdi
movq %r12, %rsi
movl %eax, %edx
callq 0x57f90
movq 0x48(%rsp), %rdi
movq %r14, %rsi
movq 0x20(%rsp), %rdx
callq 0x561a0
movq %r14, %rdi
callq 0x59200
jmp 0xb1a5a
movq 0x20(%rsp), %rdi
movq %r12, %rsi
callq 0x64280
jmp 0xb1a5a
movq %r13, %rdi
callq 0x555b0
movq 0x40(%rsp), %rdi
movl 0x8(%rdi), %eax
decl %eax
cmpl %eax, %ebp
jl 0xb1a31
leaq 0x158(%rsp), %rdi
callq 0x59210
addq $0x238, %rsp            # imm = 0x238
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0xb1be1
jmp 0xb1bdc
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x59200
jmp 0xb1bb0
jmp 0xb1bad
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x59178
jmp 0xb1bbf
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x59200
jmp 0xb1c32
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x59178
jmp 0xb1be4
jmp 0xb1bdc
movq %rax, %rbx
jmp 0xb1c25
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x59200
jmp 0xb1c25
jmp 0xb1bfa
jmp 0xb1bfa
jmp 0xb1c0e
jmp 0xb1c0e
jmp 0xb1c0e
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x59200
jmp 0xb1c11
movq %rax, %rbx
jmp 0xb1c1b
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x59200
leaq 0x50(%rsp), %rdi
callq 0x555b0
leaq 0x158(%rsp), %rdi
callq 0x59210
movq %rbx, %rdi
callq 0x57090