We are defining the function inside of another function to avoid creating global variables.
332579
function () {

// Parse a number value.

            var number,
                string = '';

            if (ch === '-') {
                string = '-';
                next('-');
            }
            while (ch >= '0' && ch <= '9') {
                string += ch;
                next();
            }
            if (ch === '.') {
                string += '.';
                while (next() && ch >= '0' && ch <= '9') {
                    string += ch;
                }
            }
            if (ch === 'e' || ch === 'E') {
                string += ch;
                next();
                if (ch === '-' || ch === '+') {
                    string += ch;
                    next();
                }
                while (ch >= '0' && ch <= '9') {
                    string += ch;
                    next();
                }
            }

            number = +string;

            if (!isFinite(number)) {
                error("Bad number");
            } else {
                
                // means JS rounded or truncated number, too big
                if (number.toString() !== string) {
                    try {
                        return new BigNumber(string);
                    } catch (e) {
                        // if fails, fallback to default behavior
                    }
                }

                return number;
            }
        }
1147445
function unsetLocalVariables()
    {
        foreach ( $this->CurrentLocalVariablesNames as $ns => $vars )
        {
            foreach ( $vars as $var => $val )
                $this->unsetLocalVariable( $var, $ns );
        }
    }
889264
function (v) {
            var i = this.__identifierInputMethod;
            v = v.toString(this);
            return !isUndefinedOrNull(i) ?
                isFunction(v[i]) ?
                    v[i]() :
                    isFunction(comb[i]) ?
                        comb[i](v)
                        : v
                : v;
        }
1191879
function (a) {

      // inlined from peanut, maybe a micro-optimisation?
      var constant_a = function () { return a; };

      var self = function () {
        // can't Fun.constant this one
        return me;
      };

      var map = function (f) {
        return some(f(a));
      };

      var bind = function (f) {
        return f(a);
      };

      var me = {
        fold: function (n, s) { return s(a); },
        is: function (v) { return a === v; },
        isSome: always,
        isNone: never,
        getOr: constant_a,
        getOrThunk: constant_a,
        getOrDie: constant_a,
        or: self,
        orThunk: self,
        map: map,
        ap: function (optfab) {
          return optfab.fold(none, function(fab) {
            return some(fab(a));
          });
        },
        each: function (f) {
          f(a);
        },
        bind: bind,
        flatten: constant_a,
        exists: bind,
        forall: bind,
        filter: function (f) {
          return f(a) ? me : NONE;
        },
        equals: function (o) {
          return o.is(a);
        },
        equals_: function (o, elementEq) {
          return o.fold(
            never,
            function (b) { return elementEq(a, b); }
          );
        },
        toArray: function () {
          return [a];
        },
        toString: function () {
          return 'some(' + a + ')';
        }
      };
      return me;
    }
170906
function () {
          if (this === global || !exists(this)) {
            throw new TypeError('this is null or not defined for ' + method)
          }
          var args = Array.prototype.slice.call(arguments)
          args.unshift(this) // sets first arg as object instance
          return method.apply(this, args)
        }
1283246
function spyGlobalVar(varName, callback) {
			phantomas.log('spy: attaching to %s global variable', varName);

			window.__defineSetter__(varName, function(val) {
				phantomas.log('spy: %s global variable has been defined', varName);

				spiedGlobals[varName] = val;
				callback(val);
			});

			window.__defineGetter__(varName, function() {
				return spiedGlobals[varName] || undefined;
			});

		}
270100
private boolean isCandidateFunction(Function fn) {
    // Don't inline exported functions.
    String fnName = fn.getName();
    if (compiler.getCodingConvention().isExported(fnName)) {
      // TODO(johnlenz): Should we allow internal references to be inlined?
      // An exported name can be replaced externally, any inlined instance
      // would not reflect this change.
      // To allow inlining we need to be able to distinguish between exports
      // that are used in a read-only fashion and those that can be replaced
      // by external definitions.
      return false;
    }

    // Don't inline this special function
    if (compiler.getCodingConvention().isPropertyRenameFunction(fnName)) {
      return false;
    }

    Node fnNode = fn.getFunctionNode();
    return injector.doesFunctionMeetMinimumRequirements(fnName, fnNode);
  }
