changeset 4324:02ee240d5948

Merge
author alanb
date Thu, 29 Sep 2016 17:49:42 +0100
parents 8684b932d0cf 90dd93e668a5
children 41a71836e768
files src/jdk.compiler/share/classes/com/sun/tools/javac/api/JavacTrees.java src/jdk.compiler/share/classes/com/sun/tools/javac/code/Flags.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Attr.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Flow.java src/jdk.compiler/share/classes/com/sun/tools/javac/file/BaseFileManager.java src/jdk.compiler/share/classes/com/sun/tools/javac/file/Locations.java src/jdk.compiler/share/classes/com/sun/tools/javac/processing/JavacProcessingEnvironment.java src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstantsSummaryWriterImpl.java src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleWriterImpl.java src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexWriter.java src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageWriterImpl.java src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlStyle.java src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/resources/stylesheet.css src/jdk.jdeps/share/classes/com/sun/tools/jdeps/Analyzer.java src/jdk.jdeps/share/classes/com/sun/tools/jdeps/Archive.java src/jdk.jdeps/share/classes/com/sun/tools/jdeps/ClassFileReader.java src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsConfiguration.java src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsTask.java src/jdk.jdeps/share/classes/com/sun/tools/jdeps/resources/jdeps.properties test/jdk/javadoc/doclet/testAnnotationTypes/TestAnnotationTypes.java test/jdk/javadoc/doclet/testJavaFX/TestJavaFX.java test/jdk/javadoc/doclet/testModules/TestModules.java test/jdk/javadoc/doclet/testTypeAnnotations/TestTypeAnnotations.java test/jdk/javadoc/tool/modules/Modules.java
diffstat 81 files changed, 2042 insertions(+), 396 deletions(-) [+]
line wrap: on
line diff
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/api/JavacTrees.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/api/JavacTrees.java	Thu Sep 29 17:49:42 2016 +0100
@@ -383,18 +383,16 @@
         JCTree tree = (JCTree) path.getLeaf();
         Symbol sym = TreeInfo.symbolFor(tree);
         if (sym == null) {
-            if (TreeInfo.isDeclaration(tree)) {
-                for (TreePath p = path; p != null; p = p.getParentPath()) {
-                    JCTree t = (JCTree) p.getLeaf();
-                    if (t.hasTag(JCTree.Tag.CLASSDEF)) {
-                        JCClassDecl ct = (JCClassDecl) t;
-                        if (ct.sym != null) {
-                            if ((ct.sym.flags_field & Flags.UNATTRIBUTED) != 0) {
-                                attr.attribClass(ct.pos(), ct.sym);
-                                sym = TreeInfo.symbolFor(tree);
-                            }
-                            break;
+            for (TreePath p = path; p != null; p = p.getParentPath()) {
+                JCTree t = (JCTree) p.getLeaf();
+                if (t.hasTag(JCTree.Tag.CLASSDEF)) {
+                    JCClassDecl ct = (JCClassDecl) t;
+                    if (ct.sym != null) {
+                        if ((ct.sym.flags_field & Flags.UNATTRIBUTED) != 0) {
+                            attr.attribClass(ct.pos(), ct.sym);
+                            sym = TreeInfo.symbolFor(tree);
                         }
+                        break;
                     }
                 }
             }
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Flags.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Flags.java	Thu Sep 29 17:49:42 2016 +0100
@@ -134,7 +134,7 @@
     /** Flag is set for nested classes that do not access instance members
      *  or `this' of an outer class and therefore don't need to be passed
      *  a this$n reference.  This value is currently set only for anonymous
-     *  classes in superclass constructor calls and only for pre 1.4 targets.
+     *  classes in superclass constructor calls.
      *  todo: use this value for optimizing away this$n parameters in
      *  other cases.
      */
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/TypeAnnotationPosition.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/TypeAnnotationPosition.java	Thu Sep 29 17:49:42 2016 +0100
@@ -789,7 +789,7 @@
         classExtends(final List<TypePathEntry> location,
                      final JCLambda onLambda,
                      final int pos) {
-        return classExtends(location, onLambda, -1, pos);
+        return classExtends(location, onLambda, 65535, pos);
     }
 
     /**
@@ -821,7 +821,7 @@
      * @param pos The position from the associated tree node.
      */
     public static TypeAnnotationPosition classExtends(final int pos) {
-        return classExtends(-1, pos);
+        return classExtends(65535, pos);
     }
 
     /**
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Attr.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Attr.java	Thu Sep 29 17:49:42 2016 +0100
@@ -921,13 +921,11 @@
                 c.complete();
 
                 // If this class appears as an anonymous class
-                // in a superclass constructor call where
-                // no explicit outer instance is given,
+                // in a superclass constructor call
                 // disable implicit outer instance from being passed.
                 // (This would be an illegal access to "this before super").
                 if (env.info.isSelfCall &&
-                        env.tree.hasTag(NEWCLASS) &&
-                        ((JCNewClass)env.tree).encl == null) {
+                        env.tree.hasTag(NEWCLASS)) {
                     c.flags_field |= NOOUTERTHIS;
                 }
                 attribClass(tree.pos(), c);
@@ -1453,7 +1451,7 @@
             try {
                 close = rs.resolveQualifiedMethod(pos,
                         env,
-                        resource,
+                        types.skipTypeVars(resource, false),
                         names.close,
                         List.<Type>nil(),
                         List.<Type>nil());
@@ -2329,6 +2327,9 @@
     /** Make an attributed null check tree.
      */
     public JCExpression makeNullCheck(JCExpression arg) {
+        // optimization: new Outer() can never be null; skip null check
+        if (arg.getTag() == NEWCLASS)
+            return arg;
         // optimization: X.this is never null; skip null check
         Name name = TreeInfo.name(arg);
         if (name == names._this || name == names._super) return arg;
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Flow.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Flow.java	Thu Sep 29 17:49:42 2016 +0100
@@ -1098,7 +1098,7 @@
                     if (types.asSuper(sup, syms.autoCloseableType.tsym) != null) {
                         Symbol closeMethod = rs.resolveQualifiedMethod(tree,
                                 attrEnv,
-                                sup,
+                                types.skipTypeVars(sup, false),
                                 names.close,
                                 List.<Type>nil(),
                                 List.<Type>nil());
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/file/BaseFileManager.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/file/BaseFileManager.java	Thu Sep 29 17:49:42 2016 +0100
@@ -291,6 +291,7 @@
 
             case MULTIRELEASE:
                 multiReleaseValue = value;
+                locations.setMultiReleaseValue(value);
                 return true;
 
             default:
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/file/Locations.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/file/Locations.java	Thu Sep 29 17:49:42 2016 +0100
@@ -130,6 +130,7 @@
 
     Map<Path, FileSystem> fileSystems = new LinkedHashMap<>();
     List<Closeable> closeables = new ArrayList<>();
+    private Map<String,String> fsEnv = Collections.emptyMap();
 
     Locations() {
         initHandlers();
@@ -207,6 +208,10 @@
         return entries;
     }
 
+    public void setMultiReleaseValue(String multiReleaseValue) {
+        fsEnv = Collections.singletonMap("multi-release", multiReleaseValue);
+    }
+
     /**
      * Utility class to help evaluate a path option. Duplicate entries are ignored, jar class paths
      * can be expanded.
@@ -1047,7 +1052,8 @@
                 }
 
                 if (p.getFileName().toString().endsWith(".jar") && fsInfo.exists(p)) {
-                    try (FileSystem fs = FileSystems.newFileSystem(p, null)) {
+                    URI uri = URI.create("jar:" + p.toUri());
+                    try (FileSystem fs = FileSystems.newFileSystem(uri, fsEnv, null)) {
                         Path moduleInfoClass = fs.getPath("module-info.class");
                         if (Files.exists(moduleInfoClass)) {
                             String moduleName = readModuleName(moduleInfoClass);
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/processing/JavacProcessingEnvironment.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/processing/JavacProcessingEnvironment.java	Thu Sep 29 17:49:42 2016 +0100
@@ -1503,13 +1503,35 @@
                 }
             }
             public void visitClassDef(JCClassDecl node) {
+                super.visitClassDef(node);
+                // remove generated constructor that may have been added during attribution:
+                List<JCTree> beforeConstructor = List.nil();
+                List<JCTree> defs = node.defs;
+                while (defs.nonEmpty() && !defs.head.hasTag(Tag.METHODDEF)) {
+                    beforeConstructor = beforeConstructor.prepend(defs.head);
+                    defs = defs.tail;
+                }
+                if (defs.nonEmpty() &&
+                    (((JCMethodDecl) defs.head).mods.flags & Flags.GENERATEDCONSTR) != 0) {
+                    defs = defs.tail;
+                    while (beforeConstructor.nonEmpty()) {
+                        defs = defs.prepend(beforeConstructor.head);
+                        beforeConstructor = beforeConstructor.tail;
+                    }
+                    node.defs = defs;
+                }
                 if (node.sym != null) {
                     node.sym.completer = new ImplicitCompleter(topLevel);
                 }
                 node.sym = null;
-                super.visitClassDef(node);
             }
             public void visitMethodDef(JCMethodDecl node) {
+                // remove super constructor call that may have been added during attribution:
+                if (TreeInfo.isConstructor(node) && node.sym != null && node.sym.owner.isEnum() &&
+                    node.body.stats.nonEmpty() && TreeInfo.isSuperCall(node.body.stats.head) &&
+                    node.body.stats.head.pos == node.body.pos) {
+                    node.body.stats = node.body.stats.tail;
+                }
                 node.sym = null;
                 super.visitMethodDef(node);
             }
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractMemberWriter.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractMemberWriter.java	Thu Sep 29 17:49:42 2016 +0100
@@ -424,12 +424,15 @@
             Content tbody = new HtmlTree(HtmlTag.TBODY);
             boolean altColor = true;
             for (Element member : deprmembers) {
-                HtmlTree td = HtmlTree.TD(HtmlStyle.colOne, getDeprecatedLink(member));
+                HtmlTree thRow = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, getDeprecatedLink(member));
+                HtmlTree tr = HtmlTree.TR(thRow);
+                HtmlTree td = new HtmlTree(HtmlTag.TD);
+                td.addStyle(HtmlStyle.colLast);
                 List<? extends DocTree> deprTrees = utils.getBlockTags(member, DocTree.Kind.DEPRECATED);
                 if (!deprTrees.isEmpty()) {
                     writer.addInlineDeprecatedComment(member, deprTrees.get(0), td);
                 }
-                HtmlTree tr = HtmlTree.TR(td);
+                tr.addContent(td);
                 tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
                 altColor = !altColor;
                 tbody.addContent(tr);
@@ -477,8 +480,9 @@
                 tdFirst.addStyle(HtmlStyle.colFirst);
                 writer.addSummaryType(this, element, tdFirst);
                 tr.addContent(tdFirst);
-                HtmlTree tdLast = new HtmlTree(HtmlTag.TD);
-                tdLast.addStyle(HtmlStyle.colLast);
+                HtmlTree thType = new HtmlTree(HtmlTag.TH);
+                thType.addStyle(HtmlStyle.colSecond);
+                thType.addAttr(HtmlAttr.SCOPE, "row");
                 if (te != null
                         && !utils.isConstructor(element)
                         && !utils.isClass(element)
@@ -487,14 +491,17 @@
                     HtmlTree name = new HtmlTree(HtmlTag.SPAN);
                     name.addStyle(HtmlStyle.typeNameLabel);
                     name.addContent(name(te) + ".");
-                    tdLast.addContent(name);
+                    thType.addContent(name);
                 }
                 addSummaryLink(utils.isClass(element) || utils.isInterface(element)
                         ? LinkInfoImpl.Kind.CLASS_USE
                         : LinkInfoImpl.Kind.MEMBER,
-                    te, element, tdLast);
-                writer.addSummaryLinkComment(this, element, tdLast);
-                tr.addContent(tdLast);
+                        te, element, thType);
+                tr.addContent(thType);
+                HtmlTree tdDesc = new HtmlTree(HtmlTag.TD);
+                tdDesc.addStyle(HtmlStyle.colLast);
+                writer.addSummaryLinkComment(this, element, tdDesc);
+                tr.addContent(tdDesc);
                 tbody.addContent(tr);
             }
             table.addContent(tbody);
@@ -557,12 +564,15 @@
         HtmlTree tdSummaryType = new HtmlTree(HtmlTag.TD);
         tdSummaryType.addStyle(HtmlStyle.colFirst);
         writer.addSummaryType(this, member, tdSummaryType);
-        HtmlTree tdSummary = new HtmlTree(HtmlTag.TD);
-        setSummaryColumnStyle(tdSummary);
-        addSummaryLink(tElement, member, tdSummary);
-        writer.addSummaryLinkComment(this, member, firstSentenceTags, tdSummary);
         HtmlTree tr = HtmlTree.TR(tdSummaryType);
-        tr.addContent(tdSummary);
+        HtmlTree thSummaryLink = new HtmlTree(HtmlTag.TH);
+        setSummaryColumnStyleAndScope(thSummaryLink);
+        addSummaryLink(tElement, member, thSummaryLink);
+        tr.addContent(thSummaryLink);
+        HtmlTree tdDesc = new HtmlTree(HtmlTag.TD);
+        tdDesc.addStyle(HtmlStyle.colLast);
+        writer.addSummaryLinkComment(this, member, firstSentenceTags, tdDesc);
+        tr.addContent(tdDesc);
         if (utils.isMethod(member) && !utils.isAnnotationType(member)) {
             int methodType = utils.isStatic(member) ? MethodTypes.STATIC.value() :
                     MethodTypes.INSTANCE.value();
@@ -612,12 +622,13 @@
     }
 
     /**
-     * Set the style for the summary column.
+     * Set the style and scope attribute for the summary column.
      *
-     * @param tdTree the column for which the style will be set
+     * @param thTree the column for which the style and scope attribute will be set
      */
-    public void setSummaryColumnStyle(HtmlTree tdTree) {
-        tdTree.addStyle(HtmlStyle.colLast);
+    public void setSummaryColumnStyleAndScope(HtmlTree thTree) {
+        thTree.addStyle(HtmlStyle.colSecond);
+        thTree.addAttr(HtmlAttr.SCOPE, "row");
     }
 
     /**
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeFieldWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeFieldWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -25,8 +25,6 @@
 
 package jdk.javadoc.internal.doclets.formats.html;
 
-import java.io.*;
-
 import java.util.Arrays;
 import java.util.List;
 
@@ -222,9 +220,7 @@
      */
     public List<String> getSummaryTableHeader(Element member) {
         List<String> header = Arrays.asList(writer.getModifierTypeHeader(),
-                configuration.getText("doclet.0_and_1",
-                        configuration.getText("doclet.Fields"),
-                        configuration.getText("doclet.Description")));
+                resources.getText("doclet.Fields"), resources.getText("doclet.Description"));
         return header;
     }
 
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeOptionalMemberWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeOptionalMemberWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -133,9 +133,8 @@
      */
     public List<String> getSummaryTableHeader(Element member) {
         List<String> header = Arrays.asList(writer.getModifierTypeHeader(),
-                configuration.getText("doclet.0_and_1",
-                        configuration.getText("doclet.Annotation_Type_Optional_Member"),
-                        configuration.getText("doclet.Description")));
+                resources.getText("doclet.Annotation_Type_Optional_Member"),
+                resources.getText("doclet.Description"));
         return header;
     }
 
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeRequiredMemberWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeRequiredMemberWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -25,7 +25,6 @@
 
 package jdk.javadoc.internal.doclets.formats.html;
 
-import java.io.*;
 import java.util.Arrays;
 import java.util.List;
 
@@ -223,9 +222,7 @@
      */
     public List<String> getSummaryTableHeader(Element member) {
         List<String> header = Arrays.asList(writer.getModifierTypeHeader(),
-                configuration.getText("doclet.0_and_1",
-                        configuration.getText("doclet.Annotation_Type_Required_Member"),
-                        configuration.getText("doclet.Description")));
+                resources.getText("doclet.Annotation_Type_Required_Member"), resources.getText("doclet.Description"));
         return header;
     }
 
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassUseWriter.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassUseWriter.java	Thu Sep 29 17:49:42 2016 +0100
@@ -330,8 +330,8 @@
             HtmlTree tr = new HtmlTree(HtmlTag.TR);
             tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
             altColor = !altColor;
-            Content tdFirst = HtmlTree.TD(HtmlStyle.colFirst, getPackageLink(pkg));
-            tr.addContent(tdFirst);
+            Content thFirst = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, getPackageLink(pkg));
+            tr.addContent(thFirst);
             HtmlTree tdLast = new HtmlTree(HtmlTag.TD);
             tdLast.addStyle(HtmlStyle.colLast);
             addSummaryComment(pkg, tdLast);
@@ -380,9 +380,9 @@
      * @param contentTree the content tree to which the package use information will be added
      */
     protected void addPackageUse(PackageElement pkg, Content contentTree) {
-        Content tdFirst = HtmlTree.TD(HtmlStyle.colFirst,
+        Content thFirst = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst,
                 getHyperLink(getPackageAnchorName(pkg), new StringContent(utils.getPackageName(pkg))));
-        contentTree.addContent(tdFirst);
+        contentTree.addContent(thFirst);
         HtmlTree tdLast = new HtmlTree(HtmlTag.TD);
         tdLast.addStyle(HtmlStyle.colLast);
         addSummaryComment(pkg, tdLast);
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstantsSummaryWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstantsSummaryWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -25,7 +25,6 @@
 
 package jdk.javadoc.internal.doclets.formats.html;
 
-import java.io.*;
 import java.util.*;
 
 import javax.lang.model.element.Modifier;
@@ -332,7 +331,7 @@
         Content nameContent = getDocLink(LinkInfoImpl.Kind.CONSTANT_SUMMARY,
                 member, member.getSimpleName(), false);
         Content code = HtmlTree.CODE(nameContent);
-        return HtmlTree.TD(code);
+        return HtmlTree.TH_ROW_SCOPE(HtmlStyle.colSecond, code);
     }
 
     /**
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstructorWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ConstructorWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -25,13 +25,13 @@
 
 package jdk.javadoc.internal.doclets.formats.html;
 
-import java.io.*;
 import java.util.*;
 
 import javax.lang.model.element.Element;
 import javax.lang.model.element.ExecutableElement;
 import javax.lang.model.element.TypeElement;
 
+import jdk.javadoc.internal.doclets.formats.html.markup.HtmlAttr;
 import jdk.javadoc.internal.doclets.formats.html.markup.HtmlConstants;
 import jdk.javadoc.internal.doclets.formats.html.markup.HtmlStyle;
 import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTag;
@@ -168,11 +168,13 @@
      * {@inheritDoc}
      */
     @Override
-    public void setSummaryColumnStyle(HtmlTree tdTree) {
-        if (foundNonPubConstructor)
-            tdTree.addStyle(HtmlStyle.colLast);
-        else
-            tdTree.addStyle(HtmlStyle.colOne);
+    public void setSummaryColumnStyleAndScope(HtmlTree thTree) {
+        if (foundNonPubConstructor) {
+            thTree.addStyle(HtmlStyle.colSecond);
+        } else {
+            thTree.addStyle(HtmlStyle.colFirst);
+        }
+        thTree.addAttr(HtmlAttr.SCOPE, "row");
     }
 
     /**
@@ -267,9 +269,8 @@
         if (foundNonPubConstructor) {
             header.add(resources.getText("doclet.Modifier"));
         }
-        header.add(resources.getText("doclet.0_and_1",
-                resources.getText("doclet.Constructor"),
-                resources.getText("doclet.Description")));
+        header.add(resources.getText("doclet.Constructor"));
+        header.add(resources.getText("doclet.Description"));
         return header;
     }
 
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DeprecatedListWriter.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DeprecatedListWriter.java	Thu Sep 29 17:49:42 2016 +0100
@@ -261,14 +261,13 @@
         for (DeprElementKind kind : DeprElementKind.values()) {
             if (deprapi.hasDocumentation(kind)) {
                 addAnchor(deprapi, kind, div);
-                memberTableSummary =
-                        configuration.getText("doclet.Member_Table_Summary",
-                        configuration.getText(getHeadingKey(kind)),
-                        configuration.getText(getSummaryKey(kind)));
+                memberTableSummary
+                        = resources.getText("doclet.Member_Table_Summary",
+                                resources.getText(getHeadingKey(kind)),
+                                resources.getText(getSummaryKey(kind)));
                 List<String> memberTableHeader = new ArrayList<>();
-                memberTableHeader.add(configuration.getText("doclet.0_and_1",
-                        configuration.getText(getHeaderKey(kind)),
-                        configuration.getText("doclet.Description")));
+                memberTableHeader.add(resources.getText(getHeaderKey(kind)));
+                memberTableHeader.add(resources.getText("doclet.Description"));
                 if (kind == DeprElementKind.PACKAGE)
                     addPackageDeprecatedAPI(deprapi.getSet(kind),
                             getHeadingKey(kind), memberTableSummary, memberTableHeader, div);
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/EnumConstantWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/EnumConstantWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -25,8 +25,7 @@
 
 package jdk.javadoc.internal.doclets.formats.html;
 
-import java.io.*;
-
+import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.List;
 
@@ -34,6 +33,7 @@
 import javax.lang.model.element.TypeElement;
 import javax.lang.model.element.VariableElement;
 
+import jdk.javadoc.internal.doclets.formats.html.markup.HtmlAttr;
 import jdk.javadoc.internal.doclets.formats.html.markup.HtmlConstants;
 import jdk.javadoc.internal.doclets.formats.html.markup.HtmlStyle;
 import jdk.javadoc.internal.doclets.formats.html.markup.HtmlTag;
@@ -214,9 +214,8 @@
      */
     @Override
     public List<String> getSummaryTableHeader(Element member) {
-        List<String> header = Arrays.asList(configuration.getText("doclet.0_and_1",
-                configuration.getText("doclet.Enum_Constant"),
-                configuration.getText("doclet.Description")));
+        List<String> header = Arrays.asList(resources.getText("doclet.Enum_Constant"),
+                resources.getText("doclet.Description"));
         return header;
     }
 
@@ -259,8 +258,9 @@
      * {@inheritDoc}
      */
     @Override
-    public void setSummaryColumnStyle(HtmlTree tdTree) {
-        tdTree.addStyle(HtmlStyle.colOne);
+    public void setSummaryColumnStyleAndScope(HtmlTree thTree) {
+        thTree.addStyle(HtmlStyle.colFirst);
+        thTree.addAttr(HtmlAttr.SCOPE, "row");
     }
 
     /**
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/FieldWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/FieldWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -25,7 +25,6 @@
 
 package jdk.javadoc.internal.doclets.formats.html;
 
-import java.io.*;
 import java.util.Arrays;
 import java.util.List;
 
@@ -215,9 +214,7 @@
     @Override
     public List<String> getSummaryTableHeader(Element member) {
         List<String> header = Arrays.asList(writer.getModifierTypeHeader(),
-            resources.getText("doclet.0_and_1",
-                    resources.getText("doclet.Field"),
-                    resources.getText("doclet.Description")));
+                resources.getText("doclet.Field"), resources.getText("doclet.Description"));
         return header;
     }
 
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java	Thu Sep 29 17:49:42 2016 +0100
@@ -405,7 +405,7 @@
                 }
                 Content classContent = getLink(new LinkInfoImpl(
                         configuration, LinkInfoImpl.Kind.PACKAGE, te));
-                Content tdClass = HtmlTree.TD(HtmlStyle.colFirst, classContent);
+                Content tdClass = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, classContent);
                 HtmlTree tr = HtmlTree.TR(tdClass);
                 tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
                 altColor = !altColor;
@@ -942,16 +942,20 @@
         Content tr = new HtmlTree(HtmlTag.TR);
         final int size = header.size();
         Content tableHeader;
-        if (size == 1) {
+        if (size == 2) {
             tableHeader = new StringContent(header.get(0));
-            tr.addContent(HtmlTree.TH(HtmlStyle.colOne, scope, tableHeader));
+            tr.addContent(HtmlTree.TH(HtmlStyle.colFirst, scope, tableHeader));
+            tableHeader = new StringContent(header.get(1));
+            tr.addContent(HtmlTree.TH(HtmlStyle.colLast, scope, tableHeader));
             return tr;
         }
         for (int i = 0; i < size; i++) {
             tableHeader = new StringContent(header.get(i));
-            if(i == 0)
+            if (i == 0)
                 tr.addContent(HtmlTree.TH(HtmlStyle.colFirst, scope, tableHeader));
-            else if(i == (size - 1))
+            else if (i == 1)
+                tr.addContent(HtmlTree.TH(HtmlStyle.colSecond, scope, tableHeader));
+            else if (i == (size - 1))
                 tr.addContent(HtmlTree.TH(HtmlStyle.colLast, scope, tableHeader));
             else
                 tr.addContent(HtmlTree.TH(scope, tableHeader));
@@ -1062,13 +1066,16 @@
             boolean altColor = true;
             for (Element e : deprPkgs) {
                 PackageElement pkg = (PackageElement) e;
-                HtmlTree td = HtmlTree.TD(HtmlStyle.colOne,
+                HtmlTree thRow = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst,
                         getPackageLink(pkg, getPackageName(pkg)));
+                HtmlTree tr = HtmlTree.TR(thRow);
+                HtmlTree tdDesc = new HtmlTree(HtmlTag.TD);
+                tdDesc.addStyle(HtmlStyle.colLast);
                 List<? extends DocTree> tags = utils.getDeprecatedTrees(pkg);
                 if (!tags.isEmpty()) {
-                    addInlineDeprecatedComment(pkg, tags.get(0), td);
+                    addInlineDeprecatedComment(pkg, tags.get(0), tdDesc);
                 }
-                HtmlTree tr = HtmlTree.TR(td);
+                tr.addContent(tdDesc);
                 tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
                 altColor = !altColor;
                 tbody.addContent(tr);
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/MethodWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/MethodWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -261,9 +261,7 @@
     @Override
     public List<String> getSummaryTableHeader(Element member) {
         List<String> header = Arrays.asList(writer.getModifierTypeHeader(),
-                resources.getText("doclet.0_and_1",
-                        resources.getText("doclet.Method"),
-                        resources.getText("doclet.Description")));
+                resources.getText("doclet.Method"), resources.getText("doclet.Description"));
         return header;
     }
 
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexWriter.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleIndexWriter.java	Thu Sep 29 17:49:42 2016 +0100
@@ -159,11 +159,11 @@
         for (ModuleElement mdle : modules) {
             if (!mdle.isUnnamed()) {
                 Content moduleLinkContent = getModuleLink(mdle, new StringContent(mdle.getQualifiedName().toString()));
-                Content tdModule = HtmlTree.TD(HtmlStyle.colFirst, moduleLinkContent);
+                Content thModule = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, moduleLinkContent);
                 HtmlTree tdSummary = new HtmlTree(HtmlTag.TD);
                 tdSummary.addStyle(HtmlStyle.colLast);
                 addSummaryComment(mdle, tdSummary);
-                HtmlTree tr = HtmlTree.TR(tdModule);
+                HtmlTree tr = HtmlTree.TR(thModule);
                 tr.addContent(tdSummary);
                 tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
                 tbody.addContent(tr);
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModuleWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -294,11 +294,11 @@
     public void addRequiresList(ModuleElement.RequiresDirective direct, Content tbody, boolean altColor) {
         ModuleElement m = direct.getDependency();
         Content moduleLinkContent = getModuleLink(m, new StringContent(m.getQualifiedName().toString()));
-        Content tdPackage = HtmlTree.TD(HtmlStyle.colFirst, moduleLinkContent);
+        Content thPackage = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, moduleLinkContent);
         HtmlTree tdSummary = new HtmlTree(HtmlTag.TD);
         tdSummary.addStyle(HtmlStyle.colLast);
         addSummaryComment(m, tdSummary);
-        HtmlTree tr = HtmlTree.TR(tdPackage);
+        HtmlTree tr = HtmlTree.TR(thPackage);
         tr.addContent(tdSummary);
         tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
         tbody.addContent(tr);
@@ -347,27 +347,27 @@
     public void addExportedPackagesList(ModuleElement.ExportsDirective direct, Content tbody, boolean altColor) {
         PackageElement pkg = direct.getPackage();
         Content pkgLinkContent = getPackageLink(pkg, new StringContent(utils.getPackageName(pkg)));
-        Content tdPackage = HtmlTree.TD(HtmlStyle.colFirst, pkgLinkContent);
-        HtmlTree tdModules = new HtmlTree(HtmlTag.TD);
-        tdModules.addStyle(HtmlStyle.colSecond);
+        Content tdPackage = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, pkgLinkContent);
+        HtmlTree thModules = new HtmlTree(HtmlTag.TD);
+        thModules.addStyle(HtmlStyle.colSecond);
         List<? extends ModuleElement> targetModules = direct.getTargetModules();
         if (targetModules != null) {
             List<? extends ModuleElement> mElements = direct.getTargetModules();
             for (int i = 0; i < mElements.size(); i++) {
                 if (i > 0) {
-                    tdModules.addContent(new HtmlTree(HtmlTag.BR));
+                    thModules.addContent(new HtmlTree(HtmlTag.BR));
                 }
                 ModuleElement m = mElements.get(i);
-                tdModules.addContent(new StringContent(m.getQualifiedName().toString()));
+                thModules.addContent(new StringContent(m.getQualifiedName().toString()));
             }
         } else {
-            tdModules.addContent(configuration.getText("doclet.All_Modules"));
+            thModules.addContent(configuration.getText("doclet.All_Modules"));
         }
         HtmlTree tdSummary = new HtmlTree(HtmlTag.TD);
         tdSummary.addStyle(HtmlStyle.colLast);
         addSummaryComment(pkg, tdSummary);
         HtmlTree tr = HtmlTree.TR(tdPackage);
-        tr.addContent(tdModules);
+        tr.addContent(thModules);
         tr.addContent(tdSummary);
         tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
         tbody.addContent(tr);
@@ -428,11 +428,11 @@
     public void addUsesList(ModuleElement.UsesDirective direct, Content tbody, boolean altColor) {
         TypeElement type = direct.getService();
         Content typeLinkContent = getLink(new LinkInfoImpl(configuration, LinkInfoImpl.Kind.PACKAGE, type));
-        Content tdPackage = HtmlTree.TD(HtmlStyle.colFirst, typeLinkContent);
+        Content thPackage = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, typeLinkContent);
         HtmlTree tdSummary = new HtmlTree(HtmlTag.TD);
         tdSummary.addStyle(HtmlStyle.colLast);
         addSummaryComment(type, tdSummary);
-        HtmlTree tr = HtmlTree.TR(tdPackage);
+        HtmlTree tr = HtmlTree.TR(thPackage);
         tr.addContent(tdSummary);
         tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
         tbody.addContent(tr);
@@ -463,18 +463,18 @@
         TypeElement srv = direct.getService();
         Content implLinkContent = getLink(new LinkInfoImpl(configuration, LinkInfoImpl.Kind.PACKAGE, impl));
         Content srvLinkContent = getLink(new LinkInfoImpl(configuration, LinkInfoImpl.Kind.PACKAGE, srv));
-        HtmlTree tdType = HtmlTree.TD(HtmlStyle.colFirst, srvLinkContent);
-        tdType.addContent(new HtmlTree(HtmlTag.BR));
-        tdType.addContent("(");
+        HtmlTree thType = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, srvLinkContent);
+        thType.addContent(new HtmlTree(HtmlTag.BR));
+        thType.addContent("(");
         HtmlTree implSpan = HtmlTree.SPAN(HtmlStyle.implementationLabel, contents.implementation);
-        tdType.addContent(implSpan);
-        tdType.addContent(Contents.SPACE);
-        tdType.addContent(implLinkContent);
-        tdType.addContent(")");
+        thType.addContent(implSpan);
+        thType.addContent(Contents.SPACE);
+        thType.addContent(implLinkContent);
+        thType.addContent(")");
         HtmlTree tdDesc = new HtmlTree(HtmlTag.TD);
         tdDesc.addStyle(HtmlStyle.colLast);
         addSummaryComment(srv, tdDesc);
-        HtmlTree tr = HtmlTree.TR(tdType);
+        HtmlTree tr = HtmlTree.TR(thType);
         tr.addContent(tdDesc);
         tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
         tbody.addContent(tr);
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/NestedClassWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/NestedClassWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -25,8 +25,6 @@
 
 package jdk.javadoc.internal.doclets.formats.html;
 
-import java.io.*;
-
 import java.util.Arrays;
 import java.util.List;
 
@@ -118,15 +116,11 @@
     public List<String> getSummaryTableHeader(Element member) {
         if (utils.isInterface(member)) {
             return Arrays.asList(writer.getModifierTypeHeader(),
-                configuration.getText("doclet.0_and_1",
-                    configuration.getText("doclet.Interface"),
-                    configuration.getText("doclet.Description")));
+                    resources.getText("doclet.Interface"), resources.getText("doclet.Description"));
 
         } else {
             return Arrays.asList(writer.getModifierTypeHeader(),
-                configuration.getText("doclet.0_and_1",
-                    configuration.getText("doclet.Class"),
-                    configuration.getText("doclet.Description")));
+                    resources.getText("doclet.Class"), resources.getText("doclet.Description"));
         }
     }
 
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexWriter.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageIndexWriter.java	Thu Sep 29 17:49:42 2016 +0100
@@ -151,11 +151,11 @@
             if (!pkg.isUnnamed()) {
                 if (!(configuration.nodeprecated && utils.isDeprecated(pkg))) {
                     Content packageLinkContent = getPackageLink(pkg, getPackageName(pkg));
-                    Content tdPackage = HtmlTree.TD(HtmlStyle.colFirst, packageLinkContent);
+                    Content thPackage = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, packageLinkContent);
                     HtmlTree tdSummary = new HtmlTree(HtmlTag.TD);
                     tdSummary.addStyle(HtmlStyle.colLast);
                     addSummaryComment(pkg, tdSummary);
-                    HtmlTree tr = HtmlTree.TR(tdPackage);
+                    HtmlTree tr = HtmlTree.TR(thPackage);
                     tr.addContent(tdSummary);
                     tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
                     tbody.addContent(tr);
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageUseWriter.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageUseWriter.java	Thu Sep 29 17:49:42 2016 +0100
@@ -187,9 +187,7 @@
      */
     protected void addClassList(Content contentTree) {
         List<String> classTableHeader = Arrays.asList(
-            configuration.getText("doclet.0_and_1",
-                    configuration.getText("doclet.Class"),
-                    configuration.getText("doclet.Description")));
+                resources.getText("doclet.Class"), resources.getText("doclet.Description"));
         for (String packageName : usingPackageToUsedClasses.keySet()) {
             PackageElement usingPackage = utils.elementUtils.getPackageElement(packageName);
             HtmlTree li = new HtmlTree(HtmlTag.LI);
@@ -234,10 +232,13 @@
         DocPath dp = pathString(usedClass,
                 DocPaths.CLASS_USE.resolve(DocPath.forName(utils, usedClass)));
         StringContent stringContent = new StringContent(utils.getSimpleName(usedClass));
-        Content td = HtmlTree.TD(HtmlStyle.colOne,
+        Content thType = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst,
                 getHyperLink(dp.fragment(getPackageAnchorName(pkg)), stringContent));
-        addIndexComment(usedClass, td);
-        contentTree.addContent(td);
+        contentTree.addContent(thType);
+        HtmlTree tdDesc = new HtmlTree(HtmlTag.TD);
+        tdDesc.addStyle(HtmlStyle.colLast);
+        addIndexComment(usedClass, tdDesc);
+        contentTree.addContent(tdDesc);
     }
 
     /**
@@ -247,10 +248,10 @@
      * @param contentTree the content tree to which the information will be added
      */
     protected void addPackageUse(PackageElement pkg, Content contentTree) {
-        Content tdFirst = HtmlTree.TD(HtmlStyle.colFirst,
+        Content thFirst = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst,
                 getHyperLink(utils.getPackageName(pkg),
                 new StringContent(utils.getPackageName(pkg))));
-        contentTree.addContent(tdFirst);
+        contentTree.addContent(thFirst);
         HtmlTree tdLast = new HtmlTree(HtmlTag.TD);
         tdLast.addStyle(HtmlStyle.colLast);
         if (pkg != null && !pkg.isUnnamed()) {
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PackageWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -229,8 +229,8 @@
                 }
                 Content classContent = getLink(new LinkInfoImpl(
                         configuration, LinkInfoImpl.Kind.PACKAGE, klass));
-                Content tdClass = HtmlTree.TD(HtmlStyle.colFirst, classContent);
-                HtmlTree tr = HtmlTree.TR(tdClass);
+                Content thClass = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, classContent);
+                HtmlTree tr = HtmlTree.TR(thClass);
                 tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
 
                 HtmlTree tdClassDescription = new HtmlTree(HtmlTag.TD);
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PropertyWriterImpl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/PropertyWriterImpl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -25,8 +25,6 @@
 
 package jdk.javadoc.internal.doclets.formats.html;
 
-import java.io.*;
-
 import java.util.Arrays;
 import java.util.List;
 
@@ -235,10 +233,8 @@
      */
     @Override
     public List<String> getSummaryTableHeader(Element member) {
-        List<String> header = Arrays.asList(configuration.getText("doclet.Type"),
-                configuration.getText("doclet.0_and_1",
-                        configuration.getText("doclet.Property"),
-                        configuration.getText("doclet.Description")));
+        List<String> header = Arrays.asList(resources.getText("doclet.Type"),
+                resources.getText("doclet.Property"), resources.getText("doclet.Description"));
         return header;
     }
 
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlStyle.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlStyle.java	Thu Sep 29 17:49:42 2016 +0100
@@ -48,7 +48,6 @@
     classUseContainer,
     colFirst,
     colLast,
-    colOne,
     colSecond,
     constantsSummary,
     constantValuesContainer,
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlTree.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/HtmlTree.java	Thu Sep 29 17:49:42 2016 +0100
@@ -808,6 +808,17 @@
     }
 
     /**
+     * Generates a TH tag with style class, scope attribute and some content.
+     *
+     * @param styleClass style for the tag
+     * @param body content for the tag
+     * @return an HtmlTree object for the TH tag
+     */
+    public static HtmlTree TH_ROW_SCOPE(HtmlStyle styleClass, Content body) {
+        return TH(styleClass, "row", body);
+    }
+
+    /**
      * Generates a TITLE tag with some content.
      *
      * @param body content for the tag
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/resources/stylesheet.css	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/resources/stylesheet.css	Thu Sep 29 17:49:42 2016 +0100
@@ -528,20 +528,23 @@
     float:left;
 
 }
+.rowColor th, .altColor th {
+    font-weight:normal;
+}
 .overviewSummary td, .memberSummary td, .typeSummary td,
 .useSummary td, .constantsSummary td, .deprecatedSummary td,
 .requiresSummary td, .packagesSummary td, .providesSummary td, .usesSummary td {
     text-align:left;
     padding:0px 0px 12px 10px;
 }
-th.colOne, th.colFirst, th.colSecond, th.colLast, .useSummary th, .constantsSummary th, .packagesSummary th,
-td.colOne, td.colFirst, td.colSecond, td.colLast, .useSummary td, .constantsSummary td {
+th.colFirst, th.colSecond, th.colLast, .useSummary th, .constantsSummary th, .packagesSummary th,
+td.colFirst, td.colSecond, td.colLast, .useSummary td, .constantsSummary td {
     vertical-align:top;
     padding-right:0px;
     padding-top:8px;
     padding-bottom:3px;
 }
-th.colFirst, th.colSecond, th.colLast, th.colOne, .constantsSummary th, .packagesSummary th {
+th.colFirst, th.colSecond, th.colLast, .constantsSummary th, .packagesSummary th {
     background:#dee3e9;
     text-align:left;
     padding:8px 3px 3px 7px;
@@ -550,10 +553,10 @@
     white-space:nowrap;
     font-size:13px;
 }
-td.colLast, th.colLast {
+td.colSecond, th.colSecond, td.colLast, th.colLast {
     font-size:13px;
 }
-td.colOne, th.colOne, .constantsSummary th, .packagesSummary th {
+.constantsSummary th, .packagesSummary th {
     font-size:13px;
 }
 .providesSummary th.colFirst, .providesSummary th.colLast, .providesSummary td.colFirst,
@@ -567,23 +570,22 @@
 .packagesSummary td.colFirst, .packagesSummary td.colSecond, .packagesSummary th.colFirst, .packagesSummary th,
 .usesSummary td.colFirst, .usesSummary th.colFirst,
 .useSummary td.colFirst, .useSummary th.colFirst,
-.overviewSummary td.colOne, .overviewSummary th.colOne,
 .memberSummary td.colFirst, .memberSummary th.colFirst,
-.memberSummary td.colOne, .memberSummary th.colOne,
+.memberSummary td.colSecond, .memberSummary th.colSecond,
 .typeSummary td.colFirst{
     width:25%;
     vertical-align:top;
 }
-td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colSecond a:link, td.colSecond a:active, td.colSecond a:visited, td.colSecond a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover {
+td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colSecond a:link, td.colSecond a:active, td.colSecond a:visited, td.colSecond a:hover, th.colFirst a:link, th.colFirst a:active, th.colFirst a:visited, th.colFirst a:hover, th.colSecond a:link, th.colSecond a:active, th.colSecond a:visited, th.colSecond a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover {
     font-weight:bold;
 }
 .tableSubHeadingColor {
     background-color:#EEEEFF;
 }
-.altColor {
+.altColor, .altColor th {
     background-color:#FFFFFF;
 }
-.rowColor {
+.rowColor, .rowColor th {
     background-color:#EEEEEF;
 }
 /*
@@ -774,4 +776,4 @@
 .searchTagHolderResult {
     font-style:italic;
     font-size:12px;
-}
+}
\ No newline at end of file
--- a/src/jdk.jdeps/share/classes/com/sun/tools/classfile/TypeAnnotation.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jdeps/share/classes/com/sun/tools/classfile/TypeAnnotation.java	Thu Sep 29 17:49:42 2016 +0100
@@ -130,10 +130,7 @@
             break;
         // class extends or implements clause
         case CLASS_EXTENDS:
-            int in = cr.readUnsignedShort();
-            if (in == 0xFFFF)
-                in = -1;
-            position.type_index = in;
+            position.type_index = cr.readUnsignedShort();;
             break;
         // throws
         case THROWS:
--- a/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/Analyzer.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/Analyzer.java	Thu Sep 29 17:49:42 2016 +0100
@@ -256,7 +256,7 @@
         // return classname or package name depending on the level
         private String getLocationName(Location o) {
             if (level == Type.CLASS || level == Type.VERBOSE) {
-                return o.getClassName();
+                return VersionHelper.get(o.getClassName());
             } else {
                 String pkg = o.getPackageName();
                 return pkg.isEmpty() ? "<unnamed>" : pkg;
--- a/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/Archive.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/Archive.java	Thu Sep 29 17:49:42 2016 +0100
@@ -45,9 +45,9 @@
  * Represents the source of the class files.
  */
 public class Archive implements Closeable {
-    public static Archive getInstance(Path p) {
+    public static Archive getInstance(Path p, Runtime.Version version) {
         try {
-            return new Archive(p, ClassFileReader.newInstance(p));
+            return new Archive(p, ClassFileReader.newInstance(p, version));
         } catch (IOException e) {
             throw new UncheckedIOException(e);
         }
--- a/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/ClassFileReader.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/ClassFileReader.java	Thu Sep 29 17:49:42 2016 +0100
@@ -29,6 +29,8 @@
 import com.sun.tools.classfile.ConstantPoolException;
 import com.sun.tools.classfile.Dependencies.ClassFileError;
 
+import jdk.internal.util.jar.VersionedStream;
+
 import java.io.Closeable;
 import java.io.File;
 import java.io.FileNotFoundException;
@@ -50,6 +52,7 @@
 import java.util.jar.JarFile;
 import java.util.stream.Collectors;
 import java.util.stream.Stream;
+import java.util.zip.ZipFile;
 
 /**
  * ClassFileReader reads ClassFile(s) of a given path that can be
@@ -60,6 +63,13 @@
      * Returns a ClassFileReader instance of a given path.
      */
     public static ClassFileReader newInstance(Path path) throws IOException {
+        return newInstance(path, JarFile.baseVersion());
+    }
+
+    /**
+     * Returns a ClassFileReader instance of a given path.
+     */
+    public static ClassFileReader newInstance(Path path, Runtime.Version version) throws IOException {
         if (Files.notExists(path)) {
             throw new FileNotFoundException(path.toString());
         }
@@ -67,20 +77,13 @@
         if (Files.isDirectory(path)) {
             return new DirectoryReader(path);
         } else if (path.getFileName().toString().endsWith(".jar")) {
-            return new JarFileReader(path);
+            return new JarFileReader(path, version);
         } else {
             return new ClassFileReader(path);
         }
     }
 
     /**
-     * Returns a ClassFileReader instance of a given JarFile.
-     */
-    public static ClassFileReader newInstance(Path path, JarFile jf) throws IOException {
-        return new JarFileReader(path, jf);
-    }
-
-    /**
      * Returns a ClassFileReader instance of a given FileSystem and path.
      *
      * This method is used for reading classes from jrtfs.
@@ -302,13 +305,16 @@
 
     static class JarFileReader extends ClassFileReader {
         private final JarFile jarfile;
-        JarFileReader(Path path) throws IOException {
-            this(path, new JarFile(path.toFile(), false));
+        private final Runtime.Version version;
+
+        JarFileReader(Path path, Runtime.Version version) throws IOException {
+            this(path, openJarFile(path.toFile(), version), version);
         }
 
-        JarFileReader(Path path, JarFile jf) throws IOException {
+        JarFileReader(Path path, JarFile jf, Runtime.Version version) throws IOException {
             super(path);
             this.jarfile = jf;
+            this.version = version;
         }
 
         @Override
@@ -316,9 +322,26 @@
             jarfile.close();
         }
 
+        private static JarFile openJarFile(File f, Runtime.Version version)
+                throws IOException {
+            JarFile jf;
+            if (version == null) {
+                jf = new JarFile(f, false);
+                if (jf.isMultiRelease()) {
+                    throw new MultiReleaseException("err.multirelease.option.notfound", f.getName());
+                }
+            } else {
+                jf = new JarFile(f, false, ZipFile.OPEN_READ, version);
+                if (!jf.isMultiRelease()) {
+                    throw new MultiReleaseException("err.multirelease.option.exists", f.getName());
+                }
+            }
+            return jf;
+        }
+
         protected Set<String> scan() {
-            try (JarFile jf = new JarFile(path.toFile())) {
-                return jf.stream().map(JarEntry::getName)
+            try (JarFile jf = openJarFile(path.toFile(), version)) {
+                return VersionedStream.stream(jf).map(JarEntry::getName)
                          .filter(n -> n.endsWith(".class"))
                          .collect(Collectors.toSet());
             } catch (IOException e) {
@@ -348,15 +371,14 @@
         }
 
         protected ClassFile readClassFile(JarFile jarfile, JarEntry e) throws IOException {
-            InputStream is = null;
-            try {
-                is = jarfile.getInputStream(e);
-                return ClassFile.read(is);
+            try (InputStream is = jarfile.getInputStream(e)) {
+                ClassFile cf = ClassFile.read(is);
+                if (jarfile.isMultiRelease()) {
+                    VersionHelper.add(jarfile, e, cf);
+                }
+                return cf;
             } catch (ConstantPoolException ex) {
                 throw new ClassFileError(ex);
-            } finally {
-                if (is != null)
-                    is.close();
             }
         }
 
@@ -370,6 +392,21 @@
         }
     }
 
+    Enumeration<JarEntry> versionedEntries(JarFile jf) {
+        Iterator<JarEntry> it = VersionedStream.stream(jf).iterator();
+        return new Enumeration<>() {
+            @Override
+            public boolean hasMoreElements() {
+                return it.hasNext();
+            }
+
+            @Override
+            public JarEntry nextElement() {
+                return it.next();
+            }
+        };
+    }
+
     class JarFileIterator implements Iterator<ClassFile> {
         protected final JarFileReader reader;
         protected Enumeration<JarEntry> entries;
@@ -388,7 +425,7 @@
             if (jarfile == null) return;
 
             this.jf = jarfile;
-            this.entries = jf.entries();
+            this.entries = versionedEntries(jf);
             this.nextEntry = nextEntry();
         }
 
--- a/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsConfiguration.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsConfiguration.java	Thu Sep 29 17:49:42 2016 +0100
@@ -82,19 +82,22 @@
     private final List<Archive> initialArchives = new ArrayList<>();
     private final Set<Module> rootModules = new HashSet<>();
     private final Configuration configuration;
+    private final Runtime.Version version;
 
     private JdepsConfiguration(SystemModuleFinder systemModulePath,
                                ModuleFinder finder,
                                Set<String> roots,
                                List<Path> classpaths,
                                List<Archive> initialArchives,
-                               boolean allDefaultModules)
+                               boolean allDefaultModules,
+                               Runtime.Version version)
         throws IOException
     {
         trace("root: %s%n", roots);
 
         this.system = systemModulePath;
         this.finder = finder;
+        this.version = version;
 
         // build root set for resolution
         Set<String> mods = new HashSet<>(roots);
@@ -122,7 +125,7 @@
         // classpath archives
         for (Path p : classpaths) {
             if (Files.exists(p)) {
-                Archive archive = Archive.getInstance(p);
+                Archive archive = Archive.getInstance(p, version);
                 addPackagesInUnnamedModule(archive);
                 classpathArchives.add(archive);
             }
@@ -293,7 +296,7 @@
             if (location.getScheme().equals("jrt")) {
                 reader = system.getClassReader(mn);
             } else {
-                reader = ClassFileReader.newInstance(Paths.get(location));
+                reader = ClassFileReader.newInstance(Paths.get(location), version);
             }
 
             builder.classes(reader);
@@ -305,6 +308,10 @@
         }
     }
 
+    public Runtime.Version getVersion() {
+        return version;
+    }
+
     /*
      * Close all archives e.g. JarFile
      */
@@ -481,6 +488,7 @@
         ModuleFinder appModulePath;
         boolean addAllApplicationModules;
         boolean addAllDefaultModules;
+        Runtime.Version version;
 
         public Builder() {
             this.systemModulePath = new SystemModuleFinder();
@@ -531,8 +539,13 @@
             return this;
         }
 
+        public Builder multiRelease(Runtime.Version version) {
+            this.version = version;
+            return this;
+        }
+
         public Builder addRoot(Path path) {
-            Archive archive = Archive.getInstance(path);
+            Archive archive = Archive.getInstance(path, version);
             if (archive.contains(MODULE_INFO)) {
                 paths.add(path);
             } else {
@@ -574,7 +587,8 @@
                                           rootModules,
                                           classPaths,
                                           initialArchives,
-                                          addAllDefaultModules);
+                                          addAllDefaultModules,
+                                          version);
         }
 
         private static ModuleFinder createModulePathFinder(String mpaths) {
--- a/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsTask.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsTask.java	Thu Sep 29 17:49:42 2016 +0100
@@ -36,6 +36,7 @@
 import java.nio.file.Paths;
 import java.text.MessageFormat;
 import java.util.*;
+import java.util.jar.JarFile;
 import java.util.regex.Pattern;
 import java.util.stream.Collectors;
 import java.util.stream.Stream;
@@ -389,6 +390,23 @@
                 }
             }
         },
+        new Option(true, "--multi-release") {
+            void process(JdepsTask task, String opt, String arg) throws BadArgs {
+                if (arg.equalsIgnoreCase("base")) {
+                    task.options.multiRelease = JarFile.baseVersion();
+                } else {
+                    try {
+                        int v = Integer.parseInt(arg);
+                        if (v < 9) {
+                            throw new BadArgs("err.invalid.arg.for.option", arg);
+                        }
+                    } catch (NumberFormatException x) {
+                        throw new BadArgs("err.invalid.arg.for.option", arg);
+                    }
+                    task.options.multiRelease = Runtime.Version.parse(arg);
+                }
+            }
+        },
     };
 
     private static final String PROGNAME = "jdeps";
@@ -481,6 +499,9 @@
         } catch (IOException e) {
             e.printStackTrace();
             return EXIT_CMDERR;
+        } catch (MultiReleaseException e) {
+            reportError(e.getKey(), (Object)e.getMsg());
+            return EXIT_CMDERR;  // could be EXIT_ABNORMAL sometimes
         } finally {
             log.flush();
         }
@@ -541,11 +562,16 @@
         if (options.classpath != null)
             builder.addClassPath(options.classpath);
 
+        if (options.multiRelease != null)
+            builder.multiRelease(options.multiRelease);
+
         // build the root set of archives to be analyzed
         for (String s : inputArgs) {
             Path p = Paths.get(s);
             if (Files.exists(p)) {
                 builder.addRoot(p);
+            } else {
+                warning("warn.invalid.arg", s);
             }
         }
 
@@ -839,6 +865,7 @@
         String modulePath;
         String rootModule;
         Set<String> addmods = new HashSet<>();
+        Runtime.Version multiRelease;
 
         boolean hasFilter() {
             return numFilters() > 0;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/MultiReleaseException.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,69 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package com.sun.tools.jdeps;
+
+/**
+ * Signals that an exception of some sort has occurred while processing
+ * a multi-release jar file.
+ *
+ * @since   9
+ */
+class MultiReleaseException extends RuntimeException {
+    private static final long serialVersionUID = 4474870142461654108L;
+    private final String key;
+    private final String[] msg;
+
+    /**
+     * Constructs an {@code MultiReleaseException} with the specified detail
+     * error message array.
+     *
+     * @param key
+     *        The key that identifies the message in the jdeps.properties file
+     * @param msg
+     *        The detail message array
+     */
+    public MultiReleaseException(String key, String... msg) {
+        super();
+        this.key = key;
+        this.msg = msg;
+    }
+
+    /**
+     * Returns the resource message key
+     */
+    public String getKey() {
+        return key;
+    }
+
+    /**
+     * Returns the detailed error message array.
+     *
+     * @return the detailed error message array
+     */
+    public String[] getMsg() {
+        return msg;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/VersionHelper.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,75 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package com.sun.tools.jdeps;
+
+import com.sun.tools.classfile.ClassFile;
+import com.sun.tools.classfile.ConstantPoolException;
+import jdk.internal.misc.SharedSecrets;
+
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.jar.JarEntry;
+import java.util.jar.JarFile;
+
+public class VersionHelper {
+    private static final String META_INF_VERSIONS = "META-INF/versions/";
+    private static final Map<String,String> nameToVersion = new ConcurrentHashMap<>();
+
+    public static String get(String classname) {
+        if (nameToVersion.containsKey(classname)) {
+            return nameToVersion.get(classname) + "/" + classname;
+        }
+        return classname;
+    }
+
+    public static void add(JarFile jarfile, JarEntry e, ClassFile cf)
+            throws ConstantPoolException
+    {
+        String realName = SharedSecrets.javaUtilJarAccess().getRealName(jarfile, e);
+        if (realName.startsWith(META_INF_VERSIONS)) {
+            int len = META_INF_VERSIONS.length();
+            int n = realName.indexOf('/', len);
+            if (n > 0) {
+                String version = realName.substring(len, n);
+                assert (Integer.parseInt(version) > 8);
+                String name = cf.getName().replace('/', '.');
+                if (nameToVersion.containsKey(name)) {
+                    if (!version.equals(nameToVersion.get(name))) {
+                        throw new MultiReleaseException(
+                                "err.multirelease.version.associated",
+                                name, nameToVersion.get(name), version
+                        );
+                    }
+                } else {
+                    nameToVersion.put(name, version);
+                }
+            } else {
+                throw new MultiReleaseException("err.multirelease.jar.malformed",
+                        jarfile.getName(), realName);
+            }
+        }
+    }
+}
--- a/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/resources/jdeps.properties	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/resources/jdeps.properties	Thu Sep 29 17:49:42 2016 +0100
@@ -150,6 +150,11 @@
 \  -q           -quiet               Do not show missing dependencies from \n\
 \                                    -genmoduleinfo output.
 
+main.opt.multi-release=\
+\  --multi-release <version>         Specifies the version when processing\n\
+\                                    multi-release jar files.  <version> should\n\
+\                                    be integer >= 9 or base.
+
 err.unknown.option=unknown option: {0}
 err.missing.arg=no value given for {0}
 err.invalid.arg.for.option=invalid argument for option: {0}
@@ -164,7 +169,11 @@
 err.root.module.not.set=root module set empty
 err.invalid.inverse.option={0} cannot be used with -inverse option
 err.inverse.filter.not.set={0} cannot be used with -inverse option
-warn.invalid.arg=Path not exist: {0}
+err.multirelease.option.exists={0} is not a multi-release jar file, but the --multi-release option is set
+err.multirelease.option.notfound={0} is a multi-release jar file, but the --multi-release option is not set
+err.multirelease.version.associated=class {0} already associated with version {1}, trying to add version {2}
+err.multirelease.jar.malformed=malformed multi-release jar, {0}, bad entry: {1}
+warn.invalid.arg=Path does not exist: {0}
 warn.split.package=package {0} defined in {1} {2}
 warn.replace.useJDKInternals=\
 JDK internal APIs are unsupported and private to JDK implementation that are\n\
--- a/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/resources/l10n.properties	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jshell/share/classes/jdk/internal/jshell/tool/resources/l10n.properties	Thu Sep 29 17:49:42 2016 +0100
@@ -543,7 +543,6 @@
 \n\
 Where <mode> is the name of a previously defined feedback mode -- see '/help /set mode'.\n\
 Where <length> is an unsigned integer representing a maximum length.\n\
-Where <format> is a quoted string which will be the value of the field if one of\n\
 Where <selector> is only needed if you wish to fine-tune value truncation length\n\
 by context, <selector> is the context in which the truncation is applied.\n\
 The structure of selector is a hyphen separated list of selector kind lists.\n\
--- a/src/jdk.jshell/share/classes/jdk/jshell/execution/DemultiplexInput.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jshell/share/classes/jdk/jshell/execution/DemultiplexInput.java	Thu Sep 29 17:49:42 2016 +0100
@@ -45,6 +45,7 @@
 
     DemultiplexInput(InputStream input, Map<String, OutputStream> io, Iterable<OutputStream> closeList) {
         super("output reader");
+        setDaemon(true);
         this.delegate = new DataInputStream(input);
         this.io = io;
         this.closeList = closeList;
--- a/src/jdk.jshell/share/classes/jdk/jshell/execution/DirectExecutionControl.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jshell/share/classes/jdk/jshell/execution/DirectExecutionControl.java	Thu Sep 29 17:49:42 2016 +0100
@@ -24,6 +24,7 @@
  */
 package jdk.jshell.execution;
 
+import java.lang.reflect.Array;
 import java.lang.reflect.Field;
 import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.Method;
@@ -200,6 +201,21 @@
             return "\"" + (String) value + "\"";
         } else if (value instanceof Character) {
             return "'" + value + "'";
+        } else if (value.getClass().isArray()) {
+            String tn = value.getClass().getTypeName();
+            int len = Array.getLength(value);
+            StringBuilder sb = new StringBuilder();
+            sb.append(tn.substring(tn.lastIndexOf('.') + 1, tn.length() - 1));
+            sb.append(len);
+            sb.append("] { ");
+            for (int i = 0; i < len; ++i) {
+                sb.append(valueString(Array.get(value, i)));
+                if (i < len - 1) {
+                    sb.append(", ");
+                }
+            }
+            sb.append(" }");
+            return sb.toString();
         } else {
             return value.toString();
         }
--- a/src/jdk.jshell/share/classes/jdk/jshell/execution/JDIEventHandler.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/src/jdk.jshell/share/classes/jdk/jshell/execution/JDIEventHandler.java	Thu Sep 29 17:49:42 2016 +0100
@@ -53,6 +53,7 @@
         this.vm = vm;
         this.reportVMExit = reportVMExit;
         this.thread = new Thread(this, "event-handler");
+        this.thread.setDaemon(true);
     }
 
     /**
--- a/test/jdk/javadoc/doclet/constantValues/TestConstantValuesDriver.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/constantValues/TestConstantValuesDriver.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug 4504730 4526070 5077317
+ * @bug 4504730 4526070 5077317 8162363
  * @summary Test the generation of constant-values.html.
  * @author jamieh
  * @library ../lib
@@ -53,29 +53,29 @@
                 "TEST4PASSES",
                 "<code>\"&lt;Hello World&gt;\"</code>",
                 "</a><code>public&nbsp;static&nbsp;final&nbsp;byte</code></td>\n" +
-                    "<td><code><a href=\"TestConstantValues.html#BYTE_MAX_VALUE\">" +
-                    "BYTE_MAX_VALUE</a></code></td>\n" +
+                    "<th class=\"colSecond\" scope=\"row\"><code><a href=\"TestConstantValues.html#BYTE_MAX_VALUE\">" +
+                    "BYTE_MAX_VALUE</a></code></th>\n" +
                     "<td class=\"colLast\"><code>127</code></td>",
                 "</a><code>public&nbsp;static&nbsp;final&nbsp;byte</code></td>\n" +
-                    "<td><code><a href=\"TestConstantValues.html#BYTE_MIN_VALUE\">" +
-                    "BYTE_MIN_VALUE</a></code></td>\n" +
+                    "<th class=\"colSecond\" scope=\"row\"><code><a href=\"TestConstantValues.html#BYTE_MIN_VALUE\">" +
+                    "BYTE_MIN_VALUE</a></code></th>\n" +
                     "<td class=\"colLast\"><code>-127</code></td>",
                 "</a><code>public&nbsp;static&nbsp;final&nbsp;char</code></td>\n" +
-                    "<td><code><a href=\"TestConstantValues.html#CHAR_MAX_VALUE\">" +
-                    "CHAR_MAX_VALUE</a></code></td>\n" +
+                    "<th class=\"colSecond\" scope=\"row\"><code><a href=\"TestConstantValues.html#CHAR_MAX_VALUE\">" +
+                    "CHAR_MAX_VALUE</a></code></th>\n" +
                     "<td class=\"colLast\"><code>65535</code></td>",
                 "</a><code>public&nbsp;static&nbsp;final&nbsp;double</code></td>",
-                    "<td><code><a href=\"TestConstantValues.html#DOUBLE_MAX_VALUE\">" +
-                    "DOUBLE_MAX_VALUE</a></code></td>\n" +
+                    "<th class=\"colSecond\" scope=\"row\"><code><a href=\"TestConstantValues.html#DOUBLE_MAX_VALUE\">" +
+                    "DOUBLE_MAX_VALUE</a></code></th>\n" +
                     "<td class=\"colLast\"><code>1.7976931348623157E308</code></td>",
                 "</a><code>public&nbsp;static&nbsp;final&nbsp;double</code></td>\n" +
-                    "<td><code><a href=\"TestConstantValues.html#DOUBLE_MIN_VALUE\">" +
-                    "DOUBLE_MIN_VALUE</a></code></td>",
+                    "<th class=\"colSecond\" scope=\"row\"><code><a href=\"TestConstantValues.html#DOUBLE_MIN_VALUE\">" +
+                    "DOUBLE_MIN_VALUE</a></code></th>",
                 "</a><code>public&nbsp;static&nbsp;final&nbsp;boolean</code></td>\n" +
-                    "<td><code><a href=\"TestConstantValues.html#GOODBYE\">" +
-                    "GOODBYE</a></code></td>",
+                    "<th class=\"colSecond\" scope=\"row\"><code><a href=\"TestConstantValues.html#GOODBYE\">" +
+                    "GOODBYE</a></code></th>",
                 "</a><code>public&nbsp;static&nbsp;final&nbsp;boolean</code></td>\n" +
-                    "<td><code><a href=\"TestConstantValues.html#HELLO\">HELLO</a></code></td>\n" +
+                    "<th class=\"colSecond\" scope=\"row\"><code><a href=\"TestConstantValues.html#HELLO\">HELLO</a></code></th>\n" +
                     "<td class=\"colLast\"><code>true</code></td>"
         );
     }
--- a/test/jdk/javadoc/doclet/testAnnotationTypes/TestAnnotationTypes.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testAnnotationTypes/TestAnnotationTypes.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug      4973609 8015249 8025633 8026567 6469561 8071982
+ * @bug      4973609 8015249 8025633 8026567 6469561 8071982 8162363
  * @summary  Make sure that annotation types with 0 members does not have
  *           extra HR tags.
  * @author   jamieh
@@ -56,9 +56,9 @@
                 + "field.detail\">Field</a>&nbsp;|&nbsp;</li>",
                 "<!-- =========== ANNOTATION TYPE FIELD SUMMARY =========== -->",
                 "<h3>Field Summary</h3>",
-                "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href=\"../"
+                "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href=\"../"
                 + "pkg/AnnotationTypeField.html#DEFAULT_NAME\">DEFAULT_NAME</a></span>"
-                + "</code>&nbsp;</td>",
+                + "</code></th>",
                 "<!-- ============ ANNOTATION TYPE FIELD DETAIL =========== -->",
                 "<h4>DEFAULT_NAME</h4>\n"
                 + "<pre>static final&nbsp;java."
--- a/test/jdk/javadoc/doclet/testHeadings/TestHeadings.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testHeadings/TestHeadings.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug      4905786 6259611
+ * @bug      4905786 6259611 8162363
  * @summary  Make sure that headings use the TH tag instead of the TD tag.
  * @author   jamieh
  * @library ../lib
@@ -76,7 +76,8 @@
         // Class documentation
         checkOutput("pkg1/C1.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Field and Description</th>",
+                + "<th class=\"colSecond\" scope=\"col\">Field</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>",
                 "<h3>Methods inherited from class&nbsp;java.lang.Object</h3>");
 
         // Class use documentation
@@ -84,17 +85,19 @@
                 "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
                 + "<th class=\"colLast\" scope=\"col\">Description</th>",
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Field and Description</th>");
+                + "<th class=\"colSecond\" scope=\"col\">Field</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         // Deprecated
         checkOutput("deprecated-list.html", true,
-                "<th class=\"colOne\" scope=\"col\">Method and Description</th>");
+                "<th class=\"colFirst\" scope=\"col\">Method</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         // Constant values
         checkOutput("constant-values.html", true,
                 "<th class=\"colFirst\" scope=\"col\">"
                 + "Modifier and Type</th>\n"
-                + "<th scope=\"col\">Constant Field</th>\n"
+                + "<th class=\"colSecond\" scope=\"col\">Constant Field</th>\n"
                 + "<th class=\"colLast\" scope=\"col\">Value</th>");
 
         // Serialized Form
--- a/test/jdk/javadoc/doclet/testHtmlTableTags/TestHtmlTableTags.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testHtmlTableTags/TestHtmlTableTags.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug      6786688 8008164
+ * @bug      6786688 8008164 8162363
  * @summary  HTML tables should have table summary, caption and table headers.
  * @author   Bhavesh Patel
  * @library  ../lib
@@ -282,25 +282,32 @@
         // Class documentation
         checkOutput("pkg1/C1.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Field and Description</th>",
+                + "<th class=\"colSecond\" scope=\"col\">Field</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>",
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Method and Description</th>");
+                + "<th class=\"colSecond\" scope=\"col\">Method</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         checkOutput("pkg2/C2.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Class and Description</th>",
-                "<th class=\"colOne\" scope=\"col\">Constructor and Description</th>");
+                + "<th class=\"colSecond\" scope=\"col\">Class</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>",
+                "<th class=\"colFirst\" scope=\"col\">Constructor</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         checkOutput("pkg2/C2.ModalExclusionType.html", true,
-                "<th class=\"colOne\" scope=\"col\">Enum Constant and Description</th>");
+                "<th class=\"colFirst\" scope=\"col\">Enum Constant</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         checkOutput("pkg2/C3.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Required Element and Description</th>");
+                + "<th class=\"colSecond\" scope=\"col\">Required Element</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         checkOutput("pkg2/C4.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Optional Element and Description</th>");
+                + "<th class=\"colSecond\" scope=\"col\">Optional Element</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         // Class use documentation
         checkOutput("pkg1/class-use/I1.html", true,
@@ -309,43 +316,52 @@
 
         checkOutput("pkg1/class-use/C1.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Field and Description</th>",
+                + "<th class=\"colSecond\" scope=\"col\">Field</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>",
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Method and Description</th>");
+                + "<th class=\"colSecond\" scope=\"col\">Method</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         checkOutput("pkg2/class-use/C2.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Field and Description</th>",
+                + "<th class=\"colSecond\" scope=\"col\">Field</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>",
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Method and Description</th>");
+                + "<th class=\"colSecond\" scope=\"col\">Method</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         checkOutput("pkg2/class-use/C2.ModalExclusionType.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
                 + "<th class=\"colLast\" scope=\"col\">Description</th>",
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Method and Description</th>");
+                + "<th class=\"colSecond\" scope=\"col\">Method</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         // Package use documentation
         checkOutput("pkg1/package-use.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
                 + "<th class=\"colLast\" scope=\"col\">Description</th>",
-                "<th class=\"colOne\" scope=\"col\">Class and Description</th>");
+                "<th class=\"colFirst\" scope=\"col\">Class</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         checkOutput("pkg2/package-use.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
                 + "<th class=\"colLast\" scope=\"col\">Description</th>",
-                "<th class=\"colOne\" scope=\"col\">Class and Description</th>");
+                "<th class=\"colFirst\" scope=\"col\">Class</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         // Deprecated
         checkOutput("deprecated-list.html", true,
-                "<th class=\"colOne\" scope=\"col\">Field and Description</th>",
-                "<th class=\"colOne\" scope=\"col\">Method and Description</th>");
+                "<th class=\"colFirst\" scope=\"col\">Field</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>",
+                "<th class=\"colFirst\" scope=\"col\">Method</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>");
 
         // Constant values
         checkOutput("constant-values.html", true,
                 "<th class=\"colFirst\" scope=\"col\">"
                 + "Modifier and Type</th>\n"
-                + "<th"
+                + "<th class=\"colSecond\""
                 + " scope=\"col\">Constant Field</th>\n"
                 + "<th class=\"colLast\" scope=\"col\">Value</th>");
 
--- a/test/jdk/javadoc/doclet/testJavaFX/TestJavaFX.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testJavaFX/TestJavaFX.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug 7112427 8012295 8025633 8026567 8061305 8081854 8150130
+ * @bug 7112427 8012295 8025633 8026567 8061305 8081854 8150130 8162363
  * @summary Test of the JavaFX doclet features.
  * @author jvalenta
  * @library ../lib
@@ -61,19 +61,17 @@
                     + "<div class=\"block\">Gets the value of the property rate.</div>\n"
                     + "<dl>\n"
                     + "<dt><span class=\"simpleTagLabel\">Property description:</span></dt>",
-                "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
-                    + "<a href=\"../pkg1/C.html#rateProperty\">rate</a></span></code>\n"
-                    + "<div class=\"block\">Defines the direction/speed at which the "
-                    + "<code>Timeline</code> is expected to",
+                "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
+                    + "<a href=\"../pkg1/C.html#rateProperty\">rate</a></span></code>",
                 "<span class=\"simpleTagLabel\">Default value:</span>",
                 "<span class=\"simpleTagLabel\">Since:</span></dt>\n"
                     + "<dd>JavaFX 8.0</dd>",
                 "<p>Sets the value of the property <code>Property</code>",
                 "<p>Gets the value of the property <code>Property</code>",
                 "<span class=\"simpleTagLabel\">Property description:</span>",
-                "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
+                "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
                     + "<a href=\"../pkg1/C.html#setTestMethodProperty--\">"
-                    + "setTestMethodProperty</a></span>()</code>&nbsp;</td>",
+                    + "setTestMethodProperty</a></span>()</code></th>",
                 "<h4>isPaused</h4>\n"
                     + "<pre>public final&nbsp;double&nbsp;isPaused()</pre>\n"
                     + "<div class=\"block\">Gets the value of the property paused.</div>");
@@ -152,34 +150,34 @@
         checkOutput("pkg2/Test.html", false, "<h3>Property Summary</h3>");
         checkOutput("pkg2/Test.html", true,
                 "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Method and Description</th>\n"
+                + "<th class=\"colSecond\" scope=\"col\">Method</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
                 + "</tr>\n"
                 + "<tr id=\"i0\" class=\"altColor\">\n"
                 + "<td class=\"colFirst\"><code>&lt;T&gt;&nbsp;java.lang.Object</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
-                + "<a href=\"../pkg2/Test.html#alphaProperty-java.util.List-\">"
-                + "alphaProperty</a></span>(java.util.List&lt;T&gt;&nbsp;foo)</code>&nbsp;</td>\n"
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
+                + "<a href=\"../pkg2/Test.html#alphaProperty-java.util.List-\">alphaProperty</a>"
+                + "</span>(java.util.List&lt;T&gt;&nbsp;foo)</code></th>\n"
+                + "<td class=\"colLast\">&nbsp;</td>\n"
                 + "</tr>\n"
                 + "<tr id=\"i1\" class=\"rowColor\">\n"
                 + "<td class=\"colFirst\"><code>java.lang.Object</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
-                + "<a href=\"../pkg2/Test.html#betaProperty--\">betaProperty</a></span>()</code>"
-                + "&nbsp;</td>\n"
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
+                + "<a href=\"../pkg2/Test.html#betaProperty--\">betaProperty</a></span>()</code></th>\n"
+                + "<td class=\"colLast\">&nbsp;</td>\n"
                 + "</tr>\n"
                 + "<tr id=\"i2\" class=\"altColor\">\n"
-                + "<td class=\"colFirst\"><code>"
-                + "java.util.List&lt;java.util.Set&lt;? super java.lang.Object&gt;&gt;"
+                + "<td class=\"colFirst\"><code>java.util.List&lt;java.util.Set&lt;? super java.lang.Object&gt;&gt;"
                 + "</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
-                + "<a href=\"../pkg2/Test.html#deltaProperty--\">"
-                + "deltaProperty</a></span>()</code>&nbsp;</td>\n"
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
+                + "<a href=\"../pkg2/Test.html#deltaProperty--\">deltaProperty</a></span>()</code></th>\n"
+                + "<td class=\"colLast\">&nbsp;</td>\n"
                 + "</tr>\n"
                 + "<tr id=\"i3\" class=\"rowColor\">\n"
-                + "<td class=\"colFirst\"><code>java.util.List&lt;java.lang.String&gt;"
-                + "</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
-                + "<a href=\"../pkg2/Test.html#gammaProperty--\">gammaProperty</a>"
-                + "</span>()</code>&nbsp;</td>"
+                + "<td class=\"colFirst\"><code>java.util.List&lt;java.lang.String&gt;</code></td>\n"
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
+                + "<a href=\"../pkg2/Test.html#gammaProperty--\">gammaProperty</a></span>()</code></th>\n"
+                + "<td class=\"colLast\">&nbsp;</td>"
         );
     }
 
--- a/test/jdk/javadoc/doclet/testMemberInheritence/TestMemberInheritence.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testMemberInheritence/TestMemberInheritence.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug 4638588 4635809 6256068 6270645 8025633 8026567
+ * @bug 4638588 4635809 6256068 6270645 8025633 8026567 8162363
  * @summary Test to make sure that members are inherited properly in the Javadoc.
  *          Verify that inheritence labels are correct.
  * @author jamieh
@@ -90,10 +90,10 @@
         checkOutput("pkg1/Implementer.html", true,
                 // ensure the method makes it
                 "<td class=\"colFirst\"><code>static java.time.Period</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
                 + "<a href=\"../pkg1/Implementer.html#between-java.time.LocalDate-java.time.LocalDate-\">"
                 + "between</a></span>(java.time.LocalDate&nbsp;startDateInclusive,\n"
-                + "       java.time.LocalDate&nbsp;endDateExclusive)</code>&nbsp;</td>",
+                + "       java.time.LocalDate&nbsp;endDateExclusive)</code></th>",
                 // check the inherited from interfaces
                 "<h3>Methods inherited from interface&nbsp;pkg1.<a href=\"../pkg1/Interface.html\""
                 + " title=\"interface in pkg1\">Interface</a></h3>\n"
--- a/test/jdk/javadoc/doclet/testMemberSummary/TestMemberSummary.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testMemberSummary/TestMemberSummary.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug      4951228 6290760 8025633 8026567 8081854
+ * @bug      4951228 6290760 8025633 8026567 8081854 8162363
  * @summary  Test the case where the overriden method returns a different
  *           type than the method in the child class.  Make sure the
  *           documentation is inherited but the return type isn't.
@@ -51,7 +51,7 @@
         checkOutput("pkg/PublicChild.html", true,
                 // Check return type in member summary.
                 "<code><a href=\"../pkg/PublicChild.html\" title=\"class in pkg\">PublicChild</a></code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href=\"../pkg/PublicChild.html#returnTypeTest--\">"
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href=\"../pkg/PublicChild.html#returnTypeTest--\">"
                 + "returnTypeTest</a></span>()</code>",
                 // Check return type in member detail.
                 "<pre>public&nbsp;<a href=\"../pkg/PublicChild.html\" title=\"class in pkg\">"
--- a/test/jdk/javadoc/doclet/testModules/TestModules.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testModules/TestModules.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug 8154119 8154262 8156077 8157987 8154261 8154817 8135291 8155995
+ * @bug 8154119 8154262 8156077 8157987 8154261 8154817 8135291 8155995 8162363
  * @summary Test modules support in javadoc.
  * @author bpatel
  * @library ../lib
@@ -397,7 +397,7 @@
                 + "</a>");
         checkOutput("module1-summary.html", true,
                 "<tr class=\"altColor\">\n"
-                + "<td class=\"colFirst\"><a href=\"testpkgmdl1/package-summary.html\">testpkgmdl1</a></td>\n"
+                + "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdl1/package-summary.html\">testpkgmdl1</a></th>\n"
                 + "<td class=\"colSecond\">All Modules</td>\n"
                 + "<td class=\"colLast\">&nbsp;</td>\n"
                 + "</tr>");
@@ -408,7 +408,7 @@
                 + "</a>");
         checkOutput("module1-summary.html", true,
                 "<tr class=\"rowColor\">\n"
-                + "<td class=\"colFirst\"><a href=\"module2-summary.html\">module2</a></td>\n"
+                + "<th class=\"colFirst\" scope=\"row\"><a href=\"module2-summary.html\">module2</a></th>\n"
                 + "<td class=\"colLast\">\n"
                 + "<div class=\"block\">This is a test description for the module2 module.</div>\n"
                 + "</td>\n"
@@ -424,8 +424,8 @@
                 + "</a>");
         checkOutput("module2-summary.html", true,
                 "<tr class=\"rowColor\">\n"
-                + "<td class=\"colFirst\"><a href=\"testpkg2mdl2/package-summary.html\">"
-                + "testpkg2mdl2</a></td>\n"
+                + "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkg2mdl2/package-summary.html\">"
+                + "testpkg2mdl2</a></th>\n"
                 + "<td class=\"colSecond\">module1</td>\n"
                 + "<td class=\"colLast\">&nbsp;</td>\n"
                 + "</tr>");
@@ -436,7 +436,7 @@
                 + "</a>");
         checkOutput("module2-summary.html", true,
                 "<tr class=\"altColor\">\n"
-                + "<td class=\"colFirst\"><a href=\"java.base-summary.html\">java.base</a></td>\n"
+                + "<th class=\"colFirst\" scope=\"row\"><a href=\"java.base-summary.html\">java.base</a></th>\n"
                 + "<td class=\"colLast\">&nbsp;</td>\n"
                 + "</tr>");
         checkOutput("module2-summary.html", true,
@@ -446,24 +446,24 @@
                 + "</a>");
         checkOutput("module2-summary.html", true,
                 "<tr class=\"altColor\">\n"
-                + "<td class=\"colFirst\"><a href=\"testpkgmdl2/TestClassInModule2.html\" "
-                + "title=\"class in testpkgmdl2\">TestClassInModule2</a></td>\n"
+                + "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkgmdl2/TestClassInModule2.html\" "
+                + "title=\"class in testpkgmdl2\">TestClassInModule2</a></th>\n"
                 + "<td class=\"colLast\">&nbsp;</td>\n"
                 + "</tr>");
         checkOutput("module2-summary.html", true,
                 "<tr class=\"altColor\">\n"
-                + "<td class=\"colFirst\"><a href=\"testpkg2mdl2/TestInterfaceInModule2.html\" "
+                + "<th class=\"colFirst\" scope=\"row\"><a href=\"testpkg2mdl2/TestInterfaceInModule2.html\" "
                 + "title=\"interface in testpkg2mdl2\">TestInterfaceInModule2</a><br>"
                 + "(<span class=\"implementationLabel\">Implementation:</span>&nbsp;"
                 + "<a href=\"testpkgmdl2/TestClassInModule2.html\" title=\"class in testpkgmdl2\">"
-                + "TestClassInModule2</a>)</td>\n"
+                + "TestClassInModule2</a>)</th>\n"
                 + "<td class=\"colLast\">&nbsp;</td>\n"
                 + "</tr");
         checkOutput("module2-summary.html", true,
                 "<caption><span>Exported Packages</span><span class=\"tabEnd\">&nbsp;</span></caption>\n"
                 + "<tr>\n"
                 + "<th class=\"colFirst\" scope=\"col\">Package</th>\n"
-                + "<th scope=\"col\">Module</th>\n"
+                + "<th class=\"colSecond\" scope=\"col\">Module</th>\n"
                 + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
                 + "</tr>");
         checkOutput("module2-summary.html", true,
--- a/test/jdk/javadoc/doclet/testNewLanguageFeatures/TestNewLanguageFeatures.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testNewLanguageFeatures/TestNewLanguageFeatures.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug      4789689 4905985 4927164 4827184 4993906 5004549 7025314 7010344 8025633 8026567
+ * @bug      4789689 4905985 4927164 4827184 4993906 5004549 7025314 7010344 8025633 8026567 8162363
  * @summary  Run Javadoc on a set of source files that demonstrate new
  *           language features.  Check the output to ensure that the new
  *           language features are properly documented.
@@ -134,7 +134,7 @@
                 // Method that returns TypeParameters
                 "<td class=\"colFirst\"><code><a href=\"../pkg/TypeParameters.html\" "
                 + "title=\"type parameter in TypeParameters\">E</a>[]</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
                 + "<a href=\"../pkg/TypeParameters.html#methodThatReturnsTypeParameterA-E:A-\">"
                 + "methodThatReturnsTypeParameterA</a></span>(<a href=\"../pkg/TypeParameters.html\" "
                 + "title=\"type parameter in TypeParameters\">E</a>[]&nbsp;e)</code>",
@@ -144,15 +144,15 @@
                 + "title=\"type parameter in TypeParameters\">E</a>[]&nbsp;e)</pre>\n",
                 "<td class=\"colFirst\"><code>&lt;T extends java.lang.Object &amp; java.lang.Comparable&lt;? super T&gt;&gt;"
                 + "<br>T</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
                 + "<a href=\"../pkg/TypeParameters.html#methodtThatReturnsTypeParametersB-java.util.Collection-\">"
-                + "methodtThatReturnsTypeParametersB</a></span>(java.util.Collection&lt;? extends T&gt;&nbsp;coll)</code>\n"
-                + "<div class=\"block\">Returns TypeParameters</div>\n",
+                + "methodtThatReturnsTypeParametersB</a></span>(java.util.Collection&lt;? extends T&gt;&nbsp;coll)</code>",
+                "<div class=\"block\">Returns TypeParameters</div>\n",
                 // Method takes a TypeVariable
                 "<td class=\"colFirst\"><code>&lt;X extends java.lang.Throwable&gt;<br>"
                 + "<a href=\"../pkg/TypeParameters.html\" title=\"type parameter in TypeParameters\">E</a>"
                 + "</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\">"
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
                 + "<a href=\"../pkg/TypeParameters.html#orElseThrow-java.util.function.Supplier-\">"
                 + "orElseThrow</a></span>(java.util.function.Supplier&lt;? extends X&gt;&nbsp;exceptionSupplier)</code>"
                 );
@@ -219,19 +219,19 @@
                 + "package-summary.html\">pkg2</a> with type parameters of "
                 + "type <a href=\"../../pkg2/Foo.html\" title=\"class in pkg2\">"
                 + "Foo</a></span><span class=\"tabEnd\">&nbsp;</span></caption>",
-                "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest1.html\" "
+                "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest1.html\" "
                 + "title=\"class in pkg2\">ClassUseTest1</a>&lt;T extends "
                 + "<a href=\"../../pkg2/Foo.html\" title=\"class in pkg2\">Foo"
                 + "</a> &amp; <a href=\"../../pkg2/Foo2.html\" title=\"interface in pkg2\">"
-                + "Foo2</a>&gt;</span></code>&nbsp;</td>",
+                + "Foo2</a>&gt;</span></code></th>",
                 "<caption><span>Methods in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> with type parameters of "
                 + "type <a href=\"../../pkg2/Foo.html\" title=\"class in "
                 + "pkg2\">Foo</a></span><span class=\"tabEnd\">&nbsp;</span></caption>",
-                "<td class=\"colLast\"><span class=\"typeNameLabel\">ClassUseTest1."
+                "<th class=\"colSecond\" scope=\"row\"><span class=\"typeNameLabel\">ClassUseTest1."
                 + "</span><code><span class=\"memberNameLink\"><a href=\"../../pkg2/"
                 + "ClassUseTest1.html#method-T-\">method</a></span>"
-                + "(T&nbsp;t)</code>&nbsp;</td>",
+                + "(T&nbsp;t)</code></th>",
                 "<caption><span>Fields in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> with type parameters of "
                 + "type <a href=\"../../pkg2/Foo.html\" title=\"class in pkg2\">"
@@ -259,20 +259,20 @@
                 + "type <a href=\"../../pkg2/Foo2.html\" title=\"interface "
                 + "in pkg2\">Foo2</a></span><span class=\"tabEnd\">&nbsp;"
                 + "</span></caption>",
-                "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest1.html\" "
+                "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest1.html\" "
                 + "title=\"class in pkg2\">ClassUseTest1</a>&lt;T extends "
                 + "<a href=\"../../pkg2/Foo.html\" title=\"class in pkg2\">Foo"
                 + "</a> &amp; <a href=\"../../pkg2/Foo2.html\" title=\"interface in pkg2\">"
-                + "Foo2</a>&gt;</span></code>&nbsp;</td>",
+                + "Foo2</a>&gt;</span></code></th>",
                 "<caption><span>Methods in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> with type parameters of "
                 + "type <a href=\"../../pkg2/Foo2.html\" title=\"interface "
                 + "in pkg2\">Foo2</a></span><span class=\"tabEnd\">&nbsp;"
                 + "</span></caption>",
-                "<td class=\"colLast\"><span class=\"typeNameLabel\">"
+                "<th class=\"colSecond\" scope=\"row\"><span class=\"typeNameLabel\">"
                 + "ClassUseTest1.</span><code><span class=\"memberNameLink\"><a href=\"../../"
                 + "pkg2/ClassUseTest1.html#method-T-\">method</a></span>"
-                + "(T&nbsp;t)</code>&nbsp;</td>"
+                + "(T&nbsp;t)</code></th>"
         );
 
         // ClassUseTest2: <T extends ParamTest<Foo3>>
@@ -282,20 +282,20 @@
                 + "type <a href=\"../../pkg2/ParamTest.html\" title=\"class "
                 + "in pkg2\">ParamTest</a></span><span class=\"tabEnd\">"
                 + "&nbsp;</span></caption>",
-                "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest2.html\" "
+                "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest2.html\" "
                 + "title=\"class in pkg2\">ClassUseTest2</a>&lt;T extends "
                 + "<a href=\"../../pkg2/ParamTest.html\" title=\"class in pkg2\">"
                 + "ParamTest</a>&lt;<a href=\"../../pkg2/Foo3.html\" title=\"class in pkg2\">"
-                + "Foo3</a>&gt;&gt;</span></code>&nbsp;</td>",
+                + "Foo3</a>&gt;&gt;</span></code></th>",
                 "<caption><span>Methods in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> with type parameters of "
                 + "type <a href=\"../../pkg2/ParamTest.html\" title=\"class "
                 + "in pkg2\">ParamTest</a></span><span class=\"tabEnd\">"
                 + "&nbsp;</span></caption>",
-                "<td class=\"colLast\"><span class=\"typeNameLabel\">ClassUseTest2."
+                "<th class=\"colSecond\" scope=\"row\"><span class=\"typeNameLabel\">ClassUseTest2."
                 + "</span><code><span class=\"memberNameLink\"><a href=\"../../pkg2/"
                 + "ClassUseTest2.html#method-T-\">method</a></span>"
-                + "(T&nbsp;t)</code>&nbsp;</td>",
+                + "(T&nbsp;t)</code></th>",
                 "<caption><span>Fields in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> declared as <a href=\"../"
                 + "../pkg2/ParamTest.html\" title=\"class in pkg2\">ParamTest"
@@ -323,20 +323,20 @@
                 + "package-summary.html\">pkg2</a> with type parameters of "
                 + "type <a href=\"../../pkg2/Foo3.html\" title=\"class in pkg2\">"
                 + "Foo3</a></span><span class=\"tabEnd\">&nbsp;</span></caption>",
-                "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest2.html\" "
+                "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest2.html\" "
                 + "title=\"class in pkg2\">ClassUseTest2</a>&lt;T extends "
                 + "<a href=\"../../pkg2/ParamTest.html\" title=\"class in pkg2\">"
                 + "ParamTest</a>&lt;<a href=\"../../pkg2/Foo3.html\" title=\"class in pkg2\">"
-                + "Foo3</a>&gt;&gt;</span></code>&nbsp;</td>",
+                + "Foo3</a>&gt;&gt;</span></code></th>",
                 "<caption><span>Methods in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> with type parameters of "
                 + "type <a href=\"../../pkg2/Foo3.html\" title=\"class in "
                 + "pkg2\">Foo3</a></span><span class=\"tabEnd\">&nbsp;"
                 + "</span></caption>",
-                "<td class=\"colLast\"><span class=\"typeNameLabel\">ClassUseTest2."
+                "<th class=\"colSecond\" scope=\"row\"><span class=\"typeNameLabel\">ClassUseTest2."
                 + "</span><code><span class=\"memberNameLink\"><a href=\"../../pkg2/"
                 + "ClassUseTest2.html#method-T-\">method</a></span>"
-                + "(T&nbsp;t)</code>&nbsp;</td>",
+                + "(T&nbsp;t)</code></th>",
                 "<caption><span>Methods in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> that return types with "
                 + "arguments of type <a href=\"../../pkg2/Foo3.html\" title"
@@ -357,20 +357,20 @@
                 + "type <a href=\"../../pkg2/ParamTest2.html\" title=\"class "
                 + "in pkg2\">ParamTest2</a></span><span class=\"tabEnd\">"
                 + "&nbsp;</span></caption>",
-                "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest3.html\" "
+                "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest3.html\" "
                 + "title=\"class in pkg2\">ClassUseTest3</a>&lt;T extends "
                 + "<a href=\"../../pkg2/ParamTest2.html\" title=\"class in pkg2\">"
                 + "ParamTest2</a>&lt;java.util.List&lt;? extends "
                 + "<a href=\"../../pkg2/Foo4.html\" title=\"class in pkg2\">"
-                + "Foo4</a>&gt;&gt;&gt;</span></code>&nbsp;</td>",
+                + "Foo4</a>&gt;&gt;&gt;</span></code></th>",
                 "<caption><span>Methods in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> with type parameters of "
                 + "type <a href=\"../../pkg2/ParamTest2.html\" title=\"class "
                 + "in pkg2\">ParamTest2</a></span><span class=\"tabEnd\">"
                 + "&nbsp;</span></caption>",
-                "<td class=\"colLast\"><span class=\"typeNameLabel\">ClassUseTest3"
+                "<th class=\"colSecond\" scope=\"row\"><span class=\"typeNameLabel\">ClassUseTest3"
                 + ".</span><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest3."
-                + "html#method-T-\">method</a></span>(T&nbsp;t)</code>&nbsp;</td>",
+                + "html#method-T-\">method</a></span>(T&nbsp;t)</code></th>",
                 "<td class=\"colFirst\"><code>&lt;T extends <a href=\"../"
                 + "../pkg2/ParamTest2.html\" title=\"class in pkg2\">"
                 + "ParamTest2</a>&lt;java.util.List&lt;? extends <a href=\".."
@@ -387,20 +387,20 @@
                 + "type <a href=\"../../pkg2/Foo4.html\" title=\"class in "
                 + "pkg2\">Foo4</a></span><span class=\"tabEnd\">&nbsp;"
                 + "</span></caption>",
-                "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest3.html\" "
+                "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest3.html\" "
                 + "title=\"class in pkg2\">ClassUseTest3</a>&lt;T extends "
                 + "<a href=\"../../pkg2/ParamTest2.html\" title=\"class in pkg2\">"
                 + "ParamTest2</a>&lt;java.util.List&lt;? extends "
                 + "<a href=\"../../pkg2/Foo4.html\" title=\"class in pkg2\">"
-                + "Foo4</a>&gt;&gt;&gt;</span></code>&nbsp;</td>",
+                + "Foo4</a>&gt;&gt;&gt;</span></code></th>",
                 "<caption><span>Methods in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> with type parameters of "
                 + "type <a href=\"../../pkg2/Foo4.html\" title=\"class in "
                 + "pkg2\">Foo4</a></span><span class=\"tabEnd\">&nbsp;</span></caption>",
-                "<td class=\"colLast\"><span class=\"typeNameLabel\">ClassUseTest3."
+                "<th class=\"colSecond\" scope=\"row\"><span class=\"typeNameLabel\">ClassUseTest3."
                 + "</span><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest3."
                 + "html#method-T-\">method</a></span>(T&nbsp;t)</code>"
-                + "&nbsp;</td>",
+                + "</th>",
                 "<caption><span>Methods in <a href=\"../../pkg2/"
                 + "package-summary.html\">pkg2</a> that return types with "
                 + "arguments of type <a href=\"../../pkg2/Foo4.html\" "
@@ -425,18 +425,17 @@
                 + "</span></caption>\n"
                 + "<tr>\n"
                 + "<th class=\"colFirst\" scope=\"col\">Modifier and Type</th>\n"
-                + "<th class=\"colLast\" scope=\"col\">Method and Description</th>\n"
+                + "<th class=\"colSecond\" scope=\"col\">Method</th>\n"
+                + "<th class=\"colLast\" scope=\"col\">Description</th>\n"
                 + "</tr>\n"
                 + "<tbody>\n"
                 + "<tr class=\"altColor\">\n"
                 + "<td class=\"colFirst\"><code>void</code></td>\n"
-                + "<td class=\"colLast\"><span class=\"typeNameLabel\">ClassUseTest3."
+                + "<th class=\"colSecond\" scope=\"row\"><span class=\"typeNameLabel\">ClassUseTest3."
                 + "</span><code><span class=\"memberNameLink\"><a href=\"../../pkg2/ClassUseTest3."
                 + "html#method-java.util.Set-\">method</a></span>(java."
                 + "util.Set&lt;<a href=\"../../pkg2/Foo4.html\" title=\""
-                + "class in pkg2\">Foo4</a>&gt;&nbsp;p)</code>&nbsp;</td>\n"
-                + "</tr>\n"
-                + "</tbody>",
+                + "class in pkg2\">Foo4</a>&gt;&nbsp;p)</code></th>",
                 "<caption><span>Constructor parameters in <a href=\"../../"
                 + "pkg2/package-summary.html\">pkg2</a> with type arguments "
                 + "of type <a href=\"../../pkg2/Foo4.html\" title=\"class in "
--- a/test/jdk/javadoc/doclet/testPackageDeprecation/TestPackageDeprecation.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testPackageDeprecation/TestPackageDeprecation.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug      6492694 8026567 8048351
+ * @bug      6492694 8026567 8048351 8162363
  * @summary  Test package deprecation.
  * @author   bpatel
  * @library  ../lib/
@@ -72,7 +72,7 @@
         checkOutput("allclasses-frame.html", false,
                 "FooDepr");
         checkOutput("class-use/C2.ModalExclusionType.html", true,
-                "<td class=\"colFirst\"><a href=\"#unnamed.package\">&lt;Unnamed&gt;</a></td>");
+                "<th class=\"colFirst\" scope=\"row\"><a href=\"#unnamed.package\">&lt;Unnamed&gt;</a></th>");
 
         checkFiles(false,
                 "pkg1/package-summary.html",
--- a/test/jdk/javadoc/doclet/testStylesheet/TestStylesheet.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testStylesheet/TestStylesheet.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug      4494033 7028815 7052425 8007338 8023608 8008164 8016549 8072461 8154261
+ * @bug      4494033 7028815 7052425 8007338 8023608 8008164 8016549 8072461 8154261 8162363
  * @summary  Run tests on doclet stylesheet.
  * @author   jamieh
  * @library  ../lib
@@ -139,9 +139,8 @@
                 + ".packagesSummary td.colFirst, .packagesSummary td.colSecond, .packagesSummary th.colFirst, .packagesSummary th,\n"
                 + ".usesSummary td.colFirst, .usesSummary th.colFirst,\n"
                 + ".useSummary td.colFirst, .useSummary th.colFirst,\n"
-                + ".overviewSummary td.colOne, .overviewSummary th.colOne,\n"
                 + ".memberSummary td.colFirst, .memberSummary th.colFirst,\n"
-                + ".memberSummary td.colOne, .memberSummary th.colOne,\n"
+                + ".memberSummary td.colSecond, .memberSummary th.colSecond,\n"
                 + ".typeSummary td.colFirst{\n"
                 + "    width:25%;\n"
                 + "    vertical-align:top;\n"
--- a/test/jdk/javadoc/doclet/testTypeAnnotations/TestTypeAnnotations.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testTypeAnnotations/TestTypeAnnotations.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug      8005091 8009686 8025633 8026567 6469562 8071982 8071984
+ * @bug      8005091 8009686 8025633 8026567 6469562 8071982 8071984 8162363
  * @summary  Make sure that type annotations are displayed correctly
  * @author   Bhavesh Patel
  * @library  ../lib
@@ -473,7 +473,7 @@
                 + "\" title=\"annotation in typeannos\">@RepTypeUseB</a> ...&nbsp;vararg)");
 
         checkOutput("typeannos/RepeatingOnField.html", true,
-                "<code>(package private) java.lang.Integer</code></td>\n<td class=\"colLast\">"
+                "<code>(package private) java.lang.Integer</code></td>\n<th class=\"colSecond\" scope=\"row\">"
                 + "<code><span class=\"memberNameLink\"><a href=\"../typeannos/RepeatingOnField.html#i1"
                 + "\">i1</a></span></code>",
 
@@ -483,7 +483,7 @@
                 + "@RepTypeUseA</a> <a href=\"../typeannos/RepTypeUseB.html\" title="
                 + "\"annotation in typeannos\">@RepTypeUseB</a> <a href=\"../typeannos/RepTypeUseB.html"
                 + "\" title=\"annotation in typeannos\">@RepTypeUseB</a> java.lang.Integer</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href="
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href="
                 + "\"../typeannos/RepeatingOnField.html#i2\">i2</a></span></code>",
 
                 "<code>(package private) <a href=\"../typeannos/RepTypeUseA.html\" title="
@@ -492,7 +492,7 @@
                 + "\"../typeannos/RepTypeUseB.html\" title=\"annotation in typeannos\">"
                 + "@RepTypeUseB</a> <a href=\"../typeannos/RepTypeUseB.html\" title="
                 + "\"annotation in typeannos\">@RepTypeUseB</a> java.lang.Integer</code>"
-                + "</td>\n<td class=\"colLast\"><code><span class=\"memberNameLink\">"
+                + "</td>\n<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
                 + "<a href=\"../typeannos/RepeatingOnField.html#i3\">i3</a></span></code>",
 
                 "<code>(package private) <a href=\"../typeannos/RepAllContextsA.html\" title=\""
@@ -501,7 +501,7 @@
                 + "\"../typeannos/RepAllContextsB.html\" title=\"annotation in typeannos\">"
                 + "@RepAllContextsB</a> <a href=\"../typeannos/RepAllContextsB.html\" title="
                 + "\"annotation in typeannos\">@RepAllContextsB</a> java.lang.Integer</code>"
-                + "</td>\n<td class=\"colLast\"><code><span class=\"memberNameLink\">"
+                + "</td>\n<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
                 + "<a href=\"../typeannos/RepeatingOnField.html#i4\">i4</a></span></code>",
 
                 "<code>(package private) java.lang.String <a href=\"../typeannos/RepTypeUseA.html"
@@ -515,7 +515,7 @@
                 + "\"annotation in typeannos\">@RepTypeUseA</a> <a href=\"../typeannos/RepTypeUseB.html"
                 + "\" title=\"annotation in typeannos\">@RepTypeUseB</a> <a href="
                 + "\"../typeannos/RepTypeUseB.html\" title=\"annotation in typeannos\">"
-                + "@RepTypeUseB</a> []</code></td>\n<td class=\"colLast\"><code><span class="
+                + "@RepTypeUseB</a> []</code></td>\n<th class=\"colSecond\" scope=\"row\"><code><span class="
                 + "\"memberNameLink\"><a href=\"../typeannos/RepeatingOnField.html#sa"
                 + "\">sa</a></span></code>",
 
@@ -572,8 +572,8 @@
                 + "@RepTypeUseB</a> [] sa</pre>");
 
         checkOutput("typeannos/RepeatingOnMethod.html", true,
-                "<code>(package private) java.lang.String</code></td>\n<td class="
-                + "\"colLast\"><code><span class=\"memberNameLink\"><a href="
+                "<code>(package private) java.lang.String</code></td>\n<th class=\"colSecond\" scope=\"row\">"
+                + "<code><span class=\"memberNameLink\"><a href="
                 + "\"../typeannos/RepeatingOnMethod.html#test1--\">test1</a></span>()</code>",
 
                 "<code>(package private) <a href=\"../typeannos/RepTypeUseA.html\" "
@@ -582,7 +582,7 @@
                 + "@RepTypeUseA</a> <a href=\"../typeannos/RepTypeUseB.html\" title="
                 + "\"annotation in typeannos\">@RepTypeUseB</a> <a href=\"../typeannos/RepTypeUseB.html"
                 + "\" title=\"annotation in typeannos\">@RepTypeUseB</a> java.lang.String</code>"
-                + "</td>\n<td class=\"colLast\"><code><span class=\"memberNameLink\">"
+                + "</td>\n<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
                 + "<a href=\"../typeannos/RepeatingOnMethod.html#test2--\">test2</a>"
                 + "</span>()</code>",
 
@@ -592,7 +592,7 @@
                 + "@RepTypeUseA</a> <a href=\"../typeannos/RepTypeUseB.html\" title="
                 + "\"annotation in typeannos\">@RepTypeUseB</a> <a href=\"../typeannos/RepTypeUseB.html\" "
                 + "title=\"annotation in typeannos\">@RepTypeUseB</a> java.lang.String</code>"
-                + "</td>\n<td class=\"colLast\"><code><span class=\"memberNameLink\">"
+                + "</td>\n<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\">"
                 + "<a href=\"../typeannos/RepeatingOnMethod.html#test3--\">test3</a>"
                 + "</span>()</code>",
 
@@ -602,7 +602,7 @@
                 + "@RepAllContextsA</a> <a href=\"../typeannos/RepAllContextsB.html\" "
                 + "title=\"annotation in typeannos\">@RepAllContextsB</a> <a href="
                 + "\"../typeannos/RepAllContextsB.html\" title=\"annotation in typeannos\">"
-                + "@RepAllContextsB</a> java.lang.String</code></td>\n<td class=\"colLast\">"
+                + "@RepAllContextsB</a> java.lang.String</code></td>\n<th class=\"colSecond\" scope=\"row\">"
                 + "<code><span class=\"memberNameLink\"><a href=\"../typeannos/RepeatingOnMethod.html"
                 + "#test4--\">test4</a></span>()</code>",
 
@@ -682,12 +682,12 @@
 
         checkOutput("typeannos/RepeatingOnTypeParametersBoundsTypeArgumentsOnMethod.html", true,
                 "<code>(package private) &lt;T&gt;&nbsp;java.lang.String</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href="
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href="
                 + "\"../typeannos/RepeatingOnTypeParametersBoundsTypeArgumentsOnMethod.html#"
                 + "genericMethod-T-\">genericMethod</a></span>(T&nbsp;t)</code>",
 
                 "<code>(package private) &lt;T&gt;&nbsp;java.lang.String</code></td>\n"
-                + "<td class=\"colLast\"><code><span class=\"memberNameLink\"><a href="
+                + "<th class=\"colSecond\" scope=\"row\"><code><span class=\"memberNameLink\"><a href="
                 + "\"../typeannos/RepeatingOnTypeParametersBoundsTypeArgumentsOnMethod.html#"
                 + "genericMethod2-T-\">genericMethod2</a></span>(<a href=\"../typeannos/RepTypeUseA.html"
                 + "\" title=\"annotation in typeannos\">@RepTypeUseA</a> <a href=\"../typeannos/RepTypeUseA.html"
@@ -695,7 +695,7 @@
                 + "\" title=\"annotation in typeannos\">@RepTypeUseB</a> <a href=\"../typeannos/RepTypeUseB.html"
                 + "\" title=\"annotation in typeannos\">@RepTypeUseB</a> T&nbsp;t)</code>",
 
-                "<code>(package private) java.lang.String</code></td>\n<td class=\"colLast\"><code>"
+                "<code>(package private) java.lang.String</code></td>\n<th class=\"colSecond\" scope=\"row\"><code>"
                 + "<span class=\"memberNameLink\"><a href=\"../typeannos/RepeatingOnTypeParametersBoundsTypeArgumentsOnMethod.html#"
                 + "test--\">test</a></span>()</code>",
 
--- a/test/jdk/javadoc/doclet/testUseOption/TestUseOption.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/doclet/testUseOption/TestUseOption.java	Thu Sep 29 17:49:42 2016 +0100
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug 4496290 4985072 7006178 7068595 8016328 8050031 8048351 8081854 8071982
+ * @bug 4496290 4985072 7006178 7068595 8016328 8050031 8048351 8081854 8071982 8162363
  * @summary A simple test to ensure class-use files are correct.
  * @author jamieh
  * @library ../lib
@@ -124,17 +124,17 @@
         checkOutput("pkg1/class-use/UsedInterface.html", true,
             "Subinterfaces of <a href=\"../../pkg1/UsedInterface.html\" title=\"interface in pkg1\">"
             + "UsedInterface</a> in <a href=\"../../pkg1/package-summary.html\">pkg1",
-            "<td class=\"colFirst\"><code>interface&nbsp;</code></td>\n<td class=\"colLast\">"
+            "<td class=\"colFirst\"><code>interface&nbsp;</code></td>\n<th class=\"colSecond\" scope=\"row\">"
             + "<code><span class=\"memberNameLink\"><a href=\"../../pkg1/SubInterface.html\" "
-            + "title=\"interface in pkg1\">SubInterface</a>&lt;T&gt;</span></code>&nbsp;</td>"
+            + "title=\"interface in pkg1\">SubInterface</a>&lt;T&gt;</span></code></th>"
         );
         checkOutput("pkg1/class-use/UsedThrowable.html", true,
             "Methods in <a href=\"../../pkg1/package-summary.html\">pkg1</a> that throw "
             + "<a href=\"../../pkg1/UsedThrowable.html\" title=\"class in pkg1\">UsedThrowable</a>",
-            "<td class=\"colFirst\"><code>void</code></td>\n<td class=\"colLast\"><span class="
+            "<td class=\"colFirst\"><code>void</code></td>\n<th class=\"colSecond\" scope=\"row\"><span class="
             + "\"typeNameLabel\">C1.</span><code><span class=\"memberNameLink\">"
             + "<a href=\"../../pkg1/C1.html#methodInC1ThrowsThrowable--\">methodInC1ThrowsThrowable"
-            + "</a></span>()</code>&nbsp;</td>"
+            + "</a></span>()</code></th>"
         );
     }
 
@@ -154,9 +154,9 @@
                 "<li class=\"blockList\"><a name=\"unnamed.package\">"
         );
         checkOutput("package-use.html", true,
-                "<td class=\"colOne\">"
-                + "<a href=\"class-use/UsedInC.html#unnamed.package\">UsedInC</a>&nbsp;</td>",
-                "<td class=\"colFirst\"><a href=\"#-Unnamed-\">&lt;Unnamed&gt;</a></td>\n"
+                "<th class=\"colFirst\" scope=\"row\">"
+                + "<a href=\"class-use/UsedInC.html#unnamed.package\">UsedInC</a></th>",
+                "<th class=\"colFirst\" scope=\"row\"><a href=\"#-Unnamed-\">&lt;Unnamed&gt;</a></th>\n"
                 + "<td class=\"colLast\">&nbsp;</td>"
         );
     }
--- a/test/jdk/javadoc/tool/modules/ModuleTestBase.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/tool/modules/ModuleTestBase.java	Thu Sep 29 17:49:42 2016 +0100
@@ -252,10 +252,14 @@
     }
 
     void assertAbsent(String regex) throws Exception {
-        List<String> foundList = tb.grep(regex, currentTask.getOutputLines(STDOUT));
+        assertAbsent(regex, STDOUT);
+    }
+
+    void assertAbsent(String regex, Task.OutputKind kind) throws Exception {
+        List<String> foundList = tb.grep(regex, currentTask.getOutputLines(kind));
         if (!foundList.isEmpty()) {
             dumpDocletDiagnostics();
-            throw new Exception(regex + " found in: " + STDOUT);
+            throw new Exception(regex + " found in: " + kind);
         }
     }
 
--- a/test/jdk/javadoc/tool/modules/Modules.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/javadoc/tool/modules/Modules.java	Thu Sep 29 17:49:42 2016 +0100
@@ -21,9 +21,9 @@
  * questions.
  */
 
-/**
+/*
  * @test
- * @bug 8159305
+ * @bug 8159305 8166127
  * @summary Tests primarily the module graph computations.
  * @modules
  *      jdk.javadoc/jdk.javadoc.internal.api
@@ -40,6 +40,8 @@
 import java.nio.file.Path;
 
 import toolbox.*;
+import toolbox.Task.Expect;
+import toolbox.Task.OutputKind;
 
 public class Modules extends ModuleTestBase {
 
@@ -54,8 +56,8 @@
         ModuleBuilder mb = new ModuleBuilder(tb, "m1");
         mb.comment("The first module.")
                 .exports("pub")
-                .classes("package pub; /** Klass A */ public class A {}")
-                .classes("package pro; /** Klass B */ public class B {}")
+                .classes("package pub; /** Class A */ public class A {}")
+                .classes("package pro; /** Class B */ public class B {}")
                 .write(src);
         execTask("--module-source-path", src.toString(),
                  "--module", "m1");
@@ -72,15 +74,15 @@
         mb1.comment("The first module.")
                 .exports("m1pub")
                 .requires("m2")
-                .classes("package m1pub; /** Klass A */ public class A {}")
-                .classes("package m1pro; /** Klass B */ public class B {}")
+                .classes("package m1pub; /** Class A */ public class A {}")
+                .classes("package m1pro; /** Class B */ public class B {}")
                 .write(src);
 
         ModuleBuilder mb2 = new ModuleBuilder(tb, "m2");
         mb2.comment("The second module.")
                 .exports("m2pub")
-                .classes("package m2pub; /** Klass A */ public class A {}")
-                .classes("package m2pro; /** Klass B */ public class B {}")
+                .classes("package m2pub; /** Class A */ public class A {}")
+                .classes("package m2pro; /** Class B */ public class B {}")
                 .write(src);
         execTask("--module-source-path", src.toString(),
             "--module", "m1,m2");
@@ -98,15 +100,15 @@
         mb1.comment("The first module.")
                 .exports("m1pub")
                 .requires("m2")
-                .classes("package m1pub; /** Klass A */ public class A {}")
-                .classes("package m1pro; /** Klass B */ public class B {}")
+                .classes("package m1pub; /** Class A */ public class A {}")
+                .classes("package m1pro; /** Class B */ public class B {}")
                 .write(src);
 
         ModuleBuilder mb2 = new ModuleBuilder(tb, "m2");
         mb2.comment("The second module.")
                 .exports("m2pub")
-                .classes("package m2pub; /** Klass A */ public class A {}")
-                .classes("package m2pro; /** Klass B */ public class B {}")
+                .classes("package m2pub; /** Class A */ public class A {}")
+                .classes("package m2pro; /** Class B */ public class B {}")
                 .write(src);
         execTask("--module-source-path", src.toString(),
             "--module", "m1",
@@ -117,7 +119,268 @@
 
     }
 
-   /**
+    @Test
+    public void testModulePathOption(Path base) throws Exception {
+        Path src = base.resolve("src");
+        Path modulePath = base.resolve("modules");
+
+        ModuleBuilder mb1 = new ModuleBuilder(tb, "m1");
+        mb1.comment("Module on module path.")
+                .exports("pkg1")
+                .classes("package pkg1; /** Class A */ public class A { }")
+                .build(modulePath);
+
+        ModuleBuilder mb2 = new ModuleBuilder(tb, "m2");
+        mb2.comment("The second module.")
+                .exports("pkg2")
+                .requires("m1")
+                .classes("package pkg2; /** Class B */ public class B { /** Field f */ public pkg1.A f; }")
+                .write(src);
+        execTask("--module-source-path", src.toString(),
+                "--module-path", modulePath.toString(),
+                "--module", "m2");
+        checkModulesSpecified("m2");
+        checkPackagesIncluded("pkg2");
+        checkMembersSelected("pkg2.B.f");
+
+        // module path option "-p"
+        execTask("--module-source-path", src.toString(),
+                "-p", modulePath.toString(),
+                "--module", "m2");
+        // no module path
+        execNegativeTask("--module-source-path", src.toString(),
+                "--module", "m2");
+        assertErrorPresent("error: module not found: m1");
+    }
+
+    @Test
+    public void testUpgradeModulePathOption(Path base) throws Exception {
+        Path src = base.resolve("src");
+        Path modulePath = base.resolve("modules");
+        Path upgradePath = base.resolve("upgrades");
+
+        ModuleBuilder mb1 = new ModuleBuilder(tb, "m1");
+        mb1.comment("Module on module path.")
+                .exports("pkg1")
+                .classes("package pkg1; /** Class A */ public class A { }")
+                .build(modulePath);
+
+        ModuleBuilder mbUpgrade = new ModuleBuilder(tb, "m1");
+        mbUpgrade.comment("Module on upgrade module path.")
+                .exports("pkg1")
+                .classes("package pkg1; /** Class C */ public class C { }")
+                .build(upgradePath);
+
+        ModuleBuilder mb2 = new ModuleBuilder(tb, "m2");
+        mb2.comment("The second module.")
+                .exports("pkg2")
+                .requires("m1")
+                .classes("package pkg2; /** Class B */ public class B { /** Field f */ public pkg1.C f; }")
+                .write(src);
+        execTask("--module-source-path", src.toString(),
+                "--module-path", modulePath.toString(),
+                "--upgrade-module-path", upgradePath.toString(),
+                "--module", "m2");
+        checkModulesSpecified("m2");
+        checkPackagesIncluded("pkg2");
+        checkMembersSelected("pkg2.B.f");
+
+        // no upgrade module path
+        execNegativeTask("--module-source-path", src.toString(),
+                "--module-path", modulePath.toString(),
+                "--module", "m2");
+        assertErrorPresent("error: cannot find symbol");
+
+        // dependency from module path
+        ModuleBuilder mb3 = new ModuleBuilder(tb, "m3");
+        mb3.comment("The third module.")
+                .exports("pkg3")
+                .requires("m1")
+                .classes("package pkg3; /** Class Z */ public class Z { /** Field f */ public pkg1.A f; }")
+                .write(src);
+        execNegativeTask("--module-source-path", src.toString(),
+                "--module-path", modulePath.toString(),
+                "--upgrade-module-path", upgradePath.toString(),
+                "--module", "m3");
+        assertErrorPresent("Z.java:1: error: cannot find symbol");
+    }
+
+    @Test
+    public void testAddModulesOption(Path base) throws Exception {
+        Path src = base.resolve("src");
+        Path modulePath = base.resolve("modules");
+
+        ModuleBuilder mb1 = new ModuleBuilder(tb, "m1");
+        mb1.comment("Module on module path.")
+                .exports("pkg1")
+                .classes("package pkg1; /** Class A */ public class A { }")
+                .build(modulePath);
+
+        ModuleBuilder mb2 = new ModuleBuilder(tb, "m2");
+        mb2.comment("The second module.")
+                .exports("pkg2")
+                .classes("package pkg2; /** @see pkg1.A */ public class B { }")
+                .write(src);
+
+        String log = new JavadocTask(tb)
+                .options("--module-source-path", src.toString(),
+                        "--module-path", modulePath.toString(),
+                        "--module", "m2")
+                .run(Expect.FAIL)
+                .writeAll()
+                .getOutput(OutputKind.DIRECT);
+        if (!log.contains("B.java:1: error: reference not found")) {
+            throw new Exception("Error not found");
+        }
+
+        new JavadocTask(tb)
+                .options("--module-source-path", src.toString(),
+                        "--module-path", modulePath.toString(),
+                        "--add-modules", "m1",
+                        "--module", "m2")
+                .run()
+                .writeAll();
+    }
+
+    @Test
+    public void testLimitModulesOption(Path base) throws Exception {
+        Path src = base.resolve("src");
+        Path modulePath = base.resolve("modules");
+
+        ModuleBuilder mb1 = new ModuleBuilder(tb, "m1");
+        mb1.comment("Module on module path.")
+                .build(modulePath);
+
+        ModuleBuilder mb2 = new ModuleBuilder(tb, "m2");
+        mb2.comment("The second module.")
+                .exports("pkg2")
+                .requires("m1")
+                .classes("package pkg2; /** Class B */ public class B { }")
+                .write(src);
+
+        execNegativeTask("--module-source-path", src.toString(),
+                "--module-path", modulePath.toString(),
+                "--limit-modules", "java.base",
+                "--module", "m2");
+        assertErrorPresent("error: module not found: m1");
+    }
+
+    @Test
+    public void testAddExportsOption(Path base) throws Exception {
+        Path src = base.resolve("src");
+        Path modulePath = base.resolve("modules");
+
+        ModuleBuilder mb1 = new ModuleBuilder(tb, "m1");
+        mb1.comment("Module on module path.")
+                .classes("package pkg1; /** Class A */ public class A { }")
+                .build(modulePath);
+
+        ModuleBuilder mb2 = new ModuleBuilder(tb, "m2");
+        mb2.comment("The second module.")
+                .exports("pkg2")
+                .requires("m1")
+                .classes("package pkg2; /** Class B */ public class B { /** Field f */ public pkg1.A f; }")
+                .write(src);
+        execTask("--module-source-path", src.toString(),
+                "--module-path", modulePath.toString(),
+                "--add-exports", "m1/pkg1=m2",
+                "--module", "m2");
+        checkModulesSpecified("m2");
+        checkPackagesIncluded("pkg2");
+        checkMembersSelected("pkg2.B.f");
+    }
+
+//    @Test @ignore JDK-8166379
+    public void testPatchModuleOption(Path base) throws Exception {
+        Path src = base.resolve("src");
+        Path modulePath = base.resolve("modules");
+        Path patchPath = base.resolve("patch");
+
+        ModuleBuilder mb1 = new ModuleBuilder(tb, "m1");
+        mb1.comment("Module on module path.")
+                .exports("pkg1")
+                .classes("package pkg1; /** Class A */ public class A { }")
+                .build(modulePath);
+
+        tb.writeJavaFiles(patchPath, "package pkg1; /** Class A */ public class A { public static int k; }");
+        new JavacTask(tb)
+                .files(patchPath.resolve("pkg1/A.java"))
+                .run();
+
+        ModuleBuilder mb2 = new ModuleBuilder(tb, "m2");
+        mb2.comment("The second module.")
+                .exports("pkg2")
+                .requires("m1")
+                .classes("package pkg2; /** Class B */ public class B { /** Field f */ public int f = pkg1.A.k; }")
+                .write(src);
+        execTask("--module-source-path", src.toString(),
+                "--patch-module", "m1=" + patchPath.toString(),
+                "--module-path", modulePath.toString(),
+                "--module", "m2");
+        checkModulesSpecified("m2");
+        checkPackagesIncluded("pkg2");
+        checkMembersSelected("pkg2.B.f");
+    }
+
+    @Test
+    public void testAddReadsOption(Path base) throws Exception {
+        Path src = base.resolve("src");
+        Path modulePath = base.resolve("modules");
+
+        ModuleBuilder mb1 = new ModuleBuilder(tb, "m1");
+        mb1.comment("Module on module path.")
+                .exports("pkg1")
+                .classes("package pkg1; /** Class A */ public class A {}")
+                .build(modulePath);
+
+        ModuleBuilder mb2 = new ModuleBuilder(tb, "m2");
+        mb2.comment("The second module.")
+                .exports("pkg2")
+                .classes("package pkg2; /** Class B */ public class B { /** Field f */ public pkg1.A f;}")
+                .write(src);
+        execTask("--module-source-path", src.toString(),
+                "--module-path", modulePath.toString(),
+                "--add-modules", "m1",
+                "--add-reads", "m2=m1",
+                "--module", "m2");
+        checkModulesSpecified("m2");
+        checkPackagesIncluded("pkg2");
+        checkMembersSelected("pkg2.B.f");
+    }
+
+    @Test
+    public void testModuleOptionsWithLegacy(Path base) throws Exception {
+        Files.createDirectory(base);
+        Path src = base.resolve("src");
+        Path classpath = base.resolve("classpath");
+        Path modulePath = base.resolve("modules");
+
+        tb.writeJavaFiles(classpath, "package pkg1; /** Class C */ public class C { }");
+        new JavacTask(tb)
+                .files(classpath.resolve("pkg1/C.java"))
+                .run();
+
+        ModuleBuilder mb = new ModuleBuilder(tb, "m1");
+        mb.comment("The first module.")
+                .exports("pub")
+                .classes("package pub; /** Class M */ public class M { }")
+                .build(modulePath);
+
+        tb.writeJavaFiles(src, "package pkg; /** Class L */ public class L { public pkg1.C f1; public pub.M f2; }");
+
+        execTask("--source-path", src.toString(),
+                "--class-path", classpath.toString(),
+                "--module-path", modulePath.toString(),
+                "--add-modules", "m1",
+                "pkg");
+        checkPackagesIncluded("pkg");
+        checkTypesIncluded("pkg.L");
+        checkMembersSelected("pkg.L.f1");
+        checkMembersSelected("pkg.L.f2");
+        assertAbsent("error", OutputKind.DIRECT);
+    }
+
+    /**
      * Tests diamond graph, inspired by javac diamond tests.
      *
      *
@@ -262,48 +525,48 @@
         new ModuleBuilder(tb, "J")
                 .comment("The J module.")
                 .exports("openJ")
-                .classes("package openJ;  /** Klass J open. */ public class J { }")
-                .classes("package closedJ; /** Klass J closed. */ public class J  { }")
+                .classes("package openJ;  /** Class J open. */ public class J { }")
+                .classes("package closedJ; /** Class J closed. */ public class J  { }")
                 .write(src);
 
         new ModuleBuilder(tb, "L")
                 .comment("The L module.")
                 .exports("openL")
-                .requiresTransitive("P")
-                .classes("package openL; /** Klass L open */ public class L { }")
-                .classes("package closedL;  /** Klass L closed */ public class L { }")
+                . requiresTransitive("P")
+                .classes("package openL; /** Class L open */ public class L { }")
+                .classes("package closedL;  /** Class L closed */ public class L { }")
                 .write(src);
 
         new ModuleBuilder(tb, "N")
                 .comment("The N module.")
                 .exports("openN")
                 .requiresTransitive("O")
-                .classes("package openN; /** Klass N open */ public class N  { }")
-                .classes("package closedN; /** Klass N closed */ public class N { }")
+                .classes("package openN; /** Class N open */ public class N  { }")
+                .classes("package closedN; /** Class N closed */ public class N { }")
                 .write(src);
 
         new ModuleBuilder(tb, "O")
                 .comment("The O module.")
                 .exports("openO")
                 .requires("J")
-                .classes("package openO; /** Klass O open. */ public class O { openJ.J j; }")
-                .classes("package closedO;  /** Klass O closed. */ public class O { }")
+                .classes("package openO; /** Class O open. */ public class O { openJ.J j; }")
+                .classes("package closedO;  /** Class O closed. */ public class O { }")
                 .write(src);
 
         new ModuleBuilder(tb, "P")
                 .comment("The O module.")
                 .exports("openP")
                 .requires("J")
-                .classes("package openP; /** Klass O open. */ public class O { openJ.J j; }")
-                .classes("package closedP;  /** Klass O closed. */ public class O { }")
+                .classes("package openP; /** Class O open. */ public class O { openJ.J j; }")
+                .classes("package closedP;  /** Class O closed. */ public class O { }")
                 .write(src);
 
         new ModuleBuilder(tb, "Q")
                 .comment("The Q module.")
                 .exports("openQ")
                 .requires("J")
-                .classes("package openQ; /** Klass Q open. */ public class Q { openJ.J j; }")
-                .classes("package closedQ;  /** Klass Q closed. */ public class Q { }")
+                .classes("package openQ; /** Class Q open. */ public class Q { openJ.J j; }")
+                .classes("package closedQ;  /** Class Q closed. */ public class Q { }")
                 .write(src);
 
     }
--- a/test/jdk/jshell/SimpleRegressionTest.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/jdk/jshell/SimpleRegressionTest.java	Thu Sep 29 17:49:42 2016 +0100
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2016, 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
@@ -22,7 +22,7 @@
  */
 
 /*
- * @test 8130450 8158906 8154374
+ * @test 8130450 8158906 8154374 8166400
  * @summary simple regression test
  * @build KullaTesting TestingInputStream
  * @run testng SimpleRegressionTest
@@ -149,4 +149,21 @@
         assertEval("class C {}");
         assertEval("C.class.getClassLoader() == Thread.currentThread().getContextClassLoader()", "true");
     }
+
+    public void testArayRepresentation() {
+        assertEval("new int[4]", "int[4] { 0, 0, 0, 0 }");
+        assertEval("new int[0]", "int[0] {  }");
+        assertEval("new byte[2]", "byte[2] { 0, 0 }");
+        assertEval("new short[] { 1234, 4321 }", "short[2] { 1234, 4321 }");
+        assertEval("new long[] { 123456789 }", "long[1] { 123456789 }");
+        assertEval("new float[] { -23.5645f, 1.0101f }", "float[2] { -23.5645, 1.0101 }");
+        assertEval("new double[] { 1/8, Math.PI }", "double[2] { 0.0, 3.141592653589793 }");
+        assertEval("new String[] { \"hi\", \"low\", null }", "String[3] { \"hi\", \"low\", null }");
+        assertEval("new char[] { 'a', 34, 77 }", "char[3] { 'a', '\"', 'M' }");
+        assertEval("new boolean[] { false, true }", "boolean[2] { false, true }");
+        assertEval("new int[][] { new int[] {44, 55}, new int[] {88,99}}",
+                "int[][2] { int[2] { 44, 55 }, int[2] { 88, 99 } }");
+        assertEval("new Object[] { \"howdy\", new int[] { 33, 44, 55 }, new String[] { \"up\", \"down\" }}",
+                "Object[3] { \"howdy\", int[3] { 33, 44, 55 }, String[2] { \"up\", \"down\" } }");
+    }
 }
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/AnonymousClass/AnonymousInSuperCallNegTest.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,31 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 8166108
+ * @summary Verify that a program cannot access instance state before construction
+ * @compile/fail/ref=AnonymousInSuperCallNegTest.out -XDrawDiagnostics AnonymousInSuperCallNegTest.java
+ */
+
+public class AnonymousInSuperCallNegTest {
+
+    static class Base {
+        Base(Object o) {}
+    }
+
+    static class Outer {
+        class Inner {}
+    }
+
+    public static class JavacBug extends Base {
+        int x;
+        JavacBug() {
+            super(new Outer().new Inner() {
+                void foo() {
+                    System.out.println("x = " + x);
+                }
+            }); }
+    }
+
+    public static void main(String[] args) {
+        new JavacBug();
+    }
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/AnonymousClass/AnonymousInSuperCallNegTest.out	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,2 @@
+AnonymousInSuperCallNegTest.java:23:49: compiler.err.cant.ref.before.ctor.called: x
+1 error
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/AnonymousClass/AnonymousInSuperCallTest.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,48 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8166108
+ * @summary Verify that javac skips outer this to anonymous inner classes in super type constructor calls
+ *
+ */
+
+public class AnonymousInSuperCallTest {
+
+    static class Base {
+        Base(Object o) {}
+    }
+
+    static class Outer {
+        class Inner {}
+    }
+
+    public static class JavacBug extends Base {
+        JavacBug() { super(new Outer().new Inner() {}); }
+    }
+
+    public static void main(String[] args) {
+        new JavacBug();
+    }
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/TryWithResources/TwrAndTypeVariables2Test.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,47 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8163027
+ * @summary AssertionError while compiling program that uses try with resources
+ * @compile TwrAndTypeVariables2Test.java
+ */
+
+abstract class TwrAndTypeVariables2Test_01 implements AutoCloseable {
+    @Override
+    public void close() {
+    }
+    public boolean close(long timeout) {
+        return true;
+    }
+}
+
+public abstract class TwrAndTypeVariables2Test<C extends TwrAndTypeVariables2Test_01> {
+    abstract C newCloseable();
+
+    void m() throws Exception{
+        try(C p= newCloseable()){
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/annotations/typeAnnotations/classfile/AnnotatedExtendsTest.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8164519
+ * @summary Verify that javac emits proper super type index (65535) for an annotated extends
+ * @library /tools/lib
+ * @modules jdk.compiler/com.sun.tools.javac.api
+ *          jdk.compiler/com.sun.tools.javac.main
+ *          jdk.jdeps/com.sun.tools.javap
+ * @build toolbox.ToolBox toolbox.JavapTask
+ * @run compile -g AnnotatedExtendsTest.java
+ * @run main AnnotatedExtendsTest
+ */
+
+import java.nio.file.Path;
+import java.nio.file.Paths;
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Target;
+
+import toolbox.JavapTask;
+import toolbox.Task;
+import toolbox.ToolBox;
+
+public class AnnotatedExtendsTest {
+
+    @Target(ElementType.TYPE_USE)
+    public @interface TA {
+    };
+
+    public class Inner extends @TA Object {}
+
+    public static strictfp void main(String args[]) throws Exception {
+        ToolBox tb = new ToolBox();
+        Path classPath = Paths.get(ToolBox.testClasses, "AnnotatedExtendsTest$Inner.class");
+        String javapOut = new JavapTask(tb)
+                .options("-v", "-p")
+                .classes(classPath.toString())
+                .run()
+                .getOutput(Task.OutputKind.DIRECT);
+        if (!javapOut.contains("0: #21(): CLASS_EXTENDS, type_index=65535"))
+            throw new AssertionError("Expected output missing: " + javapOut);
+    }
+}
\ No newline at end of file
--- a/test/tools/javac/annotations/typeAnnotations/referenceinfos/ClassExtends.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/tools/javac/annotations/typeAnnotations/referenceinfos/ClassExtends.java	Thu Sep 29 17:49:42 2016 +0100
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2009, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2009, 2016, 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
@@ -25,7 +25,7 @@
 
 /*
  * @test
- * @bug 8042451
+ * @bug 8042451 8164519
  * @summary Test population of reference info for class extends clauses
  * @modules jdk.jdeps/com.sun.tools.classfile
  * @compile -g Driver.java ReferenceInfoUtil.java ClassExtends.java
@@ -33,21 +33,21 @@
  */
 public class ClassExtends {
 
-    @TADescription(annotation = "TA", type = CLASS_EXTENDS, typeIndex = -1)
+    @TADescription(annotation = "TA", type = CLASS_EXTENDS, typeIndex = 65535)
     @TADescription(annotation = "TB", type = CLASS_EXTENDS, typeIndex = 1)
     public String regularClass() {
         return "class %TEST_CLASS_NAME% extends @TA Object implements Cloneable, @TB Runnable {"
                + "  public void run() { } }";
     }
 
-    @TADescription(annotation = "RTAs", type = CLASS_EXTENDS, typeIndex = -1)
+    @TADescription(annotation = "RTAs", type = CLASS_EXTENDS, typeIndex = 65535)
     @TADescription(annotation = "RTBs", type = CLASS_EXTENDS, typeIndex = 1)
     public String regularClassRepeatableAnnotation() {
         return "class %TEST_CLASS_NAME% extends @RTA @RTA Object implements Cloneable, @RTB @RTB Runnable {"
                 + "  public void run() { } }";
     }
 
-    @TADescription(annotation = "TA", type = CLASS_EXTENDS, typeIndex = -1,
+    @TADescription(annotation = "TA", type = CLASS_EXTENDS, typeIndex = 65535,
             genericLocation = { 3, 0 })
     @TADescription(annotation = "TB", type = CLASS_EXTENDS, typeIndex = 1,
             genericLocation  = { 3, 1 })
@@ -55,7 +55,7 @@
         return "class %TEST_CLASS_NAME% extends HashMap<@TA String, String> implements Cloneable, Map<String, @TB String>{ } ";
     }
 
-    @TADescription(annotation = "RTAs", type = CLASS_EXTENDS, typeIndex = -1,
+    @TADescription(annotation = "RTAs", type = CLASS_EXTENDS, typeIndex = 65535,
             genericLocation = { 3, 0 })
     @TADescription(annotation = "RTBs", type = CLASS_EXTENDS, typeIndex = 1,
             genericLocation  = { 3, 1 })
@@ -63,21 +63,21 @@
         return "class %TEST_CLASS_NAME% extends HashMap<@RTA @RTA String, String> implements Cloneable, Map<String, @RTB @RTB String>{ } ";
     }
 
-    @TADescription(annotation = "TA", type = CLASS_EXTENDS, typeIndex = -1)
+    @TADescription(annotation = "TA", type = CLASS_EXTENDS, typeIndex = 65535)
     @TADescription(annotation = "TB", type = CLASS_EXTENDS, typeIndex = 1)
     public String abstractClass() {
         return "abstract class %TEST_CLASS_NAME% extends @TA Date implements Cloneable, @TB Runnable {"
                + "  public void run() { } }";
     }
 
-    @TADescription(annotation = "RTAs", type = CLASS_EXTENDS, typeIndex = -1)
+    @TADescription(annotation = "RTAs", type = CLASS_EXTENDS, typeIndex = 65535)
     @TADescription(annotation = "RTBs", type = CLASS_EXTENDS, typeIndex = 1)
     public String abstractClassRepeatableAnnotation() {
         return "abstract class %TEST_CLASS_NAME% extends @RTA @RTA Date implements Cloneable, @RTB @RTB Runnable {"
                 + "  public void run() { } }";
     }
 
-    @TADescription(annotation = "RTAs", type = CLASS_EXTENDS, typeIndex = -1,
+    @TADescription(annotation = "RTAs", type = CLASS_EXTENDS, typeIndex = 65535,
             genericLocation = { 3, 0 })
     @TADescription(annotation = "RTBs", type = CLASS_EXTENDS, typeIndex = 1,
             genericLocation  = { 3, 1 })
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/file/MultiReleaseJar/MutliReleaseModuleInfoTest.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,148 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8156568
+ * @summary Update javac to support compiling against a modular multi-release JAR
+ * @library /tools/lib
+ * @modules jdk.compiler/com.sun.tools.javac.api
+ *          jdk.compiler/com.sun.tools.javac.main
+ * @build toolbox.ToolBox toolbox.JarTask toolbox.JavacTask
+ * @run main MutliReleaseModuleInfoTest
+ */
+
+import java.nio.file.Paths;
+import java.util.Set;
+import javax.annotation.processing.AbstractProcessor;
+import javax.annotation.processing.RoundEnvironment;
+import javax.annotation.processing.SupportedAnnotationTypes;
+import javax.lang.model.SourceVersion;
+import javax.lang.model.element.ModuleElement;
+import javax.lang.model.element.ModuleElement.RequiresDirective;
+import javax.lang.model.element.TypeElement;
+import javax.lang.model.util.ElementFilter;
+
+import toolbox.JarTask;
+import toolbox.JavacTask;
+import toolbox.Task;
+import toolbox.ToolBox;
+
+
+public class MutliReleaseModuleInfoTest {
+
+    private final String service_mi =
+            "module service {\n" +
+            "}\n";
+
+    private final String service =
+            "package service;\n" +
+            "public class Service {\n" +
+            "}\n";
+
+    private final String service_mi9 =
+            "module service {\n" +
+            "    requires java.desktop;\n" +
+            "}\n";
+
+    private final String service9 =
+            "package service;\n" +
+            "public class Service {\n" +
+            "}\n";
+
+    private final String client_mi =
+            "module client {\n" +
+            "    requires service;\n" +
+            "}\n";
+
+    private final String manifest =
+        "Manifest-Version: 1.0\n" +
+        "Multi-Release: true\n";
+
+    private final ToolBox tb = new ToolBox();
+
+    public static void main(String [] args) throws Exception {
+        new MutliReleaseModuleInfoTest().runTest();
+    }
+
+    private void runTest() throws Exception {
+        tb.createDirectories("classes", "classes/META-INF/versions/9");
+        new JavacTask(tb)
+                .outdir("classes")
+                .sources(service_mi, service)
+                .run();
+        new JavacTask(tb)
+                .outdir("classes/META-INF/versions/9")
+                .sources(service_mi9, service9)
+                .run();
+        new JarTask(tb, "multi-release.jar")
+                .manifest(manifest)
+                .baseDir("classes")
+                .files("module-info.class", "service/Service.class",
+                       "META-INF/versions/9/module-info.class",
+                       "META-INF/versions/9/service/Service.class")
+                .run();
+        tb.cleanDirectory(Paths.get("classes"));
+
+        tb.writeFile("module-info.java", client_mi);
+        Task.Result result = new JavacTask(tb)
+                .outdir("classes")
+                .options("-processor", VerifyRequires.class.getName(),
+                               "--module-path", "multi-release.jar")
+                .files("module-info.java")
+                .run();
+        result.writeAll();
+        tb.deleteFiles("module-info.java");
+
+        tb.deleteFiles(
+                "multi-release.jar",
+                "classes/module-info.class",
+                "classes"
+        );
+    }
+
+    @SupportedAnnotationTypes("*")
+    public static final class VerifyRequires extends AbstractProcessor {
+
+        @Override
+        public boolean process(Set<? extends TypeElement> u, RoundEnvironment r) {
+            ModuleElement sm = processingEnv.getElementUtils().getModuleElement("service");
+            if (sm == null) {
+                throw new AssertionError("Cannot find the service module!");
+            }
+            boolean foundjd = false;
+            for (RequiresDirective rd : ElementFilter.requiresIn(sm.getDirectives())) {
+                foundjd |= rd.getDependency().getSimpleName().contentEquals("java.desktop");
+            }
+            if (!foundjd) {
+                throw new AssertionError("Missing dependency on java desktop module!");
+            }
+            return false;
+        }
+
+        @Override
+        public SourceVersion getSupportedSourceVersion() {
+            return SourceVersion.latest();
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/processing/model/trees/BrokenEnumConstructor.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,40 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8047347
+ * @summary Verify that an explicit (incorrect) super constructor invocation in enums is not cleared
+ *          by JavacProcessingEnvironment
+ * @library /tools/javac/lib
+ * @modules jdk.compiler
+ * @build JavacTestingAbstractProcessor OnDemandAttribution
+ * @compile/process/fail/ref=BrokenEnumConstructor.out -XDrawDiagnostics -processor OnDemandAttribution BrokenEnumConstructor.java
+ */
+
+public enum BrokenEnumConstructor {
+
+    A;
+
+    BrokenEnumConstructor() {super(); /*illegal*/}
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/processing/model/trees/BrokenEnumConstructor.out	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,2 @@
+BrokenEnumConstructor.java:39:30: compiler.err.call.to.super.not.allowed.in.enum.ctor: BrokenEnumConstructor
+1 error
--- a/test/tools/javac/processing/model/trees/OnDemandAttribution.java	Thu Sep 22 15:24:33 2016 -0700
+++ b/test/tools/javac/processing/model/trees/OnDemandAttribution.java	Thu Sep 29 17:49:42 2016 +0100
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2014, 2016, 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
@@ -23,56 +23,88 @@
 
 /*
  * @test
- * @bug 8038455
+ * @bug 8038455 8047347
  * @summary Verify that in-method ClassSymbols from one round do not affect ClassSymbols in
  *          following rounds.
  * @library /tools/javac/lib
  * @modules jdk.compiler
  * @build JavacTestingAbstractProcessor OnDemandAttribution
- * @compile/process -processor OnDemandAttribution OnDemandAttribution.java
+ * @clean Gen
+ * @compile/process -processor OnDemandAttribution OnDemandAttributionData.java
  */
 
+import java.io.IOException;
+import java.io.Writer;
 import java.util.*;
 import javax.annotation.processing.*;
 import javax.lang.model.element.*;
-import static javax.lang.model.util.ElementFilter.*;
+import static javax.lang.model.util.ElementFilter.constructorsIn;
 import com.sun.source.tree.*;
 import com.sun.source.util.*;
 
 public class OnDemandAttribution extends JavacTestingAbstractProcessor {
 
     public OnDemandAttribution() {
-        class Local { }
-        new Object() { };
     }
 
+    int round;
+    Set<String> roots = new HashSet<>();
+
     public boolean process(Set<? extends TypeElement> annos,RoundEnvironment rEnv) {
-        TypeElement currentClass = elements.getTypeElement("OnDemandAttribution");
-        ExecutableElement constr = constructorsIn(currentClass.getEnclosedElements()).get(0);
-        Trees trees = Trees.instance(processingEnv);
-        TreePath path = trees.getPath(constr);
+        for (Element root : rEnv.getRootElements()) {
+            while (root.getEnclosingElement().getKind() != ElementKind.PACKAGE) {
+                root = root.getEnclosingElement();
+            }
+            roots.add(((TypeElement) root).getQualifiedName().toString());
+        }
+        for (String root : roots) {
+            TypeElement currentClass = elements.getTypeElement(root);
+            ExecutableElement constr = constructorsIn(currentClass.getEnclosedElements()).get(0);
+            Trees trees = Trees.instance(processingEnv);
+            TreePath path = trees.getPath(constr);
 
-        new TreePathScanner<Void, Void>() {
-            @Override public Void visitClass(ClassTree node, Void p) {
-                if (node.getSimpleName().contentEquals("Local")) {
-                     //will also attribute the body on demand:
+            new TreePathScanner<Void, Void>() {
+                @Override public Void visitClass(ClassTree node, Void p) {
+                    if (node.getSimpleName().contentEquals("Local")) {
+                         //will also attribute the body on demand:
+                        Element el = trees.getElement(getCurrentPath());
+                        Name binaryName = elements.getBinaryName((TypeElement) el);
+                        if (!binaryName.contentEquals("OnDemandAttributionData$1Local")) {
+                            throw new IllegalStateException("Incorrect binary name=" + binaryName);
+                        }
+                    }
+                    return super.visitClass(node, p);
+                }
+                @Override public Void visitNewClass(NewClassTree node, Void p) {
                     Element el = trees.getElement(getCurrentPath());
-                    Name binaryName = elements.getBinaryName((TypeElement) el);
-                    if (!binaryName.contentEquals("OnDemandAttribution$1Local")) {
+                    Name binaryName = elements.getBinaryName((TypeElement) el.getEnclosingElement());
+                    if (!binaryName.contentEquals("OnDemandAttributionData$1")) {
                         throw new IllegalStateException("Incorrect binary name=" + binaryName);
                     }
+                    return super.visitNewClass(node, p);
                 }
-                return super.visitClass(node, p);
+                @Override
+                public Void visitMethodInvocation(MethodInvocationTree node, Void p) {
+                    if (trees.getElement(getCurrentPath()) == null)
+                        throw new IllegalStateException("No element for: " + node);
+                    return super.visitMethodInvocation(node, p);
+                }
+                @Override
+                public Void visitIdentifier(IdentifierTree node, Void p) {
+                    if (trees.getElement(getCurrentPath()) == null)
+                        throw new IllegalStateException("No element for: " + node);
+                    return super.visitIdentifier(node, p);
+                }
+            }.scan(path, null);
+        }
+
+        if (round++ == 0) {
+            try (Writer out = filer.createSourceFile("Gen").openWriter()) {
+                out.write("class Gen { public static long C = 1; }");
+            } catch (IOException ex) {
+                throw new IllegalStateException(ex);
             }
-            @Override public Void visitNewClass(NewClassTree node, Void p) {
-                Element el = trees.getElement(getCurrentPath());
-                Name binaryName = elements.getBinaryName((TypeElement) el.getEnclosingElement());
-                if (!binaryName.contentEquals("OnDemandAttribution$1")) {
-                    throw new IllegalStateException("Incorrect binary name=" + binaryName);
-                }
-                return super.visitNewClass(node, p);
-            }
-        }.scan(path, null);
+        }
 
         return true;
     }
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/processing/model/trees/OnDemandAttributionData.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,59 @@
+/*
+ * Copyright (c) 2014, 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+public class OnDemandAttributionData {
+
+    public OnDemandAttributionData(int i) {
+        class Local { }
+        new Aux(Gen.C) { };
+    }
+
+    class Aux {
+        Aux(String str) {}
+        Aux(int i) {}
+        Aux(long l) {}
+    }
+
+    private void methodAttributionTest() {
+        System.err.println("");
+    }
+
+    enum E {
+        A;
+
+        final int i;
+
+        E() {
+            i = Integer.parseInt("1");
+        }
+
+    }
+
+    enum E2 {
+        A;
+
+        {
+            int i = Integer.parseInt("1");
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/MultiReleaseJar.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,274 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8153654
+ * @summary Tests for jdeps tool with multi-release jar files
+ * @modules jdk.jdeps/com.sun.tools.jdeps
+ * @library mrjar mrjar/base mrjar/9 mrjar/10 mrjar/v9 mrjar/v10
+ * @build test.* p.* q.*
+ * @run testng MultiReleaseJar
+ */
+
+import org.testng.Assert;
+import org.testng.annotations.AfterClass;
+import org.testng.annotations.BeforeClass;
+import org.testng.annotations.Test;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.nio.file.Path;
+import java.nio.file.Paths;
+import java.util.concurrent.TimeUnit;
+
+public class MultiReleaseJar {
+    Path mrjar;
+    String testJdk;
+    String fileSep;
+    Path cmdPath;
+
+    @BeforeClass
+    public void initialize() throws Exception {
+        mrjar = Paths.get(System.getProperty("test.classes", "."), "mrjar");
+        testJdk = System.getProperty("test.jdk");
+        fileSep = System.getProperty("file.separator");
+        cmdPath = Paths.get(testJdk, "bin");
+    }
+
+    @Test
+    public void basic() throws Exception {
+        // build the jar file
+        Result r = run("jar -cf Version.jar -C base test --release 9 -C 9 test --release 10 -C 10 test");
+        checkResult(r);
+
+        // try out a bunch of things
+        r = run("jdeps --multi-release 9  -v missing.jar");
+        checkResult(r, false, "Warning: Path does not exist: missing.jar");
+
+        r = run("jdeps -v Version.jar");
+        checkResult(r, false, "the --multi-release option is not set");
+
+        r = run("jdeps --multi-release base  -v Version.jar");
+        checkResult(r, true,
+                "Version.jar ->",
+                "test.Version",
+                "test.Version"
+        );
+
+        r = run("jdeps --multi-release 9  -v Version.jar");
+        checkResult(r, true,
+                "Version.jar ->",
+                "9/test.NonPublic",
+                "9/test.NonPublic",
+                "9/test.Version",
+                "9/test.Version",
+                "9/test.Version",
+                "9/test.Version"
+        );
+
+        r = run("jdeps --multi-release 10  -v Version.jar");
+        checkResult(r, true,
+                "Version.jar ->",
+                "10/test.Version",
+                "10/test.Version",
+                "10/test.Version",
+                "10/test.Version",
+                "9/test.NonPublic",
+                "9/test.NonPublic"
+        );
+
+        r = run("jdeps --multi-release 8  -v Version.jar");
+        checkResult(r, false, "Error: invalid argument for option: 8");
+
+        r = run("jdeps --multi-release 9.1  -v Version.jar");
+        checkResult(r, false, "Error: invalid argument for option: 9.1");
+
+        r = run("jdeps -v -R -cp Version.jar test/Main.class");
+        checkResult(r, false, "the --multi-release option is not set");
+
+        r = run("jdeps -v -R -cp Version.jar -multi-release 9 test/Main.class");
+        checkResult(r, false,
+                "Error: unknown option: -multi-release",
+                "Usage: jdeps <options> <path",
+                "use -h, -?, -help, or --help"
+        );
+
+        r = run("jdeps -v -R -cp Version.jar --multi-release 9 test/Main.class");
+        checkResult(r, true,
+                "Main.class ->",
+                "Main.class ->",
+                "test.Main",
+                "test.Main",
+                "test.Main",
+                "Version.jar ->",
+                "9/test.NonPublic",
+                "9/test.NonPublic",
+                "9/test.Version",
+                "9/test.Version",
+                "9/test.Version",
+                "9/test.Version"
+        );
+
+        r = run("jdeps -v -R -cp Version.jar --multi-release 10 test/Main.class");
+        checkResult(r, true,
+                "Main.class ->",
+                "Main.class ->",
+                "test.Main",
+                "test.Main",
+                "test.Main",
+                "Version.jar ->",
+                "10/test.Version",
+                "10/test.Version",
+                "10/test.Version",
+                "10/test.Version",
+                "9/test.NonPublic",
+                "9/test.NonPublic"
+        );
+
+        r = run("jdeps -v -R -cp Version.jar --multi-release base test/Main.class");
+        checkResult(r, true,
+                "Main.class ->",
+                "Main.class ->",
+                "test.Main",
+                "test.Main",
+                "test.Main",
+                "Version.jar ->",
+                "test.Version",
+                "test.Version"
+        );
+
+        r = run("jdeps -v -R -cp Version.jar --multi-release 9.1 test/Main.class");
+        checkResult(r, false, "Error: invalid argument for option: 9.1");
+
+        // Rebuild jar without version 10
+        r = run("jar -cf Version.jar -C base test --release 9 -C 9 test");
+        checkResult(r);
+
+        // but ask for version 10
+        r = run("jdeps -v -R -cp Version.jar --multi-release 10 test/Main.class");
+        checkResult(r, true,
+                "Main.class ->",
+                "Main.class ->",
+                "test.Main",
+                "test.Main",
+                "test.Main",
+                "Version.jar ->",
+                "9/test.NonPublic",
+                "9/test.NonPublic",
+                "9/test.Version",
+                "9/test.Version",
+                "9/test.Version",
+                "9/test.Version"
+        );
+    }
+
+    @Test
+    public void ps_and_qs() throws Exception {
+        // build the jar file
+        Result r = run("jar -cf PQ.jar -C base p --release 9 -C v9 p -C v9 q --release 10 -C v10 q");
+        checkResult(r);
+
+        r = run("jdeps -v -R -cp PQ.jar --multi-release base PQ.jar");
+        checkResult(r, true,
+                "PQ.jar -> java.base",
+                "p.Foo"
+        );
+
+        r = run("jdeps -v -R -cp PQ.jar --multi-release 9 PQ.jar");
+        checkResult(r, true,
+                "PQ.jar -> java.base",
+                "9/p.Foo",
+                "9/p.Foo",
+                "9/q.Bar"
+        );
+
+
+        r = run("jdeps -v -R -cp PQ.jar --multi-release 10 PQ.jar");
+        checkResult(r, true,
+                "PQ.jar -> java.base",
+                "10/q.Bar",
+                "10/q.Bar",
+                "10/q.Gee",
+                "9/p.Foo",
+                "9/p.Foo"
+        );
+    }
+
+    static class Result {
+        final String cmd;
+        final int rc;
+        final String out;
+        final String err;
+        Result(String cmd, int rc, String out, String err) {
+            this.cmd = cmd;
+            this.rc = rc;
+            this.out = out;
+            this.err = err;
+        }
+    }
+
+    Result run(String cmd) throws Exception {
+        String[] cmds = cmd.split(" +");
+        cmds[0] = cmdPath.resolve(cmds[0]).toString();
+        ProcessBuilder pb = new ProcessBuilder(cmds);
+        pb.directory(mrjar.toFile());
+        Process p = pb.start();
+        p.waitFor(10, TimeUnit.SECONDS);
+        String out;
+        try (InputStream is = p.getInputStream()) {
+            out = new String(is.readAllBytes());
+        }
+        String err;
+        try (InputStream is = p.getErrorStream()) {
+            err = new String(is.readAllBytes());
+        }
+        return new Result(cmd, p.exitValue(), out, err);
+    }
+
+    void checkResult(Result r) throws Exception {
+        System.out.println(r.cmd);
+        System.out.println(r.out);
+        if (r.rc != 0) {
+            System.out.println(r.err);
+            throw new Exception("rc=" + r.rc);
+        }
+        System.out.println();
+    }
+
+    void checkResult(Result r, boolean checkrc, String... lines) throws Exception {
+        System.out.println(r.cmd);
+        System.out.println(r.out);
+        if (checkrc && r.rc != 0) {
+            System.out.println(r.err);
+            throw new Exception("rc=" + r.rc);
+        }
+        String[] out = r.out.split("\r?\n");
+        Assert.assertEquals(out.length, lines.length);
+        int n = 0;
+        for (String line : lines) {
+            Assert.assertTrue(out[n++].contains(line), "\"" + line + "\"");
+        }
+        System.out.println();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/10/test/Version.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,40 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package test;
+
+public class Version {
+    public int getVersion() {
+        NonPublic np = new NonPublic();
+        String ignore = np.toString();
+        return 10;
+    }
+
+    private String getStringVersion() {
+        return "10";
+    }
+
+    private void foo() {
+        if (getStringVersion() == null) throw new NullPointerException();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/9/test/NonPublic.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,30 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package test;
+
+class NonPublic {
+    public String toString() {
+        return "NonPublic";
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/9/test/Version.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,36 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package test;
+
+public class Version {
+    public int getVersion() {
+        NonPublic np = new NonPublic();
+        String ignore = np.toString();
+        return 9;
+    }
+
+    private void foo() {
+        if (getVersion() != 9) throw new RuntimeException();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/base/p/Foo.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,28 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package p;
+
+// dependencies: Object
+public class Foo {
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/base/test/Version.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,34 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package test;
+
+public class Version {
+    public int getVersion() {
+        return 8;
+    }
+
+    private void foo() {
+        if (getVersion() != 8) throw new IllegalStateException();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/test/Main.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,35 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package test;
+
+public class Main {
+    public void run() {
+        Version v = new Version();
+        v.getVersion();
+    }
+
+    public static void main(String[] args) {
+        (new Main()).run();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/v10/q/Bar.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,29 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package q;
+
+// dependencies: Object, q.Gee
+class Bar {
+    Gee gee = new Gee();
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/v10/q/Gee.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,28 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package q;
+
+// dependencies: Object
+class Gee {
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/v9/p/Foo.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,31 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package p;
+
+// dependencies: Object, q.Bar
+public class Foo {
+    void crash() {
+        throw new RuntimeException();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/mrjar/v9/q/Bar.java	Thu Sep 29 17:49:42 2016 +0100
@@ -0,0 +1,28 @@
+/*
+ * Copyright (c) 2016, 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package q;
+
+// dependecies: Object
+class Bar {
+}