Skip to content

Commit 7871390

Browse files
8306952: improve generic signature of internal DCInlineTag class
Reviewed-by: iris
1 parent 6983d05 commit 7871390

File tree

1 file changed

+11
-11
lines changed
  • src/jdk.compiler/share/classes/com/sun/tools/javac/tree

1 file changed

+11
-11
lines changed

src/jdk.compiler/share/classes/com/sun/tools/javac/tree/DCTree.java

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -400,7 +400,7 @@ public String getTagName() {
400400
}
401401
}
402402

403-
public abstract static class DCInlineTag extends DCEndPosTree<DCInlineTag> implements InlineTagTree {
403+
public abstract static class DCInlineTag<T extends DCEndPosTree<T>> extends DCEndPosTree<T> implements InlineTagTree {
404404
@Override @DefinedBy(Api.COMPILER_TREE)
405405
public String getTagName() {
406406
return getKind().tagName;
@@ -514,7 +514,7 @@ public List<? extends DocTree> getBody() {
514514
}
515515
}
516516

517-
public static class DCDocRoot extends DCInlineTag implements DocRootTree {
517+
public static class DCDocRoot extends DCInlineTag<DCDocRoot> implements DocRootTree {
518518

519519
@Override @DefinedBy(Api.COMPILER_TREE)
520520
public Kind getKind() {
@@ -717,7 +717,7 @@ public Name getName() {
717717
}
718718
}
719719

720-
public static class DCIndex extends DCInlineTag implements IndexTree {
720+
public static class DCIndex extends DCInlineTag<DCIndex> implements IndexTree {
721721
public final DCTree term;
722722
public final List<DCTree> description;
723723

@@ -747,7 +747,7 @@ public java.util.List<? extends DocTree> getDescription() {
747747
}
748748
}
749749

750-
public static class DCInheritDoc extends DCInlineTag implements InheritDocTree {
750+
public static class DCInheritDoc extends DCInlineTag<DCInheritDoc> implements InheritDocTree {
751751
@Override @DefinedBy(Api.COMPILER_TREE)
752752
public Kind getKind() {
753753
return Kind.INHERIT_DOC;
@@ -759,7 +759,7 @@ public <R, D> R accept(DocTreeVisitor<R, D> v, D d) {
759759
}
760760
}
761761

762-
public static class DCLink extends DCInlineTag implements LinkTree {
762+
public static class DCLink extends DCInlineTag<DCLink> implements LinkTree {
763763
public final Kind kind;
764764
public final DCReference ref;
765765
public final List<DCTree> label;
@@ -792,7 +792,7 @@ public List<? extends DocTree> getLabel() {
792792
}
793793
}
794794

795-
public static class DCLiteral extends DCInlineTag implements LiteralTree {
795+
public static class DCLiteral extends DCInlineTag<DCLiteral> implements LiteralTree {
796796
public final Kind kind;
797797
public final DCText body;
798798

@@ -1084,7 +1084,7 @@ public List<? extends DocTree> getBody() {
10841084
}
10851085
}
10861086

1087-
public static class DCSnippet extends DCInlineTag implements SnippetTree {
1087+
public static class DCSnippet extends DCInlineTag<DCSnippet> implements SnippetTree {
10881088
public final List<? extends DocTree> attributes;
10891089
public final DCText body;
10901090

@@ -1186,7 +1186,7 @@ public boolean isSelfClosing() {
11861186
}
11871187
}
11881188

1189-
public static class DCSummary extends DCInlineTag implements SummaryTree {
1189+
public static class DCSummary extends DCInlineTag<DCSummary> implements SummaryTree {
11901190
public final List<DCTree> summary;
11911191

11921192
DCSummary(List<DCTree> summary) {
@@ -1209,7 +1209,7 @@ public List<? extends DocTree> getSummary() {
12091209
}
12101210
}
12111211

1212-
public static class DCSystemProperty extends DCInlineTag implements SystemPropertyTree {
1212+
public static class DCSystemProperty extends DCInlineTag<DCSystemProperty> implements SystemPropertyTree {
12131213
public final Name propertyName;
12141214

12151215
DCSystemProperty(Name propertyName) {
@@ -1323,7 +1323,7 @@ public List<? extends DocTree> getContent() {
13231323
}
13241324
}
13251325

1326-
public static class DCUnknownInlineTag extends DCInlineTag implements UnknownInlineTagTree {
1326+
public static class DCUnknownInlineTag extends DCInlineTag<DCUnknownInlineTag> implements UnknownInlineTagTree {
13271327
public final Name name;
13281328
public final List<DCTree> content;
13291329

@@ -1383,7 +1383,7 @@ public List<? extends DocTree> getDescription() {
13831383
}
13841384
}
13851385

1386-
public static class DCValue extends DCInlineTag implements ValueTree {
1386+
public static class DCValue extends DCInlineTag<DCValue> implements ValueTree {
13871387
public final DCText format;
13881388
public final DCReference ref;
13891389

0 commit comments

Comments
 (0)