posted 16 years ago
Based on my tests, it appears that:
A static block can throw any Exception as long as it's handled within the static block (not re-thrown to a level outside the block).A static block can generate an unchecked exception, but...A static block can not explicitly throw an unchecked exception without handling it. When this is attempted, a compilation error results: "initializer must be able to complete normally."
"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer
sscce.org