Bug #19980 - insist on curly-brace after catch block rather than just

accepting it - forces error that allows catch block to span lines for
interactive input.
This commit is contained in:
rogerl%netscape.com 1999-12-01 23:12:58 +00:00
parent c506f95548
commit 741cf4ed39
2 changed files with 4 additions and 2 deletions

View File

@ -587,7 +587,8 @@ class Parser {
nf.createCatch(varName, catchCond,
statements(ts, source),
ts.getLineno()));
ts.matchToken(ts.RC);
mustMatchToken(ts, ts.RC, "msg.no.brace.after.body");
source.append((char)ts.RC);
source.append((char)ts.EOL);
}

View File

@ -587,7 +587,8 @@ class Parser {
nf.createCatch(varName, catchCond,
statements(ts, source),
ts.getLineno()));
ts.matchToken(ts.RC);
mustMatchToken(ts, ts.RC, "msg.no.brace.after.body");
source.append((char)ts.RC);
source.append((char)ts.EOL);
}