EricWF created this revision. EricWF added a reviewer: mclow.lists. EricWF added subscribers: cfe-commits, mclow.lists.
constructing a std::unique_ptr<T[N]> will always cause a warning because the deleter (`std::default_delete<T[N]>`) will call `delete ptr` instead of `delete [] ptr`. This is a bug in the standard, not libc++. I don't see a reason why removing the test cases will decrease coverage because std::unique_ptr<T> and std::unique_ptr<T[N]> select the same primary template. However since @mclow.lists wrote this test I want him to approve this patch. http://reviews.llvm.org/D13332 Files: test/std/utilities/tuple/tuple.general/tuple.smartptr.pass.cpp Index: test/std/utilities/tuple/tuple.general/tuple.smartptr.pass.cpp =================================================================== --- test/std/utilities/tuple/tuple.general/tuple.smartptr.pass.cpp +++ test/std/utilities/tuple/tuple.general/tuple.smartptr.pass.cpp @@ -21,18 +21,10 @@ std::tuple<std::unique_ptr<char>> up; std::tuple<std::shared_ptr<char>> sp; std::tuple<std::weak_ptr <char>> wp; -// std::tuple<std::auto_ptr <char>> ap; } { std::tuple<std::unique_ptr<char[]>> up; std::tuple<std::shared_ptr<char[]>> sp; std::tuple<std::weak_ptr <char[]>> wp; -// std::tuple<std::auto_ptr <char[]>> ap; } - { - std::tuple<std::unique_ptr<char[5]>> up; - std::tuple<std::shared_ptr<char[5]>> sp; - std::tuple<std::weak_ptr <char[5]>> wp; -// std::tuple<std::auto_ptr <char[5]>> ap; - } -} \ No newline at end of file +}
Index: test/std/utilities/tuple/tuple.general/tuple.smartptr.pass.cpp =================================================================== --- test/std/utilities/tuple/tuple.general/tuple.smartptr.pass.cpp +++ test/std/utilities/tuple/tuple.general/tuple.smartptr.pass.cpp @@ -21,18 +21,10 @@ std::tuple<std::unique_ptr<char>> up; std::tuple<std::shared_ptr<char>> sp; std::tuple<std::weak_ptr <char>> wp; -// std::tuple<std::auto_ptr <char>> ap; } { std::tuple<std::unique_ptr<char[]>> up; std::tuple<std::shared_ptr<char[]>> sp; std::tuple<std::weak_ptr <char[]>> wp; -// std::tuple<std::auto_ptr <char[]>> ap; } - { - std::tuple<std::unique_ptr<char[5]>> up; - std::tuple<std::shared_ptr<char[5]>> sp; - std::tuple<std::weak_ptr <char[5]>> wp; -// std::tuple<std::auto_ptr <char[5]>> ap; - } -} \ No newline at end of file +}
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits