aboutsummaryrefslogtreecommitdiff
path: root/lib/query.cc
diff options
context:
space:
mode:
authorDavid Bremner <david@tethera.net>2021-08-24 08:17:16 -0700
committerDavid Bremner <david@tethera.net>2021-09-04 17:07:19 -0700
commitbe7e83de96b706af418fc9f139ded4d50bf342f6 (patch)
tree35350510d2fdb3302d8625fdd730463756536ed5 /lib/query.cc
parent9ae4188610dc21101fe9bdeb158854fc7c63463e (diff)
lib/parse-sexp: parse single terms and the empty list.
There is not much of a parser here yet, but it already does some useful error reporting. Most functionality sketched in the documentation is not implemented yet; detailed documentation will follow with the implementation.
Diffstat (limited to 'lib/query.cc')
-rw-r--r--lib/query.cc8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/query.cc b/lib/query.cc
index a3fe3793..435f7229 100644
--- a/lib/query.cc
+++ b/lib/query.cc
@@ -23,10 +23,6 @@
#include <glib.h> /* GHashTable, GPtrArray */
-#if HAVE_SFSEXP
-#include "sexp.h"
-#endif
-
struct _notmuch_query {
notmuch_database_t *notmuch;
const char *query_string;
@@ -210,8 +206,8 @@ _notmuch_query_ensure_parsed_sexpr (notmuch_query_t *query)
if (query->parsed)
return NOTMUCH_STATUS_SUCCESS;
- query->xapian_query = Xapian::Query::MatchAll;
- return NOTMUCH_STATUS_SUCCESS;
+ return _notmuch_sexp_string_to_xapian_query (query->notmuch, query->query_string,
+ query->xapian_query);
}
static notmuch_status_t