Function.prototype.bind2=function(context) {
????varself=this;
????//獲取bind2函數(shù)從第二個(gè)參數(shù)到最后一個(gè)參數(shù)
????var args=Array.prototype.slice.call(arguments,1);
????return function() {
????//這個(gè)時(shí)候的arguments是指bind返回的函數(shù)傳入的參數(shù)????
????var bindArgs=Array.prototype.slice.call(arguments);
????self.apply(context,args.concat(bindArgs));?
?????}
}