RE: escaping - in /u RegExp

2015-01-13 Thread Gary Guo
I think it s a bug, and I think your proposal is appropriate. From: al...@wirfs-brock.com Subject: escaping - in /u RegExp Date: Tue, 13 Jan 2015 13:23:54 -0800 To: es-discuss@mozilla.org Would those of you who consider yourselves RegExp experts take a look at

RE: Sharing a JavaScript implementation across realms

2015-01-13 Thread Gary Guo
I don't think there is any difference in self-hosting JavaScript or JS-engine in C++. For example, use the example case `Array.prototype.map`, in C++, we could code a native function and create a corresponding object for each realm (note that the only shared part is the native function). In

Re: Implicit coercion of Symbols

2015-01-13 Thread Isiah Meadows
From: Domenic Denicola d...@domenic.me To: Rick Waldron waldron.r...@gmail.com, es-discuss es-discuss@mozilla.org Cc: Date: Mon, 12 Jan 2015 18:02:17 + Subject: RE: Implicit coercion of Symbols I re-read through this whole thread and realized nobody brought up the fact that this

Re: Sharing a JavaScript implementation across realms

2015-01-13 Thread Mark S. Miller
On Tue, Jan 13, 2015 at 4:21 AM, Anne van Kesteren ann...@annevk.nl wrote: A big challenge with self-hosting is memory consumption. A JavaScript implementation is tied to a realm and therefore each realm will have its own implementation. Contrast this with a C++ implementation of the same

Re: Sharing a JavaScript implementation across realms

2015-01-13 Thread David Bruant
Le 13/01/2015 13:21, Anne van Kesteren a écrit : A big challenge with self-hosting is memory consumption. A JavaScript implementation is tied to a realm and therefore each realm will have its own implementation. Contrast this with a C++ implementation of the same feature that can be shared

Re: Sharing a JavaScript implementation across realms

2015-01-13 Thread Brendan Eich
Before we go tl;dr on this topic, how about some data to back up the asserted problem size? Filip gently raised the question. How much memory does a realm cost in top open source engines? Fair question, empirical and (I think) not hard to answer. Burdened malloc/GC heap full cost, not net

Sharing a JavaScript implementation across realms

2015-01-13 Thread Anne van Kesteren
A big challenge with self-hosting is memory consumption. A JavaScript implementation is tied to a realm and therefore each realm will have its own implementation. Contrast this with a C++ implementation of the same feature that can be shared across many realms. The C++ implementation is much more

Re: Handling error in Promises

2015-01-13 Thread Marius Gundersen
A `promise.done()` method that throws if it receives a rejected promise has been discussed, but the consensus seems to be that browsers instead should report on rejected unhandled promises that are garbage collected. This is already implemented in Firefox (at least in the DevTools edition), where

Re: Handling error in Promises

2015-01-13 Thread Jeff Morrison
You might try reading through some of the previous threads that talk about the trickiness of surfacing promise errors in the general case. Unfortunately these threads usually devolve into an endless thread of discussion and debate that become next to impossible to actually read through later

Re: Handling error in Promises

2015-01-13 Thread Jeremy Martin
Awhile back I did my best to summarize some of the previous es-discuss threads on a related GitHub thread: https://github.com/iojs/io.js/issues/11#issuecomment-65971175 Please see the immediately following comment as well for some clarification on how Bluebird surfaces unhandled rejections. On

Re: Sharing a JavaScript implementation across realms

2015-01-13 Thread Filip Pizlo
We have been trying to improve sharing in JSC for a while now. We can share bytecode between realms, but this is mostly about reducing parse time rather than space saving - the bytecode has to be linked before a realm uses it, which involves making a copy of most of the data structures. I

escaping - in /u RegExp

2015-01-13 Thread Allen Wirfs-Brock
Would those of you who consider yourselves RegExp experts take a look at https://bugs.ecmascript.org/show_bug.cgi?id=3519 Is this a bug? If so, what is the fix? This construction for Identity Escape goes back to Norbert's original proposal