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

09-16-2010 version has bug

Expand Messages
  • Harry Whitfield
    The newcap setting is working correctly in the 2010-09-16 edition that I am using in Widget Tester. I download the file from http://www.JSLint.com/jslint.js .
    Message 1 of 9 , Sep 17, 2010
    View Source
    • 0 Attachment
      The newcap setting is working correctly in the 2010-09-16 edition that I am using in Widget Tester.

      I download the file from http://www.JSLint.com/jslint.js .

      Harry,
    • Harry Whitfield
      I ve also tested the newcap option on the web version at http://www.JSLint.com/ . That is also working correctly. Harry.
      Message 2 of 9 , Sep 17, 2010
      View Source
      • 0 Attachment
        I've also tested the newcap option on the web version at http://www.JSLint.com/ .

        That is also working correctly.

        Harry.
      • abyssoft@ymail.com
        @harry152566, I m using the Web version one too and yes I ve cleared my cache and newcap is even when manually set to false. Just tested it again and I m
        Message 3 of 9 , Sep 17, 2010
        View Source
        • 0 Attachment
          @harry152566,

          I'm using the Web version one too and yes I've cleared my cache and newcap is even when manually set to false.
          Just tested it again and I'm getting the same response

          Problem at line 432 character 25: A constructor name should start with an uppercase letter.

          and I have

          /*jslint white: true, browser: true, devel: true, windows: true, sub: true, undef: true, newcap: false, nomen: true, eqeqeq: true, plusplus: true, bitwise: true, regexp: true, immed: true, strict: true */
          as my second comment in my file.
        • douglas@crockford.com
          If JSLint sees use strict ; then it turns on option.newcap for you.
          Message 4 of 9 , Sep 17, 2010
          View Source
          • 0 Attachment
            If JSLint sees "use strict"; then it turns on option.newcap for you.
          • abyssoft@ymail.com
            Thats not a good idea Douglas, I would still like very much to be able to have that one option off as I have to use a 3rd party API that is not strict. and
            Message 5 of 9 , Sep 17, 2010
            View Source
            • 0 Attachment
              Thats not a good idea Douglas, I would still like very much to be able to have that one option off as I have to use a 3rd party API that is not strict. and that is the primary area of contetion and I don't want my screen mucked up by in this case erroneous errors.
            • douglas@crockford.com
              You should never label non-strict code as strict. There is a contract that comes with use strict ;.JSLint helps you to honor that contract.
              Message 6 of 9 , Sep 17, 2010
              View Source
              • 0 Attachment
                You should never label non-strict code as strict. There is a contract that comes with "use strict";.JSLint helps you to honor that contract.
              • abyssoft@ymail.com
                ... Ok given that constraint what is the best set of options that will get me as close to strict as possible and still permit me to use class constructor names
                Message 7 of 9 , Sep 17, 2010
                View Source
                • 0 Attachment
                  --- In jslint_com@yahoogroups.com, douglas@... wrote:
                  >
                  > You should never label non-strict code as strict. There is a contract that comes with "use strict";.JSLint helps you to honor that contract.
                  >


                  Ok given that constraint what is the best set of options that will get me as close to strict as possible and still permit me to use class constructor names that start with lowercase? I'm wanting to maintain as close to strict as I can, however I have no control over whether we use the 3rd party API at my work. It is required use for the project I'm on.

                  I am most grateful for any assistance, thank you in advance.
                • Frederik Dohr
                  ... You might be able to create a local alias for the API s constructors: (function() { var Foo = lib.foo; var instance = new Foo(); })(); -- F.
                  Message 8 of 9 , Sep 18, 2010
                  View Source
                  • 0 Attachment
                    > use class constructor names that start with lowercase? I'm wanting
                    > to maintain as close to strict as I can, however I have no control
                    > over whether we use the 3rd party API

                    You might be able to create a local alias for the API's constructors:

                    (function() {

                    var Foo = lib.foo;

                    var instance = new Foo();

                    })();


                    -- F.
                  Your message has been successfully submitted and would be delivered to recipients shortly.