Apparently, terms with a common prefix are *not* connected by implicit "OR"
david at tethera.net
Sun Aug 11 16:08:58 PDT 2019
jorge+list at disroot.org (Jorge P. de Morais Neto) writes:
> Hi. The NOTMUCH-SEARCH-TERMS man page says:
> Each term in the query will be implicitly connected by a logical AND
> if no explicit operator is provided (except that terms with a common
> prefix will be implicitly combined with OR).
> However, in practice I get different results:
> $ notmuch count '(to:pontodosconcursos.com.br OR to:jorge+cp+concurso at disroot.org)'
> $ notmuch count '(to:pontodosconcursos.com.br to:jorge+cp+concurso at disroot.org)'
Thanks for the report. As a test, can you try with
$ notmuch count '(to:pontodosconcursos.com.br to:"jorge+cp+concurso at disroot.org")'
I suspect that will work around the problem, which I believe is related
to the way that notmuch uses the xapian parser (in order to provide
regexp matching for some prefixes). In particular, if I try that with
NOTMUCH_DEBUG_QUERY=yes in the environment I can see the implicit OR.
More information about the notmuch