From e5e69d9b90850eb653883f52c76e28dd870ee067 Mon Sep 17 00:00:00 2001 From: Misko Hevery Date: Tue, 7 Dec 2010 11:47:24 -0800 Subject: Remove RegExp parser - RegExp parser is rearly used, feature, and one should not have RegExps in views anyways, so we are removing it BACKWARD INCOMPATIBLE CHANGE!!! --- src/Scope.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Scope.js') diff --git a/src/Scope.js b/src/Scope.js index 203507a3..27df770d 100644 --- a/src/Scope.js +++ b/src/Scope.js @@ -66,7 +66,7 @@ function getterFn(path){ code += 'if(!s) return s;\n' + 'l=s;\n' + 's=s' + key + ';\n' + - 'if(typeof s=="function") s = function(){ return l'+key+'.apply(l, arguments); };\n'; + 'if(typeof s=="function" && !(s instanceof RegExp)) s = function(){ return l'+key+'.apply(l, arguments); };\n'; if (key.charAt(1) == '$') { // special code for super-imposed functions var name = key.substr(2); -- cgit v1.2.3