1 |
|
/****************************************************************************** |
2 |
|
* Top contributors (to current version): |
3 |
|
* Mathias Preiner, Aina Niemetz |
4 |
|
* |
5 |
|
* This file is part of the cvc5 project. |
6 |
|
* |
7 |
|
* Copyright (c) 2009-2021 by the authors listed in the file AUTHORS |
8 |
|
* in the top-level source directory and their institutional affiliations. |
9 |
|
* All rights reserved. See the file COPYING in the top-level source |
10 |
|
* directory for licensing information. |
11 |
|
* **************************************************************************** |
12 |
|
* |
13 |
|
* Option template for option modules. |
14 |
|
* |
15 |
|
* For each <module>_options.toml configuration file, mkoptions.py |
16 |
|
* expands this template and generates a <module>_options.cpp file. |
17 |
|
*/ |
18 |
|
#include "options/base_options.h" |
19 |
|
|
20 |
|
#include <iostream> |
21 |
|
|
22 |
|
#include "base/check.h" |
23 |
|
#include "options/option_exception.h" |
24 |
|
|
25 |
|
// clang-format off |
26 |
|
namespace cvc5 { |
27 |
|
|
28 |
|
template <> options::binary_name__option_t::type& Options::ref( |
29 |
|
options::binary_name__option_t) |
30 |
|
{ |
31 |
|
return base().binary_name; |
32 |
|
} |
33 |
5878 |
template <> const options::binary_name__option_t::type& Options::operator[]( |
34 |
|
options::binary_name__option_t) const |
35 |
|
{ |
36 |
5878 |
return base().binary_name; |
37 |
|
} |
38 |
|
template <> bool Options::wasSetByUser(options::binary_name__option_t) const |
39 |
|
{ |
40 |
|
return base().binary_name__setByUser__; |
41 |
|
} |
42 |
|
template <> options::err__option_t::type& Options::ref( |
43 |
|
options::err__option_t) |
44 |
|
{ |
45 |
|
return base().err; |
46 |
|
} |
47 |
37761 |
template <> const options::err__option_t::type& Options::operator[]( |
48 |
|
options::err__option_t) const |
49 |
|
{ |
50 |
37761 |
return base().err; |
51 |
|
} |
52 |
|
template <> bool Options::wasSetByUser(options::err__option_t) const |
53 |
|
{ |
54 |
|
return base().err__setByUser__; |
55 |
|
} |
56 |
12 |
template <> options::in__option_t::type& Options::ref( |
57 |
|
options::in__option_t) |
58 |
|
{ |
59 |
12 |
return base().in; |
60 |
|
} |
61 |
12 |
template <> const options::in__option_t::type& Options::operator[]( |
62 |
|
options::in__option_t) const |
63 |
|
{ |
64 |
12 |
return base().in; |
65 |
|
} |
66 |
|
template <> bool Options::wasSetByUser(options::in__option_t) const |
67 |
|
{ |
68 |
|
return base().in__setByUser__; |
69 |
|
} |
70 |
6374 |
template <> options::inputLanguage__option_t::type& Options::ref( |
71 |
|
options::inputLanguage__option_t) |
72 |
|
{ |
73 |
6374 |
return base().inputLanguage; |
74 |
|
} |
75 |
889280 |
template <> const options::inputLanguage__option_t::type& Options::operator[]( |
76 |
|
options::inputLanguage__option_t) const |
77 |
|
{ |
78 |
889280 |
return base().inputLanguage; |
79 |
|
} |
80 |
3020 |
template <> bool Options::wasSetByUser(options::inputLanguage__option_t) const |
81 |
|
{ |
82 |
3020 |
return base().inputLanguage__setByUser__; |
83 |
|
} |
84 |
|
template <> options::languageHelp__option_t::type& Options::ref( |
85 |
|
options::languageHelp__option_t) |
86 |
|
{ |
87 |
|
return base().languageHelp; |
88 |
|
} |
89 |
5878 |
template <> const options::languageHelp__option_t::type& Options::operator[]( |
90 |
|
options::languageHelp__option_t) const |
91 |
|
{ |
92 |
5878 |
return base().languageHelp; |
93 |
|
} |
94 |
|
template <> bool Options::wasSetByUser(options::languageHelp__option_t) const |
95 |
|
{ |
96 |
|
return base().languageHelp__setByUser__; |
97 |
|
} |
98 |
12 |
template <> options::out__option_t::type& Options::ref( |
99 |
|
options::out__option_t) |
100 |
|
{ |
101 |
12 |
return base().out; |
102 |
|
} |
103 |
319961 |
template <> const options::out__option_t::type& Options::operator[]( |
104 |
|
options::out__option_t) const |
105 |
|
{ |
106 |
319961 |
return base().out; |
107 |
|
} |
108 |
|
template <> bool Options::wasSetByUser(options::out__option_t) const |
109 |
|
{ |
110 |
|
return base().out__setByUser__; |
111 |
|
} |
112 |
5881 |
template <> options::outputLanguage__option_t::type& Options::ref( |
113 |
|
options::outputLanguage__option_t) |
114 |
|
{ |
115 |
5881 |
return base().outputLanguage; |
116 |
|
} |
117 |
58772 |
template <> const options::outputLanguage__option_t::type& Options::operator[]( |
118 |
|
options::outputLanguage__option_t) const |
119 |
|
{ |
120 |
58772 |
return base().outputLanguage; |
121 |
|
} |
122 |
3019 |
template <> bool Options::wasSetByUser(options::outputLanguage__option_t) const |
123 |
|
{ |
124 |
3019 |
return base().outputLanguage__setByUser__; |
125 |
|
} |
126 |
16 |
template <> options::parseOnly__option_t::type& Options::ref( |
127 |
|
options::parseOnly__option_t) |
128 |
|
{ |
129 |
16 |
return base().parseOnly; |
130 |
|
} |
131 |
312412 |
template <> const options::parseOnly__option_t::type& Options::operator[]( |
132 |
|
options::parseOnly__option_t) const |
133 |
|
{ |
134 |
312412 |
return base().parseOnly; |
135 |
|
} |
136 |
|
template <> bool Options::wasSetByUser(options::parseOnly__option_t) const |
137 |
|
{ |
138 |
|
return base().parseOnly__setByUser__; |
139 |
|
} |
140 |
|
template <> options::preprocessOnly__option_t::type& Options::ref( |
141 |
|
options::preprocessOnly__option_t) |
142 |
|
{ |
143 |
|
return base().preprocessOnly; |
144 |
|
} |
145 |
14310 |
template <> const options::preprocessOnly__option_t::type& Options::operator[]( |
146 |
|
options::preprocessOnly__option_t) const |
147 |
|
{ |
148 |
14310 |
return base().preprocessOnly; |
149 |
|
} |
150 |
|
template <> bool Options::wasSetByUser(options::preprocessOnly__option_t) const |
151 |
|
{ |
152 |
|
return base().preprocessOnly__setByUser__; |
153 |
|
} |
154 |
|
template <> options::printSuccess__option_t::type& Options::ref( |
155 |
|
options::printSuccess__option_t) |
156 |
|
{ |
157 |
|
return base().printSuccess; |
158 |
|
} |
159 |
36 |
template <> const options::printSuccess__option_t::type& Options::operator[]( |
160 |
|
options::printSuccess__option_t) const |
161 |
|
{ |
162 |
36 |
return base().printSuccess; |
163 |
|
} |
164 |
10092 |
template <> bool Options::wasSetByUser(options::printSuccess__option_t) const |
165 |
|
{ |
166 |
10092 |
return base().printSuccess__setByUser__; |
167 |
|
} |
168 |
|
template <> options::statistics__option_t::type& Options::ref( |
169 |
|
options::statistics__option_t) |
170 |
|
{ |
171 |
|
return base().statistics; |
172 |
|
} |
173 |
5877 |
template <> const options::statistics__option_t::type& Options::operator[]( |
174 |
|
options::statistics__option_t) const |
175 |
|
{ |
176 |
5877 |
return base().statistics; |
177 |
|
} |
178 |
|
template <> bool Options::wasSetByUser(options::statistics__option_t) const |
179 |
|
{ |
180 |
|
return base().statistics__setByUser__; |
181 |
|
} |
182 |
|
template <> options::statisticsAll__option_t::type& Options::ref( |
183 |
|
options::statisticsAll__option_t) |
184 |
|
{ |
185 |
|
return base().statisticsAll; |
186 |
|
} |
187 |
|
template <> const options::statisticsAll__option_t::type& Options::operator[]( |
188 |
|
options::statisticsAll__option_t) const |
189 |
|
{ |
190 |
|
return base().statisticsAll; |
191 |
|
} |
192 |
|
template <> bool Options::wasSetByUser(options::statisticsAll__option_t) const |
193 |
|
{ |
194 |
|
return base().statisticsAll__setByUser__; |
195 |
|
} |
196 |
|
template <> options::statisticsEveryQuery__option_t::type& Options::ref( |
197 |
|
options::statisticsEveryQuery__option_t) |
198 |
|
{ |
199 |
|
return base().statisticsEveryQuery; |
200 |
|
} |
201 |
15337 |
template <> const options::statisticsEveryQuery__option_t::type& Options::operator[]( |
202 |
|
options::statisticsEveryQuery__option_t) const |
203 |
|
{ |
204 |
15337 |
return base().statisticsEveryQuery; |
205 |
|
} |
206 |
|
template <> bool Options::wasSetByUser(options::statisticsEveryQuery__option_t) const |
207 |
|
{ |
208 |
|
return base().statisticsEveryQuery__setByUser__; |
209 |
|
} |
210 |
|
template <> options::statisticsExpert__option_t::type& Options::ref( |
211 |
|
options::statisticsExpert__option_t) |
212 |
|
{ |
213 |
|
return base().statisticsExpert; |
214 |
|
} |
215 |
|
template <> const options::statisticsExpert__option_t::type& Options::operator[]( |
216 |
|
options::statisticsExpert__option_t) const |
217 |
|
{ |
218 |
|
return base().statisticsExpert; |
219 |
|
} |
220 |
|
template <> bool Options::wasSetByUser(options::statisticsExpert__option_t) const |
221 |
|
{ |
222 |
|
return base().statisticsExpert__setByUser__; |
223 |
|
} |
224 |
169 |
template <> options::verbosity__option_t::type& Options::ref( |
225 |
|
options::verbosity__option_t) |
226 |
|
{ |
227 |
169 |
return base().verbosity; |
228 |
|
} |
229 |
617033 |
template <> const options::verbosity__option_t::type& Options::operator[]( |
230 |
|
options::verbosity__option_t) const |
231 |
|
{ |
232 |
617033 |
return base().verbosity; |
233 |
|
} |
234 |
|
template <> bool Options::wasSetByUser(options::verbosity__option_t) const |
235 |
|
{ |
236 |
|
return base().verbosity__setByUser__; |
237 |
|
} |
238 |
|
|
239 |
|
namespace options { |
240 |
|
|
241 |
|
thread_local struct binary_name__option_t binary_name; |
242 |
|
thread_local struct err__option_t err; |
243 |
|
thread_local struct in__option_t in; |
244 |
|
thread_local struct inputLanguage__option_t inputLanguage; |
245 |
|
thread_local struct languageHelp__option_t languageHelp; |
246 |
|
thread_local struct out__option_t out; |
247 |
|
thread_local struct outputLanguage__option_t outputLanguage; |
248 |
|
thread_local struct parseOnly__option_t parseOnly; |
249 |
|
thread_local struct preprocessOnly__option_t preprocessOnly; |
250 |
|
thread_local struct printSuccess__option_t printSuccess; |
251 |
|
thread_local struct statistics__option_t statistics; |
252 |
|
thread_local struct statisticsAll__option_t statisticsAll; |
253 |
|
thread_local struct statisticsEveryQuery__option_t statisticsEveryQuery; |
254 |
|
thread_local struct statisticsExpert__option_t statisticsExpert; |
255 |
|
thread_local struct verbosity__option_t verbosity; |
256 |
|
|
257 |
|
|
258 |
|
|
259 |
|
} // namespace options |
260 |
28191 |
} // namespace cvc5 |
261 |
|
// clang-format on |