Re: Should the entire JS structure be Object.freeze()'d if it's exposed through a read only property?

2015-07-12 Thread Tim Guan-tin Chien
On Fri, Jul 10, 2015 at 2:45 AM, Boris Zbarsky wrote: > On 7/9/15 4:48 AM, Tim Guan-tin Chien wrote: >> >> In this case, I modified the manifest object passed from mozApp API, >> and the object was subsequently removed by the platform, so did my >> modifications. Fabrice said I should not be modif

Re: Proposal to remove `aFoo` prescription from the Mozilla style guide for C and C++

2015-07-12 Thread Nicholas Nethercote
On Thu, Jul 9, 2015 at 7:01 PM, Jeff Gilbert wrote: > > Arguments have the same lifetimes as locals, and the only exceptions to > this apply to both args and locals. (references and pointers) Maybe I've misunderstood what you're saying here, but locals are frequently block-scoped which gives them

Hash table iterators, and a call for help

2015-07-12 Thread Nicholas Nethercote
Hi, Last week I landed patches that remove PL_DHashTableEnumerate() from the tree (https://bugzilla.mozilla.org/show_bug.cgi?id=1180072). You should now use PLDHashTable::Iterator if you want to iterate over a PLDHashTable. The iterator is *so* much nicer -- there's none of that "bundle up an envi

Re: Proposal to remove `aFoo` prescription from the Mozilla style guide for C and C++

2015-07-12 Thread Thomas Zimmermann
Am 08.07.2015 um 16:36 schrieb smaug: > Do you actually have any data how many % of Gecko devs would prefer > not using aFoo? I strongly prefer 'aFoo' over 'foo' for the extra context that it gives to the variable. If we want to change anything we should rather introduce a separate prefix for outp