1312351
private function _processFunctionStart() {
		$this->_inFunction = true;
		$this->_cyclomaticComplexity = 1;
		$this->_npathComplexity = 0;
		$this->_functionLevel = $this->statementStack->count();
		$this->_justAfterFuncStmt = false;

		$this->_functionStartLine = $this->lineNumber;

		// Check the position of the open curly after the function declaration
		if ($this->_isActive('funcDefinitionOpenCurly')) {
			$pos = $this->_config->getTestProperty('funcDefinitionOpenCurly', 'position');

			$currentToken = $this->tokenizer->getCurrentToken();
			$previousToken = $this->tokenizer->peekPrvsValidToken();

			if ($pos === NEW_LINE) {
				// The previous token should be on the previous line
				$isPosOk = ($previousToken->line < $currentToken->line);
			} else {
				// The previous token should be on the same line
				$isPosOk = ($previousToken->line === $currentToken->line);
			}

			if (!$isPosOk) {
				$tmp = ($pos === SAME_LINE) ? "the previous line." : "a new line.";
				$msg = $this->_getMessage('LEFT_CURLY_POS', $tmp);
				$this->_writeError('funcDefinitionOpenCurly', $msg);
			}
		}
	}
316257
function Stack(global1, local, scope, stack) {
            this.global = global1 != null ? global1 : global;
            this.local = local != null ? local : {};
            this.scope = scope != null ? scope : [];
            this.stack = stack != null ? stack : [];
        }
1101395
function _nom(fun) {
    var src = fun.toString();
    src = src.substr('function '.length);
    var n = src.substr(0, src.indexOf('('));

    if (!L.isFunction(fun)) fail("Cannot derive the name of a non-function.");
    if (fun.name && (fun.name === n)) return fun.name;
    if (n) return n;
    fail("Anonymous function has no name.");
  }
90163
function() {

      // Not as nice as arguments.callee but at least we'll only have on reference.
      var _this = this;
      var extend = function() { return _this.extend.apply(_this, arguments); };

      // If we don't have enough arguments to do anything, just return an object
      if (arguments.length < 2) {
        return {};
      }

      // Argument shuffling
      if (typeof arguments[0] !== 'boolean') {
        Array.prototype.unshift.call(arguments, true);
      }

      // Remove the variables we need from the arguments stack.
      var deep = Array.prototype.shift.call(arguments);
      var one = Array.prototype.shift.call(arguments);
      var two = Array.prototype.shift.call(arguments);

      // If we have more than two objects to merge
      if (arguments.length > 0) {

        // Push two back on to the arguments stack, it's no longer special.
        Array.prototype.unshift.call(arguments, two);

        // While we have any more arguments, call extend with the initial obj and the next argument
        while (arguments.length > 0) {
          two = Array.prototype.shift.call(arguments);

          if (typeof two !== 'object') continue;

          one = extend(deep, one, two);
        }

        return one;
      }

      // Do some checking to force one and two to be objects
      if (typeof one !== 'object') {
        one = {};
      }

      if (typeof two !== 'object') {
        two = {};
      }

      // Loop through the second object to merge it with the first
      for (var key in two) {
        // If this key actually belongs to the second argument
        if (Object.prototype.hasOwnProperty.call(two, key)) {
          var current = two[key];

          if (deep && typeof current === 'object' && typeof one[key] === 'object') {
            // Deep copy
            one[key] = extend(one[key], current);
          } else {
            one[key] = current;
          }
        }
      }

      return one;
    }
