# expression (no |, no \<, ...).
Debug_tags.tmp Trace_tags.tmp:
$(AM_V_GEN)\
- grep '\<$(@:_tags.tmp=) *( *\".*\" *)' \
+ grep '\<$(@:_tags.tmp=)\(\.isOn\)\? *( *\".*\" *)' \
`find @srcdir@/../ -name "*.cpp" -or -name "*.h" -or -name "*.cc" -or -name "*.g"` | \
- sed 's/^$(@:_tags.tmp=) *( *\"\([^"]*\)\".*/\1/;s/.*[^a-zA-Z0-9_]$(@:_tags.tmp=) *( *\"\([^"]*\)\".*/\1/' | sort | uniq >"$@"
+ sed 's/^$(@:_tags.tmp=)\(.isOn\)\? *( *\"\([^"]*\)\".*/\2/;s/.*[^a-zA-Z0-9_]$(@:_tags.tmp=)\(\.isOn\)\? *( *\"\([^"]*\)\".*/\2/' | sort | uniq >"$@"
if CVC4_CLN_IMP
libutil_la_SOURCES += \
return strcmp(*s1,*s2);
}
-bool Configuration::isDebugTag(char const *){
+bool Configuration::isDebugTag(char const *tag){
#if CVC4_DEBUG
unsigned ntags = getNumDebugTags();
char const* const* tags = getDebugTags();
- return (bsearch(&optarg, tags, ntags, sizeof(char *),
- (int(*)(const void*,const void*))strcmpptr) != NULL);
-#else /* CVC4_DEBUG */
+ for (unsigned i = 0; i < ntags; ++ i) {
+ if (strcmp(tag, tags[i]) == 0) {
+ return true;
+ }
+ }
+#endif * CVC4_DEBUG */
return false;
-#endif /* CVC4_DEBUG */
}
unsigned Configuration::getNumTraceTags() {
#endif /* CVC4_TRACING */
}
-bool Configuration::isTraceTag(char const *){
+bool Configuration::isTraceTag(char const * tag){
#if CVC4_TRACING
unsigned ntags = getNumTraceTags();
char const* const* tags = getTraceTags();
- return (bsearch(&optarg, tags, ntags, sizeof(char *),
- (int(*)(const void*,const void*))strcmpptr) != NULL);
-#else /* CVC4_TRACING */
- return false;
+ for (unsigned i = 0; i < ntags; ++ i) {
+ if (strcmp(tag, tags[i]) == 0) {
+ return true;
+ }
+ }
#endif /* CVC4_TRACING */
+ return false;
}
bool Configuration::isSubversionBuild() {