Re: Uninteresting parameters

2011-09-28 Thread Mike Shaver
On Wed, Sep 28, 2011 at 2:50 PM, Brendan Eich bren...@mozilla.com wrote: I agree holes need better handling in future arraylike extras. Design effort there can start now, using today's JS. I'd welcome it. Perhaps underscore does well already? IIRC I chose the hole behaviour in the ES5 array

Re: Uninteresting parameters

2011-09-28 Thread Mike Shaver
On Wed, Sep 28, 2011 at 9:11 PM, Brendan Eich bren...@mozilla.com wrote: No worries, array extras are a great addition, we just need to keep rolling. Oh, no offense taken. I just meant to say that there may be consistency-with-existing-pattern reasons to prefer one hole behaviour over another,

Re: Class Syntax Proposal, Complete With Arguments For and Examples.

2011-09-18 Thread Mike Shaver
On Sun, Sep 18, 2011 at 1:36 AM, Jonathan Dumaine jonathan.duma...@dumstruck.com wrote: You could go all the way and make classes a very strict subset of the language: throw an error if the user tries to set a property of a class instance that has already been declared private [...] I would

Re: IDE support?

2011-09-17 Thread Mike Shaver
On Fri, Sep 16, 2011 at 1:55 AM, Andreas Rossberg rossb...@google.com wrote: Being able to detect when a condition is violated is not equivalent to knowing that it always holds. You're right, of course. Thanks for slicing that more finely for me. Mike

Re: IDE support?

2011-09-15 Thread Mike Shaver
On Thu, Sep 15, 2011 at 9:02 AM, Andreas Rossberg rossb...@google.com wrote: On 14 September 2011 00:00, Brendan Eich bren...@mozilla.com wrote: So, static+dynamic. The static side has some powerful algorithms to bring to bear. Dynamic is necessary due to eval and kin, and gives strictly more

Re: Language modes (Was: Block scoping and redeclarations)

2011-08-24 Thread Mike Shaver
On Wed, Aug 24, 2011 at 11:30 AM, Allen Wirfs-Brock al...@wirfs-brock.com wrote: The modern mode won't seem very modern twenty years from now. allen My understanding is that anything after the Middle Ages is fair game, and I see strict as the middle age between ES.now and ES.future. :-) MIke

Re: JavaScript terminology: non-function-valued property

2011-07-22 Thread Mike Shaver
Which primitives have own properties? I thought even str.length conceptually came from the prototype. Mike On Jul 22, 2011 6:13 PM, Axel Rauschmayer a...@rauschma.de wrote: To contrast non-method properties with methods: - To say that instances usually only have non-method properties. - To

Re: Pure win: Array.from and Array.of

2011-07-10 Thread Mike Shaver
On Sun, Jul 10, 2011 at 7:09 AM, Dmitry A. Soshnikov dmitry.soshni...@gmail.com wrote: If I hadn't made map skip holes, then the fill pattern would be simple enough: Array(4).map(function (_,x) x * x); It's in particular case, you try to multiply indices, which in current implementation of

Re: prototype focus

2011-07-01 Thread Mike Shaver
On Jul 1, 2011 1:14 PM, Brendan Eich bren...@mozilla.com wrote: On Jul 1, 2011, at 2:21 AM, Tim Smart wrote: I quite the current prototype model we have in ecma5. My only gripes would be that `prototype` to too wordy, Do you use it that often? 15 years ago, writing an overwrought prototype

Re: Mailing list reminder: password is sent in the clear

2011-07-01 Thread Mike Shaver
What can someone do with that password, though? Just change your subscription settings, afaik, so the security in place seems proportionate. Could report it upstream to the mailman team, I suppose. Mike On Jul 1, 2011 10:09 AM, Axel Rauschmayer a...@rauschma.de wrote: That’s a good start,

Re: Mailing list reminder: password is sent in the clear

2011-07-01 Thread Mike Shaver
On Fri, Jul 1, 2011 at 2:30 PM, Mike Samuel mikesam...@gmail.com wrote: 2011/7/1 Mike Shaver mike.sha...@gmail.com: What can someone do with that password, though? Just change your subscription settings, afaik, so the security in place seems proportionate. Could report it upstream

