minor opt: avoid walking allterms if not needed: no stemlangs + stripchars
This commit is contained in:
parent
cb1e6a56be
commit
abc83bd22c
1 changed files with 9 additions and 0 deletions
|
@ -45,6 +45,15 @@ bool createExpansionDbs(Xapian::WritableDatabase& wdb,
|
||||||
|
|
||||||
// Erase and recreate all the expansion groups
|
// Erase and recreate all the expansion groups
|
||||||
|
|
||||||
|
// If langs is empty and we don't need casediac expansion, then no need to
|
||||||
|
// walk the big list
|
||||||
|
if (langs.empty()) {
|
||||||
|
#ifndef RCL_INDEX_STRIPCHARS
|
||||||
|
if (o_index_stripchars)
|
||||||
|
#endif
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
// Stem dbs
|
// Stem dbs
|
||||||
vector<XapWritableComputableSynFamMember> stemdbs;
|
vector<XapWritableComputableSynFamMember> stemdbs;
|
||||||
// Note: tried to make this to work with stack-allocated objects, couldn't.
|
// Note: tried to make this to work with stack-allocated objects, couldn't.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue