// File: /workspace/github_c_makefile_star2_O1/genometools[P]genometools/src/external/sqlite-3.33.0/sqlite3.c
// Function: sqlite3ResolveExprListNames
SQLITE_PRIVATE int sqlite3ResolveExprListNames(
  NameContext *pNC,       /* Namespace to resolve expressions in. */
  ExprList *pList         /* The expression list to be analyzed. */
){
  int i;
  int savedHasAgg = 0;
  Walker w;
  if( pList==0 ) return WRC_Continue;
  w.pParse = pNC->pParse;
  w.xExprCallback = resolveExprStep;
  w.xSelectCallback = resolveSelectStep;
  w.xSelectCallback2 = 0;
  w.u.pNC = pNC;
  savedHasAgg = pNC->ncFlags & (NC_HasAgg|NC_MinMaxAgg|NC_HasWin);
  pNC->ncFlags &= ~(NC_HasAgg|NC_MinMaxAgg|NC_HasWin);
  for(i=0; i<pList->nExpr; i++){
    Expr *pExpr = pList->a[i].pExpr;
    if( pExpr==0 ) continue;
#if SQLITE_MAX_EXPR_DEPTH>0
    w.pParse->nHeight += pExpr->nHeight;
    if( sqlite3ExprCheckHeight(w.pParse, w.pParse->nHeight) ){
      return WRC_Abort;
    }
#endif
    sqlite3WalkExpr(&w, pExpr);
#if SQLITE_MAX_EXPR_DEPTH>0
    w.pParse->nHeight -= pExpr->nHeight;
#endif
    assert( EP_Agg==NC_HasAgg );
    assert( EP_Win==NC_HasWin );
    testcase( pNC->ncFlags & NC_HasAgg );
    testcase( pNC->ncFlags & NC_HasWin );
    if( pNC->ncFlags & (NC_HasAgg|NC_MinMaxAgg|NC_HasWin) ){
      ExprSetProperty(pExpr, pNC->ncFlags & (NC_HasAgg|NC_HasWin) );
      savedHasAgg |= pNC->ncFlags & (NC_HasAgg|NC_MinMaxAgg|NC_HasWin);
      pNC->ncFlags &= ~(NC_HasAgg|NC_MinMaxAgg|NC_HasWin);
    }
    if( pNC->nErr>0 || w.pParse->nErr>0 ) return WRC_Abort;
  }
  pNC->ncFlags |= savedHasAgg;
  return WRC_Continue;
}

// Assembly:
xorl %eax, %eax
testq %rsi, %rsi
je 0x2ce301
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rsi, %r15
movq %rdi, %r14
movq (%rdi), %rax
movq %rax, 0x8(%rsp)
leaq 0x113(%rip), %rax       # 0x2ce302
movq %rax, 0x10(%rsp)
leaq 0x17e6(%rip), %rax      # 0x2cf9e1
movq %rax, 0x18(%rsp)
movq $0x0, 0x20(%rsp)
movq %rdi, 0x30(%rsp)
movl 0x28(%rdi), %eax
movl %eax, %r12d
andl $0x9010, %r12d          # imm = 0x9010
andl $0xffff6fef, %eax       # imm = 0xFFFF6FEF
movl %eax, 0x28(%rdi)
cmpl $0x0, (%rsi)
jle 0x2ce2e6
leaq 0x8(%r15), %r13
xorl %ebx, %ebx
movq (%r13), %rbp
testq %rbp, %rbp
je 0x2ce271
movq 0x8(%rsp), %rdi
movl 0x124(%rdi), %eax
addl 0x28(%rbp), %eax
movl %eax, 0x124(%rdi)
movq (%rdi), %rcx
movl 0x88(%rcx), %edx
cmpl %eax, %edx
jge 0x2ce278
leaq 0x11359c(%rip), %rsi    # 0x3e17ff
xorl %eax, %eax
callq 0x284eb8
movl $0x1, %ecx
jmp 0x2ce2ce
movl $0x4, %ecx
jmp 0x2ce2ce
leaq 0x8(%rsp), %rdi
movq %rbp, %rsi
callq 0x2ca211
movl 0x28(%rbp), %ecx
movq 0x8(%rsp), %rax
subl %ecx, 0x124(%rax)
movl 0x28(%r14), %ecx
movl %ecx, %edx
andl $0x9010, %edx           # imm = 0x9010
je 0x2ce2b9
movl %ecx, %esi
andl $0x8010, %esi           # imm = 0x8010
orl %esi, 0x4(%rbp)
orl %edx, %r12d
andl $0xffff6fef, %ecx       # imm = 0xFFFF6FEF
movl %ecx, 0x28(%r14)
movl $0x1, %ecx
cmpl $0x0, 0x24(%r14)
jg 0x2ce2ce
xorl %ecx, %ecx
cmpl $0x0, 0x30(%rax)
setg %cl
testb $0x3, %cl
jne 0x2ce2ee
incq %rbx
movslq (%r15), %rax
addq $0x18, %r13
cmpq %rax, %rbx
jl 0x2ce232
orl %r12d, 0x28(%r14)
xorl %eax, %eax
jmp 0x2ce2f3
movl $0x2, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq