Re: Sharing string literals

2014-01-10 Thread Henri Sivonen
On Thu, Jan 9, 2014 at 1:33 PM, Neil n...@parkwaycc.co.uk wrote: This does not apply to AssignLiteral on an nsString, since that used to take a char ()[] parameter. Instead, consider assigning an NS_LITERAL_STRING, or you can also use the new char16_t overload of AssignLiteral by wrapping your

Re: Sharing string literals

2014-01-10 Thread Benjamin Smedberg
On 1/10/2014 12:19 AM, Daniel Holbert wrote: Just to be clear -- does this mean we should strictly prefer str.Assign(NS_LITERAL_STRING(foo)) over str.AssignLiteral(foo) now? For wide strings, I'm pretty sure the pattern we want is AssignLiteral(MOZ_UTF16(foo)). And as Henri mentioned, we

Re: Sharing string literals

2014-01-10 Thread Neil
Benjamin Smedberg wrote: On 1/10/2014 12:19 AM, Daniel Holbert wrote: Just to be clear -- does this mean we should strictly prefer str.Assign(NS_LITERAL_STRING(foo)) over str.AssignLiteral(foo) now? For wide strings, I'm pretty sure the pattern we want is AssignLiteral(MOZ_UTF16(foo)).

Re: Sharing string literals

2014-01-10 Thread Neil
Nicholas Nethercote wrote: On Thu, Jan 9, 2014 at 3:33 AM, Neil n...@parkwaycc.co.uk wrote: Bug 514173 has landed, which makes use of the fact that code living in libxul can reasonably assume that string constants have infinite lifetime, meaning that any literal strings in libxul are

Re: Target Milestone field in bugzilla

2014-01-10 Thread David Lawrence
On 01/09/2014 12:47 PM, Gavin Sharp wrote: It should be possible to have the field label change only for a specific set of products, in theory. Having the ability to customize on a per-product basis like this would make a lot of these proposals easier. I think we should ask our b.m.o devs