// some syntatical issue
if (expr.getLastToken().endColumn < _elText.trim().length()-1)
{
final int offset = _context.getDocumentPosition() + expr.getLastToken().endColumn;
final int length = _elText.trim().length() - expr.getLastToken().endColumn;
final Diagnostic diagnostic =
_diagnosticFactory.create_GENERAL_SYNTAX_ERROR();
_reporter.report(diagnostic, offset, length);
}
return expr;
}
catch (ParseException e) {
Token curTok = e.currentToken;
int offset = _context.getDocumentPosition() + curTok.beginColumn;
int length = curTok.endColumn - curTok.beginColumn + 1;
final Diagnostic diagnostic = _diagnosticFactory.create_GENERAL_SYNTAX_ERROR();
_reporter.report(diagnostic, offset, length);
return null;
}
catch (TokenMgrError te) {
final int offset = _context.getDocumentPosition();
final int length = _elText.length();
final Diagnostic diagnostic =
_diagnosticFactory.create_GENERAL_SYNTAX_ERROR();
_reporter.report(diagnostic, offset, length);
return null;
}
}