On Tue, Jul 18, 2023 at 10:54 PM Phil Steitz <phil.ste...@gmail.com> wrote:
>
> I am going through now and comparing diffs of 2.11.1 and head of 2.x to
> make sure that me and sed did not do anything wrong and I am seeing a bunch
> of things like this:
>
> -    void addObject() throws Exception, IllegalStateException,
> -            UnsupportedOperationException;
> +    void addObject() throws Exception;
>
> Where the new version is the 2.x code.  I am inclined to leave as is, maybe
> adding comments in some places indicating when the unchecked exceptions
> might be thrown.  Any objections?
>

That sounds good. This is generally best practice for runtime
exceptions. Don't include them in throws clauses but do include
@throws Javadoc for each one.

-- 
Elliotte Rusty Harold
elh...@ibiblio.org

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org
For additional commands, e-mail: dev-h...@commons.apache.org

Reply via email to