Loading ...
Sorry, an error occurred while loading the content.

Re: [jslint] Is a false eqeqeq being ignored in latest version?

Expand Messages
  • Harry Whitfield
    ... if (2 == 2) { } I ve also run the above in Widget Tester using JSLint edition 2010-08-25. I am seeing correct behaviour in both cases, with eqeqeq set to
    Message 1 of 5 , Aug 30, 2010
    • 0 Attachment
      On 30 Aug 2010, at 17:39:48, Jim Auldridge wrote:

      > I was testing a command line version of JSlint and noticed that == and != are disallowed no matter what I set eqeqeq to. i am running the version from 25 Aug 10. To be sure, I tried in the online version at jslint.com and see the same result.
      >
      > I always check the "Disallow == and != " option so this isn't effecting my own code LINTing. But I wondered if I am correct that the flag is currently being ignored or if I am the only one seeing this.
      >
      > Thanks,
      > Jim

      if (2 == 2) {
      }

      I've also run the above in Widget Tester using JSLint edition 2010-08-25.

      I am seeing correct behaviour in both cases, with eqeqeq set to true and false.

      Harry.
    • Jim Auldridge
      Harry, Thanks for your time. In trying a reduced test case on the web version, I do see it working correctly. I will re-run my original test case and update
      Message 2 of 5 , Aug 30, 2010
      • 0 Attachment
        Harry,

        Thanks for your time. In trying a reduced test case on the web version, I do see it working correctly. I will re-run my original test case and update my local version to the Aug 28 version.

        Thanks again,
        Jim
      • Jim Auldridge
        It appears the comparison I had modified for testing purposes was comparing a value to 0, for which the Lint requires === regardless of the setting of eqeqeq.
        Message 3 of 5 , Aug 30, 2010
        • 0 Attachment
          It appears the comparison I had modified for testing purposes was comparing a value to 0, for which the Lint requires === regardless of the setting of eqeqeq. Using a different comparison shows the change of behavior expected when switching that flag.

          Thanks again,
          Jim
        Your message has been successfully submitted and would be delivered to recipients shortly.