
11 Mar
2009
11 Mar
'09
12:42 a.m.
I have a class that is getting a huge number of template parameters (mostly
a bunch of size_t used for vector sizes). They have a natural organization
into groups, but almost all of them have a default as 0.
How do you suggest that I design the template parameter for this? Is there
any way to use some kind of associative container so I could look these up
by "name" and default to 0 if they aren't there? I can't see how to use
mpl::map to do this kind of stuff.
Simplified Pseudocode:
--------------------
What I have:
template