C++ Logo

STD-PROPOSALS

Advanced search

Subject: Re: [std-proposals] String contains member function
From: Matthew Woehlke (mwoehlke.floss_at_[hidden])
Date: 2019-05-31 10:22:36


On 31/05/2019 10.56, Giuseppe D'Angelo via Std-Proposals wrote:
> On 31/05/2019 14:31, Ville Voutilainen via Std-Proposals wrote:
>> Well, {map,set}::contains is a logarithmic operation, string::contains
>> would be linear. That could well be an argument for naming the linear
>> operation differently from the logarithmic one.
>
> What about std::unordered_map::contains then?

That's still sub-linear (except in pathological cases).

-- 
Matthew

STD-PROPOSALS list run by herb.sutter at gmail.com

Standard Proposals Archives on Google Groups