Re: Mailing list reminder: password is sent in the clear

2011-07-01 Thread Mike Shaver
On Fri, Jul 1, 2011 at 2:50 PM, Mike Samuel mikesam...@gmail.com wrote: 2011/7/1 Mike Shaver mike.sha...@gmail.com: On Fri, Jul 1, 2011 at 2:30 PM, Mike Samuel mikesam...@gmail.com wrote: 2011/7/1 Mike Shaver mike.sha...@gmail.com: What can someone do with that password, though? Just change

Re: JavaScript parser API

2011-06-28 Thread Mike Shaver
On Tue, Jun 28, 2011 at 6:34 PM, Axel Rauschmayer a...@rauschma.de wrote: http://blog.mozilla.com/dherman/2011/06/28/the-js-parser-api-has-landed/ I’ve just read D. Herman’s post on Firefox’s parser API. Is there any chance that this kind of API will make it into Harmony? It would be really

Re: Summary: prototypes as classes

2011-06-28 Thread Mike Shaver
On Tue, Jun 28, 2011 at 3:34 PM, Bob Nystrom rnyst...@google.com wrote: I like the simplicity of this, but I'm not crazy about how it merges two distinct objects into one. TodayJS (and most class-based languages) let you distinguish two things: 1. A set of properties relevant to the class

Re: Proposal: Object.defineProperty shorthand

2011-05-26 Thread Mike Shaver
On Thu, May 26, 2011 at 11:37 AM, Sean Eagan seaneag...@gmail.com wrote: // ! implies non-writable, ~ implies non-enumerable // all assignment operators can be used ! a.b += c Legal parse today, though I'm not sure you can get runtime semantics that aren't an error. !~a.b++ !(~(a.b++))

Re: Proposal: Object.defineProperty shorthand

2011-05-26 Thread Mike Shaver
On Thu, May 26, 2011 at 11:54 AM, Sean Eagan seaneag...@gmail.com wrote: On Thu, May 26, 2011 at 1:43 PM, Mike Shaver mike.sha...@gmail.com wrote: On Thu, May 26, 2011 at 11:37 AM, Sean Eagan seaneag...@gmail.com wrote: // ! implies non-writable, ~ implies non-enumerable // all assignment

Re: Standardizing out-of-memory and stack-depth-exceeded errors?

2011-03-23 Thread Mike Shaver
On Wed, Mar 23, 2011 at 6:21 PM, Garrett Smith dhtmlkitc...@gmail.com wrote: javascript: alert(new InternalError(Got on tha inside, bitch!)); Hrm. seems odd to expose the constructor publicly. Necessary to permit instanceof testing, no? The infinite recursion could be detected and reported

Re: About private names

2011-03-20 Thread Mike Shaver
On Mar 20, 2011 3:34 PM, Kyle Simpson get...@gmail.com wrote: BTW, if you know that a property name is foo, why would you ever code obj[foo] instead of obj.foo? The most obvious reason is if the name of the property contains a character which cannot be an identifier character in the property

Re: Bringing setTimeout to ECMAScript

2011-03-20 Thread Mike Shaver
On Sun, Mar 20, 2011 at 12:24 PM, John J. Barton johnjbar...@johnjbarton.com wrote: Looping as fast as possible is likely to be a bug. It's not similar to queuing events. It's the behaviour intentionally (if unwisely) requested by a lot of animations and games, for what it's worth. There are

Re: Native JS Encryption

2011-03-19 Thread Mike Shaver
On Sat, Mar 19, 2011 at 10:09 AM, Mark S. Miller erig...@google.com wrote: I agree about outside domain experts. In fact, I wish we could invite outside domain experts participate in all tc39 activities as we deem appropriate. I do not understand the rationale for bounding invited expert

Re: Native JS Encryption

2011-03-19 Thread Mike Shaver
On Sat, Mar 19, 2011 at 2:45 PM, Robert Accettura rob...@accettura.com wrote: Are there any successful key based encryption schemes that have actually succeeded with normals? TLS would be the obvious example, bitlocker and other encrypted file systems as well. We have hopes for the Firefox

Re: Standardizing __proto__

