changeset 47362:e729cef2af4b

8186873: Possible dead code \"com.sun.tools.javac.tree.TreeInfo.isAnonymousDiamond()\" which was added in 9 Summary: Removing unused method. Reviewed-by: mcimadamore
author jlahoda
date Thu, 19 Oct 2017 09:53:53 +0200
parents 74e1913a98c0
children 77c792d06646
files src/jdk.compiler/share/classes/com/sun/tools/javac/tree/TreeInfo.java
diffstat 1 files changed, 0 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/tree/TreeInfo.java	Thu Oct 19 09:01:29 2017 +0200
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/tree/TreeInfo.java	Thu Oct 19 09:53:53 2017 +0200
@@ -198,18 +198,6 @@
         }
     }
 
-    /** Return true if the given tree represents a type elided anonymous class instance creation. */
-    public static boolean isAnonymousDiamond(JCTree tree) {
-        switch(tree.getTag()) {
-            case NEWCLASS:  {
-                JCNewClass nc = (JCNewClass)tree;
-                return nc.def != null && isDiamond(nc.clazz);
-            }
-            case ANNOTATED_TYPE: return isAnonymousDiamond(((JCAnnotatedType)tree).underlyingType);
-            default: return false;
-        }
-    }
-
     public static boolean isEnumInit(JCTree tree) {
         switch (tree.getTag()) {
             case VARDEF: