diff -r 0384683c64be -r ddb4a2bfcd82 test/tools/javac/annotations/typeAnnotations/referenceinfos/MethodThrows.java --- a/test/tools/javac/annotations/typeAnnotations/referenceinfos/MethodThrows.java Tue May 14 13:55:35 2013 -0700 +++ b/test/tools/javac/annotations/typeAnnotations/referenceinfos/MethodThrows.java Tue May 14 15:04:06 2013 -0700 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -54,4 +54,24 @@ public String interfaceMethod() { return "interface Test { void test() throws @TA RuntimeException, IllegalArgumentException, @TB Exception; }"; } + + @TADescriptions({ + @TADescription(annotation = "TA", type = THROWS, typeIndex = 0, + genericLocation = {}), + @TADescription(annotation = "TB", type = THROWS, typeIndex = 0, + genericLocation = {1, 0}), + @TADescription(annotation = "TC", type = THROWS, typeIndex = 0, + genericLocation = {1, 0, 1, 0}), + @TADescription(annotation = "TD", type = THROWS, typeIndex = 1, + genericLocation = {}), + @TADescription(annotation = "TE", type = THROWS, typeIndex = 1, + genericLocation = {1, 0}), + @TADescription(annotation = "TF", type = THROWS, typeIndex = 1, + genericLocation = {1, 0, 1, 0}) + }) + public String NestedTypes() { + return "class Outer { class Middle { class Inner1 extends Exception {}" + + " class Inner2 extends Exception{} } }" + + "class Test { void test() throws @TA Outer.@TB Middle.@TC Inner1, @TD Outer.@TE Middle.@TF Inner2 { } }"; + } }