Some more debugging stuff.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36404 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Tommaso Cucinotta 2010-11-20 11:03:24 +00:00
parent 08f49bc27a
commit 55641a1a74

View File

@ -766,7 +766,9 @@ int MatchStringAdv::findAux(DocIterator const & cur, int len, bool at_begin) con
string str = normalize(docstr); string str = normalize(docstr);
LYXERR(Debug::FIND, "After normalization: '" << str << "'"); LYXERR(Debug::FIND, "After normalization: '" << str << "'");
if (! opt.regexp) { if (! opt.regexp) {
LYXERR(Debug::FIND, "Searching in normal mode: par_as_string='" << par_as_string << "', str='" << str << "'");
if (at_begin) { if (at_begin) {
LYXERR(Debug::FIND, "size=" << par_as_string.size() << ", substr='" << str.substr(0, par_as_string.size()) << "'");
if (str.substr(0, par_as_string.size()) == par_as_string) if (str.substr(0, par_as_string.size()) == par_as_string)
return par_as_string.size(); return par_as_string.size();
} else { } else {
@ -775,6 +777,7 @@ int MatchStringAdv::findAux(DocIterator const & cur, int len, bool at_begin) con
return par_as_string.size(); return par_as_string.size();
} }
} else { } else {
LYXERR(Debug::FIND, "Searching in regexp mode");
// Try all possible regexp matches, // Try all possible regexp matches,
//until one that verifies the braces match test is found //until one that verifies the braces match test is found
regex const *p_regexp = at_begin ? &regexp : &regexp2; regex const *p_regexp = at_begin ? &regexp : &regexp2;