Re: Bytecode

2014-05-14 Thread Axel Rauschmayer
It'd be great if there was material on the limits of the JVM and the CLR. AFAICT these are the only virtual machines that are trying to be universal (run both static and dynamic languages well). [[[Sent from a mobile device. Please forgive brevity and typos.]]] Dr. Axel Rauschmayer

Re: Perhaps @@unscopable shouldn't be a Set...

2014-04-30 Thread Axel Rauschmayer
, but unfortunately won’t work. Somehow, we have to put the burden on `with` and the legacy code instead of the future-facing parts of the language. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: Perhaps @@unscopable shouldn't be a Set...

2014-04-30 Thread Axel Rauschmayer
? Thanks! Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Perhaps @@unscopable shouldn't be a Set...

2014-04-30 Thread Axel Rauschmayer
On 30 Apr 2014, at 21:17 , Boris Zbarsky bzbar...@mit.edu wrote: On 4/30/14, 2:49 PM, Axel Rauschmayer wrote: So Element.prototype is in the variable scope chain of event handlers? Wow. Is this documented somewhere? You mean other than in the spec? See http://www.whatwg.org/specs/web

Re: [[Set]] and inherited readonly data properties

2014-04-01 Thread Axel Rauschmayer
can’t seem to find it in Caja. Thanks! Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Template strings and templates

2014-03-06 Thread Axel Rauschmayer
, i'm just very interested in finding out what practical task they are meant to accomplish ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de

Re: Template strings and templates

2014-03-06 Thread Axel Rauschmayer
. You could also reorder the pieces. A bit of work for a library, but template strings would help, a little. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es

Standard modules?

2014-01-19 Thread Axel Rauschmayer
http://wiki.ecmascript.org/doku.php?id=harmony:modules_standard Is this the most current document on the standard modules? Thanks! Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: Standard modules?

2014-01-19 Thread Axel Rauschmayer
in a separate @reflect module. Regards, Tom 2014/1/19 Axel Rauschmayer a...@rauschma.de http://wiki.ecmascript.org/doku.php?id=harmony:modules_standard Is this the most current document on the standard modules? -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter

Capitalization: symbol vs. Symbol

2014-01-17 Thread Axel Rauschmayer
Given that all upcoming value object constructors will start with lowercase letters, shouldn’t Symbol, too? Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list

Re: Capitalization: symbol vs. Symbol

2014-01-17 Thread Axel Rauschmayer
are unique * Only exposed via Object.getOwnPropertySymbols instead of Object.getOwnPropertyKeys * |Object.mixin| copies both symbol and string properties -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: Enumerability

2014-01-13 Thread Axel Rauschmayer
-- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Value objects: roll your own?

2014-01-12 Thread Axel Rauschmayer
(a, b) { return point2d(a + b.x, a + b.y); } ``` Or, possibly: ``` function + (a :: number, b :: point2d) { return point2d(a + b.x, a + b.y); } ``` Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: Enumerability

2014-01-11 Thread Axel Rauschmayer
structures. After deserialising it with `JSON.parse`, I just have to recursively reconstruct the `_parent` back-references; * etc. Nice example. Data versus meta-data, in line with the `length` of an array being non-enumerable. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de

Re: Enumerability

2014-01-11 Thread Axel Rauschmayer
on: The answers and discussions on this mailing list were essential in helping me understand the language. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es

Re: Enumerability

2014-01-11 Thread Axel Rauschmayer
cut out for you, anyway. I’m thinking more along the lines along a companion document. But NOTEs are a great idea, I’ll keep it in mind while reading the spec. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Value objects: roll your own?

2014-01-11 Thread Axel Rauschmayer
http://www.slideshare.net/BrendanEich/value-objects One thing is not entirely clear from the slides: Will developers be able to define their own value object types? Without that feature I don’t see how overloading operators would be very interesting. Thanks! Axel -- Dr. Axel Rauschmayer

Re: Enumerability

2014-01-10 Thread Axel Rauschmayer
explanation of what enumerability will be, going forward. If there isn’t one then I’d argue that no new feature should be influenced by it. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es

Enumerability

2014-01-09 Thread Axel Rauschmayer
the design of ECMAScript going forward if we had a definitive and complete explanation of what enumerability is now and what it should be in the future. I’m trying to make sense of it and to explain it to others and continue to fail. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de

getOwnPropertySymbols + getOwnPropertyNames

2013-12-22 Thread Axel Rauschmayer
-- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Object.is()

2013-12-22 Thread Axel Rauschmayer
if it didn’t distinguish +0 and -0? -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Symbol.keyFor

2013-12-21 Thread Axel Rauschmayer
Offhand, ID instead of key, but that is awfully generic. It may make sense to invent a new term. On Dec 22, 2013, at 6:53 , Mark S. Miller erig...@google.com wrote: Suggestions? On Sat, Dec 21, 2013 at 9:48 PM, Axel Rauschmayer a...@rauschma.de wrote: One problem with that method name

Object.is()

2013-12-21 Thread Axel Rauschmayer
()`? Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Specifics of `class` and `super`

