Mmm, maybe I was not totally clear if you did not read my answer to Taher.
I meant to remove the useless try and catch. We have 70+ other cases like that
w/o try and catch
Jacques
Le 29/03/2017 à 11:01, Jacques Le Roux a écrit :
I think we can all agree to remove it
Jacques
Le 29/03/2017 à 09:45, Jacopo Cappellato a écrit :
On Tue, Mar 28, 2017 at 7:38 PM, Jacques Le Roux <
[email protected]> wrote:
Yikes, I thought it was clear. I mean that people should not be worried
about this swallowed exception because it's intended since no
PatternSyntaxException should not occur there
I can confirm that the comment you have added is not clear, and even the
explanatory sentence you wrote above is confusing.
I think it's better to say something than letting the catch empty.
It is better to add *useful* information but if you are adding a comment
that is stating the obvious then it is better to leave it empty.
Maybe what I said is not what I wanted to say and can be understood in
another way? What did you understand?
When I read your comment:
"obviously a PatternSyntaxException should not occur here"
I think: "hmmmm... it doesn't seem obvious to me that such an exception
should not occur... but if the committer stated it is *obvious* then it
means I am missing something"
Instead, at least based on your reply to Taher, it seems that you ignore
why the catch block was added.
What would you say?
I would either explain why the code is swallowing the runtime exception or
remove your comment.
Jacopo