lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eugene Gluzberg" <drag...@yahoo.com>
Subject Re: about my proposed patch for bug 7782
Date Mon, 15 Apr 2002 14:55:32 GMT
Although I agree with you in theory, in practice we need to be backwards
compatable as well is absolutelly correct.

ParseException also does not nesseserally mean "syntax error", it indicates
an error encountered during parsing.

If you would like we can create 3 exception classes:
ParseException
TokenMgrException extends ParseException
SyntaxException extends ParseException

but that would require significant changes thoughout the code, which IMHO
should not be in this release.

For this release we should just throw a ParseException.

>
> To make a source code analogy:  "return if break;" contains a set of
> valid tokens for the Java language, but the syntax is invalid, making a
> ParseException the right kind of error to raise.  Conversely, "swAtch
> (c) { }" contains characters which cannot be recognized by the lexer as
> a legal token, so a TokenMgrException is appropriate.
>
> I would strongly urge against blurring the distinction between these
> two classes of error, as they really are not the same thing.
>
> Eric
>
>
> --
> To unsubscribe, e-mail:
<mailto:lucene-dev-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
<mailto:lucene-dev-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:lucene-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:lucene-dev-help@jakarta.apache.org>


Mime
View raw message