2013-12-09 Thread Axel Rauschmayer
code I could compile to for roughly the same semantics, that would be helpful. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https

Re: “Arrow is not a replacement for all functions that want lexical this”

2013-12-09 Thread Axel Rauschmayer
then there is only a single kind of function definition. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es

Re: Export Default Sugarings

2013-12-05 Thread Axel Rauschmayer
: defer default export sugarings until ES7, when we can use data gathered from experience with ES6 modules to guide syntax additions. ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss -- Dr. Axel

Re: if-scoped let

2013-12-04 Thread Axel Rauschmayer
for truthy/falsy tests? In loops (for-of, while), I find this kind of thing useful, for if-then-else, much less so. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list

“Arrow is not a replacement for all functions that want lexical this”

2013-11-28 Thread Axel Rauschmayer
Source: David Herman, https://github.com/rwaldron/tc39-notes/blob/master/es6/2013-11/nov-20.md Can someone elaborate? I don’t see an alternative. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Async functions?

2013-11-28 Thread Axel Rauschmayer
#410-generator-arrow-function-syntax Thanks! Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es

Re: Async functions?

2013-11-28 Thread Axel Rauschmayer
Thanks! But I don’t see `function!`, anywhere. On Nov 28, 2013, at 16:10 , Mark S. Miller erig...@google.com wrote: http://wiki.ecmascript.org/doku.php?id=strawman:async_functions cheers, MarkM On Nov 28, 2013 12:34 AM, Axel Rauschmayer a...@rauschma.de wrote: In the most recent meeting

Re: Generator Arrow Functions

2013-11-27 Thread Axel Rauschmayer
notes, too? Thanks! Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

PutValue – correctly implemented by engines?

2013-11-23 Thread Axel Rauschmayer
mode). ```js (function () { 'use strict'; var s=''; s.foo=3 }()); ``` But it doesn’t (not on Firefox and V8). [1] http://ecma-international.org/ecma-262/5.1/#sec-8.7.2 -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: PutValue – correctly implemented by engines?

2013-11-23 Thread Axel Rauschmayer
It does indeed. I just checked in Safari and got an exception. Thanks, Axel On Nov 23, 2013, at 11:00 , Yusuke SUZUKI utatane@gmail.com wrote: JavaScriptCore implements it correctly. --- Regards, Yusuke Suzuki On Sat, Nov 23, 2013 at 6:24 PM, Axel Rauschmayer a...@rauschma.de

Re: PutValue – correctly implemented by engines?

2013-11-23 Thread Axel Rauschmayer
, Axel Rauschmayer a...@rauschma.de wrote: It does indeed. I just checked in Safari and got an exception. Thanks, Axel On Nov 23, 2013, at 11:00 , Yusuke SUZUKI utatane@gmail.com wrote: JavaScriptCore implements it correctly. --- Regards, Yusuke Suzuki On Sat, Nov 23, 2013 at 6

ES 5.1 – 9.10 CheckObjectCoercible

2013-11-22 Thread Axel Rauschmayer
Not sure it matters, but: table 15 is incomplete. Four trues are missing. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https

Re: ES 5.1 – 9.10 CheckObjectCoercible

2013-11-22 Thread Axel Rauschmayer
Well, strike that. I misunderstood what the operation does. Sorry. On Nov 22, 2013, at 21:36 , Axel Rauschmayer a...@rauschma.de wrote: Not sure it matters, but: table 15 is incomplete. Four trues are missing. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter

Re: Generator Arrow Functions

2013-11-20 Thread Axel Rauschmayer
. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Links in the ES5.1 PDF?

2013-11-20 Thread Axel Rauschmayer
In the ES5 spec PDF, there were convenient links from the ToC to the content. In the ES5.1 spec, they are gone. Is there a way to bring them back? Thanks! Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: Modules vs Scripts

2013-11-17 Thread Axel Rauschmayer
(for bundling)? Is there a way to combine module IDs and packages? Thanks! Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https

Re: Modules vs Scripts

2013-11-17 Thread Axel Rauschmayer
.) Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Generator Arrow Functions

2013-11-16 Thread Axel Rauschmayer
Caveat: with yield*, you want generators to be more like functions than like blocks. [[[Sent from a mobile device. Please forgive brevity and typos.]]] Dr. Axel Rauschmayer a...@rauschma.de Home: http://rauschma.de Blog: http://2ality.com On 16.11.2013, at 10:28, Claus Reinke claus.rei

Re: Generator Arrow Functions

