changeset 3503:99f2a8052f60

merge with jdk-9+109
author mcimadamore
date Wed, 16 Mar 2016 12:20:17 +0000
parents c7f82527a8cd 47206f242e0a
children 3197e9b4d80a
files make/build.properties src/jdk.compiler/share/classes/com/sun/tools/javac/api/JavacTrees.java src/jdk.compiler/share/classes/com/sun/tools/javac/code/Lint.java src/jdk.compiler/share/classes/com/sun/tools/javac/code/Symbol.java src/jdk.compiler/share/classes/com/sun/tools/javac/code/Symtab.java src/jdk.compiler/share/classes/com/sun/tools/javac/code/Type.java src/jdk.compiler/share/classes/com/sun/tools/javac/code/Types.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Annotate.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Attr.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Check.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Infer.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/LambdaToMethod.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Lower.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Resolve.java src/jdk.compiler/share/classes/com/sun/tools/javac/comp/SpecializeTypes.java src/jdk.compiler/share/classes/com/sun/tools/javac/file/BaseFileObject.java src/jdk.compiler/share/classes/com/sun/tools/javac/file/RegularFileObject.java src/jdk.compiler/share/classes/com/sun/tools/javac/file/ZipArchive.java src/jdk.compiler/share/classes/com/sun/tools/javac/file/ZipFileIndex.java src/jdk.compiler/share/classes/com/sun/tools/javac/file/ZipFileIndexArchive.java src/jdk.compiler/share/classes/com/sun/tools/javac/file/ZipFileIndexCache.java src/jdk.compiler/share/classes/com/sun/tools/javac/jvm/ClassReader.java src/jdk.compiler/share/classes/com/sun/tools/javac/jvm/ClassWriter.java src/jdk.compiler/share/classes/com/sun/tools/javac/jvm/Gen.java src/jdk.compiler/share/classes/com/sun/tools/javac/jvm/StringConcat.java src/jdk.compiler/share/classes/com/sun/tools/javac/main/JavaCompiler.java src/jdk.compiler/share/classes/com/sun/tools/javac/processing/JavacProcessingEnvironment.java src/jdk.compiler/share/classes/com/sun/tools/javac/resources/compiler.properties src/jdk.compiler/share/classes/com/sun/tools/javac/resources/javac.properties src/jdk.compiler/share/classes/com/sun/tools/javac/tree/DocTreeMaker.java src/jdk.compiler/share/classes/com/sun/tools/javac/util/Names.java src/jdk.compiler/share/classes/com/sun/tools/javac/util/RichDiagnosticFormatter.java src/jdk.compiler/share/classes/com/sun/tools/sjavac/server/LinePrefixFilterWriter.java src/jdk.javadoc/share/classes/com/sun/tools/doclets/internal/toolkit/util/SimpleDocFileFactory.java src/jdk.javadoc/share/classes/com/sun/tools/javadoc/api/JavadocTaskImpl.java src/jdk.javadoc/share/classes/com/sun/tools/javadoc/api/JavadocTool.java src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/util/Utils.java src/jdk.jdeps/share/classes/com/sun/tools/classfile/ClassWriter.java src/jdk.jdeps/share/classes/com/sun/tools/classfile/Dependencies.java src/jdk.jdeps/share/classes/com/sun/tools/classfile/Descriptor.java src/jdk.jshell/share/classes/jdk/internal/jshell/remote/RemoteAgent.java src/jdk.jshell/share/classes/jdk/jshell/SourceCodeAnalysisImpl.java test/jdk/javadoc/tool/sampleapi/lib/sampleapi/generator/PackageGenerator.java test/jdk/jshell/KullaTesting.java test/lib/combo/tools/javac/combo/JavacTemplateTestBase.java test/tools/javac/6521805/T6521805a.java test/tools/javac/6521805/T6521805a_1.out test/tools/javac/6521805/T6521805a_2.out test/tools/javac/6547131/p/Outer$I.class test/tools/javac/6547131/p/Outer.class test/tools/javac/InnerClassesAttribute/Outside$1$Inside.class test/tools/javac/InnerClassesAttribute/Outside.class test/tools/javac/T6413876.java test/tools/javac/T6435291/T.class test/tools/javac/T6705935.java test/tools/javac/T6873845.java test/tools/javac/annotations/typeAnnotations/classfile/NestedLambdasCastedTest.java test/tools/javac/api/T6430241.java test/tools/javac/diags/CheckResourceKeys.java test/tools/javac/diags/examples.not-yet.txt test/tools/javac/diags/examples/DiamondRedundantArgs1.java test/tools/javac/diags/examples/WarnSyntheticNameConflict.java test/tools/javac/failover/CheckAttributedTree.java test/tools/javac/file/BootClassPathPrepend.java test/tools/javac/generics/diamond/7002837/T7002837.out test/tools/javac/generics/diamond/neg/T8078473.out test/tools/javac/generics/diamond/neg/T8078473_2.out test/tools/javac/lib/DPrinter.java test/tools/javac/missingSuperRecovery/impl.class test/tools/javac/util/context/T7021650.java test/tools/javac/valhalla/typespec/Inference01.out test/tools/javac/valhalla/values/CheckInvokeDirect.java test/tools/javac/warnings/6594914/T6594914b.java test/tools/javadoc/api/basic/JavadocTaskImplTest.java test/tools/javadoc/api/basic/RunTest.java test/tools/javadoc/doclint/DocLintTest.java test/tools/javadoc/doclint/ImplicitHeadersTest.java test/tools/javadoc/sampleapi/lib/sampleapi/generator/PackageGenerator.java test/tools/sjavac/ExclPattern.java
diffstat 1848 files changed, 179047 insertions(+), 9757 deletions(-) [+]
line wrap: on
line diff
--- a/.hgtags	Wed Mar 02 19:06:15 2016 +0000
+++ b/.hgtags	Wed Mar 16 12:20:17 2016 +0000
@@ -336,3 +336,19 @@
 79501a97ca5720af846509f4bf3c6c04d7bdf82a jdk9-b91
 a3415b57507c928af8f2ad1c771eebafcd00c6c7 jdk9-b92
 7f880f98506c9046f8fb69597a41762ea1b7d042 jdk9-b93
+8356d7a909a29f321e3eaf9d3c2bbc71648529e2 jdk9-b94
+c35ddcde581676275cfeff33e1a2b90b902593d9 jdk-9+95
+d2a44416cba39957ea231eedc2fb8aad7be1b30c jdk-9+96
+ae8cdc734bab4f19ef8babd2434dcf024672ad38 jdk-9+97
+345520da2ec17100cb512a53d541a307a195305e jdk-9+98
+cb73b474703e2de266542b505cffd658bcc052da jdk-9+99
+51136404ee5e6cd5868b60d66ebd55a02170b508 jdk-9+100
+3b3bea483542bc08278af529fb25f2e5930da945 jdk-9+101
+6149fc30cd710eb3484dc9863d8837ecaedb96b6 jdk-9+102
+94cfc50c1b8a74fd7b0ed2e9e4f4a9dab4f2c6a1 jdk-9+103
+3f60a4808377a276f6398ff19e61c1b9086f4d97 jdk-9+104
+81bd82222f8a1f2b291a44a49e063973caa4e73b jdk-9+105
+dd05d3761a341143ef4a6b1a245e0960cc125b76 jdk-9+106
+7a0c343551497bd0e38ad69a77cc57d9f396615a jdk-9+107
+fd18a155ad22f62e06a9b74850ab8609d415c752 jdk-9+108
+f5991c73ed73b9a355a090b65c8d7fb9a1901f89 jdk-9+109
--- a/make/CompileInterim.gmk	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/CompileInterim.gmk	Wed Mar 16 12:20:17 2016 +0000
@@ -46,8 +46,8 @@
       $(SUPPORT_OUTPUTDIR)/gensrc/jdk.compiler \
       $(SUPPORT_OUTPUTDIR)/gensrc/jdk.javadoc \
       $(SUPPORT_OUTPUTDIR)/gensrc/jdk.jdeps, \
-    EXCLUDES := sun jdk, \
-    COPY := .gif .xml .css .js javax.tools.JavaCompilerTool, \
+    EXCLUDES := sun, \
+    COPY := .gif .png .xml .css .js javax.tools.JavaCompilerTool, \
     BIN := $(BUILDTOOLS_OUTPUTDIR)/langtools_interim_classes, \
     JAR := $(INTERIM_LANGTOOLS_JAR)))
 
--- a/make/build.properties	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/build.properties	Wed Mar 16 12:20:17 2016 +0000
@@ -77,7 +77,7 @@
     -tag "implNote:a:Implementation Note:"
 
 # Version info -- override as needed
-jdk.version = 1.9.0
+jdk.version = 9
 build.number = b00
 milestone = internal
 
@@ -88,4 +88,4 @@
 # timestamps
 # FIXME -- need to include openjdk as needed
 release = ${jdk.version}-${milestone}
-full.version = ${release}-${build.number}
+full.version = ${release}+${build.number}
--- a/make/gensrc/Gensrc-jdk.javadoc.gmk	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/gensrc/Gensrc-jdk.javadoc.gmk	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2014, 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
@@ -25,8 +25,11 @@
 
 include GensrcCommon.gmk
 
+$(eval $(call SetupVersionProperties,OLD_JAVADOC_VERSION,\
+    com/sun/tools/javadoc/resources/version.properties))
+
 $(eval $(call SetupVersionProperties,JAVADOC_VERSION,\
-    com/sun/tools/javadoc/resources/version.properties))
+    jdk/javadoc/internal/tool/resources/version.properties))
 
 $(eval $(call SetupCompileProperties,COMPILE_PROPERTIES, $(JAVADOC_VERSION)))
 
--- a/make/gensrc/GensrcCommon.gmk	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/gensrc/GensrcCommon.gmk	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2014, 2015, 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
@@ -50,7 +50,7 @@
 define SetupVersionProperties
   $(SUPPORT_OUTPUTDIR)/gensrc/$(MODULE)/$$(strip $2):
 	$(MKDIR) -p $$(@D)
-	$(PRINTF) "jdk=$(JDK_VERSION)\nfull=$(FULL_VERSION)\nrelease=$(RELEASE)\n" \
+	$(PRINTF) "jdk=$(VERSION_NUMBER)\nfull=$(VERSION_STRING)\nrelease=$(VERSION_SHORT)\n" \
 	    > $$@
 
   $$(strip $1) += $(SUPPORT_OUTPUTDIR)/gensrc/$(MODULE)/$$(strip $2)
@@ -68,7 +68,7 @@
 
   # Convert .../src/<module>/share/classes/com/sun/tools/javac/resources/javac_zh_CN.properties
   # to .../langtools/gensrc/<module>/com/sun/tools/javac/resources/javac_zh_CN.java
