[PATCH] D18637: Extract key to avoid preemptive mallocs in insert/emplace in associative containers

Duncan P. N. Exon Smith via cfe-commits cfe-commits at lists.llvm.org
Wed Apr 13 09:56:37 PDT 2016


> On 2016-Apr-13, at 09:50, Eric Fiselier <eric at efcs.ca> wrote:
> 
> EricWF added inline comments.
> 
> ================
> Comment at: test/std/containers/associative/set/insert_and_emplace_allocator_requirements.pass.cpp:29
> @@ +28,3 @@
> +template <class Arg>
> +void PrintInfo(int line, Arg&& arg)
> +{
> ----------------
> mclow.lists wrote:
>> In general, we want tests to be silent on success.
> I'll see what I can do. The reason these tests are so noisy is because almost all of the assertions are in "container_test_types.h". Meaning that when the tests fail the diagnostic points into the header with no information about what code actually triggered the assertion.  Hence why these tests manually print what they are testing.
> 
> I'll try and come up with something better.

You might be able to change the API to use macros that pass in __FILE__
and __LINE__ as arguments.

> 
> 
> http://reviews.llvm.org/D18637
> 
> 
> 



More information about the cfe-commits mailing list