2013-11-15 Thread Axel Rauschmayer
(); yield sleep(2000); status.fadeOut(); }); ``` [Example taken from task.js website.] -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org

Re: Generator Arrow Functions

2013-11-15 Thread Axel Rauschmayer
that. Thought it was *=. I don’t mind either way, my (admittedly weak) mnemonic would be “asterisk after function-defining token”. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing

Re: an idea for replacing arguments.length

2013-11-10 Thread Axel Rauschmayer
: ActualArgumentCount : '#' BindingIdentifier So, the declaration for splice could then be: function splice(start, deleteCount, ...items, #argCount) { ... if (argCount == 0) {... Thoughts? Allen -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter

Creating top-level scopes in ES6 and do blocks

2013-11-04 Thread Axel Rauschmayer
. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Creating top-level scopes in ES6 and do blocks

2013-11-04 Thread Axel Rauschmayer
at 5:36 AM, Axel Rauschmayer a...@rauschma.de wrote: What is the best way to create top-level scopes in ES6? I guess I am probably missing something important, but I thought you could just write a block and use `let` in it: { let foo = ...; ... } even in sloppy mode

Re: Novel operator syntax

2013-10-29 Thread Axel Rauschmayer
/NodeJS could easily take over the technical and statistical computing domains. Tristan -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https

Re: Proposal to simplify Generators impact

2013-10-26 Thread Axel Rauschmayer
Another reason: you can’t have empty generators without marking them in some manner. On Sat, Oct 26, 2013 at 1:01 PM, Lucio Tato luciot...@gmail.com wrote: It's really needed to make js syntax more complex in order to implement generators? It's function* really needed? -- Dr. Axel

Pass an environment to eval()?

2013-09-28 Thread Axel Rauschmayer
-- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Destructuring object outside of var declaration

2013-09-17 Thread Axel Rauschmayer
). -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Continuing woes in reading the ES6 spec language

2013-09-15 Thread Axel Rauschmayer
that is neither #1 nor #2. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Functions in blocks?

2013-09-13 Thread Axel Rauschmayer
to be available in both sloppy and strict mode (right?). That seems like a pretty good solution (I also would have been OK with only having ES6 features in strict mode). Thanks! Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: Continuing woes in reading the ES6 spec language

2013-09-13 Thread Axel Rauschmayer
: ```js function getRandomInteger(lower = 0, upper) { return Math.floor(Math.random() * (upper - lower)) + lower; } ``` Implementing this function in some other manner is much more complicated. But I agree that you want to name parameters if there are more than 2. -- Dr. Axel Rauschmayer

Re: Continuing woes in reading the ES6 spec language

2013-09-13 Thread Axel Rauschmayer
case for this, I’d find it confusing. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: ImportSpecifierSet syntax

2013-09-08 Thread Axel Rauschmayer
The problem is that you have to bite the bullet of syntactic inconvenience for either default imports or normal imports. I’d prefer the syntax you suggested, but there seem to be many people who want to make default imports as simple as possible. -- Dr. Axel Rauschmayer rauschma.de [Sent from

Serve different JS files, depending on browser support?

2013-09-05 Thread Axel Rauschmayer
and then load modules conditionally? But that seems like a more complicated solution. I’m not even sure how I would implement the detection part. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: Letting RegExp method return something iterable?

2013-08-29 Thread Axel Rauschmayer
matches (group 0) are returned. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Letting RegExp method return something iterable?

2013-08-29 Thread Axel Rauschmayer
() – execIter() `execAll()` may not be that bad. It’s not pretty, but it’s fairly easy to guess what it does (*if* one know what the normal `exec()` does). -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: Letting RegExp method return something iterable?

2013-08-29 Thread Axel Rauschmayer
:45 , Brendan Eich bren...@mozilla.com wrote: Axel Rauschmayer wrote: The fact that s.match(/re/g) returns the array of all matches (with captures) sucks some of the oxygen away from any /re/g.execAll(s) proposal. But String.prototype.match has perlish hair (e.g., those capture groups

typeof null

2013-08-29 Thread Axel Rauschmayer
Quick, possibly silly idea: What if `typeof null` returned `undefined`? -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https

Re: Creating and consuming custom iterators

2013-08-28 Thread Axel Rauschmayer
) for that? There will be a public symbol (that you can import from a system module) that will allow you to do both things. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss

Re: Letting RegExp method return something iterable?

2013-08-28 Thread Axel Rauschmayer
/.execMultipleLazy('str') ] ``` -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: `.toArray()` for all generators

2013-08-28 Thread Axel Rauschmayer
in iteratables? It would be lovely to have a module with tool functions for this, similar to Python’s itertools. http://docs.python.org/3/library/itertools.html -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Optionally ignoring case in String.prototype.contains()?

2013-08-28 Thread Axel Rauschmayer
Suggestion: a named parameter `ignoreCase`: $ 'hello world'.contains('WORLD') false $ 'hello world'.contains('WORLD', { ignoreCase: true }) true -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

RegExp. quoteText()

2013-08-28 Thread Axel Rauschmayer
parens, braces and brackets. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Letting RegExp method return something iterable?

2013-08-24 Thread Axel Rauschmayer
-- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Letting RegExp method return something iterable?

2013-08-24 Thread Axel Rauschmayer
Well, obviously it doesn’t make much sense to do that for `text()`, but it would be great to have for `exec()`. On Aug 24, 2013, at 21:39 , Axel Rauschmayer a...@rauschma.de wrote: At the moment, the following two methods abuse regular expressions as iterators (if the /g flag is set

Re: Letting RegExp method return something iterable?

2013-08-24 Thread Axel Rauschmayer
An example to make things clearer (thanks for the suggestion, Domenic): https://gist.github.com/rauschma/6330265 On Aug 24, 2013, at 21:43 , Axel Rauschmayer a...@rauschma.de wrote: Well, obviously it doesn’t make much sense to do that for `text()`, but it would be great to have for `exec

Re: Optional Strong Typing

2013-08-23 Thread Axel Rauschmayer
___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss

Refutable destructuring

2013-08-09 Thread Axel Rauschmayer
to declaratively specify a minimum arity). Then destructuring assignment and parameter handling would work very similarly. function bla(!mandatoryArg, optionalArg1, optionalArg2 = 123) { ... } Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com

Re: Refutable destructuring

2013-08-09 Thread Axel Rauschmayer
becomes: let { +a: foo, b: bar } = { a: 1 }; // foo = 1, b = undefined let { +a: foo, b: bar } = { }; // exception function bla(+mandatoryArg, optionalArg1, optionalArg2 = 123) { ... } -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com

Modules: do re-exports also import?

2013-08-04 Thread Axel Rauschmayer
; // re-exporting specified exports from another module That seems redundant. Maybe one could mark things that should be re-exported when importing them? On the other hand, this may be rare enough that it doesn’t warrant the extra syntax. -- Dr. Axel Rauschmayer a...@rauschma.de home

Re: typeof extensibility, building on my Value Objects slides from Thursday's TC39 meeting

2013-07-29 Thread Axel Rauschmayer
the option open of adding complete multiple dispatch later (or via a library). -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https

Re: Array.prototype.last

2013-07-28 Thread Axel Rauschmayer
the need for a standard :-) Array.prototype.first could work too. David [1] https://twitter.com/angustweets/status/359827047117373443 ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss -- Dr. Axel

Modules: error handling when importing declaratively?

2013-07-28 Thread Axel Rauschmayer
an event listener with the current loader, but haven’t found anything in the loader API. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https

Re: typeof extensibility, building on my Value Objects slides from Thursday's TC39 meeting

2013-07-28 Thread Axel Rauschmayer
welcome (cc'ing Allen since he is realm-master; ES1-5 left realm implicit and singular, contrary to reality in browsers). /be ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss -- Dr. Axel Rauschmayer

Re: typeof extensibility, building on my Value Objects slides from Thursday's TC39 meeting

2013-07-28 Thread Axel Rauschmayer
and multiple dispatch to implement the DCI ideas): http://www.artima.com/articles/dci_vision.html On Jul 29, 2013, at 0:41 , Brendan Eich bren...@mozilla.com wrote: Axel Rauschmayer wrote: Suggestion: put this evolving spec into a Gist or something similar. Definitely -- trying not to work all

Re: typeof extensibility, building on my Value Objects slides from Thursday's TC39 meeting

2013-07-28 Thread Axel Rauschmayer
for working with data (web services, JSON, etc.), where you don’t want to (or can’t) encapsulate behavior with data. Design-wise, they make functions aware of object-orientation so that you can use them to implement algorithms that span multiple classes (as binary operators do). -- Dr. Axel Rauschmayer

Re: More concise arrow functions

2013-07-27 Thread Axel Rauschmayer
-discuss -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: More concise arrow functions

2013-07-27 Thread Axel Rauschmayer
= =) { // ... } ``` From: Axel Rauschmayer Sent: ‎7/‎28/‎2013 0:40 To: Brandon Benvie Cc: es-discuss@mozilla.org Subject: Re: More concise arrow functions +1 My perspective: I don’t see a use case for a missing body, but a missing parameter list would be very useful – to delay the execution of a block

Re: Unique Public Symbols as Strings

2013-07-25 Thread Axel Rauschmayer
solve the main use cases. -- erik ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Re: Import: why are single-export modules favored?

2013-07-21 Thread Axel Rauschmayer
to export anything but the constructor function from each module. - Ryan -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org

Re: How primitive are Symbols? Bignums? etc

2013-07-15 Thread Axel Rauschmayer
frequent use case I’ve encountered: does the value have a prototype (i.e., will Object.getPrototypeOf() work)? I’m assuming that value objects will have a prototype, accessible via Object.getPrototypeOf (?) Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com

Re: [proposal] Function calls, syntax sugar

2013-07-12 Thread Axel Rauschmayer
that bracketing noise in syntax. -- Andrew Fedoniouk. http://terrainformatica.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter

Re: thisArg in Array#find and Array#findIndex

2013-07-10 Thread Axel Rauschmayer
be `thisValue`. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Import: why are single-export modules favored?

2013-07-04 Thread Axel Rauschmayer
functions, right? Thanks! Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Polyfilling: constructor methods versus polyfilling

2013-07-03 Thread Axel Rauschmayer
forgive brevity and typos.]]] Dr. Axel Rauschmayer a...@rauschma.de Home: http://rauschma.de Blog: http://2ality.com___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Do modules make static unnecessary?

