// File: /workspace/github_cpp_makefile_star2_O1/adamiaonr[P]rid-analytics/src/pugixml.cpp
// Function: pugi::impl::(anonymous namespace)::xpath_parser::parse_step(pugi::impl::(anonymous namespace)::xpath_ast_node*)
xpath_ast_node* parse_step(xpath_ast_node* set)
		{
			if (set && set->rettype() != xpath_type_node_set)
				throw_error("Step has to be applied to node set");

			bool axis_specified = false;
			axis_t axis = axis_child; // implied child axis

			if (_lexer.current() == lex_axis_attribute)
			{
				axis = axis_attribute;
				axis_specified = true;

				_lexer.next();
			}
			else if (_lexer.current() == lex_dot)
			{
				_lexer.next();

				return new (alloc_node()) xpath_ast_node(ast_step, set, axis_self, nodetest_type_node, 0);
			}
			else if (_lexer.current() == lex_double_dot)
			{
				_lexer.next();

				return new (alloc_node()) xpath_ast_node(ast_step, set, axis_parent, nodetest_type_node, 0);
			}

			nodetest_t nt_type = nodetest_none;
			xpath_lexer_string nt_name;

			if (_lexer.current() == lex_string)
			{
				// node name test
				nt_name = _lexer.contents();
				_lexer.next();

				// was it an axis name?
				if (_lexer.current() == lex_double_colon)
				{
					// parse axis name
					if (axis_specified) throw_error("Two axis specifiers in one step");

					axis = parse_axis_name(nt_name, axis_specified);

					if (!axis_specified) throw_error("Unknown axis");

					// read actual node test
					_lexer.next();

					if (_lexer.current() == lex_multiply)
					{
						nt_type = nodetest_all;
						nt_name = xpath_lexer_string();
						_lexer.next();
					}
					else if (_lexer.current() == lex_string)
					{
						nt_name = _lexer.contents();
						_lexer.next();
					}
					else throw_error("Unrecognized node test");
				}

				if (nt_type == nodetest_none)
				{
					// node type test or processing-instruction
					if (_lexer.current() == lex_open_brace)
					{
						_lexer.next();

						if (_lexer.current() == lex_close_brace)
						{
							_lexer.next();

							nt_type = parse_node_test_type(nt_name);

							if (nt_type == nodetest_none) throw_error("Unrecognized node type");

							nt_name = xpath_lexer_string();
						}
						else if (nt_name == PUGIXML_TEXT("processing-instruction"))
						{
							if (_lexer.current() != lex_quoted_string)
								throw_error("Only literals are allowed as arguments to processing-instruction()");

							nt_type = nodetest_pi;
							nt_name = _lexer.contents();
							_lexer.next();

							if (_lexer.current() != lex_close_brace)
								throw_error("Unmatched brace near processing-instruction()");
							_lexer.next();
						}
						else
							throw_error("Unmatched brace near node type test");

					}
					// QName or NCName:*
					else
					{
						if (nt_name.end - nt_name.begin > 2 && nt_name.end[-2] == ':' && nt_name.end[-1] == '*') // NCName:*
						{
							nt_name.end--; // erase *

							nt_type = nodetest_all_in_namespace;
						}
						else nt_type = nodetest_name;
					}
				}
			}
			else if (_lexer.current() == lex_multiply)
			{
				nt_type = nodetest_all;
				_lexer.next();
			}
			else throw_error("Unrecognized node test");

			xpath_ast_node* n = new (alloc_node()) xpath_ast_node(ast_step, set, axis, nt_type, alloc_string(nt_name));

			xpath_ast_node* last = 0;

			while (_lexer.current() == lex_open_square_brace)
			{
				_lexer.next();

				xpath_ast_node* expr = parse_expression();

				xpath_ast_node* pred = new (alloc_node()) xpath_ast_node(ast_predicate, 0, expr, predicate_default);

				if (_lexer.current() != lex_close_square_brace)
					throw_error("Unmatched square brace");
				_lexer.next();

				if (last) last->set_next(pred);
				else n->set_right(pred);

				last = pred;
			}

			return n;
		}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r15
