7 The use of `arguments.caller` and `arguments.callee` make several code optimizations impossible. They have been deprecated in future versions of JavaScript and their use is forbidden in ECMAScript 5 while in strict mode.
11 var callee = arguments.callee;
17 This rule is aimed at discouraging the use of deprecated and sub-optimal code by disallowing the use of `arguments.caller` and `arguments.callee`. As such, it will warn when `arguments.caller` and `arguments.callee` are used.
19 Examples of **incorrect** code for this rule:
24 /*eslint no-caller: "error"*/
31 arguments.callee(n - 1);
34 [1,2,3,4,5].map(function(n) {
35 return !(n > 1) ? 1 : arguments.callee(n - 1) * n;
41 Examples of **correct** code for this rule:
46 /*eslint no-caller: "error"*/
56 [1,2,3,4,5].map(function factorial(n) {
57 return !(n > 1) ? 1 : factorial(n - 1) * n;