]> git.notmuchmail.org Git - notmuch/blobdiff - lib/regexp-fields.h
emacs: Add new option notmuch-search-hide-excluded
[notmuch] / lib / regexp-fields.h
index 97778a1d6200fc0a20a42d1db6ca668279784c6e..9c871de7dce50c75b5215a1ec42934e6ef9c1864 100644 (file)
 
 #ifndef NOTMUCH_REGEXP_FIELDS_H
 #define NOTMUCH_REGEXP_FIELDS_H
-#if HAVE_XAPIAN_FIELD_PROCESSOR
+
 #include <sys/types.h>
 #include <regex.h>
 #include "database-private.h"
 #include "notmuch-private.h"
 
+notmuch_status_t
+_notmuch_regex_to_query (notmuch_database_t *notmuch, Xapian::valueno slot, std::string field,
+                        std::string regexp_str,
+                        Xapian::Query &output, std::string &msg);
+
 /* A posting source that returns documents where a value matches a
  * regexp.
  */
@@ -64,6 +69,7 @@ public:
 class RegexpFieldProcessor : public Xapian::FieldProcessor {
 protected:
     Xapian::valueno slot;
+    std::string field;
     std::string term_prefix;
     notmuch_field_flag_t options;
     Xapian::QueryParser &parser;
@@ -79,5 +85,5 @@ public:
 
     Xapian::Query operator() (const std::string & str);
 };
-#endif
+
 #endif /* NOTMUCH_REGEXP_FIELDS_H */