// File: mhe[P]raytracerframework_cpp/yaml/scantoken.cpp
// Function: YAML::Scanner::ScanDirective()
void Scanner::ScanDirective()
	{
		std::string name;
		std::vector <std::string> params;

		// pop indents and simple keys
		PopIndentTo(-1);
		VerifyAllSimpleKeys();

		m_simpleKeyAllowed = false;

		// store pos and eat indicator
		int line = INPUT.line, column = INPUT.column;
		INPUT.eat(1);

		// read name
		while(INPUT.peek() != EOF && !Exp::BlankOrBreak.Matches(INPUT))
			name += INPUT.get();

		// read parameters
		while(1) {
			// first get rid of whitespace
			while(Exp::Blank.Matches(INPUT))
				INPUT.eat(1);

			// break on newline or comment
			if(INPUT.peek() == EOF || Exp::Break.Matches(INPUT) || Exp::Comment.Matches(INPUT))
				break;

			// now read parameter
			std::string param;
			while(INPUT.peek() != EOF && !Exp::BlankOrBreak.Matches(INPUT))
				param += INPUT.get();

			params.push_back(param);
		}
		
		Token token(TT_DIRECTIVE, line, column);
		token.value = name;
		token.params = params;
		m_tokens.push(token);
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xe0, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0xc8(%rbp)
leaq -0x28(%rbp), %rdi
callq 0x55b0
leaq -0x40(%rbp), %rdi
callq 0x42050
movq -0xc8(%rbp), %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0x40a90
jmp 0x4533f
movq -0xc8(%rbp), %rdi
callq 0x49d10
jmp 0x4534d
movq -0xc8(%rbp), %rdi
movb $0x0, 0x62(%rdi)
movl 0x8(%rdi), %eax
movl %eax, -0x50(%rbp)
movl 0xc(%rdi), %eax
movl %eax, -0x54(%rbp)
movl $0x1, %esi
callq 0x4a9a0
jmp 0x45370
jmp 0x45372
movq -0xc8(%rbp), %rdi
callq 0x4a840
movb %al, -0xc9(%rbp)
jmp 0x45386
movb -0xc9(%rbp), %al
movsbl %al, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
movb %al, -0xca(%rbp)
je 0x453c5
movq -0xc8(%rbp), %rsi
leaq 0x28556(%rip), %rdi     # 0x6d900
callq 0x3c550
movb %al, -0xcb(%rbp)
jmp 0x453b7
movb -0xcb(%rbp), %al
xorb $-0x1, %al
movb %al, -0xca(%rbp)
movb -0xca(%rbp), %al
testb $0x1, %al
jne 0x453d1
jmp 0x4540f
movq -0xc8(%rbp), %rdi
callq 0x4a890
movb %al, -0xcc(%rbp)
jmp 0x453e5
movb -0xcc(%rbp), %al
movsbl %al, %esi
leaq -0x28(%rbp), %rdi
callq 0x5220
jmp 0x453f9
jmp 0x45372
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x45624
jmp 0x45411
jmp 0x45413
jmp 0x45415
movq -0xc8(%rbp), %rsi
leaq 0x2847d(%rip), %rdi     # 0x6d8a0
callq 0x3c550
movb %al, -0xcd(%rbp)
jmp 0x45430
movb -0xcd(%rbp), %al
testb $0x1, %al
jne 0x4543c
jmp 0x45451
movq -0xc8(%rbp), %rdi
movl $0x1, %esi
callq 0x4a9a0
jmp 0x4544f
jmp 0x45415
movq -0xc8(%rbp), %rdi
callq 0x4a840
movb %al, -0xce(%rbp)
jmp 0x45465
movb -0xce(%rbp), %al
movsbl %al, %eax
cmpl $-0x1, %eax
je 0x454c1
movq -0xc8(%rbp), %rsi
leaq 0x2844f(%rip), %rdi     # 0x6d8d0
callq 0x3c550
movb %al, -0xcf(%rbp)
jmp 0x4548e
movb -0xcf(%rbp), %al
testb $0x1, %al
jne 0x454c1
jmp 0x4549a
movq -0xc8(%rbp), %rsi
leaq 0x286c8(%rip), %rdi     # 0x6db70
callq 0x3c550
movb %al, -0xd0(%rbp)
jmp 0x454b5
movb -0xd0(%rbp), %al
testb $0x1, %al
jne 0x454c1
jmp 0x454c6
jmp 0x45592
leaq -0x78(%rbp), %rdi
callq 0x55b0
movq -0xc8(%rbp), %rdi
callq 0x4a840
movb %al, -0xd1(%rbp)
jmp 0x454e3
movb -0xd1(%rbp), %al
movsbl %al, %ecx
xorl %eax, %eax
cmpl $-0x1, %ecx
movb %al, -0xd2(%rbp)
je 0x45522
movq -0xc8(%rbp), %rsi
leaq 0x283f9(%rip), %rdi     # 0x6d900
callq 0x3c550
movb %al, -0xd3(%rbp)
jmp 0x45514
movb -0xd3(%rbp), %al
xorb $-0x1, %al
movb %al, -0xd2(%rbp)
movb -0xd2(%rbp), %al
testb $0x1, %al
jne 0x4552e
jmp 0x45575
movq -0xc8(%rbp), %rdi
callq 0x4a890
movb %al, -0xd4(%rbp)
jmp 0x45542
movb -0xd4(%rbp), %al
movsbl %al, %esi
leaq -0x78(%rbp), %rdi
callq 0x5220
jmp 0x45556
jmp 0x454cf
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x78(%rbp), %rdi
callq 0x5788
jmp 0x45624
leaq -0x40(%rbp), %rdi
leaq -0x78(%rbp), %rsi
callq 0x46f90
jmp 0x45584
leaq -0x78(%rbp), %rdi
callq 0x5788
jmp 0x45411
movl -0x50(%rbp), %edx
movl -0x54(%rbp), %ecx
leaq -0xc0(%rbp), %rdi
xorl %esi, %esi
callq 0x41000
jmp 0x455a8
leaq -0xb0(%rbp), %rdi
leaq -0x28(%rbp), %rsi
callq 0x5080
jmp 0x455ba
leaq -0x90(%rbp), %rdi
leaq -0x40(%rbp), %rsi
callq 0x47000
jmp 0x455cc
movq -0xc8(%rbp), %rdi
addq $0x10, %rdi
leaq -0xc0(%rbp), %rsi
callq 0x47250
jmp 0x455e5
leaq -0xc0(%rbp), %rdi
callq 0x35c00
leaq -0x40(%rbp), %rdi
callq 0x36910
leaq -0x28(%rbp), %rdi
callq 0x5788
addq $0xe0, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0xc0(%rbp), %rdi
callq 0x35c00
leaq -0x40(%rbp), %rdi
callq 0x36910
leaq -0x28(%rbp), %rdi
callq 0x5788
movq -0x48(%rbp), %rdi
callq 0x56c0
nop