aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/preamble.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/preamble.js b/src/preamble.js
index 431a3c27..ae58e7e0 100644
--- a/src/preamble.js
+++ b/src/preamble.js
@@ -401,7 +401,7 @@ var cwrap, ccall;
return ret;
}
- var sourceRegex = /^function\s\(([^)]*)\)\s*{\s*([^*]*?)[\s;]*(?:return\s*(.*?)[;\s]*)?}$/;
+ var sourceRegex = /^function\s*\(([^)]*)\)\s*{\s*([^*]*?)[\s;]*(?:return\s*(.*?)[;\s]*)?}$/;
function parseJSFunc(jsfunc) {
// Match the body and the return value of a javascript function source
var parsed = jsfunc.toString().match(sourceRegex).slice(1);