Mr_and_Mrs_D
Mr_and_Mrs_D

Reputation: 34026

eclipse "unsurround" selection (remove try/catch, if etc block)

Hitting Shift+Alt+Z having selected some text in the JDT editor one is presented with the "surround with" menu. I sometimes feel the need to do the opposite - easily remove a try catch or if block etc. So is there any way to do this (there are ways to select everything in a block so it would be easy programmatically - so maybe there is a plugin offering it ?) ?
If no way exists a bug report in eclipse jdt would be appreciated

Upvotes: 3

Views: 1331

Answers (2)

Brad Johnson
Brad Johnson

Reputation: 56

In Eclipse you can click within the catch and press Ctrl + 1 and select "Remove catch clause."

Upvotes: 4

Ravekitty
Ravekitty

Reputation: 77

I don't believe there are any plug-ins or shortcuts to remove try/catch blocks

p.s I'm not sure what a bug report is or how to make one

I hope this is enough to answer your question fully

Upvotes: -1

Related Questions