Community
Participate
Working Groups
Command: ajc -Xlint -sourceroots simple && java simple/Except Error: Exception in thread "main" java.lang.VerifyError: (class: simple/Except, method: <clinit> signature: ()V) catch_type not a subclass of Throwable Class: package simple; public class Except { public static void a(){ b(); } /** * Method b. */ private static void b() { throw new RuntimeException("Orig"); } public static void main(String[] args) { try { a(); } catch (SoftException e) { System.out.println(e.getWrappedThrowable()); } } public static interface Checked{ } static aspect Softner{ declare parents : Exception+ && !RuntimeException implements Checked; declare soft : Checked : within(Except); } }
fixed in cvs tree, test case at tests/bugs/DeclareSoftCf.java