Increments context variables
506778
def incr(**vars):
    
    for k, v in vars:
        current_context.vars.setdefault(k, 0)
        current_context[k] += v
543749
def increment(key, amount = 1, options = {})
      value = Utils.to_int(load(key, options)) + amount
      store(key, value.to_s, options)
      value
    end
1058503
def update_context(self, ctx):
        
        assert isinstance(ctx, dict)
        ctx[str(self.context_id)] = self.value
1193828
def increment(self):
    """"""
    self.value += self.increment_size
    return self.value - self.increment_size
587956
function setupContext(node) {
  if (node.type === 'Program') {
    node.context = GLOBAL_CONTEXT;
    return;
  }

  // default context is the parent context
  node.context = node.parent.context;

  // IIFE (function(win){ win.x = 'x' }(window))
  if ( isIIFE(node) ) {
    var args = node.arguments;
    var params = node.callee.params;
    if (args.length && params.length) {
      params.forEach(function(param, i){
        var arg = args[i] || {};
        var init = arg.type === 'ThisExpression'? node.context : arg.name;
        addVarToScope(node, {
          name: param.name,
          init: init
        });
      });
    }
    node.context = node.parent.context;
    return;
  }

  // function.call and function.apply change the context
  if (node.type === 'CallExpression' &&
      node.callee.type === 'MemberExpression' &&
      (node.callee.property.name === 'call' || node.callee.property.name === 'apply')) {

    var arg = node.arguments[0];
    var ctx = (!arg || arg.type === 'ThisExpression' ||
      (arg.type === 'Literal' && arg.value == null))? GLOBAL_CONTEXT : CUSTOM_CONTEXT;

    addVarToScope(node, {
      name: 'this',
      init: ctx,
      pointer: ctx
    });

    node.context = ctx;
    return;
  }

  if ((node.type === 'FunctionExpression' || node.type === 'FunctionDeclaration') && !isIIFE(node.parent)) {
    // params are "free variables"
    node.params.forEach(function(param){
      addVarToScope(node, {
        name: param.name,
        init: undefined
      });
    });

    // by default we assume that all properties of object use "this" to referece
    // itself even tho this might not be true depending on how the method is
    // called
    if (node.parent.type === 'Property' ||
        (node.parent.type === 'AssignmentExpression' &&
         node.parent.left.type === 'MemberExpression')) {
      node.context = CUSTOM_CONTEXT;
      return;
    }
  }

}
75332
function calculate(control, N, context) {
    var result = this.values.reduce(function(acc, el) {
      if (acc) {
        return context.op(acc, el)
      } else {
        return el
      }
    })
    this.$push('result = ' + result + '\n')
    control.next(N.start)
  }
1368606
def context_lookup(self, vars):
        
        while isinstance(vars, IscmExpr):
            vars = vars.resolve(self.context)
        #
        for (k,v) in vars.items():
            if isinstance(v, IscmExpr):
                vars[k] = v.resolve(self.context)
        return vars
491769
def append(self, context, data):
        
        return ContextStack(self._contexts + [context], self._data + [data])
263066
function(context) {
        var contextObj = {};
        for(var i=0; i<context.length; i++) {
            if(context[i] !== '0') {
                contextObj[this.dimensionsList[i]] = this.numberToValue[context[i]];
            }
        }
        return contextObj;
    }
376842
public void setContextLimits(int contextStart, int contextLimit) {
        if(contextStart<0) {
            this.contextStart=0;
        } else if(contextStart<=rep.length()) {
            this.contextStart=contextStart;
        } else {
            this.contextStart=rep.length();
        }
        if(contextLimit<this.contextStart) {
            this.contextLimit=this.contextStart;
        } else if(contextLimit<=rep.length()) {
            this.contextLimit=contextLimit;
        } else {
            this.contextLimit=rep.length();
        }
        reachedLimit=false;
    }
89397
private static Object add(ExecutionContext context, Object lhs, Object rhs) {
        if (lhs instanceof String || rhs instanceof String) {
            return(Types.toString(context, lhs) + Types.toString(context, rhs));
        }

        Number lhsNum = Types.toNumber(context, lhs);
        Number rhsNum = Types.toNumber(context, rhs);

        if (Double.isNaN(lhsNum.doubleValue()) || Double.isNaN(rhsNum.doubleValue())) {
            return(Double.NaN);
        }

        if (lhsNum instanceof Double || rhsNum instanceof Double) {
            if (lhsNum.doubleValue() == 0.0 && rhsNum.doubleValue() == 0.0) {
                if (Double.compare(lhsNum.doubleValue(), 0.0) < 0 && Double.compare(rhsNum.doubleValue(), 0.0) < 0) {
                    return(-0.0);
                } else {
                    return(0.0);
                }
            }

            return(lhsNum.doubleValue() - rhsNum.doubleValue());
        }

        return(lhsNum.longValue() + rhsNum.longValue());
    }
386917
def add_variables_to_context(generator):
    ''''''
    context = generator.context             # minimize attr lookup
    context['relpath_to_site'] = relpath_to_site
    context['main_siteurl'] = _MAIN_SITEURL
    context['main_lang'] = _MAIN_LANG
    context['lang_siteurls'] = _SITE_DB
    current_lang = generator.settings['DEFAULT_LANG']
    extra_siteurls = _SITE_DB.copy()
    extra_siteurls.pop(current_lang)
    context['extra_siteurls'] = extra_siteurls
798488
def process_def(exp, parent)
      inside_new_context(current_context.method_context_class, exp, parent) do
        increase_statement_count_by(exp.body)
        process(exp)
      end
    end
162717
public function increment($context = null)
    {
        $poolUsage = $this->cache->get(self::CACHE_KEY) ?: 0;
        $this->logPoolUsage($poolUsage, $context);
        $this->cache->set(self::CACHE_KEY, $poolUsage + 1, $this->lifetime);
    }
831765
public <T2 extends T> void incrementAll(Counter<T2> other) {
        for (T2 element: other.keySet()) {
            double cnt = other.getCount(element);
            incrementCount(element, cnt);
        }
    }
448038
def increment(self, key, value=1):
        
        return self._redis.incrby(self._prefix + key, value)
1372898
public static void enrichContext(Context context) {
		context.setPostProperty(Context.MEMORY_TOTAL, Runtime.getRuntime().totalMemory());
		context.setPostProperty(Context.MEMORY_FREE, Runtime.getRuntime().freeMemory());
		context.setPostProperty(Context.MEMORY_USED, Runtime.getRuntime().totalMemory() - Runtime.getRuntime().freeMemory());
	}