1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/js/src/tests/ecma_5/extensions/regress-bug629723.js Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,16 @@ 1.4 +function f(foo) { 1.5 + "use strict"; 1.6 + foo.bar; 1.7 +} 1.8 + 1.9 +var actual; 1.10 +try { 1.11 + f(); 1.12 + actual = "no error"; 1.13 +} catch (x) { 1.14 + actual = (x instanceof TypeError) ? "type error" : "some other error"; 1.15 + actual += (/use strict/.test(x)) ? " with directive" : " without directive"; 1.16 +} 1.17 + 1.18 +reportCompare("type error without directive", actual, 1.19 + "decompiled expressions in error messages should not include directive prologues");