Classification: UNCLASSIFIED ... I use that logic to determine if a value, regardless of type, can become a number type. For instance: a = "4"; if (Number(a)...
1885
urangatang@...
urangatang...
Feb 3, 2011 5:28 pm
... I'm a little confused because I think K&R style should have functions braced distinctly from statements, but JSLint does not allow this with the strict...
1886
urangatang@...
urangatang...
Feb 3, 2011 5:31 pm
I get an error when attempting to test out the continue option: /*jslint continue: true */ "use strict"; Error: Problem at line 1 character 10: Unexpected...
1887
Luke Page
page.luke...
Feb 3, 2011 5:35 pm
In these cases isn't it clearer .. 1. first if your input can be string or number, convert to a number (so === can be used etc) 2. check if the number isNaN 3....
1888
Cheney, Edward A SSG ...
sandyhead25
Feb 3, 2011 6:12 pm
Classification: UNCLASSIFIED ... There is no reason to change a variable type to number if mathematical calculations are not being performed. More often than...
1889
Cheney, Edward A SSG ...
sandyhead25
Feb 3, 2011 6:21 pm
Classification: UNCLASSIFIED ... A digital signature is not false security. It is the preferred means of validating authenticity. A digital signature should...
1890
Rob Richardson
erobrich@...
Feb 3, 2011 6:22 pm
This seems clearer: a = "4"; if (isNaN(Number(a)) { b = "4a"; if (isNaN(Number(b)) { ... but as soon as you call Number(..), you have already converted it to a...
1891
Douglas Crockford
douglascrock...
Feb 3, 2011 6:30 pm
... Thanks. Please try it now....
1892
Douglas Crockford
douglascrock...
Feb 3, 2011 6:34 pm
... Nor should it be confused with security or safety. A signature does not turn dangerous code into safe code. The problem here isn't authenticity, it is...
1893
Cheney, Edward A SSG ...
sandyhead25
Feb 3, 2011 6:38 pm
Classification: UNCLASSIFIED ... That is only partially accurate. You do perform a conversion every time you use Number() or String(), but as long you do...
1894
Jakob Kruse
thekrucible
Feb 3, 2011 6:46 pm
... I think the moral of the story is that you should use isNaN to test whether some number is NaN. Testing for NaN by comparing with itself is quirky and...
1895
mathew
metavariable
Feb 3, 2011 6:46 pm
... So you're saying we shouldn't trust you not to misuse your power? mathew -- <URL:http://www.pobox.com/~meta/> [Non-text portions of this message have been...
1896
Cheney, Edward A SSG ...
sandyhead25
Feb 3, 2011 6:48 pm
Classification: UNCLASSIFIED ... Security does not imply safety. Security merely implies the degree of hardness from distractions to the objective. My...
1897
Cheney, Edward A SSG ...
sandyhead25
Feb 3, 2011 6:48 pm
Classification: UNCLASSIFIED ... Security does not imply safety. Security merely implies the degree of hardness from distractions to the objective. My...
1898
Douglas Crockford
douglascrock...
Feb 3, 2011 7:13 pm
... No, I am saying that trust is important, and that a signature is not a substitute for trust. It can in some cases stand as a token of trust. But a...
1899
Frederik Dohr
ace_noone
Feb 3, 2011 8:02 pm
... Indeed, I hadn't quite thought that through - thanks for being thorough! ... This was relatively straightforward (I think... ): ...
1900
John Hawkinson
john.hawkinson
Feb 4, 2011 6:13 am
Hi, all. I'd like to use JSLint on Adobe's ExtendScript, a JavaScript variant that's used to script Adobe Creative Suite products, like InDesign, PhotoShop,...
1901
Jakob Kruse
thekrucible
Feb 4, 2011 7:32 am
John, If the statements you mention here are the only quirks, then you could build (and possibly publish) your own “JSLint runner for ExtendScript” which...
1902
abyssoft@...
abyssoft...
Feb 4, 2011 4:35 pm
I was looking in to it for you, but with the snippet provided I was unable to reproduce....
1903
abyssoft@...
abyssoft...
Feb 4, 2011 4:45 pm
... try using indent: 0...
1904
Chris
altearius
Feb 4, 2011 6:26 pm
... Hello, I deal with a similar problem. I am responsible for maintaining a large amount of ASP Classic code, much of which is written in JScript. This...
1905
david.herren
Feb 7, 2011 5:03 pm
I love JSLint but it's been buggy lately. One of the problems appears to be that optional parameters for a time were made mandatory. This caused me to update...
1906
Douglas Crockford
douglascrock...
Feb 7, 2011 5:36 pm
... I am not aware of bugs in JSLint. If you find any, I would be very happy to hear about them. I have made improvements to JSLint. Accepting those...
1907
Joshua Bell
inexorabletash
Feb 7, 2011 8:21 pm
The "indexOf polyfill" (as the kids would call it today) sample shown on https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/indexOf ...
1908
Douglas Crockford
douglascrock...
Feb 7, 2011 11:19 pm
JSLint now tolerates new Array(number), but rejects all other forms of new Array. new Array(number) was previously rejected because a large part of our...
1909
DH
david.herren
Feb 10, 2011 7:10 pm
The JSLint options have been acting weird over the past few weeks and I finally reproducible bug that appears both in IE 8.0.6001.18702 and Firefox 3.6.13 in...
Thanks for all the suggestions. I thought I should write back with an update, perhaps useful to others in the same boat. I did indeed end up with...
1912
Merlin
harry152566
Feb 11, 2011 12:28 pm
In response to recently expressed concerns: "Widget Tester by its very nature requires full access to the user's computer. Recent versions have had an option...
1913
Douglas Crockford
douglascrock...
Feb 11, 2011 2:12 pm
... JSLINT likes being in a sandbox. All it needs is a source text. It does not need, and should not be given, access to the network, the file system, or the...