Request for feedback on a talk on I'm giving on ES6
domenic at domenicdenicola.com
Sun Oct 21 11:50:21 PDT 2012
Thanks so much for the feedback!
From: Brendan Eich [mailto:brendan at mozilla.org]
Sent: Sunday, October 21, 2012 14:17
> Slide 15 has a comment at the bottom: // error! used a `let` before declaration but this error is about the most-indented log call, the one in the block whose last child is 'let log = Math.log'. Perhaps you are going to talk around it, but it seems to me a comment about an error should go right where the error is.
My intention here was to show that it's a runtime error that doesn't occur until you actually use the function, instead of a static error. You're right though that the stack trace will point to that line instead of the one I have marked. I'll try to come up with a better approach.
> Slide 31 ends with a question: // what about `module.exports= aFunction`?
> Cc'ing dherman.
Yeah, since there will be lots of Node-ers there, and this is their #1 feature, I thought it was important to point out there's no solution for that yet. In general my impression is that modules are undergoing some rethinking and revision, especially about syntax. It's tricky, since even if I cut those slides, I want to e.g. import iterator, but am not sure what syntax to use :-/.
> Slide 33 has a recursive call not in tail position:
Damn, OK, I thought my example met the definition at http://wiki.ecmascript.org/doku.php?id=proposals:proper_tail_calls (in particular "the only thing the caller can do when the call terminates" is "return the value of the call to its own caller"). It sounds like I don't quite understand tail recursion still, so thanks for the link---I'll brush up.
> Slides 34-35: do you want to show a multiline regexp with insignificant whitespace a la Perl's /x regex flag?
Nice, I hadn't heard about that use case but it makes perfect sense. I also like http://wiki.ecmascript.org/doku.php?id=harmony:quasis#flexible_literal_syntax now that I'm looking through the wiki.
> Slide 44 is good, a WeakMap beats a Map so you get automatic deletion when a given httpResponse dies. Could you show entries whose values might be keys (or parts of keys) of other entries? That would show the double-whammy.
This is a good idea, especially since it helps distinguish from slide 45 (wherein I replicate the WeakMap example with symbols, albeit with breakage for extension-prevented objects).
> Looks great, more slides under construction? Need a rousing conclusion ;-).
Haha yeah, the real work is turning this from a "meetup talk" (primarily didactic) into a "conference talk" (inspirational and engaging). Still figuring that out, although I am very happy with the current intro (derived from your Hacker News replies).
I might steal "always bet on JS," or maybe I'll emphasize the way we can use these features today (SpiderMonkey, Chrome Embedded Frame or Node.js apps with flags, Traceur and other transpilers for the non-magic...). Still thinking on it, and of course toeing the sleep-dep/productivity line.
More information about the es-discuss