I would say the #1 use case for templates is when your other choice is a lot of
cut and paste. The code bloat's the same in both cases and maintenance is
definitely easier in the template case.
Smart pointers are another (although those are already in ATS).
I suppose for me the standard use cas
On 3 Dec 2011, at 21:31, Alan M. Carroll wrote:
> We build our company product with MSVC and g++ and haven't had any serious
> template problems that were due to compiler issues (we have an issue where
> there is what *I* consider a bug in the template language specification for
> which MSVC h
On 12/3/11 10:19 AM, Alan M. Carroll wrote:
I have somewhat of a biased view as I was doing template style programming
before C++ had templates (using the Common Lisp Object System) so it's second
nature for me.
P.S. I've definitely found more than one bug in a compiler (both MSVC and g++)
fr
We build our company product with MSVC and g++ and haven't had any serious
template problems that were due to compiler issues (we have an issue where
there is what *I* consider a bug in the template language specification for
which MSVC has a workaround but that's not really a compiler problem).
Thanks guys,
On 12/03/2011 06:19 PM, Alan M. Carroll wrote:
P.S. I've definitely found more than one bug in a compiler (both MSVC and g++)
from templates. I used to think that if I wasn't crashing the compiler with my
templates, I wasn't really trying. That's become a bit harder but I expect
I think they do it mainly just to get me.
The problem with templates, as Igor touches on, is that they are a very sharp
knife. In the hands of a skilled coder they can do wonderful things, but it's
something that can easily get out of hand. Templates are Turing complete so you
can create very e
- Original Message -
> Crap, I should have removed that email long time ago ;)
>
> Original Message
> To: trafficserver-...@incubator.apache.org
>
> Instead hijacking thread ...
>
> On 12/02/2011 06:17 PM, Leif Hedstrom wrote:
> > On 12/1/11 5:56 PM, Alan M. Carroll wrot
Crap, I should have removed that email long time ago ;)
Original Message
To: trafficserver-...@incubator.apache.org
Instead hijacking thread ...
On 12/02/2011 06:17 PM, Leif Hedstrom wrote:
On 12/1/11 5:56 PM, Alan M. Carroll wrote:
I suppose I can get used to git (after all
Instead hijacking thread ...
On 12/02/2011 06:17 PM, Leif Hedstrom wrote:
> On 12/1/11 5:56 PM, Alan M. Carroll wrote:
>> I suppose I can get used to git (after all, I eventually moved on from RCS).
In exchange, you guys can get used to templates :-).
>
> Eep, that seems like a steep price to pa