
12 Jan
2012
12 Jan
'12
1:54 a.m.
On 1/10/2012 11:48 PM, Akira Takahashi wrote:
I think this situation's better way is wrap by function template and use boost::optional.
I agree that returning the the item (using optional, if necessary) is better in this case than returning an iterator, when the iterator is only used as a pointer that will not be used for traversing in any manner. Nice idea about wrapping the function (algorithm) first, and then using the range adaptor on the outer. —John