Ensure functions are rebound correctly by shallow cloning the __bindData__ before passing it to createBound. [closes #371]

This commit is contained in:
John-David Dalton
2013-10-20 23:45:53 -07:00
parent f9c34d6808
commit a266e3c898
2 changed files with 21 additions and 0 deletions

View File

@@ -1588,6 +1588,7 @@
}
var bindData = func && func.__bindData__;
if (bindData && bindData !== true) {
bindData = nativeSlice.call(bindData);
if (isBind && !(bindData[1] & 1)) {
bindData[4] = thisArg;
}