movq %rdi, %rbx
testq %rsi, %rsi
je 0x14898
cmpb $0x1, 0x1(%r15)
jne 0x14da5
leaq 0x8(%rbx), %rdi
movl 0x28(%rbx), %eax
cmpl $0x18, %eax
je 0x148db
cmpl $0x17, %eax
je 0x148c6
movq %rbx, 0x8(%rsp)
cmpl $0x16, %eax
jne 0x14906
movq %rdi, %r12
callq 0x13182
movl $0x2, %r13d
movb $0x1, %bpl
jmp 0x14911
callq 0x13182
movq %rbx, %rdi
callq 0x14408
movl $0x20c0138, (%rax)      # imm = 0x20C0138
jmp 0x148ee
callq 0x13182
movq %rbx, %rdi
callq 0x14408
movl $0x2090138, (%rax)      # imm = 0x2090138
movq %r15, 0x8(%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rax)
movq $0x0, 0x20(%rax)
jmp 0x14d87
movq %rdi, %r12
movl $0x3, %r13d
xorl %ebp, %ebp
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movq 0x8(%rsp), %rax
movl 0x28(%rax), %eax
cmpl $0x9, %eax
je 0x149ec
cmpl $0x14, %eax
jne 0x14db4
movq 0x8(%rsp), %rbx
leaq 0x18(%rbx), %r14
movups 0x18(%rbx), %xmm0
movaps %xmm0, 0x10(%rsp)
movq %r12, %rdi
callq 0x13182
cmpl $0x19, 0x28(%rbx)
movq %r14, 0x20(%rsp)
jne 0x149fe
testb %bpl, %bpl
jne 0x14dbd
movq 0x10(%rsp), %rax
movzbl (%rax), %eax
cmpl $0x6d, %eax
jg 0x14a08
addl $-0x61, %eax
cmpl $0x5, %eax
ja 0x14b54
leaq 0x18a5f(%rip), %rcx     # 0x2d3e8
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x1af55(%rip), %rsi     # 0x2f8ee
leaq 0x10(%rsp), %rdi
callq 0x14490
xorl %r13d, %r13d
movb $0x1, %bpl
testb %al, %al
jne 0x14b5c
leaq 0x1af3f(%rip), %rsi     # 0x2f8f7
leaq 0x10(%rsp), %rdi
callq 0x14490
movl $0x1, %r13d
testb %al, %al
jne 0x14b5c
leaq 0x19320(%rip), %rsi     # 0x2dcf7
leaq 0x10(%rsp), %rdi
callq 0x14490
movl $0x2, %r13d
jmp 0x14b50
movq %r12, %rdi
callq 0x13182
movl $0x7, %ebp
jmp 0x14cb7
xorl %ebp, %ebp
movb $0x1, %r14b
jmp 0x14bab
cmpl $0x6e, %eax
je 0x14ae0
cmpl $0x70, %eax
je 0x14b00
cmpl $0x73, %eax
jne 0x14b54
leaq 0x1aed9(%rip), %rsi     # 0x2f903
leaq 0x10(%rsp), %rdi
callq 0x14490
testb %al, %al
je 0x14b54
movl $0xc, %r13d
jmp 0x14afb
leaq 0x1aec0(%rip), %rsi     # 0x2f90e
leaq 0x10(%rsp), %rdi
callq 0x14490
movl $0x4, %r13d
movb $0x1, %bpl
testb %al, %al
jne 0x14b5c
leaq 0x1aea9(%rip), %rsi     # 0x2f919
leaq 0x10(%rsp), %rdi
callq 0x14490
movl $0x5, %r13d
jmp 0x14b50
leaq 0x1aea0(%rip), %rsi     # 0x2f92c
leaq 0x10(%rsp), %rdi
callq 0x14490
movl $0x6, %r13d
movb $0x1, %bpl
testb %al, %al
jne 0x14b5c
leaq 0x1ae88(%rip), %rsi     # 0x2f936
leaq 0x10(%rsp), %rdi
callq 0x14490
movl $0x7, %r13d
jmp 0x14b50
leaq 0x1ae3e(%rip), %rsi     # 0x2f908
leaq 0x10(%rsp), %rdi
callq 0x14490
testb %al, %al
je 0x14b54
movl $0x3, %r13d
jmp 0x14afb
leaq 0x1ae61(%rip), %rsi     # 0x2f948
leaq 0x10(%rsp), %rdi
callq 0x14490
testb %al, %al
je 0x14b54
movl $0x8, %r13d
movb $0x1, %bpl
jmp 0x14b5c
leaq 0x1a750(%rip), %rsi     # 0x2f257
leaq 0x10(%rsp), %rdi
callq 0x14490
movl $0x9, %r13d
movb $0x1, %bpl
testb %al, %al
jne 0x14b5c
leaq 0x1ae2d(%rip), %rsi     # 0x2f952
leaq 0x10(%rsp), %rdi
callq 0x14490
movl $0xa, %r13d
testb %al, %al
jne 0x14b5c
leaq 0x1ae1c(%rip), %rsi     # 0x2f95c
leaq 0x10(%rsp), %rdi
callq 0x14490
movl $0xb, %r13d
testb %al, %al
jne 0x14b5c
movl $0x3, %r13d
xorl %ebp, %ebp
testb %bpl, %bpl
je 0x14dc6
movq %r12, %rdi
callq 0x13182
movq 0x8(%rsp), %rax
movl 0x28(%rax), %eax
cmpl $0x14, %eax
je 0x14b95
cmpl $0x9, %eax
jne 0x14db4
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movl $0x7, %ebp
xorl %r14d, %r14d
jmp 0x14ba3
movups (%r14), %xmm0
movaps %xmm0, 0x10(%rsp)
xorl %ebp, %ebp
movb $0x1, %r14b
movq %r12, %rdi
callq 0x13182
testb %r14b, %r14b
je 0x14cb7
movq 0x8(%rsp), %r14
cmpl $0xc, 0x28(%r14)
jne 0x14c00
movq %r12, %rbx
movq %r12, %rdi
callq 0x13182
movl 0x28(%r14), %ebp
cmpl $0xd, %ebp
jne 0x14c3f
movq %rbx, %r12
movq %rbx, %rdi
callq 0x13182
leaq 0x10(%rsp), %rdi
callq 0x14634
testl %eax, %eax
je 0x14dd7
movl %eax, %ebp
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
jmp 0x14cb7
movq 0x18(%rsp), %rax
movq %rax, %rcx
subq 0x10(%rsp), %rcx
movl $0x1, %ebp
cmpq $0x3, %rcx
jl 0x14cb7
cmpb $0x3a, -0x2(%rax)
jne 0x14cb7
cmpb $0x2a, -0x1(%rax)
jne 0x14cb7
decq %rax
movq %rax, 0x18(%rsp)
movl $0x8, %ebp
jmp 0x14cb7
movq %rbx, %r12
leaq 0x1a965(%rip), %rsi     # 0x2f5ae
leaq 0x10(%rsp), %rdi
callq 0x14490
testb %al, %al
je 0x14de0
cmpl $0xe, %ebp
movq 0x20(%rsp), %rdx
jne 0x14de9
movq 0x8(%rsp), %rax
movl 0x28(%rax), %eax
cmpl $0x14, %eax
ja 0x14dfb
movl $0x10c800, %ecx         # imm = 0x10C800
btl %eax, %ecx
jae 0x14dfb
movups (%rdx), %xmm0
movaps %xmm0, 0x10(%rsp)
movq %r12, %rbx
movq %r12, %rdi
callq 0x13182
movq 0x8(%rsp), %rax
cmpl $0xd, 0x28(%rax)
jne 0x14df2
movq %rbx, %rdi
callq 0x13182
movl $0x6, %ebp
movq 0x8(%rsp), %rbx
movq %rbx, %rdi
callq 0x14408
movq %rax, %r14
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x1472c
movw $0x138, (%r14)          # imm = 0x138
movb %r13b, 0x2(%r14)
movb %bpl, 0x3(%r14)
movq %r15, 0x8(%r14)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%r14)
movq %r14, 0x20(%rsp)
movq %rax, 0x20(%r14)
cmpl $0x12, 0x28(%rbx)
jne 0x14d82
movq %rbx, %r13
movq %r12, %rbx
movq 0x20(%rsp), %rax
leaq 0x10(%rax), %rbp
xorl %r14d, %r14d
xorl %r12d, %r12d
movq %rbx, %rdi
callq 0x13182
movq %r13, %rdi
callq 0x13600
movq %r13, %rdi
movq %rax, %rsi
xorl %edx, %edx
callq 0x134e2
movq %rax, %r13
movq 0x8(%rsp), %rdi
callq 0x14408
movl $0x110, (%rax)          # imm = 0x110
movq %r14, 0x8(%rax)
movq %r13, 0x10(%rax)
movq 0x8(%rsp), %r13
movq %r14, 0x18(%rax)
cmpl $0x13, 0x28(%r13)
jne 0x14d96
movq %rax, %r15
movq %rbx, %rdi
callq 0x13182
leaq 0x18(%r12), %rax
testq %r12, %r12
cmoveq %rbp, %rax
movq %r15, (%rax)
cmpl $0x12, 0x28(%r13)
movq %r15, %r12
je 0x14d16
movq 0x20(%rsp), %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1a855(%rip), %rsi     # 0x2f5f2
movq %r13, %rdi
callq 0x13498
leaq 0x1a7df(%rip), %rsi     # 0x2f58b
movq %rbx, %rdi
callq 0x13498
leaq 0x1aa70(%rip), %rsi     # 0x2f82b
jmp 0x14dcd
leaq 0x1aa3a(%rip), %rsi     # 0x2f7fe
jmp 0x14dcd
leaq 0x1aa51(%rip), %rsi     # 0x2f81e
movq 0x8(%rsp), %rdi
callq 0x13498
leaq 0x1aa64(%rip), %rsi     # 0x2f842
jmp 0x14dcd
leaq 0x1aae3(%rip), %rsi     # 0x2f8ca
jmp 0x14dcd
leaq 0x1aa69(%rip), %rsi     # 0x2f859
jmp 0x14dcd
leaq 0x1aaa3(%rip), %rsi     # 0x2f89c
jmp 0x14dcd
leaq 0x1a6b5(%rip), %rdi     # 0x2f4b7
leaq 0x189bc(%rip), %rsi     # 0x2d7c5
leaq 0x1a720(%rip), %rcx     # 0x2f530
movl $0x23d7, %edx           # imm = 0x23D7
callq 0x4270