Boost logo

Boost Users :

Subject: Re: [Boost-users] Using different variables based on template type
From: Scott McMurray (me22.ca+boost_at_[hidden])
Date: 2009-06-02 03:08:25


2009/6/1 Ryan McConnehey <mccorywork_at_[hidden]>:
>
> Where would you rank this solution?
>
> [...]
>

That still requires 2 copies, 2 pastes, and 4 edits to add a new type
(PLUS those for the other functions). They're at least simple, but
it's still a violation of DRY, so I'm not a big fan.

If you decided it's more readable than the other options, then I
suppose I could go for it if the number of types was quite low.

What are the types really, anyways? Differentiating between uint16
and uint32 as in the example is rarely useful. Certainly on a normal
desktop, the map nodes will end up being the same size anyways, thanks
to padding.


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net