Edit in JSFiddle

(function(x){
  if(x < 10){
    return arguments.callee(x+1);
  }else{
    console.debug(x);
  }
})(0);