mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-23 00:38:01 +00:00
fix parser bug if \atop etc appear inside \left ... \right
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2731 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
445f2a9851
commit
e410a7e2a4
@ -424,6 +424,7 @@ void Parser::tokenize(string const & buffer)
|
||||
void Parser::error(string const & msg)
|
||||
{
|
||||
lyxerr << "Line ~" << lineno_ << ": Math parse error: " << msg << endl;
|
||||
//exit(1);
|
||||
}
|
||||
|
||||
|
||||
@ -652,7 +653,7 @@ void Parser::parse_into(MathArray & array, unsigned flags, MathTextCodes code)
|
||||
}
|
||||
|
||||
if (flags & FLAG_BLOCK) {
|
||||
if (t.cat() == catAlign || t.cs() == "\\")
|
||||
if (t.cat() == catAlign || t.cs() == "\\" || t.cs() == "right")
|
||||
return;
|
||||
if (t.cs() == "end") {
|
||||
getArg('{', '}');
|
||||
@ -767,8 +768,10 @@ void Parser::parse_into(MathArray & array, unsigned flags, MathTextCodes code)
|
||||
}
|
||||
|
||||
else if (t.cs() == "right") {
|
||||
if (!(flags & FLAG_RIGHT))
|
||||
if (!(flags & FLAG_RIGHT)) {
|
||||
lyxerr << "got so far: '" << array << "'\n";
|
||||
error("Unmatched right delimiter");
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user