Class SyntaxError

java.lang.Object
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
EOFError

public class SyntaxError extends RuntimeException
Exception thrown when a syntax error is encountered during parsing.

SyntaxError is thrown by the Parser when it encounters invalid syntax in the input line. It provides information about the location of the error (line and column) and a descriptive message about the nature of the error.

This exception is typically caught by the LineReader, which may then display an error message to the user or take other appropriate action based on the parsing context.

The EOFError subclass is used specifically for incomplete input errors, such as unclosed quotes or brackets, which might be completed by additional input.

See Also: