Strict mode

May 2, 2012 at 6:59 AM

Hi,
Are there any plans to detect strict mode by looking for "use strict" in blocks, and trigger strict mode on a block level? It would be quite nice since you could mix strict tests and "unstrict" tests in the same js-file.

What I mean is something like this:

// This should fail
(function() {
"use strict";
try {
  undeclared_variable = 2;
} catch(e) {}
})();

// This shouldn't fail
(function() {
try {
  undeclared_variable = 2;
} catch(e) {}
})();

May 3, 2012 at 3:31 PM

yes, this is planned, but jint needs a serious redesign to be able to handle strict mode completely.

May 4, 2012 at 3:25 PM

Sounds nice. Are you looking for people to help out? I'd be interested in contributing if you need it.

May 17, 2012 at 7:49 PM

Yes, any help is appreciated, if you want to contribute to Jint, please contact me.

May 19, 2012 at 6:50 AM

How do I contact you? It says on your profile that you prefer not to be contacted directly.

May 19, 2012 at 4:31 PM

sorry, I missed this option, but now you should be able to.