Re: [squid-dev] [CODE] iterating over enums

2015-08-13 Thread Kinkie
On Wed, Aug 12, 2015 at 9:11 PM, Alex Rousskov rouss...@measurement-factory.com wrote: On 08/12/2015 09:36 AM, Kinkie wrote: So I went ahead and just implemented it, starting from your observations. It's a bit more complex that your proposal, as I took the chance to implement

Re: [squid-dev] [CODE] iterating over enums

2015-08-13 Thread Alex Rousskov
On 08/13/2015 03:20 AM, Kinkie wrote: On Wed, Aug 12, 2015 at 9:11 PM, Alex Rousskov wrote: template typename Enum EnumRangeTEnum EnumRange(Enum begin, Enum end) { return EnumRangeTEnum(begin, end); } Done. * Typical use: * for ( auto enumvalue :

Re: [squid-dev] [CODE] iterating over enums

2015-08-13 Thread Alex Rousskov
On 08/13/2015 03:20 AM, Kinkie wrote: On Wed, Aug 12, 2015 at 9:11 PM, Alex Rousskov wrote: I would encourage you to show actual Squid usage examples (besides artificial test cases), either in the patch itself or in the patch cover email. ./src/HttpHdrCc.cc:HttpHdrCcType

Re: [squid-dev] More woes with ubuntu-precise

2015-08-13 Thread Amos Jeffries
On 14/08/2015 10:18 a.m., Alex Rousskov wrote: On 08/13/2015 09:29 AM, Kinkie wrote: EnumIterator has brought out one more issue with ubuntu-precise: since it carries gcc-4.6, it doesn't support std::underlying_typeenum. The options are: - drop support for precise in trunk. We claim