Index: compiler/lib/implementation/core.js |
diff --git a/compiler/lib/implementation/core.js b/compiler/lib/implementation/core.js |
index 12456e177d59536d665a777addf1551aa8f82320..bfdc313cb8efb255cd1993a17717290b0d5e8cc1 100644 |
--- a/compiler/lib/implementation/core.js |
+++ b/compiler/lib/implementation/core.js |
@@ -156,19 +156,26 @@ function $inherits(child, parent) { |
* @param {...*} var_args |
*/ |
function $bind(fn, thisObj, var_args) { |
+ var func; |
if (arguments.length > 2) { |
var boundArgs = Array.prototype.slice.call(arguments, 2); |
- return function() { |
+ func = function() { |
// Prepend the bound arguments to the current arguments. |
var newArgs = Array.prototype.slice.call(arguments); |
Array.prototype.unshift.apply(newArgs, boundArgs); |
return fn.apply(thisObj, newArgs); |
}; |
} else { |
- return function() { |
+ func = function() { |
return fn.apply(thisObj, arguments); |
}; |
} |
+ if(fn.$lookupRTT) { |
+ func.$lookupRTT = function() { |
+ return fn.$lookupRTT.apply(thisObj, arguments); |
+ }; |
+ } |
+ return func; |
} |
/** |