2011-03-18 Thread Mike Shaver
On Fri, Mar 18, 2011 at 9:14 AM, John-David Dalton john.david.dal...@gmail.com wrote: The __proto__ property is a powerful language feature that cannot be reproduced through any existing part of the language. Current proposals like, http://wiki.ecmascript.org/doku.php?id=strawman:array_create,

Re: Standardizing __proto__

2011-03-18 Thread Mike Shaver
On Fri, Mar 18, 2011 at 9:29 AM, John-David Dalton john.david.dal...@gmail.com wrote: @Mike Shaver For other possible uses please check out: http://msdn.microsoft.com/en-us/scriptjunkie/gg278167 https://github.com/jdalton/fusebox#readme Those all look like they are needing custom

Re: Standardizing __proto__

2011-03-18 Thread Mike Shaver
On Fri, Mar 18, 2011 at 10:45 AM, Oliver Hunt oli...@apple.com wrote: I think so -- my proposal doesn't take instances, nor produce instances, it takes the constructor function (Image is one of a handful of DOM constructor that can actually be used to construct things) and returns a new

Re: Standardizing __proto__

2011-03-18 Thread Mike Shaver
On Fri, Mar 18, 2011 at 1:53 PM, John-David Dalton john.david.dal...@gmail.com wrote: Ya, some people have that reaction at first, but after use it's not bad. Most of the time you create a string or value once then pass around the variable. Because these sandboxed natives chain, usage is

Re: Standardizing __proto__

2011-03-18 Thread Mike Shaver
On Fri, Mar 18, 2011 at 5:11 PM, John-David Dalton john.david.dal...@gmail.com wrote: Extending the Object.prototype is a compatibility nightmare It was a compatibility nightmare when people didn't namespace, and when you couldn't make non-enumerable properties. Using a namespace for additions

Re: Harmony is a super-set of ES5 strict

2011-02-25 Thread Mike Shaver
On Fri, Feb 25, 2011 at 7:36 AM, David Bruant bru...@enseirb-matmeca.fr wrote: Does it mean that the use strict directive is implicit whenever an ESHarmony feature is used? (this sounds wrong, but I'm asing the question anyway) It means that the semantics of Harmony are based on ES5-strict,

Re: idea: try/catch and rethrow...?

2011-02-01 Thread Mike Shaver
On Tue, Feb 1, 2011 at 10:53 AM, Kyle Simpson get...@gmail.com wrote: ?I have something that annoys me about how JavaScript try/catch error handling currently works. Don't get me wrong, I totally understand why it works that way, and it makes sense. But having the option to get around that

Re: Stupid i18n use cases question

2011-01-30 Thread Mike Shaver
On Sun, Jan 30, 2011 at 10:32 AM, Shawn Steele shawn.ste...@microsoft.com wrote: I'm still trying to grok word processing in JavaScript (beyond the simple case) What's to grok? Microsoft is putting word processors on the web, even. They don't want to go back to the server for all processing

Re: Stupid i18n use cases question

2011-01-29 Thread Mike Shaver
On Sat, Jan 29, 2011 at 9:24 PM, Shawn Steele shawn.ste...@microsoft.com wrote: I realize what line breaking's for, but I didn't think that would often be done in JavaScript.  You preformat some text in JavaScript? Yeah, for use in SVG or rendering atop canvas, for example. Mike

Re: Operator Overloading

2011-01-10 Thread Mike Shaver
On Mon, Jan 10, 2011 at 10:55 AM, Brendan Eich bren...@mozilla.com wrote: In light of the incubation argument and big-ticket items, I don't think value proxies break our complexity budget but they are very new. They're unlikely to get into ES6. Let's keep discussing here and working on the

Re: Colons and other annotative characters

2010-11-22 Thread Mike Shaver
I'd expect that o = { a : b = 5 } Was legal now, setting both o.a and b to 5. Not at a shell, is there an exception in the grammar for assignment expressions in the value position? { a = 5 : T } might work, though. Mike On Nov 22, 2010 6:09 PM, Waldemar Horwat walde...@google.com wrote: On

Re: Errors in syntax for array destructuring?

2010-10-15 Thread Mike Shaver
On Fri, Oct 15, 2010 at 8:34 AM, Brendan Eich bren...@mozilla.com wrote: On Oct 14, 2010, at 11:47 PM, Dominic Cooney wrote: On the harmony:destructuring page http://wiki.ecmascript.org/doku.php?id=harmony:destructuring it specifies this syntax for patterns: Pattern ::= { (Field (,

Re: Syntax for Efficient Traits is now ready for discussion (was: Classes as Sugar is...)

2010-09-14 Thread Mike Shaver
On Tue, Sep 14, 2010 at 8:46 AM, Mark S. Miller erig...@google.com wrote: Btw, the current proposal does currently repurpose with for renamings. Even though there's no syntactic conflict, if we use with instead of mixin we should choose a different syntax for renamings. Suggestions? as. Mike

Re: use strict; prepended blindly to scripts in the wild

2010-09-09 Thread Mike Shaver
On Thu, Sep 9, 2010 at 1:09 AM, Dmitry Soshnikov dmitry.soshni...@gmail.com wrote: Currently, a site may normally concatenate 3rd-party libs with use strict at the global level. The technique is the same as with forgotten semicolon -- just to put an empty statement at the beginning of the end

Re: WeakMap API questions?

2010-09-03 Thread Mike Shaver
On Fri, Sep 3, 2010 at 8:22 AM, David Herman dher...@mozilla.com wrote: Mike momentarily forgot what they mean Yes, it was a lapse from a casual observer reading the conversations quickly; please don't let my brain-blip harm the sweet naming. Mike ___

Re: WeakMap API questions?

2010-09-02 Thread Mike Shaver
On Thu, Sep 2, 2010 at 12:46 AM, Erik Corry erik.co...@gmail.com wrote: And this is as it should be.  As it stands the weak map can be used as an object with private members.  The object key acts as a capability that controls whether or not you have access to the private member. If I were to

Re: WeakMap API questions?

2010-09-02 Thread Mike Shaver
On Thu, Sep 2, 2010 at 11:32 AM, Erik Corry erik.co...@gmail.com wrote: Surely that is the case with WeakMap?  At least unless you lost the key and don't have any other references to the value.  In which case you can't reach the value any more, so why would you care whether it is kept alive?

Re: Rationalizing ASI (was: simple shorter function syntax)

2010-07-25 Thread Mike Shaver
On Sun, Jul 25, 2010 at 8:15 PM, Mark S. Miller erig...@google.com wrote: veryLongObjectName.someOtherVeryVeryLongObjectName.ridiculouslyLongFunctionName    (longArgument1, longArgument2, longArgument3, longArgument4, longArgument5); Yes. Even in the absence of ASI issues, my inclination

Re: Structs

2010-06-02 Thread Mike Shaver
On Wed, Jun 2, 2010 at 7:02 AM, Sam Ruby ru...@intertwingly.net wrote: On 06/02/2010 03:52 AM, Jason Orendorff wrote: I'll still maintain that the choice that ECMA 334 takes, namely that the assignment to b in the example above, makes a mutable copy is a valid choice. I would expect  

Re: modules proposal

2010-05-17 Thread Mike Shaver
On Mon, May 17, 2010 at 12:37 AM, Kam Kasravi kamkasr...@yahoo.com wrote: [kam] An example might be something like SVG.*Filter* where the importer was interested in retrieving only filter related features within a SVG module. For this, I would rather let the exporter define named export lists,

Re: Adoption of the Typed Array Specification

2010-05-14 Thread Mike Shaver
On Fri, May 14, 2010 at 2:09 AM, Oliver Hunt oli...@apple.com wrote: The data is mutable, the length is not -- this is more in line with arrays in other languages, but more importantly the whole point of the typed array spec was to provide a compact typed storage mechanism.  Allowing the

Re: Proposal: Array.prototype.last()

2010-05-05 Thread Mike Shaver
On Wed, May 5, 2010 at 8:27 AM, Jordan Osete jordan.os...@yahoo.fr wrote: I've been wondering for some time if there couldn't be a way to index arrays from the last element directly. Currently if you have an array lost in a deep objects hierarchy, you have to refer to it twice, once to access

Re: Strategies for standardizing mistakes

2009-10-15 Thread Mike Shaver
On Thu, Oct 15, 2009 at 2:29 PM, Maciej Stachowiak m...@apple.com wrote: Just as a minor point of technical correction - this will actually alert not IE in Firefox because the right-hand sign of an assignment is considered a detecting access. (Just tested to confirm.) Thank you! I see that I

Re: Property Iteration in JSON serialization

2009-10-14 Thread Mike Shaver
On Wed, Oct 14, 2009 at 7:24 PM, Waldemar Horwat walde...@google.com wrote: No.  As I wrote, there is no de-facto implementation order because the implementations do not agree on the order in general, and what you call fringes such as numbers do matter.  Trying to force, say, insertion order

Re: Property Iteration in JSON serialization

2009-10-14 Thread Mike Shaver
On Wed, Oct 14, 2009 at 7:39 PM, Jeff Walden jwalden...@mit.edu wrote: On 10/13/2009 10:54 PM, Luke Smith wrote: Currently FF3.5.4 doesn't properly apply replacer functions, but Safari 4, WebKit, IE8, and Chrome 3 work fine for this task. How precisely are replacer functions not properly

Re: Strategies for standardizing mistakes

2009-10-14 Thread Mike Shaver
On Wed, Oct 14, 2009 at 7:40 PM, Jim Blandy j...@mozilla.com wrote: There's one specific kind of contextual information that's being looked at askance here: knowledge of the expression surrounding the call that invoked you.  Perl lets subroutines check what sort of value their caller is

Re: Another de-facto insecurity we need to fix in ES5

2009-06-17 Thread Mike Shaver
On Wed, Jun 17, 2009 at 6:34 PM, Mark S. Millererig...@google.com wrote: I sincerely applaud this bold stance. If Mozilla proceeds in this manner successfully, then the present issue becomes a non-concern; as probably do several more we haven't stumbled across yet. Please let us know what we

Re: Explict Memory Managment

2009-05-22 Thread Mike Shaver
On Fri, May 22, 2009 at 4:53 PM, David Semeria da...@lmframework.com wrote: Ok. I assume object references are implemnted bi-directionally, otherwise the GC would take a lifetime to run. I don't know of any that are implemented bidirectionally, since it would be a waste of space; it's certainly

Re: Case transformations in strings

2009-03-04 Thread Mike Shaver
On Wed, Mar 4, 2009 at 2:35 PM, Allen Wirfs-Brock allen.wirfs-br...@microsoft.com wrote: Any input from our other Unicode experts would be appreciated... Here's what I found (running on Windows Vista): IE, FF, Opera \u00DF.toUpperCase()  returns \u00DF Same on FF3.1b3 on OS X. Mike

Re: Inline regexps and caching

2009-01-23 Thread Mike Shaver
2009/1/23 Laurens Holst lho...@students.cs.uu.nl: Hi, I and a colleague were puzzled by some strange behaviour in Firefox, we found that in some browsers literal regular expressions are cached and reused. Testcase: function test(str) { var regexp = /^[^d]*\bd{1,4}\b[^d]*$/g;

Re: The JS onerror event and the ECMA Standard

2009-01-05 Thread Mike Shaver
On Mon, Jan 5, 2009 at 7:42 AM, Michael Ratcliffe mich...@ratcliffefamily.org wrote: Are there any plans to make onerror part of the ECMA standard and, if so, is it possible for me to suggest adding an additional item that should be accessible from the onerror handler? I would suggest that

Re: Volunteers needed: Function.prototype.bind() in ES3.1 pseudo-code

2008-09-18 Thread Mike Shaver
On Thu, Sep 18, 2008 at 1:41 PM, Garrett Smith [EMAIL PROTECTED] wrote: 2008/9/18 Mark S. Miller [EMAIL PROTECTED]: The Redmond mtg is fast approaching. We'd like to put out an official for-Redmond-mtg draft of the ES3.1 spec by then. I had volunteered to write the spec for

Re: Ye olde arguments argument (was: Topic list - pending changes and issues for the ES3.1 spec)

2008-09-15 Thread Mike Shaver
On Mon, Sep 15, 2008 at 4:32 PM, Jon Zeppieri [EMAIL PROTECTED] wrote: Any magically bound variable breaks TC. The expression callee should have the same meaning as (function() { return callee; })() ...and it clearly does not. True, but it doesn't work for arguments or