Fahad,
Labeled statements do not work with declarations. The following is 'labeled' declaration, which won't work:
Labels can be used with a looping statements (for, while, do), if constructs (if statement), expression, assignment, return, try, throws, and with a block. It is interesting to note that the above declaration can be defined within a block statement as follows:
A little, funny & weird story may help you to remember this Java Rule:
Boss (Java) was announcing bonus (privilege of using labels) for all its employees (language constructs) that were present in the office. 'declaration' wasn't awarded this privilege because it was away, partying, and hence missed on it.
I know its very weird and funny, but it will help you to retain this info!
cheers
Mala