2013-07-01 Thread Axel Rauschmayer
and Array.of for an example of this in action. Similarly: @@create (which enables the subtyping of built-ins). -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss

Re: Do modules make static unnecessary?

2013-07-01 Thread Axel Rauschmayer
, a (sub)class is the implementation of a (sub)type. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es

Re: Do modules make static unnecessary?

2013-07-01 Thread Axel Rauschmayer
(Underscore etc.). With ES6, “subclassing” works, because there are classes, but I wouldn’t want to use it for ES5. Suggestions for a better word are welcome. Axel On Jul 1, 2013, at 19:34 , Andreas Rossberg rossb...@google.com wrote: On 1 July 2013 19:00, Axel Rauschmayer a...@rauschma.de

Re: Classical inheritance is obsolete

2013-06-30 Thread Axel Rauschmayer
will improve (partially helped by classes). Additionally, unit tests minimize the risks of refactoring. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss

Re: Classical inheritance is obsolete

2013-06-30 Thread Axel Rauschmayer
coupling between child and parents, and much more easily provide for selective inheritance (I only want the banana, not the gorilla, banana, and entire jungle). - Eric -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Classical inheritance is obsolete

2013-06-29 Thread Axel Rauschmayer
the consensus for ECMAScript 6 classes (lots of incredibly long, incredibly passionate discussions!). Would I have done classes differently? Yes. But the consensus enables us to have a solution that is good enough, which (IMO) is far better than having nothing. -- Dr. Axel Rauschmayer a...@rauschma.de

Re: Function declarations with lexical `this`?

2013-06-25 Thread Axel Rauschmayer
function would even be useful: a generator with lexical `this`. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org

Re: Function declarations with lexical `this`?

2013-06-25 Thread Axel Rauschmayer
arrow function would even be useful: a generator with lexical `this`. see https://bugs.ecmascript.org/show_bug.cgi?id=1489 Perfect. That’s how I thought it would work. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com

Function declarations with lexical `this`?

2013-06-24 Thread Axel Rauschmayer
need a consistent story for ES6 in this area. Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: New ES6 strawman: Array.prototype.fill and Array.prototype.move

2013-06-23 Thread Axel Rauschmayer
,source=0, count=this.length-source) Is the case of moving trailing elements somewhere else very common? If not, then I’d define the parameters in this order: source, count, target. Rationale: easier to memorize. -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma

Re: New ES6 strawman: Array.prototype.fill and Array.prototype.move

2013-06-23 Thread Axel Rauschmayer
,%20int,%20java.lang.Object,%20int,%20int%29 -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Automatically binding extracted methods

2013-06-14 Thread Axel Rauschmayer
Thanks to proxies now having a separate trap for “invoke”, we can automatically bind methods on “get”. I’ve written down my thoughts here: http://www.2ality.com/2013/06/auto-binding.html Axel -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog

Re: Why can’t for-of be applied to iterators?

2013-06-11 Thread Axel Rauschmayer
-and-an-iterable -- Dr. Axel Rauschmayer a...@rauschma.de home: rauschma.de twitter: twitter.com/rauschma blog: 2ality.com ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

<    1   2   3   4   5   6   7   8   9   10   >