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

Is a false eqeqeq being ignored in latest version?

Expand Messages
  • Jim Auldridge
    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
    Message 1 of 5 , Aug 30, 2010
    View Source
    • 0 Attachment
      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
    • Harry Whitfield
      ... if (2 == 2) { } I ve just run the above in Widget Tester and in the version of JSLint at http://www.JSLint.com/ . Both use edition 2010-08-28. I am seeing
      Message 2 of 5 , Aug 30, 2010
      View Source
      • 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 just run the above in Widget Tester and in the version of JSLint at http://www.JSLint.com/ .

        Both use edition 2010-08-28.

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

        The current version of Widget Tester is at http://tinyurl.com/5unocx and at http://widgets.yahoo.com/file/download/widget-tester/mac/version/9937 or http://widgets.yahoo.com/file/download/widget-tester/win/version/9937 .

        Harry.
      • 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 3 of 5 , Aug 30, 2010
        View Source
        • 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 4 of 5 , Aug 30, 2010
          View Source
          • 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 5 of 5 , Aug 30, 2010
            View Source
            • 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.