anchor.diff:                  let expr = compileToSeqPipeline queryExpr' context optimize
                   expr 
               | Aggregate (seed, Lambda ([accVarExpr; varExpr], bodyExpr), queryExpr') ->
  +                let seed = optimize seed
                   let bodyExpr = optimize bodyExpr
                   let initExpr = assign accVarExpr seed
                   let accExpr = assign accVarExpr bodyExpr
  
positive.code:                     block (enumeratorVarExpr :: disposableVarExpr :: context.VarExprs) [block [] context.InitExprs; enumeratorAssignExpr; disposableAssignExpr; loopExpr; context.ReturnExpr] 
              | RangeGenerator(start, countExpr) ->
                      // count < 0 || (int64 start + int64 count) - 1L > int64 Int32.MaxValue
                      let countVarExpr = var "___count___" typeof<int>
                      let countVarInitExpr = assign countVarExpr countExpr
                      let countCheckExpr = 
  
negative.code:                             (loop (block [] [incCurrExpr; branchExpr ; context.AccExpr]) context.BreakLabel context.ContinueLabel)
                      block (countVarExpr :: currVarExpr :: context.VarExprs) [block [] context.InitExprs; countVarInitExpr; currVarInitExpr; loopExpr; context.ReturnExpr ]
              | RepeatGenerator(elementExpr, countExpr) ->
                      let countExpr = optimize countExpr
                      let t = elementExpr.Type
                      let countVarExpr = var "___count___" typeof<int>
                      let countVarInitExpr = assign countVarExpr countExpr
  