// File: /workspace/github_cpp_makefile_star2_O1/Nallantli[P]Rossa/main/rossa/tokenizer/tokenizer.cpp
// Function: lexString(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::filesystem::__cxx11::path const&)
const std::vector<token_t> lexString(const std::string &INPUT, const std::filesystem::path &filename)
{
	std::vector<std::string> LINES;
	std::stringstream ss(INPUT);
	std::string item;

	while (std::getline(ss, item, '\n'))
	{
		LINES.push_back(item);
	}

	std::vector<token_t> tokens;
	size_t INPUT_INDEX = 0;
	size_t LINE_INDEX = 0;
	size_t TOKEN_DIST = 0;
	std::string ID_STRING;

	bool in_sig = false;

	while (true)
	{
		int token = getToken(INPUT, INPUT_INDEX, LINE_INDEX, TOKEN_DIST, ID_STRING);
		if (token == TOK_EOF)
			break;
		if (token == '#')
			continue;
		token_t t = {filename, LINES[LINE_INDEX], LINE_INDEX, TOKEN_DIST, ID_STRING, token};
		if (t.type == TOK_DEF)
		{
			in_sig = true;
			tokens.push_back(t);
		}
		else
		{
			if (in_sig)
			{
				if (t.type == '(' && tokens.back().type == TOK_DEF)
				{
					tokens.back().type = TOK_LAMBDA;
				}
				if (t.type != TOK_IDF && t.valueString == ">>")
				{
					tokens.push_back({t.filename, t.line, t.lineNumber, t.distance, ">", '>'});
					tokens.push_back({t.filename, t.line, t.lineNumber, t.distance, ">", '>'});
				}
				else if (t.type != TOK_IDF && t.valueString == "<<")
				{
					tokens.push_back({t.filename, t.line, t.lineNumber, t.distance, "<", '<'});
					tokens.push_back({t.filename, t.line, t.lineNumber, t.distance, "<", '<'});
				}
				else if (t.type != TOK_IDF && t.valueString == "<>")
				{
					tokens.push_back({t.filename, t.line, t.lineNumber, t.distance, "<", '<'});
					tokens.push_back({t.filename, t.line, t.lineNumber, t.distance, ">", '>'});
				}
				else
				{
					tokens.push_back(t);
				}
				if (tokens.back().type == ')')
				{
					in_sig = false;
				}
			}
			else
			{
				tokens.push_back(t);
			}
		}
	}

	for (auto &t : tokens)
	{
		while (!t.line.empty() && isspace(t.line[0]))
		{
			t.line = t.line.substr(1);
			t.distance--;
		}
	}

	return tokens;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x318, %rsp            # imm = 0x318
movq %rdx, 0x160(%rsp)
movq %rsi, %r15
movq %rdi, 0x8(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, 0x140(%rsp)
movq $0x0, 0x150(%rsp)
leaq 0x190(%rsp), %rdi
movl $0x18, %edx
callq 0x10630
leaq 0x178(%rsp), %rax
movq %rax, -0x10(%rax)
movq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x190(%rsp), %rbx
leaq 0x168(%rsp), %r14
leaq 0x140(%rsp), %r12
movq %rbx, %rdi
movq %r14, %rsi
movl $0xa, %edx
callq 0x10720
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x239c3
movq %r12, %rdi
movq %r14, %rsi
callq 0x20e04
jmp 0x23998
xorps %xmm0, %xmm0
movq 0x8(%rsp), %rax
movups %xmm0, (%rax)
xorl %ecx, %ecx
movq %rcx, 0x10(%rax)
leaq 0x188(%rsp), %rbp
movq %rcx, (%rbp)
leaq 0x118(%rsp), %rax
movq %rcx, (%rax)
leaq 0x110(%rsp), %rax
movq %rcx, (%rax)
leaq 0x130(%rsp), %rax
movq %rax, -0x10(%rax)
movq %rcx, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x48(%rsp), %rax
movq %rax, 0x158(%rsp)
leaq 0x90(%rsp), %rbx
xorl %r13d, %r13d
movq %r15, %rdi
movq %rbp, %rsi
leaq 0x118(%rsp), %rdx
leaq 0x110(%rsp), %rcx
leaq 0x120(%rsp), %r8
callq 0x2201f
movl %eax, %r12d
cmpl $-0x1, %eax
je 0x23b1b
cmpl $0x23, %r12d
je 0x24049
movq %rbp, %r14
movq %rbx, %rdi
movq 0x160(%rsp), %rsi
callq 0x1e698
movq 0x118(%rsp), %rbp
movq 0x140(%rsp), %rax
movq %rbp, %rcx
shlq $0x5, %rcx
leaq 0xc8(%rsp), %rdx
movq %rdx, 0xb8(%rsp)
movq (%rax,%rcx), %rsi
movq 0x8(%rax,%rcx), %rdx
addq %rsi, %rdx
leaq 0xb8(%rsp), %rdi
callq 0x1e014
movq %rbp, 0xd8(%rsp)
movq 0x110(%rsp), %rax
movq %rax, 0xe0(%rsp)
leaq 0xf8(%rsp), %rax
movq %rax, 0xe8(%rsp)
movq 0x120(%rsp), %rsi
movq 0x128(%rsp), %rdx
addq %rsi, %rdx
leaq 0xe8(%rsp), %rdi
callq 0x1e014
movl %r12d, 0x108(%rsp)
cmpl $-0xe, %r12d
movq %r14, %rbp
jne 0x23b22
movb $0x1, %r13b
movq 0x8(%rsp), %rdi
movq %rbx, %rsi
callq 0x243a4
jmp 0x23ff7
movb $0x1, %al
jmp 0x2404b
testb $0x1, %r13b
je 0x23bc8
cmpl $0x28, %r12d
jne 0x23b48
movq 0x8(%rsp), %rax
movq 0x8(%rax), %rax
cmpl $-0xe, -0x8(%rax)
jne 0x23b48
movl $0xffffffca, -0x8(%rax) # imm = 0xFFFFFFCA
cmpl $-0x2, 0x108(%rsp)
je 0x23b6a
leaq 0xe8(%rsp), %rdi
leaq 0x60966(%rip), %rsi     # 0x844c7
callq 0x10110
testl %eax, %eax
je 0x23bda
cmpl $-0x2, 0x108(%rsp)
je 0x23b90
leaq 0xe8(%rsp), %rdi
leaq 0x60941(%rip), %rsi     # 0x844c4
callq 0x10110
testl %eax, %eax
je 0x23d1c
cmpl $-0x2, 0x108(%rsp)
je 0x23bb6
leaq 0xe8(%rsp), %rdi
leaq 0x60921(%rip), %rsi     # 0x844ca
callq 0x10110
testl %eax, %eax
je 0x23e5e
movq 0x8(%rsp), %rdi
movq %rbx, %rsi
callq 0x243a4
jmp 0x23fdd
movq 0x8(%rsp), %rdi
movq %rbx, %rsi
callq 0x243a4
jmp 0x23ff7
leaq 0x10(%rsp), %rdi
movq %rbx, %rsi
callq 0x1e698
leaq 0x48(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0xb8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
addq %rsi, %rdx
leaq 0x38(%rsp), %rdi
callq 0x1e014
movups 0xd8(%rsp), %xmm0
movups %xmm0, 0x58(%rsp)
leaq 0x78(%rsp), %rax
movq %rax, 0x68(%rsp)
leaq 0x68(%rsp), %rdi
leaq 0x606f7(%rip), %rsi     # 0x84328
leaq 0x606f1(%rip), %rdx     # 0x84329
callq 0x1e7ca
movl $0x3e, 0x88(%rsp)
movq 0x8(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x2481a
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0x23c73
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0x38(%rsp), %rdi
leaq 0x48(%rsp), %rax
cmpq %rax, %rdi
je 0x23c8f
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x103d0
leaq 0x10(%rsp), %r14
movq %r14, %rdi
callq 0x1d736
movq %r14, %rdi
movq %rbx, %rsi
callq 0x1e698
leaq 0x48(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0xb8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
addq %rsi, %rdx
leaq 0x38(%rsp), %rdi
callq 0x1e014
movups 0xd8(%rsp), %xmm0
movups %xmm0, 0x58(%rsp)
leaq 0x78(%rsp), %rax
movq %rax, 0x68(%rsp)
leaq 0x68(%rsp), %rdi
leaq 0x60637(%rip), %rsi     # 0x84328
leaq 0x60631(%rip), %rdx     # 0x84329
callq 0x1e7ca
movl $0x3e, 0x88(%rsp)
movq 0x8(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x2481a
jmp 0x23f9b
leaq 0x10(%rsp), %rdi
movq %rbx, %rsi
callq 0x1e698
leaq 0x48(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0xb8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
addq %rsi, %rdx
leaq 0x38(%rsp), %rdi
callq 0x1e014
movups 0xd8(%rsp), %xmm0
movups %xmm0, 0x58(%rsp)
leaq 0x78(%rsp), %rax
movq %rax, 0x68(%rsp)
leaq 0x68(%rsp), %rdi
leaq 0x605ec(%rip), %rsi     # 0x8435f
leaq 0x605e6(%rip), %rdx     # 0x84360
callq 0x1e7ca
movl $0x3c, 0x88(%rsp)
movq 0x8(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x2481a
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0x23db5
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0x38(%rsp), %rdi
leaq 0x48(%rsp), %rax
cmpq %rax, %rdi
je 0x23dd1
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x103d0
leaq 0x10(%rsp), %r14
movq %r14, %rdi
callq 0x1d736
movq %r14, %rdi
movq %rbx, %rsi
callq 0x1e698
leaq 0x48(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0xb8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
addq %rsi, %rdx
leaq 0x38(%rsp), %rdi
callq 0x1e014
movups 0xd8(%rsp), %xmm0
movups %xmm0, 0x58(%rsp)
leaq 0x78(%rsp), %rax
movq %rax, 0x68(%rsp)
leaq 0x68(%rsp), %rdi
leaq 0x6052c(%rip), %rsi     # 0x8435f
leaq 0x60526(%rip), %rdx     # 0x84360
callq 0x1e7ca
movl $0x3c, 0x88(%rsp)
movq 0x8(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x2481a
jmp 0x23f9b
leaq 0x10(%rsp), %rdi
movq %rbx, %rsi
callq 0x1e698
leaq 0x48(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0xb8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
addq %rsi, %rdx
leaq 0x38(%rsp), %rdi
callq 0x1e014
movups 0xd8(%rsp), %xmm0
movups %xmm0, 0x58(%rsp)
leaq 0x78(%rsp), %rax
movq %rax, 0x68(%rsp)
leaq 0x68(%rsp), %rdi
leaq 0x604aa(%rip), %rsi     # 0x8435f
leaq 0x604a4(%rip), %rdx     # 0x84360
callq 0x1e7ca
movl $0x3c, 0x88(%rsp)
movq 0x8(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x2481a
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0x23ef7
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0x38(%rsp), %rdi
leaq 0x48(%rsp), %rax
cmpq %rax, %rdi
je 0x23f13
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x103d0
leaq 0x10(%rsp), %r14
movq %r14, %rdi
callq 0x1d736
movq %r14, %rdi
movq %rbx, %rsi
callq 0x1e698
leaq 0x48(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0xb8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
addq %rsi, %rdx
leaq 0x38(%rsp), %rdi
callq 0x1e014
movups 0xd8(%rsp), %xmm0
movups %xmm0, 0x58(%rsp)
leaq 0x78(%rsp), %rax
movq %rax, 0x68(%rsp)
leaq 0x68(%rsp), %rdi
leaq 0x603b3(%rip), %rsi     # 0x84328
leaq 0x603ad(%rip), %rdx     # 0x84329
callq 0x1e7ca
movl $0x3e, 0x88(%rsp)
movq 0x8(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x2481a
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0x23fb7
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0x38(%rsp), %rdi
leaq 0x48(%rsp), %rax
cmpq %rax, %rdi
je 0x23fd3
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x103d0
leaq 0x10(%rsp), %rdi
callq 0x1d736
movq 0x8(%rsp), %rax
movq 0x8(%rax), %rax
cmpl $0x29, -0x8(%rax)
movzbl %r13b, %r13d
movl $0x0, %eax
cmovel %eax, %r13d
movq 0xe8(%rsp), %rdi
leaq 0xf8(%rsp), %rax
cmpq %rax, %rdi
je 0x2401c
movq 0xf8(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0xb8(%rsp), %rdi
leaq 0xc8(%rsp), %rax
cmpq %rax, %rdi
je 0x24041
movq 0xc8(%rsp), %rsi
incq %rsi
callq 0x103d0
movq %rbx, %rdi
callq 0x1d736
xorl %eax, %eax
testb %al, %al
je 0x23a21
movq 0x8(%rsp), %rax
movq (%rax), %r15
movq 0x8(%rax), %r12
cmpq %r12, %r15
je 0x240e1
leaq 0xa0(%rsp), %r13
leaq 0x90(%rsp), %rbx
cmpq $0x0, 0x30(%r15)
je 0x240d8
leaq 0x28(%r15), %r14
movq (%r14), %rax
movsbl (%rax), %edi
callq 0x10060
testl %eax, %eax
je 0x240d8
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
movq $-0x1, %rcx
callq 0x10410
movq %r14, %rdi
movq %rbx, %rsi
callq 0x104f0
movq 0x90(%rsp), %rdi
cmpq %r13, %rdi
je 0x240cd
movq 0xa0(%rsp), %rsi
incq %rsi
callq 0x103d0
decq 0x50(%r15)
cmpq $0x0, 0x30(%r15)
jne 0x2407f
subq $-0x80, %r15
cmpq %r12, %r15
jne 0x24074
movq 0x120(%rsp), %rdi
leaq 0x130(%rsp), %rax
cmpq %rax, %rdi
je 0x24106
movq 0x130(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0x168(%rsp), %rdi
leaq 0x178(%rsp), %rax
cmpq %rax, %rdi
je 0x2412b
movq 0x178(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0x92e1e(%rip), %rsi     # 0xb6f50
leaq 0x190(%rsp), %rdi
callq 0x102e0
leaq 0x210(%rsp), %rdi
callq 0x10150
leaq 0x140(%rsp), %rdi
callq 0x1dca2
movq 0x8(%rsp), %rax
addq $0x318, %rsp            # imm = 0x318
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x241a5
jmp 0x241bb
jmp 0x24215
jmp 0x24236
jmp 0x241a5
jmp 0x241bb
jmp 0x24215
jmp 0x24236
jmp 0x241a5
jmp 0x241bb
jmp 0x24215
jmp 0x24236
jmp 0x241a5
jmp 0x241bb
jmp 0x24215
jmp 0x24236
movq %rax, %rbx
leaq 0x48(%rsp), %r14
leaq 0x10(%rsp), %rdi
callq 0x211f6
xorl %ebp, %ebp
jmp 0x241c6
movq %rax, %rbx
movb $0x1, %bpl
leaq 0x48(%rsp), %r14
testb %bpl, %bpl
je 0x2421b
movq 0x38(%rsp), %rdi
cmpq %r14, %rdi
jne 0x24206
jmp 0x2421b
jmp 0x24215
jmp 0x24236
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x211f6
xorl %ebp, %ebp
jmp 0x241f2
movq %rax, %rbx
movb $0x1, %bpl
testb %bpl, %bpl
je 0x2421b
movq 0x38(%rsp), %rdi
cmpq 0x158(%rsp), %rdi
je 0x2421b
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x103d0
jmp 0x2421b
movq %rax, %rbx
movb $0x1, %bpl
testb %bpl, %bpl
je 0x24239
leaq 0x10(%rsp), %rdi
callq 0x1d736
jmp 0x24239
jmp 0x24236
movq %rax, %rbx
jmp 0x24305
movq %rax, %rbx
leaq 0x90(%rsp), %rdi
callq 0x211f6
jmp 0x24290
movq %rax, %rbx
movq 0xb8(%rsp), %rdi
leaq 0xc8(%rsp), %rax
cmpq %rax, %rdi
je 0x24275
movq 0xc8(%rsp), %rsi
incq %rsi
callq 0x103d0
jmp 0x24275
movq %rax, %rbx
leaq 0x90(%rsp), %rdi
callq 0x1d736
jmp 0x24290
jmp 0x2428d
jmp 0x2428d
movq %rax, %rbx
jmp 0x242bf
movq %rax, %rbx
movq 0x120(%rsp), %rdi
leaq 0x130(%rsp), %rax
cmpq %rax, %rdi
je 0x242b5
movq 0x130(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0x8(%rsp), %rdi
callq 0x20ba4
movq 0x168(%rsp), %rdi
leaq 0x178(%rsp), %rax
cmpq %rax, %rdi
je 0x242e4
movq 0x178(%rsp), %rsi
incq %rsi
callq 0x103d0
movq 0x92c65(%rip), %rsi     # 0xb6f50
leaq 0x190(%rsp), %rdi
callq 0x102e0
leaq 0x210(%rsp), %rdi
callq 0x10150
leaq 0x140(%rsp), %rdi
callq 0x1dca2
movq %rbx, %rdi
callq 0x106f0