aboutsummaryrefslogtreecommitdiff
path: root/src/runtime.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime.js')
-rw-r--r--src/runtime.js11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/runtime.js b/src/runtime.js
index 51fbbdb3..6a251c46 100644
--- a/src/runtime.js
+++ b/src/runtime.js
@@ -323,6 +323,17 @@ var Runtime = {
}
},
+ funcWrappers: {},
+
+ getFuncWrapper: function(func) {
+ if (!Runtime.funcWrappers[func]) {
+ Runtime.funcWrappers[func] = function() {
+ FUNCTION_TABLE[func].apply(null, arguments);
+ };
+ }
+ return Runtime.funcWrappers[func];
+ },
+
#if RUNTIME_DEBUG
debug: true, // Switch to false at runtime to disable logging at the right times