garydgregory edited a comment on pull request #204:
URL: https://github.com/apache/commons-io/pull/204#issuecomment-780218203


   -1: Probably a good idea but not in this form. Most (if not all) of Commons 
IO uses `IndexOutOfBoundsException` for this type of failure, so if you want to 
make such a change, it should be done consistently _throughout_ the code, not 
in just one random location. Currently I see 10 locations that throw  
`IndexOutOfBoundsException`.
   
   The argument against is that the JRE uses `IndexOutOfBoundsException` in 
methods like `java.io.InputStream.read(byte[], int, int)` and 
`java.io.BufferedWriter.write(char[], int, int)`, so we have to ask ourselves 
if we want to diverge from that pattern. IMO, probably. Let's if any one else 
opines.
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to