Re: PSA: mozilla::Pair is now a little more flexible

2015-03-15 Thread Seth Fowler
On Mar 15, 2015, at 12:01 PM, Eric Rescorla e...@rtfm.com wrote: I'm not sure I want to get in a long argument about this, but I'm not convinced this is good advice. I don’t really care what we do - keep in mind, I had nothing to do with introducing mozilla::Pair - but I think that we

Re: PSA: mozilla::Pair is now a little more flexible

2015-03-15 Thread Eric Rescorla
On Sun, Mar 15, 2015 at 12:33 PM, Seth Fowler s...@mozilla.com wrote: On Mar 15, 2015, at 12:01 PM, Eric Rescorla e...@rtfm.com wrote: I'm not sure I want to get in a long argument about this, but I'm not convinced this is good advice. I don’t really care what we do - keep in mind, I

Re: PSA: mozilla::Pair is now a little more flexible

2015-03-15 Thread Eric Rescorla
On Fri, Mar 13, 2015 at 10:54 AM, Seth Fowler s...@mozilla.com wrote: On Mar 13, 2015, at 6:14 AM, Eric Rescorla e...@rtfm.com wrote: Sorry if this is a dumb question, but it seems like std::pair is fairly widely used in our code base. Can you explain the circumstances in which you

Re: PSA: mozilla::Pair is now a little more flexible

2015-03-15 Thread Joshua Cranmer 
On 3/15/2015 2:33 PM, Seth Fowler wrote: I don’t really care what we do - keep in mind, I had nothing to do with introducing mozilla::Pair - but I think that we should recommend the use of one thing, either std::pair or mozilla::Pair. If we choose to prefer std::pair, we should probably

Re: PSA: mozilla::Pair is now a little more flexible

2015-03-15 Thread Seth Fowler
On Mar 15, 2015, at 6:26 PM, Joshua Cranmer  pidgeo...@gmail.com wrote: In general, std::pair should be preferred over mozilla::Pair unless you need the empty type optimization. If that’s the case, perhaps we should rename it to e.g. mozilla::CompactPair? It’s current name strongly