[libcxx-commits] [PATCH] D65161: [libc++] Implement LWG 2510

Zoe Carver via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Wed Sep 25 14:19:00 PDT 2019


zoecarver added inline comments.


================
Comment at: libcxx/test/std/utilities/memory/allocator.tag/allocator_arg.fail.cpp:19
 
-int main(int, char**)
-{
-    test(std::allocator_arg);
+std::allocator_arg_t f() { return {}; } // expected-error 1 {{chosen constructor is explicit in copy-initialization}}
 
----------------
ldionne wrote:
> zoecarver wrote:
> > If we are keeping this test we should update this function to `return std:: allocator_arg_t ()`. 
> The whole point of this test is to exercise the error caused by the non-explicit copy-initialization. I'm not sure I understand your comment.
I think I was worried about C++03 mode. Now that this has been updated to be unsupported in C++03, don't worry about it. 


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D65161/new/

https://reviews.llvm.org/D65161





More information about the libcxx-commits mailing list