]> git.ipfire.org Git - thirdparty/gcc.git/blame - libstdc++-v3/testsuite/util/regression/trait/assoc/node_update_trait.hpp
Update copyright years.
[thirdparty/gcc.git] / libstdc++-v3 / testsuite / util / regression / trait / assoc / node_update_trait.hpp
CommitLineData
4569a895
AT
1// -*- C++ -*-
2
8d9254fc 3// Copyright (C) 2005-2020 Free Software Foundation, Inc.
4569a895
AT
4//
5// This file is part of the GNU ISO C++ Library. This library is free
6// software; you can redistribute it and/or modify it under the terms
7// of the GNU General Public License as published by the Free Software
748086b7 8// Foundation; either version 3, or (at your option) any later
4569a895
AT
9// version.
10
11// This library is distributed in the hope that it will be useful, but
12// WITHOUT ANY WARRANTY; without even the implied warranty of
13// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14// General Public License for more details.
15
16// You should have received a copy of the GNU General Public License
748086b7
JJ
17// along with this library; see the file COPYING3. If not see
18// <http://www.gnu.org/licenses/>.
4569a895 19
4569a895
AT
20
21// Copyright (C) 2004 Ami Tavory and Vladimir Dreizin, IBM-HRL.
22
23// Permission to use, copy, modify, sell, and distribute this software
24// is hereby granted without fee, provided that the above copyright
25// notice appears in all copies, and that both that copyright notice
26// and this permission notice appear in supporting documentation. None
27// of the above authors, nor IBM Haifa Research Laboratories, make any
28// representation about the suitability of this software for any
29// purpose. It is provided "as is" without express or implied
30// warranty.
31
32/**
33 * @file node_update_trait.hpp
2e3f9c21 34 * Contains traits for a random regression test
4569a895
AT
35 * for a specific container type.
36 */
37
38#ifndef PB_DS_REGRESSION_TEST_NODE_UPDATOR_TRAIT_HPP
39#define PB_DS_REGRESSION_TEST_NODE_UPDATOR_TRAIT_HPP
40
41#include <ext/pb_ds/assoc_container.hpp>
42#include <common_type/assoc/detail/tree_supports_order_statistics.hpp>
43#include <common_type/assoc/detail/trie_supports_order_statistics.hpp>
44#include <common_type/assoc/detail/trie_supports_prefix_search.hpp>
45
5e11f978 46namespace __gnu_pbds
4569a895
AT
47{
48
49 namespace test
50 {
51
52 namespace detail
53 {
54
55 template<typename Cntnr, class Tag>
56 struct regression_test_node_update_traits
57 {
58 enum
59 {
60 order_statistics = false,
61 prefix_search = false
62 };
63 };
64
65 template<typename Cntnr>
66 struct regression_test_node_update_traits<
67 Cntnr,
5e11f978 68 __gnu_pbds::pat_trie_tag>
4569a895
AT
69 {
70 enum
71 {
72 order_statistics =
73 trie_supports_order_statistics<Cntnr>::value,
74 prefix_search =
75 trie_supports_prefix_search<Cntnr>::value
76 };
77 };
78
79 template<typename Cntnr>
80 struct regression_test_node_update_traits<
81 Cntnr,
5e11f978 82 __gnu_pbds::rb_tree_tag>
4569a895
AT
83 {
84 enum
85 {
86 order_statistics =
87 tree_supports_order_statistics<Cntnr>::value,
88 prefix_search = false
89 };
90 };
91
92 template<typename Cntnr>
93 struct regression_test_node_update_traits<
94 Cntnr,
5e11f978 95 __gnu_pbds::splay_tree_tag>
4569a895
AT
96 {
97 enum
98 {
99 order_statistics =
100 tree_supports_order_statistics<Cntnr>::value,
101 prefix_search = false
102 };
103 };
104
105 template<typename Cntnr>
106 struct regression_test_node_update_traits<
107 Cntnr,
5e11f978 108 __gnu_pbds::ov_tree_tag>
4569a895
AT
109 {
110 enum
111 {
112 order_statistics =
113 tree_supports_order_statistics<Cntnr>::value,
114 prefix_search = false
115 };
116 };
117
118 } // namespace detail
119
120 } // namespace test
121
5e11f978 122} // namespace __gnu_pbds
4569a895
AT
123
124#endif // #ifndef PB_DS_REGRESSION_TEST_NODE_UPDATOR_TRAIT_HPP