diff options
author | Andrew Sapperstein <asapperstein@google.com> | 2020-08-10 14:50:13 +0000 |
---|---|---|
committer | Andrew Sapperstein <asapperstein@google.com> | 2020-08-10 14:52:57 +0000 |
commit | 24c6e9fb4585b34ec3fc11936ba900844940dfcc (patch) | |
tree | 4097c6984c74d6f1d777ba9631814ec54743e92f | |
parent | 696f76f1d7a523ae9663ebecd7035e459fe89d19 (diff) | |
download | doclava-24c6e9fb4585b34ec3fc11936ba900844940dfcc.tar.gz |
Remove workaround to suppress reference errors.
Leanback prebuilt is being updated so we can remove this workaround.
Bug: 6963924
Change-Id: I187f53f1567ec0c13e2d6c77fab228cc61dfb95d
Fixes: 155814218
Fixes: 163313403
-rw-r--r-- | src/com/google/doclava/Converter.java | 21 | ||||
-rw-r--r-- | src/com/google/doclava/Doclava.java | 7 |
2 files changed, 1 insertions, 27 deletions
diff --git a/src/com/google/doclava/Converter.java b/src/com/google/doclava/Converter.java index 030cdad..cf14237 100644 --- a/src/com/google/doclava/Converter.java +++ b/src/com/google/doclava/Converter.java @@ -501,28 +501,9 @@ public class Converter { return result; } else { ConstructorDoc m = (ConstructorDoc) o; - String name = m.name(); - if (Doclava.SUPPRESS_REFERENCE_ERRORS) { - // Workaround for a JavaDoc behavior change introduced in OpenJDK 8 that breaks - // links in documentation and the content of API files like current.txt. - // http://b/18051133. - ClassDoc containingClass = m.containingClass(); - if (containingClass.containingClass() != null) { - // This should detect the new behavior and be bypassed otherwise. - String qualName = containingClass.qualifiedName(); - if (!name.contains(".") - && ("androidx.leanback.widget.GuidedAction.Builder".equals(qualName) - || "androidx.leanback.widget.RowHeaderPresenter.ViewHolder".equals(qualName))) { - // Constructors of inner classes do not contain the name of the enclosing class - // with OpenJDK 8. This simulates the old behavior: - name = containingClass.name(); - } - } - } - // End of workaround. MethodInfo result = new MethodInfo(m.getRawCommentText(), new ArrayList<TypeInfo>(Arrays.asList(Converter.convertTypes(m.typeParameters()))), - name, m.signature(), Converter.obtainClass(m.containingClass()), Converter + m.name(), m.signature(), Converter.obtainClass(m.containingClass()), Converter .obtainClass(m.containingClass()), m.isPublic(), m.isProtected(), m .isPackagePrivate(), m.isPrivate(), m.isFinal(), m.isStatic(), m.isSynthetic(), false, m.isSynchronized(), m.isNative(), false/*isDefault*/, false, "constructor", m.flatSignature(), diff --git a/src/com/google/doclava/Doclava.java b/src/com/google/doclava/Doclava.java index 493676c..049e93e 100644 --- a/src/com/google/doclava/Doclava.java +++ b/src/com/google/doclava/Doclava.java @@ -80,8 +80,6 @@ public class Doclava { public static boolean USE_DEVSITE_LOCALE_OUTPUT_PATHS = false; /* generate navtree.js without other docs */ public static boolean NAVTREE_ONLY = false; - /* Suppress errors in LinkReference.parse (@see/@link) errors. */ - public static boolean SUPPRESS_REFERENCE_ERRORS = false; /* Generate reference navtree.js with all inherited members */ public static boolean AT_LINKS_NAVTREE = false; public static boolean METALAVA_API_SINCE = false; @@ -408,8 +406,6 @@ public class Doclava { manifestFile = a[1]; } else if (a[0].equals("-compatconfig")) { compatConfig = a[1]; - } else if (a[0].equals("-suppressReferenceErrors")) { - SUPPRESS_REFERENCE_ERRORS = true; } } @@ -973,9 +969,6 @@ public class Doclava { if (option.equals("-compatconfig")) { return 2; } - if (option.equals("-suppressReferenceErrors")) { - return 1; - } return 0; } public static boolean validOptions(String[][] options, DocErrorReporter r) { |