Lines Matching refs:array
40 std::array<T, 5> array = {T{0}, T{1}, T{2}, T{3}, T{4}}; in tests() local
47 test_bounded_ptr<QualT> ptr(array.begin() + 0, array.begin(), array.end()); in tests()
50 _assert(&ref == &array[0]); in tests()
53 _assert(&ptr->i == &array[0].i); in tests()
60 test_bounded_ptr<QualT> ptr(array.begin() + 1, array.begin(), array.end()); in tests()
63 _assert(&ref == &array[1]); in tests()
66 _assert(&ptr->i == &array[1].i); in tests()
73 test_bounded_ptr<QualT> ptr(array.begin() + 2, array.begin(), array.end()); in tests()
76 _assert(&ref == &array[2]); in tests()
79 _assert(&ptr->i == &array[2].i); in tests()
86 test_bounded_ptr<QualT> ptr(array.begin() + 4, array.begin(), array.end()); in tests()
89 _assert(&ref == &array[4]); in tests()
92 _assert(&ptr->i == &array[4].i); in tests()
101 libkern::bounded_ptr<QualT, tracking_policy> ptr(array.begin() + 1, array.begin(), array.end()); in tests()
115 libkern::bounded_ptr<QualT, tracking_policy> ptr(array.end() - 1, array.begin(), array.end() - 2); in tests()
130 libkern::bounded_ptr<QualT, tracking_policy> ptr(array.begin(), array.begin() + 1, array.end()); in tests()
145 T* t3 = const_cast<T*>(array.begin() + 3); in tests()
147 …tr<QualT, tracking_policy> ptr(reinterpret_cast<QualT*>(just_off), array.begin(), array.end() - 1); in tests()