> -----Original Message-----
> From: Neil Mix [mailto:[EMAIL PROTECTED] 
> Sent: 13. mars 2008 14:47
> To: Lars Hansen
> Cc: es4-discuss@mozilla.org
> Subject: Re: Controlling DontEnum (was: ES4 draft: Object)
> 
> On Mar 13, 2008, at 11:47 AM, Lars Hansen wrote:
> 
> >  function __createProperty__(name:EnumerableId,
> >                              dontEnum:boolean=false,
> >                              dontDelete:boolean=false,
> >                              readOnly:boolean=false): void
> 
> 
> I like where this is going.  May I (in addition to Kris's 
> suggestion for adding a value parameter) kindly nit on the 
> parameter names?
> 
> function __createProperty__(name:EnumerableId,
>                              value:*,
>                              enumerable:boolean=true,
>                              removable:boolean=true,
>                              writable:boolean=true): void
> 
> Or some reasonable variant therein?  I have no strong 
> opinions on the form the parameters eventually take, but 
> trying to parse what dontenum=false means tends to give me 
> headaches. ;)

Well, it had to come up at some point ;)

I suspect what you're proposing is the better UI.  Obviously JS1/ES3
shows a bias for enumerable, removable, writable properties -- the
attribute bits flag exceptions from the general rule.  The more general
design has attribute bits that simply control those property aspects,
and the less biased names feel like an improvement.

Brendan, opinions?

--lars
_______________________________________________
Es4-discuss mailing list
Es4-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es4-discuss

Reply via email to