Boost logo

Boost :

Subject: Re: [boost] [auto_buffer] Interest check: container with preallocated buffer
From: Thorsten Ottosen (thorsten.ottosen_at_[hidden])
Date: 2009-05-19 15:14:25

Jeffrey Bosboom skrev:
> Thorsten Ottosen wrote:
>>> The "GrowPolicy" template parameter should be named "GrowthPolicy."
>> Really?
> "Grow" is a verb; "Growth" is a noun. "GrowthPolicy" just sounds better.
>>> "optimized_const_reference" would be better named "by_value_type" or
>>> something.
>>> For small types, optimized_const_reference isn't a reference at all, so
>>> the name is misleading.
>>> Better to name it for the usage rather than the type.
>> But then for large types, "by_value_type" is not a value type, but a
>> reference. What about parameter_type or param_type?
> boost::call_traits uses param_type. I haven't looked at the code, so I'm
> not sure what you're using it for or if you'd just be able to use
> call_traits.
> --Jeffrey Bosboom

I could use boost::call_traits, albeit it seems that

1. it defines small types to be too small, eg. sizeof(T) <= sizeof(void*).

2. it doesn't seem to take into account PODs or types with a trivial
assignment operator.


Boost list run by bdawes at, gregod at, cpdaniel at, john at