Live data from Hacker News

Wat

destroyallsoftware.com

31–40 of 103 posts

Re: Wat

#31
post #27
post #21

Earlier quoted context omitted.

JavaScript has a strong design principle of not throwing errors for syntactically valid constructs. The most common way it accomplishes this is through gratuitous use of implicit type conversions. It does a lot of implicit string conversions, even on things that you would think of as error codes, like undefined or NaN. JavaScript went down the path of being a "forgiving" language because it was intended to provide "e…

I wish there was some technology that could take a bunch of code and warn you of common errors before having it execute and 'noisily crash the page it was on'. Maybe someday...

Sarcasm doesn't work here. It's not reasonable to expect proper testing or usage of an IDE by ordinary citizens authoring HTML. Specially in 1996.

Re: Wat

#34
post #19

Earlier quoted context omitted.

It's jsc (comes with Webkit) - it's present on Mac OS X by default in /System/Library/Frameworks/JavaScriptCore.framework/Versions/A/Resources/jsc You can just do: sudo ln /System/Library/Frameworks/JavaScriptCore.framework/Versions/A/Resources/jsc /bin/jsc To be able to invoke it directly from the command line.

Thanks, I'll look how to get this working on linux.

Alternatively, you could use Rhino Shell (https://developer.mozilla.org/en/Rhino_Shell) - it even supports tab completion!

Re: Wat

#35
Guess I'm not a hacker? It's like watching a rerun I've seen twice over with the laugh track turned up to 11 (just to clarify, someone said it was a repost but I haven't seen it before).

Re: Wat

#36
post #19

Does anybody knows which is the javascript interpreter he is using on the screencast?

It's jsc (comes with Webkit) - it's present on Mac OS X by default in /System/Library/Frameworks/JavaScriptCore.framework/Versions/A/Resources/jsc You can just do: sudo ln /System/Library/Frameworks/JavaScriptCore.framework/Versions/A/Resources/jsc /bin/jsc To be able to invoke it directly from the command line.

That is extremely useful. Do you know if any testing libraries or other useful functionality have been built around this?

I suppose if you are a WebKit-only developer, this utility could have many useful applications.

Re: Wat

#37
Interestingly the results from jsc, are different from node.js:

----- jsc ------

   [] + []
   
   > [] + {}
   [object Object]
   > {} + []
   0
   > {} + {}
   NaN
------ node.js ------

   > [] + []
   ''
   > [] + {}
   '[object Object]'
   > {} + []
   '[object Object]'
   > {} + {}
   '[object Object][object Object]'

Re: Wat

#39
Wow, this title suffers from some serious editorializing. What's next, "10 ways to know if you are a hacker? (cracked.com)"

Re: Wat

#40

What presentation software is he using? Is he just jumping from his slide deck into a shell?

It's Keynote. I recorded those sessions as screencasts, then sliced them into tiny pieces so I can advance them perfectly with my talking. There are 37 slides in that four-minute talk. In some cases, the slices are only two or three frames long.
Post reply on HN