// File: /workspace/github_c_makefile_star2_O2/baskerville[P]bspwm/src/rule.c
// Function: parse_key_value
void parse_key_value(char *key, char *value, rule_consequence_t *csq)
{
	bool v;
	if (streq("monitor", key)) {
		snprintf(csq->monitor_desc, sizeof(csq->monitor_desc), "%s", value);
	} else if (streq("desktop", key)) {
		snprintf(csq->desktop_desc, sizeof(csq->desktop_desc), "%s", value);
	} else if (streq("node", key)) {
		snprintf(csq->node_desc, sizeof(csq->node_desc), "%s", value);
	} else if (streq("split_dir", key)) {
		direction_t dir;
		if (parse_direction(value, &dir)) {
			SET_CSQ_SPLIT_DIR(dir);
		}
	} else if (streq("state", key)) {
		client_state_t cst;
		if (parse_client_state(value, &cst)) {
			SET_CSQ_STATE(cst);
		}
	} else if (streq("layer", key)) {
		stack_layer_t lyr;
		if (parse_stack_layer(value, &lyr)) {
			SET_CSQ_LAYER(lyr);
		}
	} else if (streq("split_ratio", key)) {
		double rat;
		if (sscanf(value, "%lf", &rat) == 1 && rat > 0 && rat < 1) {
			csq->split_ratio = rat;
		}
	} else if (streq("rectangle", key)) {
		if (csq->rect == NULL) {
			csq->rect = calloc(1, sizeof(xcb_rectangle_t));
		}
		if (!parse_rectangle(value, csq->rect)) {
			free(csq->rect);
			csq->rect = NULL;
		}
	} else if (streq("honor_size_hints", key)) {
		if (!parse_honor_size_hints_mode(value, &csq->honor_size_hints)) {
			csq->honor_size_hints = HONOR_SIZE_HINTS_DEFAULT;
		}
	} else if (parse_bool(value, &v)) {
		if (streq("hidden", key)) {
			csq->hidden = v;
		}
#define SETCSQ(name) \
		else if (streq(#name, key)) { \
			csq->name = v; \
		}
		SETCSQ(sticky)
		SETCSQ(private)
		SETCSQ(locked)
		SETCSQ(marked)
		SETCSQ(center)
		SETCSQ(follow)
		SETCSQ(manage)
		SETCSQ(focus)
		SETCSQ(border)
#undef SETCSQ
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
leaq 0x3421(%rip), %rdi      # 0x1f1d6
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1bf87
leaq 0x341d(%rip), %rdi      # 0x1f1e9
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1bf90
leaq 0x3419(%rip), %rdi      # 0x1f1fc
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1bf99
leaq 0x477d(%rip), %rdi      # 0x20577
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1bfc2
leaq 0x2f75(%rip), %rdi      # 0x1ed86
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1bff7
leaq 0x2f34(%rip), %rdi      # 0x1ed5c
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c028
leaq 0x3882(%rip), %rdi      # 0x1f6c1
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c067
leaq 0x32d3(%rip), %rdi      # 0x1f129
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c0aa
leaq 0x3787(%rip), %rdi      # 0x1f5f4
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c0f0
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x15728
testb %al, %al
je 0x1c05d
leaq 0x3e23(%rip), %rdi      # 0x1fcbc
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c115
leaq 0x3e14(%rip), %rdi      # 0x1fcc4
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c124
leaq 0x3e05(%rip), %rdi      # 0x1fccc
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c133
leaq 0x3df7(%rip), %rdi      # 0x1fcd5
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c142
leaq 0x3de8(%rip), %rdi      # 0x1fcdd
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c151
leaq 0x4675(%rip), %rdi      # 0x20581
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c160
leaq 0x2df2(%rip), %rdi      # 0x1ed15
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c16f
leaq 0x464e(%rip), %rdi      # 0x20588
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c17e
leaq 0x2d74(%rip), %rdi      # 0x1ecc5
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
je 0x1c18d
leaq 0x4627(%rip), %rdi      # 0x2058f
movq %r14, %rsi
callq 0x4820
testl %eax, %eax
jne 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x62d(%rbx)
jmp 0x1c05d
addq $0x300, %rbx            # imm = 0x300
jmp 0x1bfa0
addq $0x400, %rbx            # imm = 0x400
jmp 0x1bfa0
addq $0x500, %rbx            # imm = 0x500
leaq 0x20a0(%rip), %rdx      # 0x1e047
movl $0x100, %esi            # imm = 0x100
movq %rbx, %rdi
movq %r15, %rcx
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
jmp 0x4110
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x15947
testb %al, %al
je 0x1c05d
movq 0x600(%rbx), %rax
testq %rax, %rax
jne 0x1c057
pushq $0x1
popq %rdi
pushq $0x4
popq %rsi
callq 0x48b0
movq %rax, 0x600(%rbx)
jmp 0x1c057
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x15874
testb %al, %al
je 0x1c05d
movq 0x618(%rbx), %rax
testq %rax, %rax
jne 0x1c057
pushq $0x1
popq %rdi
pushq $0x4
popq %rsi
callq 0x48b0
movq %rax, 0x618(%rbx)
jmp 0x1c057
leaq 0x8(%rsp), %rsi
movq %r15, %rdi
callq 0x158e9
testb %al, %al
je 0x1c05d
movq 0x610(%rbx), %rax
testq %rax, %rax
jne 0x1c057
pushq $0x1
popq %rdi
pushq $0x4
popq %rsi
callq 0x48b0
movq %rax, 0x610(%rbx)
movl 0x8(%rsp), %ecx
movl %ecx, (%rax)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
leaq 0x2db3(%rip), %rsi      # 0x1ee21
leaq 0x8(%rsp), %rdx
movq %r15, %rdi
xorl %eax, %eax
callq 0x41c0
cmpl $0x1, %eax
jne 0x1c05d
movsd 0x8(%rsp), %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x1c05d
movsd 0x256e(%rip), %xmm1     # 0x1e608
ucomisd %xmm0, %xmm1
jbe 0x1c05d
movsd %xmm0, 0x608(%rbx)
jmp 0x1c05d
movq 0x630(%rbx), %rsi
testq %rsi, %rsi
jne 0x1c0cb
pushq $0x1
popq %rdi
pushq $0x8
popq %rsi
callq 0x48b0
movq %rax, %rsi
movq %rax, 0x630(%rbx)
movq %r15, %rdi
callq 0x1610b
testb %al, %al
jne 0x1c05d
movq 0x630(%rbx), %rdi
callq 0x4460
andq $0x0, 0x630(%rbx)
jmp 0x1c05d
addq $0x620, %rbx            # imm = 0x620
movq %r15, %rdi
movq %rbx, %rsi
callq 0x15e46
testb %al, %al
jne 0x1c05d
movl $0x4, (%rbx)
jmp 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x624(%rbx)
jmp 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x625(%rbx)
jmp 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x626(%rbx)
jmp 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x627(%rbx)
jmp 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x628(%rbx)
jmp 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x629(%rbx)
jmp 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x62a(%rbx)
jmp 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x62b(%rbx)
jmp 0x1c05d
movb 0x8(%rsp), %al
movb %al, 0x62c(%rbx)
jmp 0x1c05d