-  # Strip away prefix and suffix, leaving for example only: 
+  # Strip away prefix and suffix, leaving for example only:
   # "<module>/share/classes/com/sun/tools/javac/resources/javac_zh_CN"
   PROPJAVAS := $$(patsubst $(LANGTOOLS_TOPDIR)/src/%, \
       $(SUPPORT_OUTPUTDIR)/gensrc/%, \
--- a/make/netbeans/langtools/build.xml	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/netbeans/langtools/build.xml	Wed Mar 16 12:20:17 2016 +0000
@@ -93,7 +93,11 @@
         <macrodef name="resolve-main-class">
           <attribute name="tool.name"/>
           <sequential>
-            <property name="langtools.main.class" value="${tool.@{tool.name}.main.class}"/>
+            <condition property="langtools.main.class"
+                    value="jdk.javadoc.internal.tool.Main"
+                    else="${tool.@{tool.name}.main.class}">
+                <equals arg1="${langtools.tool.name}" arg2="javadoc"/>
+            </condition>
           </sequential>
         </macrodef>
     </target>
--- a/make/netbeans/langtools/nbproject/project.xml	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/netbeans/langtools/nbproject/project.xml	Wed Mar 16 12:20:17 2016 +0000
@@ -520,7 +520,7 @@
                 <package-root>${root}/build/bootstrap/jdk.jshell/gensrc</package-root>
                 <package-root>${root}/../jdk/src/jdk.internal.le/share/classes</package-root>
                 <package-root>${root}/../jdk/src/jdk.jdi/share/classes</package-root>
-                <classpath mode="compile">${root}/build/java.compiler/classes:${root}/build/jdk.compiler/classes:${root}/build/jdk.internal.le/aux:${root}/build/jdk.jdi/aux:${root}/build/jdk.internal.le/classes:${root}/build/jdk.jdi/classes</classpath>
+                <classpath mode="compile">${root}/build/java.compiler/classes:${root}/build/jdk.compiler/classes:${root}/build/jdk.internal.le/classes:${root}/build/jdk.jdi/classes</classpath>
                 <built-to>${root}/build/jdk.jshell/classes</built-to>
                 <source-level>1.8</source-level>
             </compilation-unit>
--- a/make/tools/propertiesparser/parser/Message.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/tools/propertiesparser/parser/Message.java	Wed Mar 16 12:20:17 2016 +0000
@@ -20,6 +20,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package propertiesparser.parser;
 
 import java.util.ArrayList;
--- a/make/tools/propertiesparser/parser/MessageFile.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/tools/propertiesparser/parser/MessageFile.java	Wed Mar 16 12:20:17 2016 +0000
@@ -20,6 +20,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package propertiesparser.parser;
 
 import java.io.*;
--- a/make/tools/propertiesparser/parser/MessageInfo.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/tools/propertiesparser/parser/MessageInfo.java	Wed Mar 16 12:20:17 2016 +0000
@@ -20,6 +20,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package propertiesparser.parser;
 
 import propertiesparser.parser.MessageType.CompoundType;
--- a/make/tools/propertiesparser/parser/MessageLine.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/make/tools/propertiesparser/parser/MessageLine.java	Wed Mar 16 12:20:17 2016 +0000
@@ -20,6 +20,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package propertiesparser.parser;
 
 import java.util.regex.Pattern;
--- a/src/java.compiler/share/classes/javax/lang/model/SourceVersion.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/lang/model/SourceVersion.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2015, 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
@@ -55,7 +55,7 @@
      * 1.6: no changes
      * 1.7: diamond syntax, try-with-resources, etc.
      * 1.8: lambda expressions and default methods
-     * 1.9: To be determined
+     * 9: To be determined
      */
 
     /**
@@ -145,7 +145,7 @@
      * The version recognized by the Java Platform, Standard Edition
      * 9.
      *
-     * @since 1.9
+     * @since 9
      */
      RELEASE_9;
 
@@ -168,6 +168,7 @@
             String specVersion = System.getProperty("java.specification.version");
 
             switch (specVersion) {
+                case "9":
                 case "1.9":
                     return RELEASE_9;
                 case "1.8":
--- a/src/java.compiler/share/classes/javax/lang/model/util/AbstractAnnotationValueVisitor9.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/lang/model/util/AbstractAnnotationValueVisitor9.java	Wed Mar 16 12:20:17 2016 +0000
@@ -57,7 +57,7 @@
  * @see AbstractAnnotationValueVisitor6
  * @see AbstractAnnotationValueVisitor7
  * @see AbstractAnnotationValueVisitor8
- * @since 1.9
+ * @since 9
  */
 @SupportedSourceVersion(RELEASE_9)
 public abstract class AbstractAnnotationValueVisitor9<R, P> extends AbstractAnnotationValueVisitor8<R, P> {
--- a/src/java.compiler/share/classes/javax/lang/model/util/AbstractElementVisitor9.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/lang/model/util/AbstractElementVisitor9.java	Wed Mar 16 12:20:17 2016 +0000
@@ -61,7 +61,7 @@
  * @see AbstractElementVisitor6
  * @see AbstractElementVisitor7
  * @see AbstractElementVisitor8
- * @since 1.9
+ * @since 9
  */
 @SupportedSourceVersion(RELEASE_9)
 public abstract class AbstractElementVisitor9<R, P> extends AbstractElementVisitor8<R, P> {
--- a/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor9.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/lang/model/util/AbstractTypeVisitor9.java	Wed Mar 16 12:20:17 2016 +0000
@@ -61,7 +61,7 @@
  * @see AbstractTypeVisitor6
  * @see AbstractTypeVisitor7
  * @see AbstractTypeVisitor8
- * @since 1.9
+ * @since 9
  */
 @SupportedSourceVersion(RELEASE_9)
 public abstract class AbstractTypeVisitor9<R, P> extends AbstractTypeVisitor8<R, P> {
--- a/src/java.compiler/share/classes/javax/lang/model/util/ElementKindVisitor9.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/lang/model/util/ElementKindVisitor9.java	Wed Mar 16 12:20:17 2016 +0000
@@ -74,7 +74,7 @@
  * @see ElementKindVisitor6
  * @see ElementKindVisitor7
  * @see ElementKindVisitor8
- * @since 1.9
+ * @since 9
  */
 @SupportedSourceVersion(RELEASE_9)
 public class ElementKindVisitor9<R, P> extends ElementKindVisitor8<R, P> {
--- a/src/java.compiler/share/classes/javax/lang/model/util/ElementScanner9.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/lang/model/util/ElementScanner9.java	Wed Mar 16 12:20:17 2016 +0000
@@ -87,7 +87,7 @@
  * @see ElementScanner6
  * @see ElementScanner7
  * @see ElementScanner8
- * @since 1.9
+ * @since 9
  */
 @SupportedSourceVersion(RELEASE_9)
 public class ElementScanner9<R, P> extends ElementScanner8<R, P> {
--- a/src/java.compiler/share/classes/javax/lang/model/util/SimpleAnnotationValueVisitor9.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/lang/model/util/SimpleAnnotationValueVisitor9.java	Wed Mar 16 12:20:17 2016 +0000
@@ -64,7 +64,7 @@
  * @see SimpleAnnotationValueVisitor6
  * @see SimpleAnnotationValueVisitor7
  * @see SimpleAnnotationValueVisitor8
- * @since 1.9
+ * @since 9
  */
 @SupportedSourceVersion(RELEASE_9)
 public class SimpleAnnotationValueVisitor9<R, P> extends SimpleAnnotationValueVisitor8<R, P> {
--- a/src/java.compiler/share/classes/javax/lang/model/util/SimpleElementVisitor9.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/lang/model/util/SimpleElementVisitor9.java	Wed Mar 16 12:20:17 2016 +0000
@@ -69,7 +69,7 @@
  * @see SimpleElementVisitor6
  * @see SimpleElementVisitor7
  * @see SimpleElementVisitor8
- * @since 1.9
+ * @since 9
  */
 @SupportedSourceVersion(RELEASE_9)
 public class SimpleElementVisitor9<R, P> extends SimpleElementVisitor8<R, P> {
--- a/src/java.compiler/share/classes/javax/lang/model/util/TypeKindVisitor9.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/lang/model/util/TypeKindVisitor9.java	Wed Mar 16 12:20:17 2016 +0000
@@ -72,7 +72,7 @@
  * @see TypeKindVisitor6
  * @see TypeKindVisitor7
  * @see TypeKindVisitor8
- * @since 1.9
+ * @since 9
  */
 @SupportedSourceVersion(RELEASE_9)
 public class TypeKindVisitor9<R, P> extends TypeKindVisitor8<R, P> {
--- a/src/java.compiler/share/classes/javax/tools/DocumentationTool.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/tools/DocumentationTool.java	Wed Mar 16 12:20:17 2016 +0000
@@ -22,6 +22,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package javax.tools;
 
 import java.io.Writer;
--- a/src/java.compiler/share/classes/javax/tools/FileManagerUtils.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/tools/FileManagerUtils.java	Wed Mar 16 12:20:17 2016 +0000
@@ -32,7 +32,7 @@
 /**
  * Package-private utility methods to convert between files and paths.
  *
- * @since 1.9
+ * @since 9
  */
 class FileManagerUtils {
     private FileManagerUtils() { }
--- a/src/java.compiler/share/classes/javax/tools/StandardJavaFileManager.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/tools/StandardJavaFileManager.java	Wed Mar 16 12:20:17 2016 +0000
@@ -187,7 +187,7 @@
      * a directory or if this file manager does not support any of the
      * given paths.
      *
-     * @since 1.9
+     * @since 9
      */
     default Iterable<? extends JavaFileObject> getJavaFileObjectsFromPaths(
             Iterable<? extends Path> paths) {
@@ -226,7 +226,7 @@
      * @throws NullPointerException if the given array contains null
      * elements
      *
-     * @since 1.9
+     * @since 9
      */
     default Iterable<? extends JavaFileObject> getJavaFileObjects(Path... paths) {
         return getJavaFileObjectsFromPaths(Arrays.asList(paths));
@@ -295,7 +295,7 @@
      * @throws IOException if {@code location} is an output location and
      * {@code paths} does not represent an existing directory
      *
-     * @since 1.9
+     * @since 9
      */
     default void setLocationFromPaths(Location location, Iterable<? extends Path> paths)
         throws IOException {
@@ -324,7 +324,7 @@
      * associated search path
      *
      * @see #setLocationFromPaths
-     * @since 1.9
+     * @since 9
      */
     default Iterable<? extends Path> getLocationAsPaths(Location location) {
         return asPaths(getLocation(location));
@@ -345,7 +345,7 @@
      * @throws IllegalArgumentException if the file object does not have an underlying path
      * @throws UnsupportedOperationException if the operation is not supported by this file manager
      *
-     * @since 1.9
+     * @since 9
      */
     default Path asPath(FileObject file) {
         throw new UnsupportedOperationException();
--- a/src/java.compiler/share/classes/javax/tools/ToolProvider.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/java.compiler/share/classes/javax/tools/ToolProvider.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 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
@@ -28,12 +28,7 @@
 import java.lang.ref.Reference;
 import java.lang.ref.WeakReference;
 import java.util.HashMap;
-import java.util.Locale;
 import java.util.Map;
-import java.util.logging.Logger;
-import java.util.logging.Level;
-
-import static java.util.logging.Level.*;
 
 /**
  * Provides methods for locating tool providers, for example,
@@ -45,47 +40,6 @@
  */
 public class ToolProvider {
 
-    private static final String propertyName = "sun.tools.ToolProvider";
-    private static final String loggerName   = "javax.tools";
-
-    /*
-     * Define the system property "sun.tools.ToolProvider" to enable
-     * debugging:
-     *
-     *     java ... -Dsun.tools.ToolProvider ...
-     */
-    static <T> T trace(Level level, Object reason) {
-        // NOTE: do not make this method private as it affects stack traces
-        try {
-            if (System.getProperty(propertyName) != null) {
-                StackTraceElement[] st = Thread.currentThread().getStackTrace();
-                String method = "???";
-                String cls = ToolProvider.class.getName();
-                if (st.length > 2) {
-                    StackTraceElement frame = st[2];
-                    method = String.format((Locale)null, "%s(%s:%s)",
-                                           frame.getMethodName(),
-                                           frame.getFileName(),
-                                           frame.getLineNumber());
-                    cls = frame.getClassName();
-                }
-                Logger logger = Logger.getLogger(loggerName);
-                if (reason instanceof Throwable) {
-                    logger.logp(level, cls, method,
-                                reason.getClass().getName(), (Throwable)reason);
-                } else {
-                    logger.logp(level, cls, method, String.valueOf(reason));
-                }
-            }
-        } catch (SecurityException ex) {
-            System.err.format((Locale)null, "%s: %s; %s%n",
-                              ToolProvider.class.getName(),
-                              reason,
-                              ex.getLocalizedMessage());
-        }
-        return null;
-    }
-
     private static final String systemJavaCompilerName
         = "com.sun.tools.javac.api.JavacTool";
 
@@ -104,7 +58,7 @@
     }
 
     private static final String systemDocumentationToolName
-        = "com.sun.tools.javadoc.api.JavadocTool";
+        = "jdk.javadoc.internal.api.JavadocTool";
 
     /**
      * Returns the Java&trade; programming language documentation tool provided
@@ -153,7 +107,7 @@
         try {
             return c.asSubclass(clazz).newInstance();
         } catch (InstantiationException | IllegalAccessException | RuntimeException | Error e) {
-            return trace(WARNING, e);
+            throw new Error(e);
         }
     }
 
@@ -164,7 +118,7 @@
             try {
                 c = Class.forName(name, false, ClassLoader.getSystemClassLoader());
             } catch (ClassNotFoundException | RuntimeException | Error e) {
-                return trace(WARNING, e);
+                throw new Error(e);
             }
             toolClasses.put(name, new WeakReference<>(c));
         }
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/AttributeTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/AttributeTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -33,12 +33,10 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface AttributeTree extends DocTree {
     /**
      * The kind of an attribute value.
      */
-    @jdk.Exported
     enum ValueKind {
         /** The attribute value is empty. */
         EMPTY,
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/AuthorTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/AuthorTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface AuthorTree extends BlockTagTree {
     /**
      * Returns the name of the author.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/BlockTagTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/BlockTagTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -31,7 +31,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface BlockTagTree extends DocTree {
     /**
      * Returns the name of the tag.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/CommentTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/CommentTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -33,7 +33,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface CommentTree extends DocTree {
     /**
      * Returns the text of the comment.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/DeprecatedTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/DeprecatedTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface DeprecatedTree extends BlockTagTree {
     /**
      * Returns the description explaining why an item is deprecated.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/DocCommentTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/DocCommentTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -36,7 +36,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface DocCommentTree extends DocTree {
     /**
      * Returns the first sentence of a documentation comment.
@@ -49,7 +48,7 @@
      * before any block tags, including the first sentence.
      * @return body of a documentation comment first sentence inclusive
      *
-     * @since 1.9
+     * @since 9
      */
     default List<? extends DocTree> getFullBody() {
         ArrayList<DocTree> bodyList = new ArrayList<>();
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/DocRootTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/DocRootTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -33,5 +33,4 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface DocRootTree extends InlineTagTree { }
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/DocTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/DocTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2011, 2015, 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
@@ -30,12 +30,10 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface DocTree {
     /**
      * Enumerates all kinds of trees.
      */
-    @jdk.Exported
     enum Kind {
         /**
          * Used for instances of {@link AttributeTree}
@@ -110,6 +108,12 @@
         IDENTIFIER,
 
         /**
+         * Used for instances of {@index term optional-descr}
+         * representing a search term.
+         */
+        INDEX("index"),
+
+        /**
          * Used for instances of {@link InheritDocTree}
          * representing an @inheritDoc tag.
          */
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/DocTreeVisitor.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/DocTreeVisitor.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -54,7 +54,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface DocTreeVisitor<R,P> {
 
     /**
@@ -138,6 +137,14 @@
     R visitIdentifier(IdentifierTree node, P p);
 
     /**
+     * Visits an IndexTree node.
+     * @param node the node being visited
+     * @param p a parameter value
+     * @return a result value
+     */
+    R visitIndex(IndexTree node, P p);
+
+    /**
      * Visits an InheritDocTree node.
      * @param node the node being visited
      * @param p a parameter value
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/EndElementTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/EndElementTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface EndElementTree extends DocTree {
     /**
      * Returns the name of this element.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/EntityTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/EntityTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -38,7 +38,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface EntityTree extends DocTree {
     /**
      * Returns the name or value of the entity.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/ErroneousTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/ErroneousTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -22,6 +22,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package com.sun.source.doctree;
 
 import javax.tools.Diagnostic;
@@ -32,7 +33,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface ErroneousTree extends TextTree {
     /**
      * Returns a diagnostic object giving details about
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/IdentifierTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/IdentifierTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface IdentifierTree extends DocTree {
     /**
      * Returns the name of the identifier.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/IndexTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -0,0 +1,50 @@
+/*
+ * Copyright (c) 2015, 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.source.doctree;
+
+import java.util.List;
+
+/**
+ * A tree node for an @index or &#064;index inline tag.
+ *
+ * <p>
+ * {&#064;index keyword optional description} <br>
+ *
+ * @since 9
+ */
+public interface IndexTree extends InlineTagTree {
+    /**
+     * Returns the specified search term.
+     * @return the search term
+     */
+    DocTree getSearchTerm();
+
+    /**
+     * Returns the description, if any.
+     * @return the description
+     */
+    List<? extends DocTree> getDescription();
+}
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/InheritDocTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/InheritDocTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -34,5 +34,4 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface InheritDocTree extends InlineTagTree { }
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/InlineTagTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/InlineTagTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -31,7 +31,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface InlineTagTree extends DocTree {
     /**
      * Returns the name of the tag.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/LinkTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/LinkTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -36,7 +36,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface LinkTree extends InlineTagTree {
     /**
      * Returns the reference of a link.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/LiteralTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/LiteralTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -34,7 +34,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface LiteralTree extends InlineTagTree {
     /**
      * Returns the body of the {@code @code} or {@code @literal} tag.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/ParamTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/ParamTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface ParamTree extends BlockTagTree {
     /**
      * Returns true if this is documenting a type parameter.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/ReferenceTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/ReferenceTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -34,7 +34,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface ReferenceTree extends DocTree {
     /**
      * Returns the signature of the Java language element being referenced,
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/ReturnTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/ReturnTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface ReturnTree extends BlockTagTree {
     /**
      * Returns the description of the return value of a method.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/SeeTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/SeeTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -38,7 +38,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface SeeTree extends BlockTagTree {
     /**
      * Returns the reference.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/SerialDataTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/SerialDataTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface SerialDataTree extends BlockTagTree {
     /**
      * Returns the description of the serial data.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/SerialFieldTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/SerialFieldTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface SerialFieldTree extends BlockTagTree {
     /**
      * Returns the name of the serial field.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/SerialTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/SerialTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface SerialTree extends BlockTagTree {
     /**
      * Returns the description of the field, or the word
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/SinceTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/SinceTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface SinceTree extends BlockTagTree {
     /**
      * Returns the text explaining the availability of the item being documented.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/StartElementTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/StartElementTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -36,7 +36,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface StartElementTree extends DocTree {
     /**
      * Returns the name of the element.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/TextTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/TextTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -30,7 +30,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface TextTree extends DocTree {
     /**
      * Returns the text.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/ThrowsTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/ThrowsTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -38,7 +38,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface ThrowsTree extends BlockTagTree {
     /**
      * Returns a name of the exception being documented.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/UnknownBlockTagTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/UnknownBlockTagTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -22,6 +22,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package com.sun.source.doctree;
 
 import java.util.List;
@@ -35,7 +36,6 @@
  * @since 1.8
  *
  */
-@jdk.Exported
 public interface UnknownBlockTagTree extends BlockTagTree {
     /**
      * Returns the content of an unrecognized block tag.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/UnknownInlineTagTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/UnknownInlineTagTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -22,6 +22,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package com.sun.source.doctree;
 
 import java.util.List;
@@ -35,7 +36,6 @@
  * @since 1.8
  *
  */
-@jdk.Exported
 public interface UnknownInlineTagTree extends InlineTagTree {
     /**
      * Returns the content of an unrecognized inline tag.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/ValueTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/ValueTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -33,7 +33,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface ValueTree extends InlineTagTree {
     /**
      * Returns the reference to the value.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/VersionTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/VersionTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -36,7 +36,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface VersionTree extends BlockTagTree {
     /**
      * Returns the body of the tag.
--- a/src/jdk.compiler/share/classes/com/sun/source/doctree/package-info.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/doctree/package-info.java	Wed Mar 16 12:20:17 2016 +0000
@@ -31,5 +31,4 @@
  * @since 1.8
  * @see <a href="http://download.oracle.com/javase/6/docs/technotes/tools/solaris/javadoc.html#javadoctags">http://download.oracle.com/javase/6/docs/technotes/tools/solaris/javadoc.html#javadoctags</a>
  */
-@jdk.Exported
 package com.sun.source.doctree;
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/AnnotatedTypeTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/AnnotatedTypeTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Mahmood Ali
  * @since 1.8
  */
-@jdk.Exported
 public interface AnnotatedTypeTree extends ExpressionTree {
     /**
      * Returns the annotations associated with this type expression.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/AnnotationTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/AnnotationTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -42,7 +42,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface AnnotationTree extends ExpressionTree {
     /**
      * Returns the annotation type.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ArrayAccessTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ArrayAccessTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,7 +39,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ArrayAccessTree extends ExpressionTree {
     /**
      * Returns the expression for the array being accessed.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ArrayTypeTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ArrayTypeTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,7 +39,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ArrayTypeTree extends Tree {
     /**
      * Returns the element type of this array type.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/AssertTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/AssertTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface AssertTree extends StatementTree {
     /**
      * Returns the condition being asserted.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/AssignmentTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/AssignmentTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,7 +39,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface AssignmentTree extends ExpressionTree {
     /**
      * Returns the variable being assigned to.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/BinaryTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/BinaryTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -40,7 +40,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface BinaryTree extends ExpressionTree {
     /**
      * Returns the left (first) operand of the expression.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/BlockTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/BlockTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -45,7 +45,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface BlockTree extends StatementTree {
     /**
      * Returns true if and only if this is a static initializer block.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/BreakTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/BreakTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -43,7 +43,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface BreakTree extends StatementTree {
     /**
      * Returns the label for this {@code break} statement.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/CaseTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/CaseTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -45,7 +45,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface CaseTree extends Tree {
     /**
      * Returns the expression for the case, or
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/CatchTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/CatchTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -40,7 +40,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface CatchTree extends Tree {
     /**
      * Returns the catch variable.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ClassTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ClassTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -48,7 +48,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ClassTree extends StatementTree {
     /**
      * Returns the modifiers, including any annotations,
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/CompilationUnitTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/CompilationUnitTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -37,7 +37,6 @@
  * @author Peter von der Ah&eacute;
  * @since 1.6
  */
-@jdk.Exported
 public interface CompilationUnitTree extends Tree {
     /**
      * Returns the annotations listed on any package declaration
@@ -59,7 +58,7 @@
      * Returns the package tree associated with this compilation unit,
      * or {@code null} if there is no package declaration.
      * @return the package tree
-     * @since 1.9
+     * @since 9
      */
     PackageTree getPackage();
 
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/CompoundAssignmentTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/CompoundAssignmentTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -40,7 +40,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface CompoundAssignmentTree extends ExpressionTree {
     /**
      * Returns the variable on the left hand side of the compound assignment.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ConditionalExpressionTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ConditionalExpressionTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,7 +39,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ConditionalExpressionTree extends ExpressionTree {
     /**
      * Returns the condition.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ContinueTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ContinueTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -42,7 +42,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ContinueTree extends StatementTree {
     /**
      * Returns the label for this {@code continue} statement.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/DoWhileLoopTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/DoWhileLoopTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface DoWhileLoopTree extends StatementTree {
     /**
      * Returns the condition of the loop.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/EmptyStatementTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/EmptyStatementTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,5 +39,4 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface EmptyStatementTree extends StatementTree {}
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/EnhancedForLoopTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/EnhancedForLoopTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -40,7 +40,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface EnhancedForLoopTree extends StatementTree {
     /**
      * Returns the control variable for the loop.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ErroneousTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ErroneousTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -34,7 +34,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ErroneousTree extends ExpressionTree {
     /**
      * Returns any trees that were saved in this node.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ExpressionStatementTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ExpressionStatementTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,7 +39,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ExpressionStatementTree extends StatementTree {
     /**
      * Returns the expression constituting this statement.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ExpressionTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ExpressionTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,5 +35,4 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ExpressionTree extends Tree {}
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ForLoopTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ForLoopTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -42,7 +42,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ForLoopTree extends StatementTree {
     /**
      * Returns any initializers of the {@code for} statement.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/IdentifierTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/IdentifierTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface IdentifierTree extends ExpressionTree {
     /**
      * Returns the name of the identifier.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/IfTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/IfTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -45,7 +45,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface IfTree extends StatementTree {
     /**
      * Returns the condition of the if-statement.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ImportTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ImportTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ImportTree extends Tree {
     /**
      * Returns true if this is a static import declaration.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/InstanceOfTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/InstanceOfTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,7 +39,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface InstanceOfTree extends ExpressionTree {
     /**
      * Returns the expression to be tested.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/IntersectionTypeTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/IntersectionTypeTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -34,7 +34,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface IntersectionTypeTree extends Tree {
     /**
      * Returns the bounds of the type.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/LabeledStatementTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/LabeledStatementTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface LabeledStatementTree extends StatementTree {
     /**
      * Returns the label.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/LambdaExpressionTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/LambdaExpressionTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -37,7 +37,6 @@
  *   (x,y)-> { return x + y; }
  * }</pre>
  */
-@jdk.Exported
 public interface LambdaExpressionTree extends ExpressionTree {
 
     /**
@@ -47,7 +46,6 @@
      * <li> statement lambdas, whose body is a block
      * </ul>
      */
-    @jdk.Exported
     public enum BodyKind {
         /** enum constant for expression lambdas */
         EXPRESSION,
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/LineMap.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/LineMap.java	Wed Mar 16 12:20:17 2016 +0000
@@ -31,7 +31,6 @@
  *
  * @since 1.6
  */
-@jdk.Exported
 public interface LineMap {
     /**
      * Finds the start position of a line.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/LiteralTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/LiteralTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -40,7 +40,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface LiteralTree extends ExpressionTree {
     /**
      * Returns the value of the literal expression.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/MemberReferenceTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/MemberReferenceTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,14 +39,12 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface MemberReferenceTree extends ExpressionTree {
 
     /**
      * There are two kinds of member references: (i) method references and
      * (ii) constructor references
      */
-    @jdk.Exported
     public enum ReferenceMode {
         /** enum constant for method references. */
         INVOKE,
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/MemberSelectTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/MemberSelectTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface MemberSelectTree extends ExpressionTree {
     /**
      * Returns the expression for which a member is to be selected.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/MethodInvocationTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/MethodInvocationTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -43,7 +43,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface MethodInvocationTree extends ExpressionTree {
     /**
      * Returns the type arguments for this method invocation.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/MethodTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/MethodTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -46,7 +46,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface MethodTree extends Tree {
     /**
      * Returns the modifiers, including any annotations for the method being declared.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ModifiersTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ModifiersTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -45,7 +45,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ModifiersTree extends Tree {
     /**
      * Returns the flags in this modifiers tree.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/NewArrayTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/NewArrayTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -43,7 +43,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface NewArrayTree extends ExpressionTree {
     /**
      * Returns the base type of the expression.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/NewClassTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/NewClassTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -48,7 +48,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface NewClassTree extends ExpressionTree {
     /**
      * Returns the enclosing expression, or {@code null} if none.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/PackageTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/PackageTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -33,9 +33,8 @@
  * @jls sections 7.3, and 7.4
  *
  * @author Paul Govereau
- * @since 1.9
+ * @since 9
  */
-@jdk.Exported
 public interface PackageTree extends Tree {
     /**
      * Returns the annotations associated with this package declaration.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ParameterizedTypeTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ParameterizedTypeTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ParameterizedTypeTree extends Tree {
     /**
      * Returns the base type.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ParenthesizedTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ParenthesizedTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -40,7 +40,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ParenthesizedTree extends ExpressionTree {
     /**
      * Returns the expression within the parentheses.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/PrimitiveTypeTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/PrimitiveTypeTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface PrimitiveTypeTree extends Tree {
     /**
      * Returns the kind of this primitive type.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ReturnTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ReturnTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -40,7 +40,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ReturnTree extends StatementTree {
     /**
      * Returns the expression to be returned.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/Scope.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/Scope.java	Wed Mar 16 12:20:17 2016 +0000
@@ -48,7 +48,6 @@
  *
  * @since 1.6
  */
-@jdk.Exported
 public interface Scope {
     /**
      * Returns the enclosing scope.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/StatementTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/StatementTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,5 +35,4 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface StatementTree extends Tree {}
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/SwitchTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/SwitchTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -43,7 +43,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface SwitchTree extends StatementTree {
     /**
      * Returns the expression for the {@code switch} statement.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/SynchronizedTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/SynchronizedTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -40,7 +40,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface SynchronizedTree extends StatementTree {
     /**
      * Returns the expression on which to synchronize.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/ThrowTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/ThrowTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,7 +39,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface ThrowTree extends StatementTree {
     /**
      * Returns the expression to be thrown.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/Tree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/Tree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,13 +39,11 @@
  *
  * @since 1.6
  */
-@jdk.Exported
 public interface Tree {
 
     /**
      * Enumerates all kinds of trees.
      */
-    @jdk.Exported
     public enum Kind {
         /**
          * Used for instances of {@link AnnotatedTypeTree}
@@ -212,7 +210,7 @@
 
         /**
          * Used for instances of {@link PackageTree}.
-         * @since 1.9
+         * @since 9
          */
         PACKAGE(PackageTree.class),
 
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/TreeVisitor.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/TreeVisitor.java	Wed Mar 16 12:20:17 2016 +0000
@@ -56,7 +56,6 @@
  *
  * @since 1.6
  */
-@jdk.Exported
 public interface TreeVisitor<R,P> {
     /**
      * Visits an AnnotatedTypeTree node.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/TryTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/TryTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -45,7 +45,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface TryTree extends StatementTree {
     /**
      * Returns the block of the {@code try} statement.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/TypeCastTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/TypeCastTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,7 +39,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface TypeCastTree extends ExpressionTree {
     /**
      * Returns the target type of the cast.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/TypeParameterTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/TypeParameterTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -46,7 +46,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface TypeParameterTree extends Tree {
     /**
      * Returns the name of the type parameter.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/UnaryTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/UnaryTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -42,7 +42,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface UnaryTree extends ExpressionTree {
     /**
      * Returns the expression that is the operand of the unary operator.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/UnionTypeTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/UnionTypeTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  *
  * @since 1.7
  */
-@jdk.Exported
 public interface UnionTypeTree extends Tree {
     /**
      * Returns the alternative type expressions.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/VariableTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/VariableTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -42,7 +42,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface VariableTree extends StatementTree {
     /**
      * Returns the modifiers, including any annotations, on the declaration.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/WhileLoopTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/WhileLoopTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -41,7 +41,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface WhileLoopTree extends StatementTree {
     /**
      * Returns the condition of the loop.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/WildcardTree.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/WildcardTree.java	Wed Mar 16 12:20:17 2016 +0000
@@ -44,7 +44,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface WildcardTree extends Tree {
     /**
      * Returns the bound of the wildcard.
--- a/src/jdk.compiler/share/classes/com/sun/source/tree/package-info.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/tree/package-info.java	Wed Mar 16 12:20:17 2016 +0000
@@ -31,5 +31,4 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 package com.sun.source.tree;
--- a/src/jdk.compiler/share/classes/com/sun/source/util/DocSourcePositions.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/DocSourcePositions.java	Wed Mar 16 12:20:17 2016 +0000
@@ -36,7 +36,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface DocSourcePositions extends SourcePositions {
 
     /**
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/DocTreeFactory.java	Wed Mar 16 12:20:17 2016 +0000
@@ -0,0 +1,338 @@
+/*
+ * Copyright (c) 2011, 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.source.util;
+
+import java.util.List;
+
+import javax.lang.model.element.Name;
+import javax.tools.Diagnostic;
+import javax.tools.JavaFileObject;
+
+import com.sun.source.doctree.AttributeTree;
+import com.sun.source.doctree.AttributeTree.ValueKind;
+import com.sun.source.doctree.AuthorTree;
+import com.sun.source.doctree.CommentTree;
+import com.sun.source.doctree.DeprecatedTree;
+import com.sun.source.doctree.DocCommentTree;
+import com.sun.source.doctree.DocRootTree;
+import com.sun.source.doctree.DocTree;
+import com.sun.source.doctree.EndElementTree;
+import com.sun.source.doctree.EntityTree;
+import com.sun.source.doctree.ErroneousTree;
+import com.sun.source.doctree.IdentifierTree;
+import com.sun.source.doctree.IndexTree;
+import com.sun.source.doctree.InheritDocTree;
+import com.sun.source.doctree.LinkTree;
+import com.sun.source.doctree.LiteralTree;
+import com.sun.source.doctree.ParamTree;
+import com.sun.source.doctree.ReferenceTree;
+import com.sun.source.doctree.ReturnTree;
+import com.sun.source.doctree.SeeTree;
+import com.sun.source.doctree.SerialDataTree;
+import com.sun.source.doctree.SerialFieldTree;
+import com.sun.source.doctree.SerialTree;
+import com.sun.source.doctree.SinceTree;
+import com.sun.source.doctree.StartElementTree;
+import com.sun.source.doctree.TextTree;
+import com.sun.source.doctree.ThrowsTree;
+import com.sun.source.doctree.UnknownBlockTagTree;
+import com.sun.source.doctree.UnknownInlineTagTree;
+import com.sun.source.doctree.ValueTree;
+import com.sun.source.doctree.VersionTree;
+
+/**
+ *  Factory for creating {@code DocTree} nodes.
+ *
+ *  @implNote The methods in an implementation of this interface may only accept {@code DocTree}
+ *  nodes that have been created by the same implementation.
+ *
+ *  @since 9
+ */
+public interface DocTreeFactory {
+    /**
+     * Create a new {@code AttributeTree} object, to represent an HTML attribute in an HTML tag.
+     * @param name  the name of the attribute
+     * @param vkind the kind of attribute value
+     * @param value the value, if any, of the attribute
+     * @return an {@code AttributeTree} object
+     */
+    AttributeTree newAttributeTree(Name name, ValueKind vkind, List<? extends DocTree> value);
+
+    /**
+     * Create a new {@code AuthorTree} object, to represent an {@code {@author } } tag.
+     * @param name the name of the author
+     * @return an {@code AuthorTree} object
+     */
+    AuthorTree newAuthorTree(List<? extends DocTree> name);
+
+    /**
+     * Create a new {@code CodeTree} object, to represent a {@code {@code } } tag.
+     * @param text the content of the tag
+     * @return a {@code CodeTree} object
+     */
+    LiteralTree newCodeTree(TextTree text);
+
+    /**
+     * Create a new {@code CommentTree}, to represent an HTML comment.
+     * @param text the content of the comment
+     * @return a {@code CommentTree} object
+     */
+    CommentTree newCommentTree(String text);
+
+    /**
+     * Create a new {@code DeprecatedTree} object, to represent an {@code {@deprecated } } tag.
+     * @param text the content of the tag
+     * @return a {@code DeprecatedTree} object
+     */
+    DeprecatedTree newDeprecatedTree(List<? extends DocTree> text);
+
+    /**
+     * Create a new {@code DocCommentTree} object, to represent a complete doc comment.
+     * @param firstSentence the first sentence of the doc comment
+     * @param body the body of the doc comment following the first sentence
+     * @param tags the block tags in the doc comment
+     * @return a {@code DocCommentTree} object
+     */
+    DocCommentTree newDocCommentTree(List<? extends DocTree> firstSentence, List<? extends DocTree> body, List<? extends DocTree> tags);
+
+    /**
+     * Create a new {@code DocRootTree} object, to represent an {@code {@docroot} } tag.
+     * @return a {@code DocRootTree} object
+     */
+    DocRootTree newDocRootTree();
+
+    /**
+     * Create a new {@code EndElement} object, to represent the end of an HTML element.
+     * @param name the name of the HTML element
+     * @return an {@code EndElementTree} object
+     */
+    EndElementTree newEndElementTree(Name name);
+
+    /**
+     * Create a new {@code EntityTree} object, to represent an HTML entity.
+     * @param name the name of the entity, representing the characters between '&lt;' and ';'
+     * in the representation of the entity in an HTML document
+     * @return an {@code EntityTree} object
+     */
+    EntityTree newEntityTree(Name name);
+
+    /**
+     * Create a new {@code ErroneousTree} object, to represent some unparseable input.
+     * @param text the unparseable text
+     * @param diag a diagnostic associated with the unparseable text, or null
+     * @return an {@code ErroneousTree} object
+     */
+    ErroneousTree newErroneousTree(String text, Diagnostic<JavaFileObject> diag);
+
+    /**
+     * Create a new {@code ExceptionTree} object, to represent an {@code @exception } tag.
+     * @param name the name of the exception
+     * @param description a description of why the exception might be thrown
+     * @return an {@code ExceptionTree} object
+     */
+    ThrowsTree newExceptionTree(ReferenceTree name, List<? extends DocTree> description);
+
+    /**
+     * Create a new {@code IdentifierTree} object, to represent an identifier, such as in a
+     * {@code @param } tag.
+     * @param name the name of the identifier
+     * @return an {@code IdentifierTree} object
+     */
+    IdentifierTree newIdentifierTree(Name name);
+
+    /**
+     * Create a new {@code IndexTree} object, to represent an {@code {@index } } tag.
+     * @param term the search term
+     * @param description an optional description of the search term
+     * @return an {@code IndexTree} object
+     */
+    IndexTree newIndexTree(DocTree term, List<? extends DocTree> description);
+
+    /**
+     * Create a new {@code InheritDocTree} object, to represent an {@code {@inheritDoc} } tag.
+     * @return an {@code InheritDocTree} object
+     */
+    InheritDocTree newInheritDocTree();
+
+    /**
+     * Create a new {@code LinkTree} object, to represent a {@code {@link } } tag.
+     * @param ref the API element being referenced
+     * @param label an optional label for the link
+     * @return a {@code LinkTree} object
+     */
+    LinkTree newLinkTree(ReferenceTree ref, List<? extends DocTree> label);
+
+    /**
+     * Create a new {@code LinkPlainTree} object, to represent a {@code {@linkplain } } tag.
+     * @param ref the API element being referenced
+     * @param label an optional label for the link
+     * @return a {@code LinkPlainTree} object
+     */
+    LinkTree newLinkPlainTree(ReferenceTree ref, List<? extends DocTree> label);
+
+    /**
+     * Create a new {@code LiteralTree} object, to represent a {@code {@literal } } tag.
+     * @param text the content of the tag
+     * @return a {@code LiteralTree} object
+     */
+    LiteralTree newLiteralTree(TextTree text);
+
+    /**
+     * Create a new {@code ParamTree} object, to represent a {@code @param } tag.
+     * @param isTypeParameter true if this is a type parameter, and false otherwise
+     * @param name the parameter being described
+     * @param description the description of the parameter
+     * @return a {@code ParamTree} object
+     */
+    ParamTree newParamTree(boolean isTypeParameter, IdentifierTree name, List<? extends DocTree> description);
+
+    /**
+     * Create a new {@code ReferenceTree} object, to represent a reference to an API element.
+     *
+     * @param signature the doc comment signature of the reference
+     * @return a {@code ReferenceTree} object
+     */
+    ReferenceTree newReferenceTree(String signature);
+
+    /**
+     * Create a new {@code ReturnTree} object, to represent a {@code @return } tag.
+     * @param description the description of the return value of a method
+     * @return a {@code ReturnTree} object
+     */
+    ReturnTree newReturnTree(List<? extends DocTree> description);
+
+    /**
+     * Create a new {@code SeeTree} object, to represent a {@code @see } tag.
+     * @param reference the reference
+     * @return a {@code SeeTree} object
+     */
+    SeeTree newSeeTree(List<? extends DocTree> reference);
+
+    /**
+     * Create a new {@code SerialTree} object, to represent a {@code @serial } tag.
+     * @param description the description for the tag
+     * @return a {@code SerialTree} object
+     */
+    SerialTree newSerialTree(List<? extends DocTree> description);
+
+    /**
+     * Create a new {@code SerialDataTree} object, to represent a {@code @serialData } tag.
+     * @param description the description for the tag
+     * @return a {@code SerialDataTree} object
+     */
+    SerialDataTree newSerialDataTree(List<? extends DocTree> description);
+
+    /**
+     * Create a new {@code SerialFieldTree} object, to represent a {@code @serialField } tag.
+     * @param name the name of the field
+     * @param type the type of the field
+     * @param description the description of the field
+     * @return a {@code SerialFieldTree} object
+     */
+    SerialFieldTree newSerialFieldTree(IdentifierTree name, ReferenceTree type, List<? extends DocTree> description);
+
+    /**
+     * Create a new {@code SinceTree} object, to represent a {@code @since } tag.
+     * @param text the content of the tag
+     * @return a {@code SinceTree} object
+     */
+    SinceTree newSinceTree(List<? extends DocTree> text);
+
+    /**
+     * Create a new {@code StartElementTree} object, to represent the start of an HTML element.
+     * @param name the name of the HTML element
+     * @param attrs the attributes
+     * @param selfClosing true if the start element is marked as self-closing; otherwise false
+     * @return a {@code StartElementTree} object
+     */
+    StartElementTree newStartElementTree(Name name, List<? extends DocTree> attrs, boolean selfClosing);
+
+    /**
+     * Create a new {@code TextTree} object, to represent some plain text.
+     * @param text the text
+     * @return a {@code TextTree} object
+     */
+    TextTree newTextTree(String text);
+
+    /**
+     * Create a new {@code ThrowsTree} object, to represent a {@code @throws } tag.
+     * @param name the name of the exception
+     * @param description a description of why the exception might be thrown
+     * @return a {@code ThrowsTree} object
+     */
+    ThrowsTree newThrowsTree(ReferenceTree name, List<? extends DocTree> description);
+
+    /**
+     * Create a new {@code UnknownBlockTagTree} object, to represent an unrecognized block tag.
+     * @param name the name of the block tag
+     * @param content the content
+     * @return an {@code UnknownBlockTagTree} object
+     */
+    UnknownBlockTagTree newUnknownBlockTagTree(Name name, List<? extends DocTree> content);
+
+    /**
+     * Create a new {@code UnknownInlineTagTree} object, to represent an unrecognized inline tag.
+     * @param name the name of the inline tag
+     * @param content the content
+     * @return an {@code UnknownInlineTagTree} object
+     */
+    UnknownInlineTagTree newUnknownInlineTagTree(Name name, List<? extends DocTree> content);
+
+    /**
+     * Create a new {@code ValueTree} object, to represent a {@code {@value } } tag.
+     * @param ref a reference to the value
+     * @return a {@code ValueTree} object
+     */
+    ValueTree newValueTree(ReferenceTree ref);
+
+    /**
+     * Create a new {@code VersionTree} object, to represent a {@code {@version } } tag.
+     * @param text the content of the tag
+     * @return a {@code VersionTree} object
+     */
+    VersionTree newVersionTree(List<? extends DocTree> text);
+
+    /**
+     * Set the position to be recorded in subsequent tree nodes created by this factory.
+     * The position should be a character offset relative to the beginning of the source file
+     * or {@link javax.tools.Diagnostic#NOPOS NOPOS}.
+     * @param pos the position
+     * @return this object, to facilitate method chaining
+     */
+    DocTreeFactory at(int pos);
+
+    /**
+     * Get the first sentence contained in a list of content.
+     * The determination of the first sentence is implementation specific, and may
+     * involve the use of a locale-specific {@link java.text.BreakIterator BreakIterator}
+     * and other heuristics.
+     * The resulting list may share a common set of initial items with the input list.
+     * @param list the list
+     * @return a list containing the first sentence of the list.
+     */
+    List<DocTree> getFirstSentence(List<? extends DocTree> list);
+
+}
--- a/src/jdk.compiler/share/classes/com/sun/source/util/DocTreePath.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/DocTreePath.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2006, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2006, 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
@@ -37,7 +37,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public class DocTreePath implements Iterable<DocTree> {
     /**
      * Returns a documentation tree path for a tree node within a compilation unit,
@@ -71,6 +70,7 @@
         }
 
         class PathFinder extends DocTreePathScanner<DocTreePath,DocTree> {
+            @Override
             public DocTreePath scan(DocTree tree, DocTree target) {
                 if (tree == target) {
                     throw new Result(new DocTreePath(getCurrentPath(), target));
@@ -152,18 +152,22 @@
         return parent;
     }
 
+    @Override
     public Iterator<DocTree> iterator() {
         return new Iterator<DocTree>() {
+            @Override
             public boolean hasNext() {
                 return next != null;
             }
 
+            @Override
             public DocTree next() {
                 DocTree t = next.leaf;
                 next = next.parent;
                 return t;
             }
 
+            @Override
             public void remove() {
                 throw new UnsupportedOperationException();
             }
--- a/src/jdk.compiler/share/classes/com/sun/source/util/DocTreePathScanner.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/DocTreePathScanner.java	Wed Mar 16 12:20:17 2016 +0000
@@ -22,6 +22,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package com.sun.source.util;
 
 import com.sun.source.doctree.DocTree;
@@ -36,7 +37,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public class DocTreePathScanner<R, P> extends DocTreeScanner<R, P> {
     /**
      * Scans a tree from a position identified by a tree path.
--- a/src/jdk.compiler/share/classes/com/sun/source/util/DocTreeScanner.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/DocTreeScanner.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2011, 2015, 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
@@ -26,6 +26,7 @@
 package com.sun.source.util;
 
 import com.sun.source.doctree.*;
+import com.sun.tools.javac.tree.DCTree.DCIndex;
 
 
 /**
@@ -67,7 +68,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public class DocTreeScanner<R,P> implements DocTreeVisitor<R,P> {
 
     /**
@@ -255,6 +255,20 @@
      * @return the result of scanning
      */
     @Override
+    public R visitIndex(IndexTree node, P p) {
+        R r = scan(node.getSearchTerm(), p);
+        r = scanAndReduce(node.getDescription(), p, r);
+        return r;
+    }
+
+    /**
+     * {@inheritDoc} This implementation returns {@code null}.
+     *
+     * @param node  {@inheritDoc}
+     * @param p  {@inheritDoc}
+     * @return the result of scanning
+     */
+    @Override
     public R visitInheritDoc(InheritDocTree node, P p) {
         return null;
     }
--- a/src/jdk.compiler/share/classes/com/sun/source/util/DocTrees.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/DocTrees.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2011, 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
@@ -43,7 +43,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public abstract class DocTrees extends Trees {
     /**
      * Returns a DocTrees object for a given CompilationTask.
@@ -73,7 +72,7 @@
      * Returns {@code null} if none has been specified.
      * @return the break iterator
      *
-     * @since 1.9
+     * @since 9
      */
     public abstract BreakIterator getBreakIterator();
 
@@ -91,7 +90,7 @@
      * @param e an element whose documentation is required
      * @return the doc comment tree
      *
-     * @since 1.9
+     * @since 9
      */
     public abstract DocCommentTree getDocCommentTree(Element e);
 
@@ -105,7 +104,7 @@
      * @param fileObject the content container
      * @return the doc comment tree
      *
-     * @since 1.9
+     * @since 9
      */
     public abstract DocCommentTree getDocCommentTree(FileObject fileObject);
 
@@ -122,11 +121,25 @@
      * @return the doc comment tree
      * @throws java.io.IOException if an exception occurs
      *
-     * @since 1.9
+     * @since 9
      */
     public abstract DocCommentTree getDocCommentTree(Element e, String relativePath) throws IOException;
 
     /**
+     * Returns a doc tree path containing the doc comment tree of the given file.
+     * The file must be an HTML file, in which case the doc comment tree represents the
+     * contents of the &lt;body&gt; tag, and any enclosing tags are ignored.
+     * Returns {@code null} if no doc comment was found.
+     * Future releases may support additional file types.
+     *
+     * @param fileObject the content container
+     * @return a doc tree path containing the doc comment read from the given file.
+     *
+     * @since 9
+     */
+    public abstract DocTreePath getDocTreePath(FileObject fileObject);
+
+    /**
      * Returns the language model element referred to by the leaf node of the given
      * {@link DocTreePath}, or {@code null} if unknown.
      * @param path the path for the tree node
@@ -141,7 +154,7 @@
      * @param list the DocTree list to interrogate
      * @return the first sentence
      *
-     * @since 1.9
+     * @since 9
      */
     public abstract List<DocTree> getFirstSentence(List<? extends DocTree> list);
 
@@ -173,7 +186,15 @@
      * @param breakiterator a break iterator or {@code null} to specify the default
      *                      sentence breaker
      *
-     * @since 1.9
+     * @since 9
      */
     public abstract void setBreakIterator(BreakIterator breakiterator);
+
+    /**
+     * Returns a utility object for creating {@code DocTree} objects.
+     * @return  a utility object for creating {@code DocTree} objects
+     *
+     * @since 9
+     */
+    public abstract DocTreeFactory getDocTreeFactory();
 }
--- a/src/jdk.compiler/share/classes/com/sun/source/util/JavacTask.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/JavacTask.java	Wed Mar 16 12:20:17 2016 +0000
@@ -48,7 +48,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public abstract class JavacTask implements CompilationTask {
 
     /**
--- a/src/jdk.compiler/share/classes/com/sun/source/util/Plugin.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/Plugin.java	Wed Mar 16 12:20:17 2016 +0000
@@ -22,6 +22,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package com.sun.source.util;
 
 import java.util.ServiceLoader;
@@ -48,7 +49,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public interface Plugin {
     /**
      * Returns the user-friendly name of this plug-in.
--- a/src/jdk.compiler/share/classes/com/sun/source/util/SimpleDocTreeVisitor.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/SimpleDocTreeVisitor.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2015, 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
@@ -38,7 +38,6 @@
  *
  * @since 1.8
  */
-@jdk.Exported
 public class SimpleDocTreeVisitor<R,P> implements DocTreeVisitor<R, P> {
     /**
      * The default value, returned by the {@link #defaultAction default action}.
@@ -224,6 +223,18 @@
      * @return  the result of {@code defaultAction}
      */
     @Override
+    public R visitIndex(IndexTree node, P p) {
+        return defaultAction(node, p);
+    }
+
+    /**
+     * {@inheritDoc} This implementation calls {@code defaultAction}.
+     *
+     * @param node {@inheritDoc}
+     * @param p {@inheritDoc}
+     * @return  the result of {@code defaultAction}
+     */
+    @Override
     public R visitInheritDoc(InheritDocTree node, P p) {
         return defaultAction(node, p);
     }
--- a/src/jdk.compiler/share/classes/com/sun/source/util/SimpleTreeVisitor.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/SimpleTreeVisitor.java	Wed Mar 16 12:20:17 2016 +0000
@@ -39,7 +39,6 @@
  * @author Peter von der Ah&eacute;
  * @since 1.6
  */
-@jdk.Exported
 public class SimpleTreeVisitor <R,P> implements TreeVisitor<R,P> {
     /**
      * The default value, returned by the {@link #defaultAction default action}.
--- a/src/jdk.compiler/share/classes/com/sun/source/util/SourcePositions.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/SourcePositions.java	Wed Mar 16 12:20:17 2016 +0000
@@ -35,7 +35,6 @@
  * @author Peter von der Ah&eacute;
  * @since 1.6
  */
-@jdk.Exported
 public interface SourcePositions {
 
     /**
--- a/src/jdk.compiler/share/classes/com/sun/source/util/TaskEvent.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/TaskEvent.java	Wed Mar 16 12:20:17 2016 +0000
@@ -36,14 +36,12 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public final class TaskEvent
 {
     /**
      * Kind of task event.
      * @since 1.6
      */
-    @jdk.Exported
     public enum Kind {
         /**
          * For events related to the parsing of a file.
@@ -74,7 +72,7 @@
          * This event is not sent when using {@link JavacTask#parse()},
          * {@link JavacTask#analyze()} or {@link JavacTask#generate()}.
          *
-         * @since 1.9
+         * @since 9
          */
         COMPILATION,
     }
--- a/src/jdk.compiler/share/classes/com/sun/source/util/TaskListener.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/TaskListener.java	Wed Mar 16 12:20:17 2016 +0000
@@ -32,7 +32,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public interface TaskListener
 {
     /**
--- a/src/jdk.compiler/share/classes/com/sun/source/util/TreePath.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/TreePath.java	Wed Mar 16 12:20:17 2016 +0000
@@ -37,7 +37,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public class TreePath implements Iterable<Tree> {
     /**
      * Returns a tree path for a tree node within a compilation unit,
--- a/src/jdk.compiler/share/classes/com/sun/source/util/TreePathScanner.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/TreePathScanner.java	Wed Mar 16 12:20:17 2016 +0000
@@ -38,7 +38,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public class TreePathScanner<R, P> extends TreeScanner<R, P> {
 
     /**
--- a/src/jdk.compiler/share/classes/com/sun/source/util/TreeScanner.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/TreeScanner.java	Wed Mar 16 12:20:17 2016 +0000
@@ -74,7 +74,6 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 public class TreeScanner<R,P> implements TreeVisitor<R,P> {
 
     /**
--- a/src/jdk.compiler/share/classes/com/sun/source/util/Trees.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/Trees.java	Wed Mar 16 12:20:17 2016 +0000
@@ -51,7 +51,6 @@
  *
  * @author Peter von der Ah&eacute;
  */
-@jdk.Exported
 public abstract class Trees {
     /**
      * Returns a Trees object for a given CompilationTask.
--- a/src/jdk.compiler/share/classes/com/sun/source/util/package-info.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/source/util/package-info.java	Wed Mar 16 12:20:17 2016 +0000
@@ -30,5 +30,4 @@
  * @author Jonathan Gibbons
  * @since 1.6
  */
-@jdk.Exported
 package com.sun.source.util;
--- a/src/jdk.compiler/share/classes/com/sun/tools/doclint/Checker.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/doclint/Checker.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 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
@@ -149,13 +149,13 @@
         env.setCurrent(p, tree);
 
         boolean isOverridingMethod = !env.currOverriddenMethods.isEmpty();
+        JavaFileObject fo = p.getCompilationUnit().getSourceFile();
 
         if (p.getLeaf().getKind() == Tree.Kind.PACKAGE) {
             // If p points to a package, the implied declaration is the
             // package declaration (if any) for the compilation unit.
             // Handle this case specially, because doc comments are only
             // expected in package-info files.
-            JavaFileObject fo = p.getCompilationUnit().getSourceFile();
             boolean isPkgInfo = fo.isNameCompatible("package-info", JavaFileObject.Kind.SOURCE);
             if (tree == null) {
                 if (isPkgInfo)
@@ -165,6 +165,12 @@
                 if (!isPkgInfo)
                     reportReference("dc.unexpected.comment");
             }
+        } else if (tree != null && fo.isNameCompatible("package", JavaFileObject.Kind.HTML)) {
+            // a package.html file with a DocCommentTree
+            if (tree.getFullBody().isEmpty()) {
+                reportMissing("dc.missing.comment");
+                return null;
+            }
         } else {
             if (tree == null) {
                 if (!isSynthetic() && !isOverridingMethod)
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/Main.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/Main.java	Wed Mar 16 12:20:17 2016 +0000
@@ -31,7 +31,6 @@
  * The programmatic interface for the Java Programming Language
  * compiler, javac.
  */
-@jdk.Exported
 public class Main {
 
     /** Main entry point for the launcher.
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/api/ClientCodeWrapper.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/api/ClientCodeWrapper.java	Wed Mar 16 12:20:17 2016 +0000
@@ -23,7 +23,6 @@
  * questions.
  */
 
-
 package com.sun.tools.javac.api;
 
 import java.io.File;
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/api/DiagnosticFormatter.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/api/DiagnosticFormatter.java	Wed Mar 16 12:20:17 2016 +0000
@@ -22,6 +22,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package com.sun.tools.javac.api;
 
 import java.util.Locale;
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/api/JavacTrees.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/api/JavacTrees.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 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
@@ -28,7 +28,9 @@
 import java.io.FileNotFoundException;
 import java.io.IOException;
 import java.text.BreakIterator;
+import java.util.HashMap;
 import java.util.HashSet;
+import java.util.Map;
 import java.util.Set;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
@@ -49,7 +51,6 @@
 import javax.tools.Diagnostic;
 import javax.tools.FileObject;
 import javax.tools.ForwardingFileObject;
-import javax.tools.ForwardingJavaFileObject;
 import javax.tools.JavaCompiler;
 import javax.tools.JavaFileManager;
 import javax.tools.JavaFileObject;
@@ -69,12 +70,16 @@
 import com.sun.source.util.JavacTask;
 import com.sun.source.util.TreePath;
 import com.sun.tools.javac.code.Flags;
+import com.sun.tools.javac.code.Scope.NamedImportScope;
+import com.sun.tools.javac.code.Scope.StarImportScope;
+import com.sun.tools.javac.code.Scope.WriteableScope;
 import com.sun.tools.javac.code.Symbol;
 import com.sun.tools.javac.code.Symbol.ClassSymbol;
 import com.sun.tools.javac.code.Symbol.MethodSymbol;
 import com.sun.tools.javac.code.Symbol.PackageSymbol;
 import com.sun.tools.javac.code.Symbol.TypeSymbol;
 import com.sun.tools.javac.code.Symbol.VarSymbol;
+import com.sun.tools.javac.code.Symtab;
 import com.sun.tools.javac.code.Type;
 import com.sun.tools.javac.code.Type.ArrayType;
 import com.sun.tools.javac.code.Type.ClassType;
@@ -104,6 +109,7 @@
 import com.sun.tools.javac.tree.DCTree.DCParam;
 import com.sun.tools.javac.tree.DCTree.DCReference;
 import com.sun.tools.javac.tree.DCTree.DCText;
+import com.sun.tools.javac.tree.DocCommentTable;
 import com.sun.tools.javac.tree.DocTreeMaker;
 import com.sun.tools.javac.tree.EndPosTable;
 import com.sun.tools.javac.tree.JCTree;
@@ -160,10 +166,12 @@
     private JavacTaskImpl javacTaskImpl;
     private Names names;
     private Types types;
-    private DocTreeMaker doctreeMaker;
+    private DocTreeMaker docTreeMaker;
     private BreakIterator breakIterator;
     private JavaFileManager fileManager;
     private ParserFactory parser;
+    private Symtab syms;
+    private Map<JavaFileObject, PackageSymbol> javaFileObjectToPackageMap;
 
     // called reflectively from Trees.instance(CompilationTask task)
     public static JavacTrees instance(JavaCompiler.CompilationTask task) {
@@ -187,6 +195,7 @@
     }
 
     protected JavacTrees(Context context) {
+        javaFileObjectToPackageMap = new HashMap<>();
         this.breakIterator = null;
         context.put(JavacTrees.class, this);
         init(context);
@@ -206,8 +215,9 @@
         memberEnter = MemberEnter.instance(context);
         names = Names.instance(context);
         types = Types.instance(context);
-        doctreeMaker = DocTreeMaker.instance(context);
+        docTreeMaker = DocTreeMaker.instance(context);
         parser = ParserFactory.instance(context);
+        syms = Symtab.instance(context);
         fileManager = context.get(JavaFileManager.class);
         JavacTask t = context.get(JavacTask.class);
         if (t instanceof JavacTaskImpl)
@@ -294,6 +304,11 @@
             };
     }
 
+    @Override @DefinedBy(Api.COMPILER_TREE)
+    public DocTreeMaker getDocTreeFactory() {
+        return docTreeMaker;
+    }
+
     private DocTree getLastChild(DocTree tree) {
         final DocTree[] last = new DocTree[] {null};
 
@@ -398,7 +413,7 @@
 
     @Override @DefinedBy(Api.COMPILER_TREE)
     public java.util.List<DocTree> getFirstSentence(java.util.List<? extends DocTree> list) {
-        return doctreeMaker.getFirstSentence(list);
+        return docTreeMaker.getFirstSentence(list);
     }
 
     private Symbol attributeDocReference(TreePath path, DCReference ref) {
@@ -411,9 +426,9 @@
             final Name memberName;
             if (ref.qualifierExpression == null) {
                 tsym = env.enclClass.sym;
-                memberName = ref.memberName;
+                memberName = (Name) ref.memberName;
             } else {
-                // See if the qualifierExpression is a type or package name.
+                // newSeeTree if the qualifierExpression is a type or package name.
                 // javac does not provide the exact method required, so
                 // we first check if qualifierExpression identifies a type,
                 // and if not, then we check to see if it identifies a package.
@@ -437,7 +452,7 @@
                     }
                 } else {
                     tsym = t.tsym;
-                    memberName = ref.memberName;
+                    memberName = (Name) ref.memberName;
                 }
             }
 
@@ -449,7 +464,7 @@
                 paramTypes = null;
             else {
                 ListBuffer<Type> lb = new ListBuffer<>();
-                for (List<JCTree> l = ref.paramTypes; l.nonEmpty(); l = l.tail) {
+                for (List<JCTree> l = (List<JCTree>) ref.paramTypes; l.nonEmpty(); l = l.tail) {
                     JCTree tree = l.head;
                     Type t = attr.attribType(tree, env);
                     lb.add(t);
@@ -913,7 +928,7 @@
         }
     }
 
-    private JavaFileObject asJavaFileObject(FileObject fileObject) {
+    static JavaFileObject asJavaFileObject(FileObject fileObject) {
         JavaFileObject jfo = null;
 
         if (fileObject instanceof JavaFileObject) {
@@ -927,11 +942,11 @@
         return jfo;
     }
 
-    private void checkHtmlKind(FileObject fileObject) {
+    private static void checkHtmlKind(FileObject fileObject) {
         checkHtmlKind(fileObject, BaseFileManager.getKind(fileObject.getName()));
     }
 
-    private void checkHtmlKind(FileObject fileObject, JavaFileObject.Kind kind) {
+    private static void checkHtmlKind(FileObject fileObject, JavaFileObject.Kind kind) {
         if (kind != JavaFileObject.Kind.HTML) {
             throw new IllegalArgumentException("HTML file expected:" + fileObject.getName());
         }
@@ -1012,6 +1027,13 @@
     }
 
     @Override @DefinedBy(Api.COMPILER_TREE)
+    public DocTreePath getDocTreePath(FileObject fileObject) {
+        JavaFileObject jfo = asJavaFileObject(fileObject);
+        DocCommentTree docCommentTree = getDocCommentTree(jfo);
+        return new DocTreePath(makeTreePath(jfo, docCommentTree), docCommentTree);
+    }
+
+    @Override @DefinedBy(Api.COMPILER_TREE)
     public void setBreakIterator(BreakIterator breakiterator) {
         this.breakIterator = breakiterator;
     }
@@ -1126,11 +1148,20 @@
         }
     }
 
-    public TreePath makeTreePath(final FileObject fileObject, final int offset) {
-        JavaFileObject jfo = asJavaFileObject(fileObject);
+    /**
+     * Register a file object, such as for a package.html, that provides
+     * doc comments for a package.
+     * @param psym the PackageSymbol representing the package.
+     * @param jfo  the JavaFileObject for the given package.
+     */
+    public void putJavaFileObject(PackageSymbol psym, JavaFileObject jfo) {
+        javaFileObjectToPackageMap.putIfAbsent(jfo, psym);
+    }
+
+    private TreePath makeTreePath(final JavaFileObject jfo, DocCommentTree dcTree) {
         JCCompilationUnit jcCompilationUnit = new JCCompilationUnit(List.nil()) {
             public int getPos() {
-                return offset;
+                return Position.FIRSTPOS;
             }
 
             public JavaFileObject getSourcefile() {
@@ -1140,15 +1171,51 @@
             @Override @DefinedBy(Api.COMPILER_TREE)
             public Position.LineMap getLineMap() {
                 try {
-                    CharSequence content = fileObject.getCharContent(true);
+                    CharSequence content = jfo.getCharContent(true);
                     String s = content.toString();
                     return Position.makeLineMap(s.toCharArray(), s.length(), true);
                 } catch (IOException ignore) {}
                 return null;
             }
         };
+
+        PackageSymbol psym = javaFileObjectToPackageMap.getOrDefault(jfo, syms.unnamedPackage);
+
+        jcCompilationUnit.docComments = new DocCommentTable() {
+            @Override
+            public boolean hasComment(JCTree tree) {
+                return false;
+            }
+
+            @Override
+            public Comment getComment(JCTree tree) {
+                throw new UnsupportedOperationException();
+            }
+
+            @Override
+            public String getCommentText(JCTree tree) {
+                throw new UnsupportedOperationException();
+            }
+
+            @Override
+            public DCDocComment getCommentTree(JCTree tree) {
+                return (DCDocComment)dcTree;
+            }
+
+            @Override
+            public void putComment(JCTree tree, Comment c) {
+                throw new UnsupportedOperationException();
+            }
+
+        };
+        jcCompilationUnit.lineMap = jcCompilationUnit.getLineMap();
+        jcCompilationUnit.namedImportScope = new NamedImportScope(psym, jcCompilationUnit.toplevelScope);
+        jcCompilationUnit.packge = psym;
+        jcCompilationUnit.starImportScope = null;
         jcCompilationUnit.sourcefile = jfo;
-        enter.main(List.of(jcCompilationUnit));
+        jcCompilationUnit.starImportScope = new StarImportScope(psym);
+        jcCompilationUnit.toplevelScope = WriteableScope.create(psym);
+
         return new TreePath(jcCompilationUnit);
     }
 }
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/AnnoConstruct.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/AnnoConstruct.java	Wed Mar 16 12:20:17 2016 +0000
@@ -22,6 +22,7 @@
  * or visit www.oracle.com if you need additional information or have any
  * questions.
  */
+
 package com.sun.tools.javac.code;
 
 import java.lang.annotation.Annotation;
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/ClassFinder.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/ClassFinder.java	Wed Mar 16 12:20:17 2016 +0000
@@ -343,7 +343,7 @@
                 }
                 currentClassFile = classfile;
                 if (verbose) {
-                    log.printVerbose("loading", currentClassFile.toString());
+                    log.printVerbose("loading", currentClassFile.getName());
                 }
                 if (classfile.getKind() == JavaFileObject.Kind.CLASS ||
                     classfile.getKind() == JavaFileObject.Kind.OTHER) {
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Lint.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Lint.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 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
@@ -223,11 +223,6 @@
         STATIC("static"),
 
         /**
-         * Warn about proprietary API that may be removed in a future release.
-         */
-        SUNAPI("sunapi", true),
-
-        /**
          * Warn about issues relating to use of try blocks (i.e. try-with-resources)
          */
         TRY("try"),
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Printer.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Printer.java	Wed Mar 16 12:20:17 2016 +0000
@@ -175,8 +175,8 @@
 
     @Override
     public String visitUndetVar(UndetVar t, Locale locale) {
-        if (t.inst != null) {
-            return printAnnotations(t) + visit(t.inst, locale);
+        if (t.getInst() != null) {
+            return printAnnotations(t) + visit(t.getInst(), locale);
         } else {
             return printAnnotations(t) + visit(t.qtype, locale) + "?";
         }
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Symbol.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Symbol.java	Wed Mar 16 12:20:17 2016 +0000
@@ -431,6 +431,9 @@
     }
 
     /** The closest enclosing class of this symbol's declaration.
+     *  Warning: this (misnamed) method returns the receiver itself
+     *  when the receiver is a class (as opposed to its enclosing
+     *  class as one may be misled to believe.)
      */
     public ClassSymbol enclClass() {
         Symbol c = this;
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Symtab.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Symtab.java	Wed Mar 16 12:20:17 2016 +0000
@@ -26,9 +26,7 @@
 package com.sun.tools.javac.code;
 
 import java.util.HashMap;
-import java.util.HashSet;
 import java.util.Map;
-import java.util.Set;
 
 import javax.lang.model.element.ElementVisitor;
 import javax.tools.JavaFileObject;
@@ -39,7 +37,6 @@
 import com.sun.tools.javac.code.Symbol.Completer;
 import com.sun.tools.javac.code.Symbol.CompletionFailure;
 import com.sun.tools.javac.code.Symbol.MethodSymbol;
-import com.sun.tools.javac.code.Symbol.OperatorSymbol;
 import com.sun.tools.javac.code.Symbol.PackageSymbol;
 import com.sun.tools.javac.code.Symbol.TypeSymbol;
 import com.sun.tools.javac.code.Symbol.VarSymbol;
@@ -53,7 +50,6 @@
 import com.sun.tools.javac.code.Type.JCVoidType;
 import com.sun.tools.javac.code.Type.MethodType;
 import com.sun.tools.javac.code.Type.UnknownType;
-import com.sun.tools.javac.jvm.ByteCodes;
 import com.sun.tools.javac.jvm.Target;
 import com.sun.tools.javac.util.Assert;
 import com.sun.tools.javac.util.Context;
@@ -68,7 +64,6 @@
 
 import static com.sun.tools.javac.code.Flags.*;
 import static com.sun.tools.javac.code.Kinds.Kind.*;
-import static com.sun.tools.javac.jvm.ByteCodes.*;
 import static com.sun.tools.javac.code.TypeTag.*;
 
 /** A class that defines all predefined constants and operators
@@ -203,6 +198,7 @@
     public final Type autoCloseableType;
     public final Type trustMeType;
     public final Type lambdaMetafactory;
+    public final Type stringConcatFactory;
     public final Type repeatableType;
     public final Type documentedType;
     public final Type elementTypeType;
@@ -540,6 +536,7 @@
         trustMeType = enterClass("java.lang.SafeVarargs");
         nativeHeaderType = enterClass("java.lang.annotation.Native");
         lambdaMetafactory = enterClass("java.lang.invoke.LambdaMetafactory");
+        stringConcatFactory = enterClass("java.lang.invoke.StringConcatFactory");
         functionalInterfaceType = enterClass("java.lang.FunctionalInterface");
         genericMethodSpecialzer = enterClass("java.lang.invoke.GenericMethodSpecializer");
         genericInstanceDispatch = enterClass("java.lang.invoke.GenericInstanceDispatch");
@@ -562,6 +559,7 @@
         synthesizeEmptyBSMIfMissing(virtualAccess);
         synthesizeEmptyBSMIfMissing(objectibleDispatch);
         synthesizeEmptyInterfaceIfMissing(serializedLambdaType);
+        synthesizeEmptyInterfaceIfMissing(stringConcatFactory);
         synthesizeBoxTypeIfMissing(doubleType);
         synthesizeBoxTypeIfMissing(floatType);
         synthesizeBoxTypeIfMissing(voidType);
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Type.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Type.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2015, 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
@@ -26,6 +26,7 @@
 package com.sun.tools.javac.code;
 
 import java.lang.annotation.Annotation;
+import java.util.ArrayDeque;
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.EnumMap;
@@ -39,8 +40,11 @@
 import com.sun.tools.javac.code.Symbol.*;
 import com.sun.tools.javac.code.Types.TypeVarKind;
 import com.sun.tools.javac.code.TypeMetadata.Entry;
+import com.sun.tools.javac.comp.Infer.IncorporationAction;
 import com.sun.tools.javac.util.*;
 import com.sun.tools.javac.util.DefinedBy.Api;
+import com.sun.tools.javac.util.Tuple.Tuple2;
+
 import static com.sun.tools.javac.code.BoundKind.*;
 import static com.sun.tools.javac.code.Flags.*;
 import static com.sun.tools.javac.code.Kinds.Kind.*;
@@ -369,6 +373,10 @@
                 accept(stripMetadata, null) :
                 this;
     }
+
+    public Type stripMetadata() {
+        return accept(stripMetadata, null);
+    }
     //where
         private final static TypeMapping<Void> stripMetadata = new TypeMapping<Void>() {
             @Override
@@ -1612,6 +1620,7 @@
         public TypeVar(Name name, Symbol owner, Type lower) {
             super(null, TypeMetadata.EMPTY);
             tsym = new TypeVariableSymbol(0, name, this, owner);
+            this.bound = null;
             this.lower = lower;
         }
 
@@ -1906,7 +1915,9 @@
          */
         public interface UndetVarListener {
             /** called when some inference variable bounds (of given kinds ibs) change */
-            void varChanged(UndetVar uv, Set<InferenceBound> ibs);
+            void varBoundChanged(UndetVar uv, InferenceBound ib, Type bound, boolean update);
+            /** called when the inferred type is set on some inference variable */
+            default void varInstantiated(UndetVar uv) { Assert.error(); }
         }
 
         /**
@@ -1923,10 +1934,6 @@
          * Inference variable bound kinds
          */
         public enum InferenceBound {
-            /** upper bounds */
-            UPPER {
-                public InferenceBound complement() { return LOWER; }
-            },
             /** lower bounds */
             LOWER {
                 public InferenceBound complement() { return UPPER; }
@@ -1934,16 +1941,38 @@
             /** equality constraints */
             EQ {
                 public InferenceBound complement() { return EQ; }
+            },
+            /** upper bounds */
+            UPPER {
+                public InferenceBound complement() { return LOWER; }
             };
 
             public abstract InferenceBound complement();
+
+            public boolean lessThan(InferenceBound that) {
+                if (that == this) {
+                    return false;
+                } else {
+                    switch (that) {
+                        case UPPER: return true;
+                        case LOWER: return false;
+                        case EQ: return (this != UPPER);
+                        default:
+                            Assert.error("Cannot get here!");
+                            return false;
+                    }
+                }
+            }
         }
 
+        /** list of incorporation actions (used by the incorporation engine). */
+        public ArrayDeque<IncorporationAction> incorporationActions = new ArrayDeque<>();
+
         /** inference variable bounds */
         protected Map<InferenceBound, List<Type>> bounds;
 
         /** inference variable's inferred type (set from Infer.java) */
-        public Type inst = null;
+        private Type inst = null;
 
         /** number of declared (upper) bounds */
         public int declaredCount;
@@ -1959,20 +1988,25 @@
             return v.visitUndetVar(this, s);
         }
 
-        public UndetVar(TypeVar origin, Types types) {
-            this(origin, types, EnumSet.noneOf(Flag.class));
+        public UndetVar(TypeVar origin, UndetVarListener listener, Types types) {
+            this(origin, listener, types, EnumSet.noneOf(Flag.class));
         }
 
-        protected UndetVar(TypeVar origin, Types types, EnumSet<Flag> flags) {
+        protected UndetVar(TypeVar origin, UndetVarListener listener, Types types, EnumSet<Flag> flags) {
             // This is a synthesized internal type, so we cannot annotate it.
             super(UNDETVAR, origin);
+            this.listener = listener;
+            this.flags = flags;
             bounds = new EnumMap<>(InferenceBound.class);
             List<Type> declaredBounds = types.getBounds(origin);
             declaredCount = declaredBounds.length();
-            bounds.put(InferenceBound.UPPER, declaredBounds);
-            bounds.put(InferenceBound.LOWER, List.<Type>nil());
-            bounds.put(InferenceBound.EQ, List.<Type>nil());
-            this.flags = flags;
+            bounds.put(InferenceBound.UPPER, List.nil());
+            bounds.put(InferenceBound.LOWER, List.nil());
+            bounds.put(InferenceBound.EQ, List.nil());
+            for (Type t : declaredBounds.reverse()) {
+                //add bound works in reverse order
+                addBound(InferenceBound.UPPER, t, types, true);
+            }
         }
 
         @DefinedBy(Api.LANGUAGE_MODEL)
@@ -2002,6 +2036,32 @@
             return result;
         }
 
+        /**
+         * Returns a new copy of this undet var.
+         */
+        public UndetVar dup(Types types) {
+            UndetVar uv2 = new UndetVar((TypeVar)qtype, listener, types);
+            dupTo(uv2, types);
+            return uv2;
+        }
+
+        /**
+         * Dumps the contents of this undet var on another undet var.
+         */
+        public void dupTo(UndetVar uv2, Types types) {
+            uv2.listener = null;
+            uv2.bounds.clear();
+            for (InferenceBound ib : InferenceBound.values()) {
+                uv2.bounds.put(ib, List.nil());
+                for (Type t : getBounds(ib)) {
+                    uv2.addBound(ib, t, types, true);
+                }
+            }
+            uv2.inst = inst;
+            uv2.listener = listener;
+            uv2.incorporationActions = new ArrayDeque<>(incorporationActions);
+        }
+
         @Override
         public UndetVar cloneWithMetadata(TypeMetadata md) {
             throw new AssertionError("Cannot add metadata to an UndetVar type");
@@ -2027,6 +2087,17 @@
             this.flags.addAll(Arrays.asList(flags));
         }
 
+        public Type getInst() {
+            return inst;
+        }
+
+        public void setInst(Type inst) {
+            this.inst = inst;
+            if (listener != null) {
+                listener.varInstantiated(this);
+            }
+        }
+
         /** get all bounds of a given kind */
         public List<Type> getBounds(InferenceBound... ibs) {
             ListBuffer<Type> buf = new ListBuffer<>();
@@ -2061,13 +2132,14 @@
             Type bound2 = bound.map(toTypeVarMap, false).baseType();
             if (!bound2.hasTag(NONE)) {
                 List<Type> prevBounds = bounds.get(ib);
+                if (bound == qtype) return;
                 for (Type b : prevBounds) {
                     //check for redundancy - use strict version of isSameType on tvars
                     //(as the standard version will lead to false positives w.r.t. clones ivars)
-                    if (types.isSameType(b, bound2, true) || bound == qtype) return;
+                    if (types.isSameType(b, bound2, true)) return;
                 }
                 bounds.put(ib, prevBounds.prepend(bound2));
-                notifyChange(EnumSet.of(ib));
+                notifyBoundChange(ib, bound2, false);
             }
         }
         //where
@@ -2101,16 +2173,14 @@
 
         /** replace types in all bounds - this might trigger listener notification */
         public void substBounds(List<Type> from, List<Type> to, Types types) {
-            List<Type> instVars = from.diff(to);
-            //if set of instantiated ivars is empty, there's nothing to do!
-            if (instVars.isEmpty()) return;
-            final EnumSet<InferenceBound> boundsChanged = EnumSet.noneOf(InferenceBound.class);
+            final ListBuffer<Tuple2<InferenceBound, Type>>  boundsChanged = new ListBuffer<>();
             UndetVarListener prevListener = listener;
             try {
                 //setup new listener for keeping track of changed bounds
                 listener = new UndetVarListener() {
-                    public void varChanged(UndetVar uv, Set<InferenceBound> ibs) {
-                        boundsChanged.addAll(ibs);
+                    public void varBoundChanged(UndetVar uv, InferenceBound ib, Type t, boolean _ignored) {
+                        Assert.check(uv == UndetVar.this);
+                        boundsChanged.add(new Tuple2<>(ib, t));
                     }
                 };
                 for (Map.Entry<InferenceBound, List<Type>> _entry : bounds.entrySet()) {
@@ -2120,7 +2190,7 @@
                     ListBuffer<Type> deps = new ListBuffer<>();
                     //step 1 - re-add bounds that are not dependent on ivars
                     for (Type t : prevBounds) {
-                        if (!t.containsAny(instVars)) {
+                        if (!t.containsAny(from)) {
                             newBounds.append(t);
                         } else {
                             deps.append(t);
@@ -2135,12 +2205,22 @@
                 }
             } finally {
                 listener = prevListener;
-                if (!boundsChanged.isEmpty()) {
-                    notifyChange(boundsChanged);
+                for (Tuple2<InferenceBound, Type> boundUpdate : boundsChanged) {
+                    notifyBoundChange(boundUpdate.elem0, boundUpdate.elem1, true);
                 }
             }
         }
 
+        private void notifyBoundChange(InferenceBound ib, Type bound, boolean update) {
+            if (listener != null) {
+                listener.varBoundChanged(this, ib, bound, update);
+            }
+        }
+
+        public boolean isCaptured() {
+            return hasFlag(Flag.CAPTURED);
+        }
+
         /**
          * Box all primitive bounds of this inference variable. This routine is used during
          * inference of 'any' type-variables. The synthetic 'any' (upper) bound is also removed.
@@ -2153,16 +2233,6 @@
                 }
             }
         }
-
-        private void notifyChange(EnumSet<InferenceBound> ibs) {
-            if (listener != null) {
-                listener.varChanged(this, ibs);
-            }
-        }
-
-        public boolean isCaptured() {
-            return hasFlag(Flag.CAPTURED);
-        }
     }
 
     /**
@@ -2173,10 +2243,10 @@
      */
     public static class CapturedUndetVar extends UndetVar {
 
-        public CapturedUndetVar(CapturedType origin, Types types) {
-            super(origin, types, EnumSet.of(Flag.CAPTURED));
+        public CapturedUndetVar(CapturedType origin, UndetVarListener listener, Types types) {
+            super(origin, listener, types, EnumSet.of(Flag.CAPTURED));
             if (!origin.lower.hasTag(BOT)) {
-                bounds.put(InferenceBound.LOWER, List.of(origin.lower));
+                addBound(InferenceBound.LOWER, origin.lower, types, true);
             }
         }
 
@@ -2188,7 +2258,13 @@
             }
             else if (bound.hasTag(UNDETVAR) && !((UndetVar) bound).isCaptured()) {
                 ((UndetVar) bound).addBound(ib.complement(), this, types, false);
-            }        
+            }
+        }
+
+        public UndetVar dup(Types types) {
+            UndetVar uv2 = new CapturedUndetVar((CapturedType)qtype, listener, types);
+            dupTo(uv2, types);
+            return uv2;
         }
     }
 
@@ -2307,6 +2383,7 @@
         public boolean isNullOrReference() {
             return true;
         }
+
     }
 
     /** Represents the (synthetic) upper bound of an 'any' type-variable */
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/TypeAnnotations.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/TypeAnnotations.java	Wed Mar 16 12:20:17 2016 +0000
@@ -115,31 +115,23 @@
      * called from MemberEnter.
      */
     public void organizeTypeAnnotationsSignatures(final Env<AttrContext> env, final JCClassDecl tree) {
-        annotate.afterTypes(new Runnable() {
-            @Override
-            public void run() {
-                JavaFileObject oldSource = log.useSource(env.toplevel.sourcefile);
-
-                try {
-                    new TypeAnnotationPositions(true).scan(tree);
-                } finally {
-                    log.useSource(oldSource);
-                }
+        annotate.afterTypes(() -> {
+            JavaFileObject oldSource = log.useSource(env.toplevel.sourcefile);
+            try {
+                new TypeAnnotationPositions(true).scan(tree);
+            } finally {
+                log.useSource(oldSource);
             }
         });
     }
 
     public void validateTypeAnnotationsSignatures(final Env<AttrContext> env, final JCClassDecl tree) {
-        annotate.validate(new Runnable() { //validate annotations
-            @Override
-            public void run() {
-                JavaFileObject oldSource = log.useSource(env.toplevel.sourcefile);
-
-                try {
-                    attr.validateTypeAnnotations(tree, true);
-                } finally {
-                    log.useSource(oldSource);
-                }
+        annotate.validate(() -> { //validate annotations
+            JavaFileObject oldSource = log.useSource(env.toplevel.sourcefile);
+            try {
+                attr.validateTypeAnnotations(tree, true);
+            } finally {
+                log.useSource(oldSource);
             }
         });
     }
@@ -1025,7 +1017,7 @@
                 case METHOD_INVOCATION: {
                     JCMethodInvocation invocation = (JCMethodInvocation)frame;
                     if (!invocation.typeargs.contains(tree)) {
-                        throw new AssertionError("{" + tree + "} is not an argument in the invocation: " + invocation);
+                        return TypeAnnotationPosition.unknown;
                     }
                     MethodSymbol exsym = (MethodSymbol) TreeInfo.symbol(invocation.getMethodSelect());
                     final int type_index = invocation.typeargs.indexOf(tree);
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/TypeMetadata.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/TypeMetadata.java	Wed Mar 16 12:20:17 2016 +0000
@@ -1,7 +1,6 @@
 /*
- * Copyright (c) 2014, Oracle and/or its affiliates. All rights
- * reserved.  DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE
- * HEADER.
+ * Copyright (c) 2014, 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
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Types.java	Wed Mar 02 19:06:15 2016 +0000
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Types.java	Wed Mar 16 12:20:17 2016 +0000
@@ -590,7 +590,6 @@
             //we need to perform subtyping if (i) both are primitive types, (ii) both are reference types
             return isSubtypeUnchecked(t, s, warn);
         }
-        //default - box
         return tPrimitive
             ? isSubtype(boxedClass(t).type, s)
             : isSubtype(unboxedType(t), s);
@@ -882,36 +881,42 @@
     }
 
     public Type removeWildcards(Type site) {
-        Type capturedSite = capture(site);
-        if (capturedSite != site) {
-            Type formalInterface = site.tsym.type;
-            ListBuffer<Type> typeargs = new ListBuffer<>();
-            List<Type> actualTypeargs = site.getTypeArguments();
-            List<Type> capturedTypeargs = capturedSite.getTypeArguments();
-            //simply replace the wildcards with its bound
-            for (Type t : formalInterface.getTypeArguments()) {
-                if (actualTypeargs.head.hasTag(WILDCARD)) {
-                    WildcardType wt = (WildcardType)actualTypeargs.head;
-                    Type bound;
-                    switch (wt.kind) {
-                        case EXTENDS:
-                        case UNBOUND:
-                            CapturedType capVar = (CapturedType)capturedTypeargs.head;
-                            //use declared bound if it doesn't depend on formal type-args
-                            bound = capVar.getBound().containsAny(capturedSite.getTypeArguments()) ?
-                                    wt.type : capVar.getBound();
-                            break;
-                        default:
-                            bound = wt.type;
+        if (site.getTypeArguments().stream().anyMatch(t -> t.hasTag(WILDCARD))) {
+            //compute non-wildcard parameterization - JLS 9.9
+            List<Type> actuals = site.getTypeArguments();
+            List<Type> formals = site.tsym.type.getTypeArguments();
+            ListBuffer<Type> targs = new ListBuffer<>();
+            for (Type formal : formals) {
+                Type actual = actuals.head;
+                Type bound = formal.getUpperBound();
+                if (actuals.head.hasTag(WILDCARD)) {
+                    WildcardType wt = (WildcardType)actual;
+                    //check that bound does not contain other formals
+                    if (bound.containsAny(formals)) {
+                        targs.add(wt.type);
+                    } else {
+                        //compute new type-argument based on declared bound and wildcard bound
+                        switch (wt.kind) {
+                            case UNBOUND:
+                                targs.add(bound);
+                                break;
+                            case EXTENDS:
+                                targs.add(glb(bound, wt.type));
+                                break;
+                            case SUPER:
+                                targs.add(wt.type);
+                                break;
+                            default:
+                                Assert.error("Cannot get here!");
+                        }
                     }
-                    typeargs.append(bound);
                 } else {
-                    typeargs.append(actualTypeargs.head);
+                    //not a wildcard - the new type argument remains unchanged
+                    targs.add(actual);
                 }
-                actualTypeargs = actualTypeargs.tail;
-                capturedTypeargs = capturedTypeargs.tail;
-            }
-            return subst(formalInterface, formalInterface.getTypeArguments(), typeargs.toList());
+                actuals = actuals.tail;
+            }
+            return subst(site.tsym.type, formals, targs.toList());
         } else {
             return site;
         }
@@ -1366,7 +1371,7 @@
     }
 
     /**
-    * A polymorphic signature method (JLS SE 7, 8.4.1) is a method that
+    * A polymorphic signature method (JLS 15.12.3) is a method that
     * (i) is declared in the java.lang.invoke.MethodHandle class, (ii) takes
     * a single variable arity parameter (iii) whose declared type is Object[],
     * (iv) has a return type of Object and (v) is native.
@@ -1457,14 +1462,21 @@
                     if (!visit(supertype(t), supertype(s)))
                         return false;
 
-                    HashSet<UniqueType> set = new HashSet<>();
-                    for (Type x : interfaces(t))
-                        set.add(new UniqueType(x, Types.this));
-                    for (Type x : interfaces(s)) {
-                        if (!set.remove(new UniqueType(x, Types.this)))
+                    Map<Symbol,Type> tMap = new HashMap<>();
+                    for (Type ti : interfaces(t)) {
+                        if (tMap.containsKey(ti)) {
+                            throw new AssertionError("Malformed intersection");
+                        }
+                        tMap.put(ti.tsym, ti);
+                    }
+                    for (Type si : interfaces(s)) {
+                        if (!tMap.containsKey(si.tsym))
+                            return false;
+                        Type ti = tMap.remove(si.tsym);
+                        if (!visit(ti, si))
                             return false;
                     }
-                    return (set.isEmpty());
+                    return tMap.isEmpty();
                 }
                 return t.tsym == s.tsym
                     && visit(t.getEnclosingType(), s.getEnclosingType())
@@ -1762,18 +1774,19 @@
     public boolean isCastable(Type t, Type s, Warner warn) {
         if (t == s)
             return true;
-
         if (t.isPrimitive() != s.isPrimitive()) {
             if (isSpecializableTypeVar(t) || isSpecializableTypeVar(s)) {
                 //primitive is castable to 'any' tvar w/o warnings
                 return true;
             } else {
+                t = skipTypeVars(t, false);
                 return (isConvertible(t, s, warn)
-                                || (allowObjectToPrimitiveCast &&
-                                s.isPrimitive() &&
-                                isSubtype(boxedClass(s).type, t)));
-            }
-        } else if (warn != warnStack.head) {
+                        || (allowObjectToPrimitiveCast &&