I have some code that is parsing an int from a string:
int number = Integer.parseInt(a[0]);
there is no guarantee that the string I will receive is well formed and this may throw a NumberFormatException. However, as this exception is optional, Eclipse does not give me a light bulb for generating it.
Is there a menu or context menu option to wrap an exception of a method beneath the cursor or carrot?