/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/strings/basic.string/string.cons/ |
D | substr.pass.cpp | 29 typedef typename S::allocator_type A; in test() typedef 38 assert(s2.get_allocator() == A()); in test() 52 typedef typename S::allocator_type A; in test() typedef 61 assert(s2.get_allocator() == A()); in test() 75 typedef typename S::allocator_type A; in test() typedef 96 typedef test_allocator<char> A; in main() typedef 97 typedef std::basic_string<char, std::char_traits<char>, A> S; in main() 99 test(S(A(3)), 0); in main() 100 test(S(A(3)), 1); in main() 101 test(S("1", A(5)), 0); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/language.support/support.exception/propagation/ |
D | current_exception.pass.cpp | 17 struct A struct 21 A() {++constructed;} in A() function 22 ~A() {--constructed;} in ~A() argument 23 A(const A&) {++constructed;} in A() argument 26 int A::constructed = 0; 37 assert(A::constructed == 0); in main() 38 throw A(); in main() 43 assert(A::constructed == 1); in main() 45 assert(A::constructed == 0); in main() 47 assert(A::constructed == 0); in main() [all …]
|
/ndk/tests/device/test-stlport_shared-exception/jni/ |
D | ice990323-2.cpp | 6 template <class T, int n, class U> struct A { struct 7 A() {} in A() argument 8 A(const char*) {} in A() function 13 throw *(new A<double, 47, A<int, 37, short> >); in f1() 18 throw *(new A<double, 47, A<int, 36, short> >); in f2() 23 throw A<double, 47, A<int, 37, short> > ("howdy"); in f3() 28 throw A<double, 47, A<int, 36, short> > ("hi michey"); in f4() 39 catch (A<double, 47, A<int, 36, short> >) { in main() 42 catch (A<double, 47, A<int, 37, short> >) { in main() 52 catch (A<double, 47, A<int, 36, short&> >) { in main() [all …]
|
D | eh990323-5.cpp | 11 struct A { struct 13 A(); argument 14 A(const A&); 15 ~A(); 18 A::A() in A() function in A 26 A::A(const A&) in A() function in A 34 A::~A() in ~A() 43 A a[] = {A(), A(), A(), A(), A(), A(), A(), A(), A(), A(), A(), A()}; in f()
|
D | eh990323-1.cpp | 9 template <class T> struct A { struct 10 A() {ctor++;} in A() argument 11 A(int) {ctor++;} in A() function 12 A(const A&) {ctor++;} in A() argument 13 ~A() {dtor++;} in ~A() argument 31 A<int> a1; in f() argument 32 A<double> a2(37); in f() 33 A<long> a3 = A<long>(47); in f() 34 A<short> a4 = 97; in f() 36 g(A<char*>()); in f() [all …]
|
/ndk/tests/device/test-stlport_static-exception/jni/ |
D | ice990323-2.cpp | 6 template <class T, int n, class U> struct A { struct 7 A() {} in A() function 8 A(const char*) {} in A() argument 13 throw *(new A<double, 47, A<int, 37, short> >); in f1() 18 throw *(new A<double, 47, A<int, 36, short> >); in f2() 23 throw A<double, 47, A<int, 37, short> > ("howdy"); in f3() 28 throw A<double, 47, A<int, 36, short> > ("hi michey"); in f4() 39 catch (A<double, 47, A<int, 36, short> >) { in main() 42 catch (A<double, 47, A<int, 37, short> >) { in main() 52 catch (A<double, 47, A<int, 36, short&> >) { in main() [all …]
|
D | eh990323-5.cpp | 11 struct A { struct 13 A(); argument 14 A(const A&); 15 ~A(); 18 A::A() in A() function in A 26 A::A(const A&) in A() argument 34 A::~A() in ~A() 43 A a[] = {A(), A(), A(), A(), A(), A(), A(), A(), A(), A(), A(), A()}; in f()
|
D | eh990323-1.cpp | 9 template <class T> struct A { struct 10 A() {ctor++;} in A() argument 11 A(int) {ctor++;} in A() function 12 A(const A&) {ctor++;} in A() argument 13 ~A() {dtor++;} in ~A() argument 31 A<int> a1; in f() argument 32 A<double> a2(37); in f() 33 A<long> a3 = A<long>(47); in f() 34 A<short> a4 = 97; in f() 36 g(A<char*>()); in f() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/utility/forward/ |
D | move_copy.pass.cpp | 18 class A class 27 A(const A&) {++copy_ctor;} in A() function in A 28 A& operator=(const A&); 30 A(A&&) {++move_ctor;} in A() argument 31 A& operator=(A&&); 33 A(const A&) {++copy_ctor;} 34 A& operator=(A&); 36 operator std::__rv<A> () {return std::__rv<A>(*this);} 37 A(std::__rv<A>) {++move_ctor;} 40 A() {} in A() function in A [all …]
|
D | forward.pass.cpp | 15 struct A struct 19 A source() {return A();} in source() 20 const A csource() {return A();} in csource() 27 one test(A&); 28 two test(const A&); 32 four test(A&&); 33 eight test(const A&&); 39 A a; in main() 40 const A ca = A(); in main() 43 static_assert(sizeof(test(std::forward<A&>(a))) == 1, ""); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/ |
D | move01.pass.cpp | 24 struct A struct 27 A() {++count;} in A() argument 28 A(const A&) {++count;} in A() function 29 ~A() {--count;} in ~A() argument 32 int A::count = 0; 37 std::unique_ptr<A[]> s1(new A[3]); in main() 38 A* p = s1.get(); in main() 39 assert(A::count == 3); in main() 40 std::unique_ptr<A[]> s2(new A[2]); in main() 41 assert(A::count == 5); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/language.support/support.limits/limits/numeric.limits/ |
D | default.pass.cpp | 18 struct A struct 20 A(int i = 0) : data_(i) {} in A() function 24 bool operator == (const A& x, const A& y) {return x.data_ == y.data_;} in operator ==() argument 28 static_assert(std::numeric_limits<A>::is_specialized == false, in main() 30 assert(std::numeric_limits<A>::min() == A()); in main() 31 assert(std::numeric_limits<A>::max() == A()); in main() 32 assert(std::numeric_limits<A>::lowest() == A()); in main() 33 static_assert(std::numeric_limits<A>::digits == 0, in main() 35 static_assert(std::numeric_limits<A>::digits10 == 0, in main() 37 static_assert(std::numeric_limits<A>::max_digits10 == 0, in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.asgn/ |
D | move01.pass.cpp | 24 struct A struct 27 A() {++count;} in A() argument 28 A(const A&) {++count;} in A() function 29 ~A() {--count;} in ~A() argument 32 int A::count = 0; 37 std::unique_ptr<A> s1(new A); in main() 38 A* p = s1.get(); in main() 39 std::unique_ptr<A> s2(new A); in main() 40 assert(A::count == 2); in main() 42 assert(A::count == 1); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.getdeleter/ |
D | get_deleter.pass.cpp | 20 struct A struct 24 A() {++count;} in A() function 25 A(const A&) {++count;} in A() function 26 ~A() {--count;} in ~A() argument 29 int A::count = 0; 35 A* ptr = new A; in main() 36 std::shared_ptr<A> p(ptr, test_deleter<A>(3)); in main() 37 test_deleter<A>* d = std::get_deleter<test_deleter<A> >(p); in main() 38 assert(test_deleter<A>::count == 1); in main() 39 assert(test_deleter<A>::dealloc_count == 0); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/unique.ptr/unique.ptr.special/ |
D | swap.pass.cpp | 21 struct A struct 25 A() : state_(0) {++count;} in A() function 26 explicit A(int i) : state_(i) {++count;} in A() argument 27 A(const A& a) : state_(a.state_) {++count;} in A() argument 28 A& operator=(const A& a) {state_ = a.state_; return *this;} in operator =() argument 29 ~A() {--count;} in ~A() argument 31 friend bool operator==(const A& x, const A& y) in operator ==() 35 int A::count = 0; 40 A* p1 = new A(1); in main() 41 std::unique_ptr<A, Deleter<A> > s1(p1, Deleter<A>(1)); in main() [all …]
|
D | eq.pass.cpp | 27 struct A struct 30 A() {++count;} in A() function 31 A(const A&) {++count;} in A() argument 32 virtual ~A() {--count;} in ~A() argument 35 int A::count = 0; 38 : public A 51 const std::unique_ptr<A, Deleter<A> > p1(new A); in main() 52 const std::unique_ptr<A, Deleter<A> > p2(new A); in main() 57 const std::unique_ptr<A, Deleter<A> > p1(new A); in main() 63 const std::unique_ptr<A[], Deleter<A[]> > p1(new A[3]); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.mod/ |
D | reset_pointer_deleter_allocator.pass.cpp | 32 struct A struct 37 A() {++count;} in A() argument 38 A(const A&) {++count;} in A() argument 39 ~A() {--count;} in ~A() argument 42 int A::count = 0; 48 A* ptr = new A; in main() 49 p.reset(ptr, test_deleter<A>(3), test_allocator<A>(4)); in main() 50 assert(A::count == 1); in main() 54 test_deleter<A>* d = std::get_deleter<test_deleter<A> >(p); in main() 55 assert(test_deleter<A>::count == 1); in main() [all …]
|
D | swap.pass.cpp | 19 struct A struct 23 A() {++count;} in A() argument 24 A(const A&) {++count;} in A() argument 25 ~A() {--count;} in ~A() argument 28 int A::count = 0; 33 A* ptr1 = new A; in main() 34 A* ptr2 = new A; in main() 35 std::shared_ptr<A> p1(ptr1); in main() 37 std::shared_ptr<A> p2(ptr2); in main() 43 assert(A::count == 2); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/ |
D | pointer_deleter_allocator.pass.cpp | 19 struct A struct 23 A() {++count;} in A() argument 24 A(const A&) {++count;} in A() argument 25 ~A() {--count;} in ~A() argument 28 int A::count = 0; 33 A* ptr = new A; in main() 34 std::shared_ptr<A> p(ptr, test_deleter<A>(3), test_allocator<A>(5)); in main() 35 assert(A::count == 1); in main() 38 test_deleter<A>* d = std::get_deleter<test_deleter<A> >(p); in main() 39 assert(test_deleter<A>::count == 1); in main() [all …]
|
D | nullptr_t_deleter_allocator.pass.cpp | 19 struct A struct 23 A() {++count;} in A() function 24 A(const A&) {++count;} in A() function 25 ~A() {--count;} in ~A() argument 28 int A::count = 0; 33 std::shared_ptr<A> p(nullptr, test_deleter<A>(3), test_allocator<A>(5)); in main() 34 assert(A::count == 0); in main() 37 test_deleter<A>* d = std::get_deleter<test_deleter<A> >(p); in main() 38 assert(test_deleter<A>::count == 1); in main() 39 assert(test_deleter<A>::dealloc_count == 0); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/unique.ptr/unique.ptr.single/unique.ptr.single.modifiers/ |
D | swap.pass.cpp | 21 struct A struct 25 explicit A(int i) : state_(i) {++count;} in A() function 26 A(const A& a) : state_(a.state_) {++count;} in A() argument 27 A& operator=(const A& a) {state_ = a.state_; return *this;} in operator =() argument 28 ~A() {--count;} in ~A() argument 30 friend bool operator==(const A& x, const A& y) in operator ==() 34 int A::count = 0; 39 A* p1 = new A(1); in main() 40 std::unique_ptr<A, Deleter<A> > s1(p1, Deleter<A>(1)); in main() 41 A* p2 = new A(2); in main() [all …]
|
D | reset1.pass.cpp | 19 struct A struct 22 A() {++count;} in A() argument 23 A(const A&) {++count;} in A() function 24 ~A() {--count;} in ~A() argument 27 int A::count = 0; 32 std::unique_ptr<A> p(new A); in main() 33 assert(A::count == 1); in main() 34 A* i = p.get(); in main() 36 assert(A::count == 0); in main() 39 assert(A::count == 0); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.spec/ |
D | swap.pass.cpp | 19 struct A struct 23 A() {++count;} in A() argument 24 A(const A&) {++count;} in A() argument 25 ~A() {--count;} in ~A() argument 28 int A::count = 0; 33 A* ptr1 = new A; in main() 34 A* ptr2 = new A; in main() 35 std::shared_ptr<A> p1(ptr1); in main() 37 std::shared_ptr<A> p2(ptr2); in main() 43 assert(A::count == 2); in main() [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.ctor/ |
D | move02.pass.cpp | 24 struct A struct 27 A() {++count;} in A() function 28 A(const A&) {++count;} in A() function 29 ~A() {--count;} in ~A() argument 32 int A::count = 0; 47 void operator()(A* p) {delete [] p;} in operator ()() 50 std::unique_ptr<A[]> 53 return std::unique_ptr<A[]>(new A[3]); in source1() 56 void sink1(std::unique_ptr<A[]> p) in sink1() 60 std::unique_ptr<A[], Deleter<A[]> > [all …]
|
/ndk/sources/cxx-stl/llvm-libc++/libcxx/test/utilities/memory/unique.ptr/unique.ptr.runtime/unique.ptr.runtime.modifiers/ |
D | reset1.pass.cpp | 19 struct A struct 22 A() {++count;} in A() argument 23 A(const A&) {++count;} in A() argument 24 ~A() {--count;} in ~A() argument 27 int A::count = 0; 32 std::unique_ptr<A[]> p(new A[3]); in main() 33 assert(A::count == 3); in main() 34 A* i = p.get(); in main() 36 assert(A::count == 0); in main() 39 assert(A::count == 0); in main() [all …]
|