1 //===----------------------------------------------------------------------===//
3 // The LLVM Compiler Infrastructure
5 // This file is dual licensed under the MIT and the University of Illinois Open
6 // Source Licenses. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
14 // Test unique_ptr::pointer type
17 #include <type_traits>
19 #include "test_macros.h"
38 typedef std::unique_ptr<int> P;
39 static_assert((std::is_same<P::pointer, int*>::value), "");
42 typedef std::unique_ptr<int, Deleter> P;
43 static_assert((std::is_same<P::pointer, Deleter::pointer>::value), "");
45 #if TEST_STD_VER >= 11
47 typedef std::unique_ptr<int, D2> P;
48 static_assert(std::is_same<P::pointer, int*>::value, "");
51 typedef std::unique_ptr<int, D3> P;
52 static_assert(std::is_same<P::pointer, int*>::value, "");