On 2017-10-18 4:51 AM, Mark Banner wrote:
I expect that this will find a number of lurking errorsy, so we may want
to migrate code progressively, using a directive, say "use strict
moz-platform" and static analysis to help encourage using this directive.
It would definitely be interesting to fail tests on some of the strict failures. I was surprised when I recently turned on the pref again to see how many warnings there were.

Having looked through a few of those, I've just found at least one issue <https://bugzilla.mozilla.org/show_bug.cgi?id=1409691>, though non-critical, and I'm thinking we want to get the no-unused-expressions <https://bugzilla.mozilla.org/show_bug.cgi?id=1409693> rule turned on for ESLint as a result.

Bug 1394556 just enabled strict mode by default for all JSM components in Firefox 57.

Bug 807862 suggested enabling strict mode by default for all builtin Firefox JS, but it was resolved incomplete because of concerns about add-on compatibility. Nosy add-ons could reach up the stack into Firefox JS with code like `arguments.callee.caller.caller.caller.name == "sss_duplicateTab"`. Perhaps that is worth revisiting now that we only support WebExtensions in 57+.
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to