1325457
private Optional<ImmutableTerm> combineDefinitions(ImmutableTerm d1, ImmutableTerm d2,
                                                       VariableGenerator variableGenerator,
                                                       boolean topLevel) {
        if (d1.equals(d2)) {
            return Optional.of(
                    // Top-level var-to-var must not be renamed since they are about projected variables
                    (d1.isGround() || (topLevel && (d1 instanceof Variable)))
                            ? d1
                            : replaceVariablesByFreshOnes((NonGroundTerm)d1, variableGenerator));
        }
        else if (d1 instanceof Variable)  {
            return topLevel
                    ? Optional.empty()
                    : Optional.of(variableGenerator.generateNewVariableFromVar((Variable) d1));
        }
        else if (d2 instanceof Variable)  {
            return topLevel
                    ? Optional.empty()
                    : Optional.of(variableGenerator.generateNewVariableFromVar((Variable) d2));
        }
        else if ((d1 instanceof ImmutableFunctionalTerm) && (d2 instanceof ImmutableFunctionalTerm)) {
            ImmutableFunctionalTerm functionalTerm1 = (ImmutableFunctionalTerm) d1;
            ImmutableFunctionalTerm functionalTerm2 = (ImmutableFunctionalTerm) d2;

            /*
             * Different function symbols: stops the common part here
             */
            if (!functionalTerm1.getFunctionSymbol().equals(functionalTerm2.getFunctionSymbol())) {
                return topLevel
                        ? Optional.empty()
                        : Optional.of(variableGenerator.generateNewVariable());
            }
            else {
                ImmutableList<? extends ImmutableTerm> arguments1 = functionalTerm1.getTerms();
                ImmutableList<? extends ImmutableTerm> arguments2 = functionalTerm2.getTerms();
                if (arguments1.size() != arguments2.size()) {
                    throw new IllegalStateException("Functions have different arities, they cannot be combined");
                }

                ImmutableList.Builder<ImmutableTerm> argumentBuilder = ImmutableList.builder();
                for (int i = 0; i < arguments1.size(); i++) {
                    // Recursive
                    ImmutableTerm newArgument = combineDefinitions(arguments1.get(i), arguments2.get(i),
                            variableGenerator, false)
                            .orElseGet(variableGenerator::generateNewVariable);
                    argumentBuilder.add(newArgument);
                }
                return Optional.of(termFactory.getImmutableFunctionalTerm(functionalTerm1.getFunctionSymbol(),
                        argumentBuilder.build()));
            }
        }
        else {
            return Optional.empty();
        }
    }
681397
function (out) {
            out.newBlock("main", 0);
            out.newBlock("classDefinition", 0);
            out.newBlock("prototype", 2);
            out.newBlock("globalVars", 5);
            out.newBlock("initTemplate", 3);
            out.newBlock("classInit", 3);
        }
373239
def if_else( action1, action2 )
      @function << "#{@function.indent}if ( #{self} ) {\n"
      @function.indent_offset +1
      action1.call
      @function.indent_offset -1
      @function << "#{@function.indent}} else {\n"
      @function.indent_offset +1
      action2.call
      @function.indent_offset -1
      @function << "#{@function.indent}};\n"
      self
    end
1137178
def visit_FunctionDef(self, node):
        
        # Ensure there are no nested functions.
        assert self.current_function is None
        self.current_function = node
        self.naming = dict()
        self.in_cond = False  # True when we are in a if, while or for
        self.generic_visit(node)
        self.current_function = None
153466
function Name() {
    /**
     * The prefix value
     * @member
     */
    this.prefix = null;
    /**
     * The first value
     * @member
     */
    this.first = null;
    /**
     * The middle value
     * @member
     */
    this.middle = null;
    /**
     * The last value
     * @member
     */
    this.last = null;
    /**
     * The suffix value
     * @member
     */
    this.suffix = null;

}
597576
function createChainedFunction(one, two) {
  var hasOne = typeof one === 'function';
  var hasTwo = typeof two === 'function';

  if (!hasOne && !hasTwo) {return null;}
  if (!hasOne) {return two;}
  if (!hasTwo) {return one;}

  return function chainedFunction() {
    one.apply(this, arguments);
    two.apply(this, arguments);
  };
}