changeset 405:5a36337cc053

Merge
author andrew
date Mon, 21 Sep 2009 17:11:48 +0100
parents 70cd643d6217 (current diff) 261c54b2312e (diff)
children 26651c0cabb7
files test/tools/javac/innerClassFile/Driver.java test/tools/javac/meth/InvokeMH_BAD68.java test/tools/javac/meth/InvokeMH_BAD72.java test/tools/javac/quid/QuotedIdent_BAD61.java test/tools/javac/quid/QuotedIdent_BAD62.java test/tools/javac/quid/QuotedIdent_BAD63.java
diffstat 310 files changed, 2877 insertions(+), 3418 deletions(-) [+]
line wrap: on
line diff
--- a/.hgtags	Fri Sep 04 03:08:16 2009 +0100
+++ b/.hgtags	Mon Sep 21 17:11:48 2009 +0100
@@ -45,3 +45,4 @@
 95c1212b07e33b1b8c689b1d279d82ffd5a56e43 jdk7-b68
 ce9bcdcb7859bb7ef10afd078ad59ba7847f208d jdk7-b69
 97d06f3e87873e310aa2f3fbca58fc8872d86b9f jdk7-b70
+33c8c38e1757006c17d80499fb3347102501fae5 jdk7-b71
--- a/src/share/classes/com/sun/tools/doclets/internal/toolkit/resources/doclet.xml	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/doclets/internal/toolkit/resources/doclet.xml	Mon Sep 21 17:11:48 2009 +0100
@@ -1,7 +1,7 @@
 <?xml version='1.0' encoding='utf-8'?>
 
 <!--
- Copyright 2003-2009 Sun Microsystems, Inc.  All Rights Reserved.
+ Copyright 2003-2009 Sun Microsystems, Inc.  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
@@ -44,7 +44,7 @@
         <PackageTags/>
         <PackageFooter/>
     </PackageDoc>
-    
+
     <AnnotationTypeDoc>
         <AnnotationTypeHeader/>
         <DeprecationInfo/>
@@ -52,7 +52,7 @@
         <AnnotationTypeDescription/>
         <AnnotationTypeTagInfo/>
         <MemberSummary>
-        	<AnnotationTypeRequiredMemberSummary/>
+                <AnnotationTypeRequiredMemberSummary/>
             <AnnotationTypeOptionalMemberSummary/>
         </MemberSummary>
         <AnnotationTypeRequiredMemberDetails>
@@ -77,16 +77,16 @@
                 <MemberFooter/>
             </AnnotationTypeOptionalMember>
             <Footer/>
-        </AnnotationTypeOptionalMemberDetails>        
+        </AnnotationTypeOptionalMemberDetails>
         <AnnotationTypeFooter/>
     </AnnotationTypeDoc>
-    
+
     <ClassDoc>
         <ClassHeader/>
         <ClassTree/>
         <TypeParamInfo/>
         <SuperInterfacesInfo/>
-        <ImplementedInterfacesInfo/>        
+        <ImplementedInterfacesInfo/>
         <SubClassInfo/>
         <SubInterfacesInfo/>
         <InterfaceUsageInfo/>
@@ -100,7 +100,7 @@
             <NestedClassesInheritedSummary/>
             <EnumConstantsSummary/>
             <FieldsSummary/>
-            <FieldsInheritedSummary/>  
+            <FieldsInheritedSummary/>
             <ConstructorsSummary/>
             <MethodsSummary/>
             <MethodsInheritedSummary/>
@@ -155,7 +155,7 @@
         </MethodDetails>
         <ClassFooter/>
     </ClassDoc>
-    
+
     <ConstantSummary>
         <Header/>
         <Contents/>
@@ -166,12 +166,12 @@
                     <ClassHeader/>
                     <ConstantMembers/>
                     <ClassFooter/>
-                </ClassConstantSummary>     
+                </ClassConstantSummary>
             </PackageConstantSummary>
-        </ConstantSummaries>    
+        </ConstantSummaries>
         <Footer/>
     </ConstantSummary>
-    
+
     <SerializedForm>
         <Header/>
         <SerializedFormSummaries>
--- a/src/share/classes/com/sun/tools/javac/code/Source.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/code/Source.java	Mon Sep 21 17:11:48 2009 +0100
@@ -122,6 +122,9 @@
     public boolean allowGenerics() {
         return compareTo(JDK1_5) >= 0;
     }
+    public boolean allowDiamond() {
+        return compareTo(JDK1_7) >= 0;
+    }
     public boolean allowEnums() {
         return compareTo(JDK1_5) >= 0;
     }
--- a/src/share/classes/com/sun/tools/javac/code/Type.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/code/Type.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1068,7 +1068,7 @@
 
         /**
          * Replaces this ForAll's typevars with a set of concrete Java types
-         * and returns the instantiated generic type. Subclasses might override
+         * and returns the instantiated generic type. Subclasses should override
          * in order to check that the list of types is a valid instantiation
          * of the ForAll's typevars.
          *
@@ -1081,6 +1081,42 @@
             return types.subst(qtype, tvars, actuals);
         }
 
+        /**
+         * Kind of type-constraint derived during type inference
+         */
+        public enum ConstraintKind {
+            /**
+             * upper bound constraint (a type variable must be instantiated
+             * with a type T, where T is a subtype of all the types specified by
+             * its EXTENDS constraints).
+             */
+            EXTENDS,
+            /**
+             * lower bound constraint (a type variable must be instantiated
+             * with a type T, where T is a supertype of all the types specified by
+             * its SUPER constraints).
+             */
+            SUPER,
+            /**
+             * equality constraint (a type variable must be instantiated to the type
+             * specified by its EQUAL constraint.
+             */
+            EQUAL;
+        }
+
+        /**
+         * Get the type-constraints of a given kind for a given type-variable of
+         * this ForAll type. Subclasses should override in order to return more
+         * accurate sets of constraints.
+         *
+         * @param tv the type-variable for which the constraint is to be retrieved
+         * @param ck the constraint kind to be retrieved
+         * @return the list of types specified by the selected constraint
+         */
+        public List<Type> getConstraints(TypeVar tv, ConstraintKind ck) {
+            return List.nil();
+        }
+
         public Type map(Mapping f) {
             return f.apply(qtype);
         }
--- a/src/share/classes/com/sun/tools/javac/comp/Attr.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/comp/Attr.java	Mon Sep 21 17:11:48 2009 +0100
@@ -195,6 +195,21 @@
         return owntype;
     }
 
+    Type checkReturn(JCTree tree, Type owntype, int ownkind, int pkind, Type pt) {
+        if (owntype.tag != ERROR && pt.tag != METHOD && pt.tag != FORALL) {
+            if ((ownkind & ~pkind) == 0) {
+                owntype = chk.checkReturnType(tree.pos(), owntype, pt);
+            } else {
+                log.error(tree.pos(), "unexpected.type",
+                          kindNames(pkind),
+                          kindName(ownkind));
+                owntype = types.createErrorType(owntype);
+            }
+        }
+        tree.type = owntype;
+        return owntype;
+    }
+
     /** Is given blank final variable assignable, i.e. in a scope where it
      *  may be assigned to even though it is final?
      *  @param v      The blank final variable.
@@ -413,7 +428,14 @@
     /** Derived visitor method: attribute a type tree.
      */
     Type attribType(JCTree tree, Env<AttrContext> env) {
-        Type result = attribTree(tree, env, TYP, Type.noType);
+        Type result = attribType(tree, env, Type.noType);
+        return result;
+    }
+
+    /** Derived visitor method: attribute a type tree.
+     */
+    Type attribType(JCTree tree, Env<AttrContext> env, Type pt) {
+        Type result = attribTree(tree, env, TYP, pt);
         return result;
     }
 
@@ -1357,7 +1379,7 @@
 
             // Check that value of resulting type is admissible in the
             // current context.  Also, capture the return type
-            result = check(tree, capture(restype), VAL, pkind, pt);
+            result = checkReturn(tree, capture(restype), VAL, pkind, pt);
         }
         chk.validate(tree.typeargs, localEnv);
     }
@@ -1432,9 +1454,9 @@
 
         // Attribute clazz expression and store
         // symbol + type back into the attributed tree.
-        Type clazztype = chk.checkClassType(
-            tree.clazz.pos(), attribType(clazz, env), true);
+        Type clazztype = attribType(clazz, env);
         chk.validate(clazz, localEnv);
+        clazztype = chk.checkNewClassType(clazz.pos(), clazztype, true, pt);
         if (tree.encl != null) {
             // We have to work in this case to store
             // symbol + type back into the attributed tree.
@@ -1539,7 +1561,9 @@
                 //       ...
                 //     }
                 if (Resolve.isStatic(env)) cdef.mods.flags |= STATIC;
-
+                clazz = TreeInfo.isDiamond(tree) ?
+                    make.Type(clazztype)
+                    : clazz;
                 if (clazztype.tsym.isInterface()) {
                     cdef.implementing = List.of(clazz);
                 } else {
@@ -2522,7 +2546,7 @@
         if (clazztype.tag == CLASS) {
             List<Type> formals = clazztype.tsym.type.getTypeArguments();
 
-            if (actuals.length() == formals.length()) {
+            if (actuals.length() == formals.length() || actuals.isEmpty()) {
                 List<Type> a = actuals;
                 List<Type> f = formals;
                 while (a.nonEmpty()) {
@@ -2548,7 +2572,18 @@
                         clazzOuter = site;
                     }
                 }
-                owntype = new ClassType(clazzOuter, actuals, clazztype.tsym);
+                if (actuals.nonEmpty()) {
+                    owntype = new ClassType(clazzOuter, actuals, clazztype.tsym);
+                }
+                else if (TreeInfo.isDiamond(tree)) {
+                    //a type apply with no explicit type arguments - diamond operator
+                    //the result type is a forall F where F's tvars are the type-variables
+                    //that will be inferred when F is checked against the expected type
+                    List<Type> ftvars = clazztype.tsym.type.getTypeArguments();
+                    List<Type> new_tvars = types.newInstances(ftvars);
+                    clazztype = new ClassType(clazzOuter, new_tvars, clazztype.tsym);
+                    owntype = new ForAll(new_tvars, clazztype);
+                }
             } else {
                 if (formals.length() != 0) {
                     log.error(tree.pos(), "wrong.number.type.args",
--- a/src/share/classes/com/sun/tools/javac/comp/Check.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/comp/Check.java	Mon Sep 21 17:11:48 2009 +0100
@@ -60,8 +60,6 @@
     private final Log log;
     private final Symtab syms;
     private final Infer infer;
-    private final Target target;
-    private final Source source;
     private final Types types;
     private final JCDiagnostic.Factory diags;
     private final boolean skipAnnotations;
@@ -90,18 +88,20 @@
         this.types = Types.instance(context);
         diags = JCDiagnostic.Factory.instance(context);
         Options options = Options.instance(context);
-        target = Target.instance(context);
-        source = Source.instance(context);
         lint = Lint.instance(context);
         treeinfo = TreeInfo.instance(context);
 
         Source source = Source.instance(context);
         allowGenerics = source.allowGenerics();
         allowAnnotations = source.allowAnnotations();
+        allowCovariantReturns = source.allowCovariantReturns();
         complexInference = options.get("-complexinference") != null;
         skipAnnotations = options.get("skipAnnotations") != null;
         warnOnSyntheticConflicts = options.get("warnOnSyntheticConflicts") != null;
 
+        Target target = Target.instance(context);
+        syntheticNameChar = target.syntheticNameChar();
+
         boolean verboseDeprecated = lint.isEnabled(LintCategory.DEPRECATION);
         boolean verboseUnchecked = lint.isEnabled(LintCategory.UNCHECKED);
         boolean verboseSunApi = lint.isEnabled(LintCategory.SUNAPI);
@@ -123,10 +123,18 @@
      */
     boolean allowAnnotations;
 
+    /** Switch: covariant returns enabled?
+     */
+    boolean allowCovariantReturns;
+
     /** Switch: -complexinference option set?
      */
     boolean complexInference;
 
+    /** Character for synthetic names
+     */
+    char syntheticNameChar;
+
     /** A table mapping flat names of all compiled classes in this run to their
      *  symbols; maintained from outside.
      */
@@ -343,7 +351,7 @@
         for (int i=1; ; i++) {
             Name flatname = names.
                 fromString("" + c.owner.enclClass().flatname +
-                           target.syntheticNameChar() + i +
+                           syntheticNameChar + i +
                            c.name);
             if (compiled.get(flatname) == null) return flatname;
         }
@@ -362,8 +370,6 @@
     Type checkType(DiagnosticPosition pos, Type found, Type req) {
         if (req.tag == ERROR)
             return req;
-        if (found.tag == FORALL)
-            return instantiatePoly(pos, (ForAll)found, req, convertWarner(pos, found, req));
         if (req.tag == NONE)
             return found;
         if (types.isAssignable(found, req, convertWarner(pos, found, req)))
@@ -381,11 +387,38 @@
         return typeError(pos, diags.fragment("incompatible.types"), found, req);
     }
 
+    Type checkReturnType(DiagnosticPosition pos, Type found, Type req) {
+        if (found.tag == FORALL) {
+            try {
+                return instantiatePoly(pos, (ForAll) found, req, convertWarner(pos, found, req));
+            } catch (Infer.NoInstanceException ex) {
+                if (ex.isAmbiguous) {
+                    JCDiagnostic d = ex.getDiagnostic();
+                    log.error(pos,
+                            "undetermined.type" + (d != null ? ".1" : ""),
+                            found, d);
+                    return types.createErrorType(req);
+                } else {
+                    JCDiagnostic d = ex.getDiagnostic();
+                    return typeError(pos,
+                            diags.fragment("incompatible.types" + (d != null ? ".1" : ""), d),
+                            found, req);
+                }
+            } catch (Infer.InvalidInstanceException ex) {
+                JCDiagnostic d = ex.getDiagnostic();
+                log.error(pos, "invalid.inferred.types", ((ForAll)found).tvars, d);
+                return types.createErrorType(req);
+            }
+        } else {
+            return checkType(pos, found, req);
+        }
+    }
+
     /** Instantiate polymorphic type to some prototype, unless
      *  prototype is `anyPoly' in which case polymorphic type
      *  is returned unchanged.
      */
-    Type instantiatePoly(DiagnosticPosition pos, ForAll t, Type pt, Warner warn) {
+    Type instantiatePoly(DiagnosticPosition pos, ForAll t, Type pt, Warner warn) throws Infer.NoInstanceException {
         if (pt == Infer.anyPoly && complexInference) {
             return t;
         } else if (pt == Infer.anyPoly || pt.tag == NONE) {
@@ -394,28 +427,9 @@
         } else if (pt.tag == ERROR) {
             return pt;
         } else {
-            try {
-                return infer.instantiateExpr(t, pt, warn);
-            } catch (Infer.NoInstanceException ex) {
-                if (ex.isAmbiguous) {
-                    JCDiagnostic d = ex.getDiagnostic();
-                    log.error(pos,
-                              "undetermined.type" + (d!=null ? ".1" : ""),
-                              t, d);
-                    return types.createErrorType(pt);
-                } else {
-                    JCDiagnostic d = ex.getDiagnostic();
-                    return typeError(pos,
-                                     diags.fragment("incompatible.types" + (d!=null ? ".1" : ""), d),
-                                     t, pt);
-                }
-            } catch (Infer.InvalidInstanceException ex) {
-                JCDiagnostic d = ex.getDiagnostic();
-                log.error(pos, "invalid.inferred.types", t.tvars, d);
-                return types.createErrorType(pt);
-            }
+            return infer.instantiateExpr(t, pt, warn);
         }
-    }
+     }
 
     /** Check that a given type can be cast to a given target type.
      *  Return the result of the cast.
@@ -530,7 +544,7 @@
             while (args.nonEmpty()) {
                 if (args.head.tag == WILDCARD)
                     return typeTagError(pos,
-                                        log.getLocalizedString("type.req.exact"),
+                                        Log.getLocalizedString("type.req.exact"),
                                         args.head);
                 args = args.tail;
             }
@@ -538,6 +552,29 @@
         return t;
     }
 
+    /** Check that type is a valid type for a new expression. If the type contains
+     * some uninferred type variables, instantiate them exploiting the expected
+     * type.
+     *
+     *  @param pos           Position to be used for error reporting.
+     *  @param t             The type to be checked.
+     *  @param noBounds    True if type bounds are illegal here.
+     *  @param pt          Expected type (used with diamond operator)
+     */
+    Type checkNewClassType(DiagnosticPosition pos, Type t, boolean noBounds, Type pt) {
+        if (t.tag == FORALL) {
+            try {
+                t = instantiatePoly(pos, (ForAll)t, pt, Warner.noWarnings);
+            }
+            catch (Infer.NoInstanceException ex) {
+                JCDiagnostic d = ex.getDiagnostic();
+                log.error(pos, "cant.apply.diamond", t.getTypeArguments(), d);
+                return types.createErrorType(pt);
+            }
+        }
+        return checkClassType(pos, t, noBounds);
+    }
+
     /** Check that type is a reifiable class, interface or array type.
      *  @param pos           Position to be used for error reporting.
      *  @param t             The type to be checked.
@@ -765,8 +802,10 @@
                 this.specialized = false;
             };
 
+            @Override
             public void visitTree(JCTree tree) { /* no-op */ }
 
+            @Override
             public void visitVarDef(JCVariableDecl tree) {
                 if ((tree.mods.flags & ENUM) != 0) {
                     if (tree.init instanceof JCNewClass &&
@@ -838,10 +877,12 @@
      */
     class Validator extends JCTree.Visitor {
 
+        @Override
         public void visitTypeArray(JCArrayTypeTree tree) {
             validate(tree.elemtype, env);
         }
 
+        @Override
         public void visitTypeApply(JCTypeApply tree) {
             if (tree.type.tag == CLASS) {
                 List<Type> formals = tree.type.tsym.type.allparams();
@@ -890,7 +931,8 @@
                 }
 
                 checkCapture(tree);
-
+            }
+            if (tree.type.tag == CLASS || tree.type.tag == FORALL) {
                 // Check that this type is either fully parameterized, or
                 // not parameterized at all.
                 if (tree.type.getEnclosingType().isRaw())
@@ -900,6 +942,7 @@
             }
         }
 
+        @Override
         public void visitTypeParameter(JCTypeParameter tree) {
             validate(tree.bounds, env);
             checkClassBounds(tree.pos(), tree.type);
@@ -911,6 +954,7 @@
                 validate(tree.inner, env);
         }
 
+        @Override
         public void visitSelect(JCFieldAccess tree) {
             if (tree.type.tag == CLASS) {
                 visitSelectInternal(tree);
@@ -934,12 +978,14 @@
             }
         }
 
+        @Override
         public void visitAnnotatedType(JCAnnotatedType tree) {
             tree.underlyingType.accept(this);
         }
 
         /** Default visitor method: do nothing.
          */
+        @Override
         public void visitTree(JCTree tree) {
         }
 
@@ -1211,7 +1257,7 @@
         boolean resultTypesOK =
             types.returnTypeSubstitutable(mt, ot, otres, overrideWarner);
         if (!resultTypesOK) {
-            if (!source.allowCovariantReturns() &&
+            if (!allowCovariantReturns &&
                 m.owner != origin &&
                 m.owner.isSubClass(other.owner, types)) {
                 // allow limited interoperability with covariant returns
@@ -2319,6 +2365,7 @@
             this.expected = expected;
         }
 
+        @Override
         public void warnUnchecked() {
             boolean warned = this.warned;
             super.warnUnchecked();
--- a/src/share/classes/com/sun/tools/javac/comp/Infer.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/comp/Infer.java	Mon Sep 21 17:11:48 2009 +0100
@@ -29,6 +29,7 @@
 import com.sun.tools.javac.util.List;
 import com.sun.tools.javac.code.*;
 import com.sun.tools.javac.code.Type.*;
+import com.sun.tools.javac.code.Type.ForAll.ConstraintKind;
 import com.sun.tools.javac.code.Symbol.*;
 import com.sun.tools.javac.util.JCDiagnostic;
 
@@ -50,6 +51,7 @@
 
     Symtab syms;
     Types types;
+    Check chk;
     Resolve rs;
     JCDiagnostic.Factory diags;
 
@@ -65,6 +67,7 @@
         syms = Symtab.instance(context);
         types = Types.instance(context);
         rs = Resolve.instance(context);
+        chk = Check.instance(context);
         diags = JCDiagnostic.Factory.instance(context);
         ambiguousNoInstanceException =
             new NoInstanceException(true, diags);
@@ -250,14 +253,19 @@
                                 Warner warn) throws InferenceException {
         List<Type> undetvars = Type.map(that.tvars, fromTypeVarFun);
         for (List<Type> l = undetvars; l.nonEmpty(); l = l.tail) {
-            UndetVar v = (UndetVar) l.head;
+            UndetVar uv = (UndetVar) l.head;
+            TypeVar tv = (TypeVar)uv.qtype;
             ListBuffer<Type> hibounds = new ListBuffer<Type>();
-            for (List<Type> l1 = types.getBounds((TypeVar) v.qtype); l1.nonEmpty(); l1 = l1.tail) {
-                if (!l1.head.containsSome(that.tvars)) {
-                    hibounds.append(l1.head);
+            for (Type t : that.getConstraints(tv, ConstraintKind.EXTENDS).prependList(types.getBounds(tv))) {
+                if (!t.containsSome(that.tvars) && t.tag != BOT) {
+                    hibounds.append(t);
                 }
             }
-            v.hibounds = hibounds.toList();
+            List<Type> inst = that.getConstraints(tv, ConstraintKind.EQUAL);
+            if (inst.nonEmpty() && inst.head.tag != BOT) {
+                uv.inst = inst.head;
+            }
+            uv.hibounds = hibounds.toList();
         }
         Type qtype1 = types.subst(that.qtype, that.tvars, undetvars);
         if (!types.isSubtype(qtype1, to)) {
@@ -273,7 +281,7 @@
         List<Type> targs = Type.map(undetvars, getInstFun);
         targs = types.subst(targs, that.tvars, targs);
         checkWithinBounds(that.tvars, targs, warn);
-        return that.inst(targs, types);
+        return chk.checkType(warn.pos(), that.inst(targs, types), to);
     }
 
     /** Instantiate method type `mt' by finding instantiations of
@@ -349,6 +357,9 @@
         /** Type variables instantiated to bottom */
         ListBuffer<Type> restvars = new ListBuffer<Type>();
 
+        /** Undet vars instantiated to bottom */
+        final ListBuffer<Type> restundet = new ListBuffer<Type>();
+
         /** Instantiated types or TypeVars if under-constrained */
         ListBuffer<Type> insttypes = new ListBuffer<Type>();
 
@@ -359,6 +370,7 @@
             UndetVar uv = (UndetVar)t;
             if (uv.inst.tag == BOT) {
                 restvars.append(uv.qtype);
+                restundet.append(uv);
                 insttypes.append(uv.qtype);
                 undettypes.append(uv);
                 uv.inst = null;
@@ -379,17 +391,32 @@
             final MethodType mt2 = new MethodType(mt.argtypes, null, mt.thrown, syms.methodClass);
             mt2.restype = new ForAll(restvars.toList(), mt.restype) {
                 @Override
+                public List<Type> getConstraints(TypeVar tv, ConstraintKind ck) {
+                    for (Type t : restundet.toList()) {
+                        UndetVar uv = (UndetVar)t;
+                        if (uv.qtype == tv) {
+                            switch (ck) {
+                                case EXTENDS: return uv.hibounds;
+                                case SUPER: return uv.lobounds;
+                                case EQUAL: return uv.inst != null ? List.of(uv.inst) : List.<Type>nil();
+                            }
+                        }
+                    }
+                    return List.nil();
+                }
+
+                @Override
                 public Type inst(List<Type> inferred, Types types) throws NoInstanceException {
                     List<Type> formals = types.subst(mt2.argtypes, tvars, inferred);
-                   if (!rs.argumentsAcceptable(capturedArgs, formals,
+                    if (!rs.argumentsAcceptable(capturedArgs, formals,
                            allowBoxing, useVarargs, warn)) {
                       // inferred method is not applicable
                       throw invalidInstanceException.setMessage("inferred.do.not.conform.to.params", formals, argtypes);
-                   }
-                   // check that inferred bounds conform to their bounds
-                   checkWithinBounds(all_tvars,
+                    }
+                    // check that inferred bounds conform to their bounds
+                    checkWithinBounds(all_tvars,
                            types.subst(inferredTypes, tvars, inferred), warn);
-                   return super.inst(inferred, types);
+                    return super.inst(inferred, types);
             }};
             return mt2;
         }
--- a/src/share/classes/com/sun/tools/javac/file/BaseFileObject.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/file/BaseFileObject.java	Mon Sep 21 17:11:48 2009 +0100
@@ -29,6 +29,8 @@
 import java.io.IOException;
 import java.io.InputStreamReader;
 import java.io.Reader;
+import java.net.URI;
+import java.net.URISyntaxException;
 import java.nio.charset.CharsetDecoder;
 import javax.lang.model.element.Modifier;
 import javax.lang.model.element.NestingKind;
@@ -93,7 +95,26 @@
         return (lastDot == -1 ? fileName : fileName.substring(0, lastDot));
     }
 
+    protected static URI createJarUri(File jarFile, String entryName) {
+        URI jarURI = jarFile.toURI().normalize();
+        String separator = entryName.startsWith("/") ? "!" : "!/";
+        try {
+            // The jar URI convention appears to be not to re-encode the jarURI
+            return new URI("jar:" + jarURI + separator + entryName);
+        } catch (URISyntaxException e) {
+            throw new CannotCreateUriError(jarURI + separator + entryName, e);
+        }
+    }
+
+    /** Used when URLSyntaxException is thrown unexpectedly during
+     *  implementations of (Base)FileObject.toURI(). */
+    protected static class CannotCreateUriError extends Error {
+        private static final long serialVersionUID = 9101708840997613546L;
+        public CannotCreateUriError(String value, Throwable cause) {
+            super(value, cause);
+        }
+    }
+
     /** The file manager that created this JavaFileObject. */
     protected final JavacFileManager fileManager;
-
 }
--- a/src/share/classes/com/sun/tools/javac/file/JavacFileManager.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/file/JavacFileManager.java	Mon Sep 21 17:11:48 2009 +0100
@@ -26,6 +26,7 @@
 package com.sun.tools.javac.file;
 
 import java.io.ByteArrayOutputStream;
+import java.io.Closeable;
 import java.io.File;
 import java.io.FileInputStream;
 import java.io.FileNotFoundException;
@@ -36,6 +37,7 @@
 import java.lang.reflect.Constructor;
 import java.net.MalformedURLException;
 import java.net.URI;
+import java.net.URISyntaxException;
 import java.net.URL;
 import java.net.URLClassLoader;
 import java.nio.ByteBuffer;
@@ -77,7 +79,6 @@
 import com.sun.tools.javac.util.Log;
 import com.sun.tools.javac.util.Options;
 
-import java.io.Closeable;
 import static javax.tools.StandardLocation.*;
 import static com.sun.tools.javac.main.OptionName.*;
 
@@ -437,6 +438,7 @@
             return Collections.emptySet();
         }
 
+        @Override
         public String toString() {
             return "MissingArchive[" + zipFileName + "]";
         }
@@ -654,10 +656,10 @@
     private final ByteBufferCache byteBufferCache;
 
     CharsetDecoder getDecoder(String encodingName, boolean ignoreEncodingErrors) {
-        Charset charset = (this.charset == null)
+        Charset cs = (this.charset == null)
             ? Charset.forName(encodingName)
             : this.charset;
-        CharsetDecoder decoder = charset.newDecoder();
+        CharsetDecoder decoder = cs.newDecoder();
 
         CodingErrorAction action;
         if (ignoreEncodingErrors)
@@ -892,7 +894,7 @@
         nullCheck(location);
         // validatePackageName(packageName);
         nullCheck(packageName);
-        if (!isRelativeUri(URI.create(relativeName))) // FIXME 6419701
+        if (!isRelativeUri(relativeName))
             throw new IllegalArgumentException("Invalid relative name: " + relativeName);
         RelativeFile name = packageName.length() == 0
             ? new RelativeFile(relativeName)
@@ -946,7 +948,7 @@
         nullCheck(location);
         // validatePackageName(packageName);
         nullCheck(packageName);
-        if (!isRelativeUri(URI.create(relativeName))) // FIXME 6419701
+        if (!isRelativeUri(relativeName))
             throw new IllegalArgumentException("relativeName is invalid");
         RelativeFile name = packageName.length() == 0
             ? new RelativeFile(relativeName)
@@ -1085,6 +1087,15 @@
         return first != '.' && first != '/';
     }
 
+    // Convenience method
+    protected static boolean isRelativeUri(String u) {
+        try {
+            return isRelativeUri(new URI(u));
+        } catch (URISyntaxException e) {
+            return false;
+        }
+    }
+
     /**
      * Converts a relative file name to a relative URI.  This is
      * different from File.toURI as this method does not canonicalize
@@ -1099,7 +1110,7 @@
     public static String getRelativeName(File file) {
         if (!file.isAbsolute()) {
             String result = file.getPath().replace(File.separatorChar, '/');
-            if (JavacFileManager.isRelativeUri(URI.create(result))) // FIXME 6419701
+            if (isRelativeUri(result))
                 return result;
         }
         throw new IllegalArgumentException("Invalid relative path: " + file);
--- a/src/share/classes/com/sun/tools/javac/file/RegularFileObject.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/file/RegularFileObject.java	Mon Sep 21 17:11:48 2009 +0100
@@ -34,7 +34,6 @@
 import java.io.OutputStreamWriter;
 import java.io.Writer;
 import java.net.URI;
-import java.net.URISyntaxException;
 import java.nio.ByteBuffer;
 import java.nio.CharBuffer;
 import java.nio.charset.CharsetDecoder;
@@ -73,6 +72,7 @@
         return new FileInputStream(f);
     }
 
+    @Override
     protected CharsetDecoder getDecoder(boolean ignoreEncodingErrors) {
         return fileManager.getDecoder(fileManager.getEncodingName(), ignoreEncodingErrors);
     }
@@ -147,6 +147,7 @@
     }
 
     @Deprecated
+    @Override
     public String getPath() {
         return f.getPath();
     }
@@ -201,11 +202,6 @@
     }
 
     public URI toUri() {
-        try {
-            String path = f.getAbsolutePath().replace(File.separatorChar, '/');
-            return new URI("file://" + path).normalize();
-        } catch (URISyntaxException ex) {
-            return f.toURI();
-        }
+        return f.toURI().normalize();
     }
 }
--- a/src/share/classes/com/sun/tools/javac/file/SymbolArchive.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/file/SymbolArchive.java	Mon Sep 21 17:11:48 2009 +0100
@@ -73,12 +73,14 @@
         map.put(dirname, list);
     }
 
+    @Override
     public JavaFileObject getFileObject(RelativeDirectory subdirectory, String file) {
         RelativeDirectory prefix_subdir = new RelativeDirectory(prefix, subdirectory.path);
         ZipEntry ze = new RelativeFile(prefix_subdir, file).getZipEntry(zdir);
         return new SymbolFileObject(this, file, ze);
     }
 
+    @Override
     public String toString() {
         return "SymbolArchive[" + zdir.getName() + "]";
     }
--- a/src/share/classes/com/sun/tools/javac/file/ZipArchive.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/file/ZipArchive.java	Mon Sep 21 17:11:48 2009 +0100
@@ -122,6 +122,7 @@
         zdir.close();
     }
 
+    @Override
     public String toString() {
         return "ZipArchive[" + zdir.getName() + "]";
     }
@@ -154,6 +155,7 @@
             throw new UnsupportedOperationException();
         }
 
+        @Override
         protected CharsetDecoder getDecoder(boolean ignoreEncodingErrors) {
             return fileManager.getDecoder(fileManager.getEncodingName(), ignoreEncodingErrors);
         }
@@ -177,6 +179,7 @@
         }
 
         @Deprecated
+        @Override
         public String getPath() {
             return zarch.zdir.getName() + "(" + entry + ")";
         }
@@ -235,9 +238,8 @@
         }
 
         public URI toUri() {
-            String zipName = new File(getZipName()).toURI().normalize().getPath();
-            String entryName = getZipEntryName();
-            return URI.create("jar:" + zipName + "!" + entryName);
+            File zipFile = new File(getZipName());
+            return createJarUri(zipFile, entry.getName());
         }
 
         @Override
--- a/src/share/classes/com/sun/tools/javac/file/ZipFileIndexArchive.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/file/ZipFileIndexArchive.java	Mon Sep 21 17:11:48 2009 +0100
@@ -72,7 +72,7 @@
     public JavaFileObject getFileObject(RelativeDirectory subdirectory, String file) {
         RelativeFile fullZipFileName = new RelativeFile(subdirectory, file);
         ZipFileIndex.Entry entry = zfIndex.getZipIndexEntry(fullZipFileName);
-        JavaFileObject ret = new ZipFileIndexFileObject(fileManager, zfIndex, entry, zfIndex.getZipFile().getPath());
+        JavaFileObject ret = new ZipFileIndexFileObject(fileManager, zfIndex, entry, zfIndex.getZipFile());
         return ret;
     }
 
@@ -84,6 +84,7 @@
         zfIndex.close();
     }
 
+    @Override
     public String toString() {
         return "ZipFileIndexArchive[" + zfIndex + "]";
     }
@@ -111,10 +112,10 @@
 
         /** The name of the zip file where this entry resides.
          */
-        String zipName;
+        File zipName;
 
 
-        ZipFileIndexFileObject(JavacFileManager fileManager, ZipFileIndex zfIndex, ZipFileIndex.Entry entry, String zipFileName) {
+        ZipFileIndexFileObject(JavacFileManager fileManager, ZipFileIndex zfIndex, ZipFileIndex.Entry entry, File zipFileName) {
             super(fileManager);
             this.name = entry.getFileName();
             this.zfIndex = zfIndex;
@@ -130,6 +131,7 @@
             return inputStream;
         }
 
+        @Override
         protected CharsetDecoder getDecoder(boolean ignoreEncodingErrors) {
             return fileManager.getDecoder(fileManager.getEncodingName(), ignoreEncodingErrors);
         }
@@ -157,6 +159,7 @@
 
         /** @deprecated see bug 6410637 */
         @Deprecated
+        @Override
         public String getPath() {
             return zipName + "(" + entry.getName() + ")";
         }
@@ -183,7 +186,7 @@
         }
 
         public String getZipName() {
-            return zipName;
+            return zipName.getPath();
         }
 
         public String getZipEntryName() {
@@ -191,9 +194,10 @@
         }
 
         public URI toUri() {
-            String zipName = new File(getZipName()).toURI().normalize().getPath();
-            String entryName = getZipEntryName();
-            return URI.create("jar:" + zipName + "!" + entryName);
+            if (zfIndex.symbolFilePrefix != null)
+                return createJarUri(zipName, zfIndex.symbolFilePrefix.path + entry.getName());
+            else
+                return createJarUri(zipName, entry.getName());
         }
 
         private byte[] read() throws IOException {
--- a/src/share/classes/com/sun/tools/javac/jvm/ClassReader.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/jvm/ClassReader.java	Mon Sep 21 17:11:48 2009 +0100
@@ -27,6 +27,7 @@
 
 import java.io.*;
 import java.net.URI;
+import java.net.URISyntaxException;
 import java.nio.CharBuffer;
 import java.util.EnumSet;
 import java.util.HashMap;
@@ -2614,7 +2615,11 @@
         }
 
         public URI toUri() {
-            return URI.create(name.toString());
+            try {
+                return new URI(null, name.toString(), null);
+            } catch (URISyntaxException e) {
+                throw new CannotCreateUriError(name.toString(), e);
+            }
         }
 
         @Override
--- a/src/share/classes/com/sun/tools/javac/parser/JavacParser.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/parser/JavacParser.java	Mon Sep 21 17:11:48 2009 +0100
@@ -131,6 +131,7 @@
         this.allowForeach = source.allowForeach();
         this.allowStaticImport = source.allowStaticImport();
         this.allowAnnotations = source.allowAnnotations();
+        this.allowDiamond = source.allowDiamond();
         this.allowTypeAnnotations = source.allowTypeAnnotations();
         this.keepDocComments = keepDocComments;
         if (keepDocComments)
@@ -148,6 +149,10 @@
      */
     boolean allowGenerics;
 
+    /** Switch: Should diamond operator be recognized?
+     */
+    boolean allowDiamond;
+
     /** Switch: Should varargs be recognized?
      */
     boolean allowVarargs;
@@ -194,6 +199,7 @@
     static final int TYPE = 2;
     static final int NOPARAMS = 4;
     static final int TYPEARG = 8;
+    static final int DIAMOND = 16;
 
     /** The current mode.
      */
@@ -1326,6 +1332,11 @@
         ListBuffer<JCExpression> args = lb();
         if (S.token() == LT) {
             S.nextToken();
+            if (S.token() == GT && (mode & DIAMOND) != 0) {
+                checkDiamond();
+                S.nextToken();
+                return List.nil();
+            }
             args.append(((mode & EXPR) == 0) ? typeArgument() : parseType());
             while (S.token() == COMMA) {
                 S.nextToken();
@@ -1497,7 +1508,7 @@
             t = F.AnnotatedType(newAnnotations, t);
 
         int oldmode = mode;
-        mode = TYPE;
+        mode = TYPE | DIAMOND;
         if (S.token() == LT) {
             checkGenerics();
             t = typeArguments(t);
@@ -1547,8 +1558,11 @@
     JCExpression innerCreator(int newpos, List<JCExpression> typeArgs, JCExpression encl) {
         JCExpression t = toP(F.at(S.pos()).Ident(ident()));
         if (S.token() == LT) {
+            int oldmode = mode;
+            mode |= DIAMOND;
             checkGenerics();
             t = typeArguments(t);
+            mode = oldmode;
         }
         return classCreatorRest(newpos, encl, typeArgs, t);
     }
@@ -3099,6 +3113,12 @@
         }
     }
 
+    void checkDiamond() {
+        if (!allowDiamond) {
+            log.error(S.pos(), "diamond.not.supported.in.source", source.name);
+            allowDiamond = true;
+        }
+    }
     void checkGenerics() {
         if (!allowGenerics) {
             log.error(S.pos(), "generics.not.supported.in.source", source.name);
--- a/src/share/classes/com/sun/tools/javac/processing/JavacProcessingEnvironment.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/processing/JavacProcessingEnvironment.java	Mon Sep 21 17:11:48 2009 +0100
@@ -287,11 +287,12 @@
         // The to-be-wrapped iterator.
         private Iterator<?> iterator;
         private Log log;
+        private Class<?> loaderClass;
+        private boolean jusl;
+        private Object loader;
 
         ServiceIterator(ClassLoader classLoader, Log log) {
-            Class<?> loaderClass;
             String loadMethodName;
-            boolean jusl;
 
             this.log = log;
             try {
@@ -324,6 +325,7 @@
                 // For java.util.ServiceLoader, we have to call another
                 // method to get the iterator.
                 if (jusl) {
+                    loader = result; // Store ServiceLoader to call reload later
                     Method m = loaderClass.getMethod("iterator");
                     result = m.invoke(result); // serviceLoader.iterator();
                 }
@@ -365,6 +367,18 @@
         public void remove() {
             throw new UnsupportedOperationException();
         }
+
+        public void close() {
+            if (jusl) {
+                try {
+                    // Call java.util.ServiceLoader.reload
+                    Method reloadMethod = loaderClass.getMethod("reload");
+                    reloadMethod.invoke(loader);
+                } catch(Exception e) {
+                    ; // Ignore problems during a call to reload.
+                }
+            }
+        }
     }
 
 
@@ -552,7 +566,7 @@
      * been discoverd so far as well as the means to discover more, if
      * necessary.  A single iterator should be used per round of
      * annotation processing.  The iterator first visits already
-     * discovered processors then fails over to the service provided
+     * discovered processors then fails over to the service provider
      * mechanism if additional queries are made.
      */
     class DiscoveredProcessors implements Iterable<ProcessorState> {
@@ -624,6 +638,16 @@
             this.processorIterator = processorIterator;
             this.procStateList = new ArrayList<ProcessorState>();
         }
+
+        /**
+         * Free jar files, etc. if using a service loader.
+         */
+        public void close() {
+            if (processorIterator != null &&
+                processorIterator instanceof ServiceIterator) {
+                ((ServiceIterator) processorIterator).close();
+            }
+        }
     }
 
     private void discoverAndRunProcs(Context context,
@@ -910,7 +934,7 @@
         * second to last round; errorRaised() gives the error status
         * of the last round.
         */
-       errorStatus = errorStatus || messager.errorRaised();
+        errorStatus = errorStatus || messager.errorRaised();
 
 
         // Free resources
@@ -1023,6 +1047,8 @@
      */
     public void close() throws IOException {
         filer.close();
+        if (discoveredProcs != null) // Make calling close idempotent
+            discoveredProcs.close();
         discoveredProcs = null;
         if (processorClassLoader != null && processorClassLoader instanceof Closeable)
             ((Closeable) processorClassLoader).close();
--- a/src/share/classes/com/sun/tools/javac/processing/PrintingProcessor.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/processing/PrintingProcessor.java	Mon Sep 21 17:11:48 2009 +0100
@@ -48,7 +48,8 @@
  * deletion without notice.</b>
  */
 @SupportedAnnotationTypes("*")
-@SupportedSourceVersion(SourceVersion.RELEASE_6)
+// TODO: Change to version 7 based visitors when available
+@SupportedSourceVersion(SourceVersion.RELEASE_7)
 public class PrintingProcessor extends AbstractProcessor {
     PrintWriter writer;
 
@@ -374,6 +375,7 @@
                 for(TypeParameterElement tpe: typeParams) {
                     if (!first)
                         writer.print(", ");
+                    printAnnotationsInline(tpe);
                     writer.print(tpe.toString());
                     first = false;
                 }
--- a/src/share/classes/com/sun/tools/javac/resources/compiler.properties	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/resources/compiler.properties	Mon Sep 21 17:11:48 2009 +0100
@@ -1073,6 +1073,10 @@
     symbol:   {0} <{2}>{1}({3})\n\
     location: {4} {5}
 
+compiler.err.cant.apply.diamond=\
+    diamond operator cannot infer types for {0};\n\
+    reason: {1}
+
 ## The following are all possible string for "kindname".
 ## They should be called whatever the JLS calls them after it been translated
 ## to the appropriate language.
@@ -1205,6 +1209,10 @@
     enums are not supported in -source {0}\n\
 (use -source 5 or higher to enable enums)
 
+compiler.err.diamond.not.supported.in.source=\
+    diamond operator is not supported in -source {0}\n\
+(use -source 7 or higher to enable diamond operator)
+
 ########################################
 # Diagnostics for where clause implementation
 # used by the RichDiagnosticFormatter.
--- a/src/share/classes/com/sun/tools/javac/tree/TreeInfo.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javac/tree/TreeInfo.java	Mon Sep 21 17:11:48 2009 +0100
@@ -204,6 +204,15 @@
         return (JCMethodInvocation)exec.expr;
     }
 
+    /** Return true if a tree represents a diamond new expr. */
+    public static boolean isDiamond(JCTree tree) {
+        switch(tree.getTag()) {
+            case JCTree.TYPEAPPLY: return ((JCTypeApply)tree).getTypeArguments().isEmpty();
+            case JCTree.NEWCLASS: return isDiamond(((JCNewClass)tree).clazz);
+            default: return false;
+        }
+    }
+
     /** Return true if a tree represents the null literal. */
     public static boolean isNull(JCTree tree) {
         if (tree.getTag() != JCTree.LITERAL)
--- a/src/share/classes/com/sun/tools/javadoc/ClassDocImpl.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javadoc/ClassDocImpl.java	Mon Sep 21 17:11:48 2009 +0100
@@ -297,7 +297,7 @@
                         po instanceof SourcePositionImpl) {
                     URI uri = ((SourcePositionImpl) po).filename.toUri();
                     if ("file".equals(uri.getScheme())) {
-                        File f = new File(uri.getPath());
+                        File f = new File(uri);
                         File dir = f.getParentFile();
                         if (dir != null) {
                             File pf = new File(dir, "package.html");
--- a/src/share/classes/com/sun/tools/javap/JavapTask.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/src/share/classes/com/sun/tools/javap/JavapTask.java	Mon Sep 21 17:11:48 2009 +0100
@@ -455,8 +455,19 @@
                     return EXIT_CMDERR;
             }
 
-            boolean ok = run();
-            return ok ? EXIT_OK : EXIT_ERROR;
+            try {
+                boolean ok = run();
+                return ok ? EXIT_OK : EXIT_ERROR;
+            } finally {
+                if (defaultFileManager != null) {
+                    try {
+                        defaultFileManager.close();
+                        defaultFileManager = null;
+                    } catch (IOException e) {
+                        throw new InternalError(e);
+                    }
+                }
+            }
         } catch (BadArgs e) {
             reportError(e.key, e.args);
             if (e.showUsage) {
@@ -856,7 +867,9 @@
     }
 
     private JavaFileManager getDefaultFileManager(final DiagnosticListener<? super JavaFileObject> dl, PrintWriter log) {
-        return JavapFileManager.create(dl, log);
+        if (defaultFileManager == null)
+            defaultFileManager = JavapFileManager.create(dl, log);
+        return defaultFileManager;
     }
 
     private JavaFileObject getClassFileObject(String className) throws IOException {
@@ -1004,6 +1017,7 @@
 
     protected Context context;
     JavaFileManager fileManager;
+    JavaFileManager defaultFileManager;
     PrintWriter log;
     DiagnosticListener<? super JavaFileObject> diagnosticListener;
     List<String> classes;
--- a/test/Makefile	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/Makefile	Mon Sep 21 17:11:48 2009 +0100
@@ -44,7 +44,6 @@
 # Default bundle of all test results (passed or not)
 JPRT_ARCHIVE_BUNDLE=$(TEST_ROOT)/JPRT_ARCHIVE_BUNDLE.zip
 
-# Default home for JTREG
 ifeq ($(PLATFORM), windows)
   SLASH_JAVA = J:
 else
@@ -52,8 +51,12 @@
 endif
 
 # Default JTREG to run
-JT_HOME = $(SLASH_JAVA)/svc/jct-tools3.2.2_02
-JTREG = $(JT_HOME)/$(JT_PLATFORM)/bin/jtreg
+ifdef JPRT_JTREG_HOME
+  JTREG_HOME = $(JPRT_JTREG_HOME)
+else
+  JTREG_HOME = $(SLASH_JAVA)/re/jtreg/4.0/promoted/latest/binaries/jtreg
+endif
+JTREG = $(JTREG_HOME)/$(JT_PLATFORM)/bin/jtreg
 
 # Default JDK for JTREG
 ifdef JPRT_JAVA_HOME
@@ -63,7 +66,12 @@
 endif
 
 # Default JDK to test
-TESTJAVA = $(SLASH_JAVA)/re/jdk/1.7.0/promoted/latest/binaries/$(PLATFORM)-$(ARCH)
+ifdef JPRT_IMPORT_PRODUCT_HOME
+  TESTJAVA = $(JPRT_IMPORT_PRODUCT_HOME)
+else
+  TESTJAVA = $(SLASH_JAVA)/re/jdk/1.7.0/promoted/latest/binaries/$(PLATFORM)-$(ARCH)
+endif
+
 TESTBOOTCLASSPATH = $(PRODUCT_HOME)/dist/lib/classes.jar
 
 # The test directories to run
@@ -73,41 +81,40 @@
 # Root of all test results
 TEST_OUTPUT_DIR = $(TEST_ROOT)/o_$(PLATFORM)-$(ARCH)
 
-# Export this setting and pass it in.
-JAVA_TOOL_OPTIONS = -Djava.awt.headless=true
-export JAVA_TOOL_OPTIONS
-
 # Default make rule
-all javac javadoc javah javap apt: clean check jtreg-tests $(JPRT_ARCHIVE_BUNDLE)
+all apt javac javadoc javah javap: clean check jtreg-tests $(JPRT_ARCHIVE_BUNDLE)
 	@echo "Testing completed successfully"
 
 # for use with JPRT -testrule
 all:		TESTDIRS = .
-javac fastjavac: TESTDIRS = tools/javac
+apt:		TESTDIRS = tools/apt
+javac: 		TESTDIRS = tools/javac
 javadoc:	TESTDIRS = tools/javadoc com/sun/javadoc
 javah:		TESTDIRS = tools/javah
 javap:		TESTDIRS = tools/javap
-apt:		TESTDIRS = tools/apt
-
-fastjavac:	SAMEVM = -samevm
 
 # Check to make sure these directories exist
 check: $(JT_HOME) $(PRODUCT_HOME) $(JTREG)
 
 # Run the tests
 jtreg-tests: FRC
-	ls /opt/jprt /opt/jprt/jdk*
 	@echo "Using export JAVA_TOOL_OPTIONS=$(JAVA_TOOL_OPTIONS)"
 	@rm -f -r $(TEST_OUTPUT_DIR)/JTwork $(TEST_OUTPUT_DIR)/JTreport
 	@mkdir -p $(TEST_OUTPUT_DIR)
-	JT_JAVA=$(JT_JAVA) $(JTREG) -k:\!ignore -a -v:fail,error $(SAMEVM) \
+	JT_JAVA=$(JT_JAVA) $(JTREG) \
+	  -a -samevm -k:\!ignore -v:fail,error,nopass \
           -r:$(TEST_OUTPUT_DIR)/JTreport \
           -w:$(TEST_OUTPUT_DIR)/JTwork \
           -jdk:$(TESTJAVA) \
 	  -Xbootclasspath/p:$(TESTBOOTCLASSPATH) \
-          $(JAVA_TOOL_OPTIONS:%=-vmoption:%) \
           $(JAVA_ARGS:%=-vmoption:%) \
-          $(TESTDIRS)
+          $(TESTDIRS) \
+	|| ( status=$$? ; \
+		echo ; echo "Summary of test failures" ; \
+		cat $(TEST_OUTPUT_DIR)/JTreport/text/summary.txt | \
+			grep -v 'Not run' | grep -v 'Passed' ; \
+		echo ; \
+		exit $$status )
 
 # Bundle up the results
 $(JPRT_ARCHIVE_BUNDLE): FRC
--- a/test/com/sun/javadoc/lib/JavadocTester.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/lib/JavadocTester.java	Mon Sep 21 17:11:48 2009 +0100
@@ -124,6 +124,14 @@
     private static int javadocRunNum = 0;
 
     /**
+     * Whether or not to match newlines exactly.
+     * Set this value to false if the match strings
+     * contain text from javadoc comments containing
+     * non-platform newlines.
+     */
+    protected boolean exactNewlineMatch = true;
+
+    /**
      * Construct a JavadocTester.
      */
     public JavadocTester() {
@@ -419,15 +427,22 @@
     /**
      * Search for the string in the given file and return true
      * if the string was found.
+     * If exactNewlineMatch is false, newlines will be normalized
+     * before the comparison.
      *
      * @param fileString    the contents of the file to search through
      * @param stringToFind  the string to search for
      * @return              true if the string was found
      */
     private boolean findString(String fileString, String stringToFind) {
-        return fileString.indexOf(stringToFind) >= 0;
+        if (exactNewlineMatch) {
+            return fileString.indexOf(stringToFind) >= 0;
+        } else {
+            return fileString.replace(NL, "\n").indexOf(stringToFind.replace(NL, "\n")) >= 0;
+        }
     }
 
+
     /**
      * Return the standard output.
      * @return the standard output
--- a/test/com/sun/javadoc/testCRLineSeparator/TestCRLineSeparator.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testCRLineSeparator/TestCRLineSeparator.java	Mon Sep 21 17:11:48 2009 +0100
@@ -32,6 +32,9 @@
  * @run main TestCRLineSeparator
  */
 
+import java.io.*;
+import java.util.*;
+
 public class TestCRLineSeparator extends JavadocTester {
 
     //Test information.
@@ -39,7 +42,7 @@
 
     //Javadoc arguments.
     private static final String[] ARGS = new String[] {
-        "-d", BUG_ID, "-sourcepath", SRC_DIR, "pkg"
+        "-d", BUG_ID, "-sourcepath", ".", "pkg"
     };
 
     //Input for string search tests.
@@ -53,7 +56,8 @@
      * The entry point of the test.
      * @param args the array of command line arguments.
      */
-    public static void main(String[] args) {
+    public static void main(String[] args) throws Exception {
+        initFiles(new File(SRC_DIR), new File("."), "pkg");
         TestCRLineSeparator tester = new TestCRLineSeparator();
         run(tester, ARGS, TEST, NEGATED_TEST);
         tester.printSummary();
@@ -72,4 +76,36 @@
     public String getBugName() {
         return getClass().getName();
     }
+
+    // recursively copy files from fromDir to toDir, replacing newlines
+    // with \r
+    static void initFiles(File fromDir, File toDir, String f) throws IOException {
+        File from_f = new File(fromDir, f);
+        File to_f = new File(toDir, f);
+        if (from_f.isDirectory()) {
+            to_f.mkdirs();
+            for (String child: from_f.list()) {
+                initFiles(from_f, to_f, child);
+            }
+        } else {
+            List<String> lines = new ArrayList<String>();
+            BufferedReader in = new BufferedReader(new FileReader(from_f));
+            try {
+                String line;
+                while ((line = in.readLine()) != null)
+                    lines.add(line);
+            } finally {
+                in.close();
+            }
+            BufferedWriter out = new BufferedWriter(new FileWriter(to_f));
+            try {
+                for (String line: lines) {
+                    out.write(line);
+                    out.write("\r");
+                }
+            } finally {
+                out.close();
+            }
+        }
+    }
 }
--- a/test/com/sun/javadoc/testCRLineSeparator/pkg/MyClass.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testCRLineSeparator/pkg/MyClass.java	Mon Sep 21 17:11:48 2009 +0100
@@ -21,4 +21,11 @@
  * have any questions.
  */
 
-package pkg;

/**
 * Line 1
 * Line 2
 */
public class MyClass {}
+package pkg;
+
+/**
+ * Line 1
+ * Line 2
+ */
+public class MyClass {}
+
--- a/test/com/sun/javadoc/testHref/package-list	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testHref/package-list	Mon Sep 21 17:11:48 2009 +0100
@@ -1,1 +1,1 @@
-java.lang
+java.lang
--- a/test/com/sun/javadoc/testHtmlDefinitionListTag/TestHtmlDefinitionListTag.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testHtmlDefinitionListTag/TestHtmlDefinitionListTag.java	Mon Sep 21 17:11:48 2009 +0100
@@ -351,6 +351,7 @@
      */
     public static void main(String[] args) {
         TestHtmlDefinitionListTag tester = new TestHtmlDefinitionListTag();
+        tester.exactNewlineMatch = false;
         run(tester, ARGS1, TEST_ALL, NEGATED_TEST);
         run(tester, ARGS1, TEST_CMNT_DEPR, NEGATED_TEST);
         run(tester, ARGS2, TEST_ALL, NEGATED_TEST);
--- a/test/com/sun/javadoc/testLinkOption/testNewLineInLink/package.html	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testLinkOption/testNewLineInLink/package.html	Mon Sep 21 17:11:48 2009 +0100
@@ -1,6 +1,6 @@
-<html>
-<body>
-{@link java.awt.Color#getAlpha()
-getAlpha}
-</body>
-</html>
+<html>
+<body>
+{@link java.awt.Color#getAlpha()
+getAlpha}
+</body>
+</html>
--- a/test/com/sun/javadoc/testNoPackagesFile/TestNoPackagesFile.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testNoPackagesFile/TestNoPackagesFile.java	Mon Sep 21 17:11:48 2009 +0100
@@ -52,7 +52,7 @@
         TestNoPackagesFile tester = new TestNoPackagesFile();
         run(tester, ARGS, NO_TEST, NO_TEST);
         if ((new java.io.File(BUG_ID + FS + "packages.html")).exists()) {
-            throw new Error("Test Fails: packages file should not be " +
                "generated anymore.");
+            throw new Error("Test Fails: packages file should not be " +                "generated anymore.");
         } else {
             System.out.println("Test passes:  packages.html not found.");
         }
--- a/test/com/sun/javadoc/testOverridenMethods/TestMultiInheritence.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testOverridenMethods/TestMultiInheritence.java	Mon Sep 21 17:11:48 2009 +0100
@@ -46,7 +46,7 @@
     //Method foo() is inherited from BOTH I2 and I3
     private static final String[][] TEST = {
        {BUG_ID + FS + "pkg3" + FS + "I1.html",
-        "Methods inherited from interface pkg3." +
        "<A HREF=\"../pkg3/I2.html\" title=\"interface in pkg3\">I2</A>"},
+        "Methods inherited from interface pkg3." +        "<A HREF=\"../pkg3/I2.html\" title=\"interface in pkg3\">I2</A>"},
         {BUG_ID + FS + "pkg3" + FS +"I1.html",
         "Methods inherited from interface pkg3." +
         "<A HREF=\"../pkg3/I3.html\" title=\"interface in pkg3\">I3</A>"},
--- a/test/com/sun/javadoc/testRelativeLinks/pkg/package.html	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testRelativeLinks/pkg/package.html	Mon Sep 21 17:11:48 2009 +0100
@@ -1,6 +1,7 @@
-<html>
-	<body>
-		Here is a relative link in a package: 
-       <a href="relative-package-link.html">relative package link</a>.
-	</body>
-</html>
\ No newline at end of file
+<html>
+	<body>
+		Here is a relative link in a package: 
+       <a href="relative-package-link.html">relative package link</a>.
+	</body>
+</html>
+
--- a/test/com/sun/javadoc/testSerializedFormDeprecationInfo/TestSerializedFormDeprecationInfo.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testSerializedFormDeprecationInfo/TestSerializedFormDeprecationInfo.java	Mon Sep 21 17:11:48 2009 +0100
@@ -128,6 +128,7 @@
      */
     public static void main(String[] args) {
         TestSerializedFormDeprecationInfo tester = new TestSerializedFormDeprecationInfo();
+        tester.exactNewlineMatch = false;
         run(tester, ARGS1, TEST_CMNT_DEPR, TEST_NOCMNT);
         run(tester, ARGS2, TEST_NOCMNT, TEST_CMNT_DEPR);
         run(tester, ARGS3, TEST_NODEPR, TEST_NOCMNT_NODEPR);
--- a/test/com/sun/javadoc/testTaglets/TestTaglets.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testTaglets/TestTaglets.java	Mon Sep 21 17:11:48 2009 +0100
@@ -55,7 +55,7 @@
 
     //Input for string search tests.
     private static final String[][] TEST_4654308 = new String[][] {
-        {"4654308" + FS + "C.html", "<B>Foo:</B><DD>my only method is " +
            "<A HREF=\"C.html#method()\"><CODE>here</CODE></A>"}
+        {"4654308" + FS + "C.html", "<B>Foo:</B><DD>my only method is " +            "<A HREF=\"C.html#method()\"><CODE>here</CODE></A>"}
     };
     private static final String[][] NEGATED_TEST_4654308 = NO_TEST;
 
--- a/test/com/sun/javadoc/testWarnings/pkg/package.html	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/com/sun/javadoc/testWarnings/pkg/package.html	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,4 @@
-<HTML>
-   Testing.
-<HTML>
\ No newline at end of file
+<HTML>
+   Testing.
+<HTML>
+
--- a/test/tools/apt/Basics/apt.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/apt/Basics/apt.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -33,12 +33,11 @@
 
 OS=`uname -s`;
 case "${OS}" in
-        Windows* | CYGWIN* )
-                SEP=";"
+        CYGWIN* )
+                DIFFOPTS="--strip-trailing-cr"
         ;;
 
 	* )
-	SEP=":"
 	;;
 esac
 
@@ -94,7 +93,7 @@
 do
 	printf "%s\n" "Testing annotations on source file ${i}"
 	${APT} @options ${i} 2> result.txt
-	diff ${TESTSRC}/golden.txt result.txt
+	diff ${DIFFOPTS} ${TESTSRC}/golden.txt result.txt
 
 	RESULT=$?
 	case "$RESULT" in
@@ -109,7 +108,7 @@
 	CLASS=`basename ${i} .java`
 	printf "%s\n" "Testing annotations on class file ${CLASS}"
 	${APT} @options1 ${CLASS} 2> result2.txt
-	diff ${TESTSRC}/golden.txt result2.txt
+	diff ${DIFFOPTS} ${TESTSRC}/golden.txt result2.txt
 
 	RESULT=$?
 	case "$RESULT" in
--- a/test/tools/apt/Basics/print.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/apt/Basics/print.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -32,12 +32,11 @@
 
 OS=`uname -s`;
 case "${OS}" in
-        Windows* | CYGWIN* )
-                SEP=";"
+        CYGWIN* )
+                DIFFOPTS="--strip-trailing-cr"
         ;;
 
 	* )
-	SEP=":"
 	;;
 esac
 
@@ -88,7 +87,7 @@
 # check for mutliple methods and no static initializer
 
 ${APT} -XclassesAsDecls -cp ${TESTCLASSES} -print Aggregate > aggregate.txt
-diff aggregate.txt ${TESTSRC}/goldenAggregate.txt
+diff ${DIFFOPTS} aggregate.txt ${TESTSRC}/goldenAggregate.txt
 
 RESULT=$?
 case "$RESULT" in
--- a/test/tools/apt/Compile/compile.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/apt/Compile/compile.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -57,7 +57,12 @@
 
 OS=`uname -s`;
 case "${OS}" in
-        Windows* | CYGWIN* )
+        Windows* )
+                SEP=";"
+        ;;
+
+        CYGWIN* )
+		DIFFOPTS="--strip-trailing-cr"
                 SEP=";"
         ;;
 
@@ -150,7 +155,7 @@
 
 TestNoFile "HelloWorld.class"
 
-diff output ${TESTSRC}/golden.txt
+diff ${DIFFOPTS} output ${TESTSRC}/golden.txt
 
 RESULT=$?
 case "$RESULT" in
@@ -180,7 +185,7 @@
 printf "%s\n" "HelloAnnotation.java"        >> options3
 ${APT} @options3 2> output
 
-diff output ${TESTSRC}/goldenWarn.txt
+diff ${DIFFOPTS} output ${TESTSRC}/goldenWarn.txt
 
 RESULT=$?
 case "$RESULT" in
@@ -485,7 +490,7 @@
 printf "%s\n" "${TESTSRC}/Dummy1.java" >> options8
 ${APT} @options8 > multiRoundOutput 2> multiRoundError
 
-diff multiRoundOutput  ${TESTSRC}/goldenFactory.txt
+diff ${DIFFOPTS} multiRoundOutput  ${TESTSRC}/goldenFactory.txt
 
 RESULT=$?
 case "$RESULT" in
--- a/test/tools/javac/4846262/Test.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/4846262/Test.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -45,13 +45,13 @@
 OS=`uname -s`
 case "$OS" in
   SunOS | Linux )
-    NULL=/dev/null
-    PS=":"
     FS="/"
     ;;
+  CYGWIN* )
+    FS="/"
+    DIFFOPTS="--strip-trailing-cr"
+    ;;
   Windows* )
-    NULL=NUL
-    PS=";"
     FS="\\"
     ;;
   * )
@@ -68,7 +68,7 @@
 
 "${TESTJAVA}${FS}bin${FS}native2ascii" ${TESTTOOLVMOPTS} -encoding IBM1047 Test.tmp Test.out
 
-diff -c "${TESTSRC}${FS}Test.out" Test.out
+diff ${DIFFOPTS} -c "${TESTSRC}${FS}Test.out" Test.out
 result=$?
 
 if [ $result -eq o ]
--- a/test/tools/javac/6302184/T6302184.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6302184/T6302184.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -42,13 +42,13 @@
 OS=`uname -s`
 case "$OS" in
   SunOS | Linux )
-    NULL=/dev/null
-    PS=":"
     FS="/"
     ;;
+  CYGWIN* )
+    FS="/"
+    DIFFOPTS="--strip-trailing-cr"
+    ;;
   Windows* )
-    NULL=NUL
-    PS=";"
     FS="\\"
     ;;
   * )
@@ -57,8 +57,8 @@
     ;;
 esac
 
-"${TESTJAVA}${FS}bin${FS}javac" ${TESTTOOLVMOPTS} -d ${TC} -cp ${TC} -encoding iso-8859-1 -XD-printsource ${TS}${FS}T6302184.java 2>&1 > ${NULL}
-diff -c ${TC}${FS}T6302184.java ${TS}${FS}T6302184.out
+"${TESTJAVA}${FS}bin${FS}javac" ${TESTTOOLVMOPTS} -d ${TC} -cp ${TC} -encoding iso-8859-1 -XD-printsource ${TS}${FS}T6302184.java 2>&1
+diff ${DIFFOPTS} -c ${TC}${FS}T6302184.java ${TS}${FS}T6302184.out
 result=$?
 
 
--- a/test/tools/javac/6521805/T6521805a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6521805/T6521805a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6521805
  * @summary Regression: JDK5/JDK6 javac allows write access to outer class reference
  * @author mcimadamore
--- a/test/tools/javac/6521805/T6521805a_1.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6521805/T6521805a_1.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6521805a.java:40:12: compiler.err.synthetic.name.conflict: this$0, T6521805a.Outer
+T6521805a.java:17:12: compiler.err.synthetic.name.conflict: this$0, T6521805a.Outer
 1 error
--- a/test/tools/javac/6521805/T6521805a_2.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6521805/T6521805a_2.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6521805a.java:40:12: compiler.warn.synthetic.name.conflict: this$0, T6521805a.Outer
+T6521805a.java:17:12: compiler.warn.synthetic.name.conflict: this$0, T6521805a.Outer
 1 warning
--- a/test/tools/javac/6521805/T6521805d.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6521805/T6521805d.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6521805
  * @summary Regression: JDK5/JDK6 javac allows write access to outer class reference
  * @author mcimadamore
--- a/test/tools/javac/6521805/T6521805d.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6521805/T6521805d.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6521805d.java:41:18: compiler.err.synthetic.name.conflict: this$0, T6521805.Inner
+T6521805d.java:18:18: compiler.err.synthetic.name.conflict: this$0, T6521805.Inner
 1 error
--- a/test/tools/javac/6589361/T6589361.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6589361/T6589361.java	Mon Sep 21 17:11:48 2009 +0100
@@ -23,8 +23,9 @@
             set.add(JavaFileObject.Kind.CLASS);
             Iterable<JavaFileObject> files = fm.list(StandardLocation.PLATFORM_CLASS_PATH, "java.lang", set, false);
             for (JavaFileObject file : files) {
-
-                if (file.toString().contains("java" + File.separator + "lang" + File.separator + "Object.class")) {
+                // Note: Zip/Jar entry names use '/', not File.separator, but just to be sure,
+                // we normalize the filename as well.
+                if (file.toString().replace(File.separatorChar, '/').contains("java/lang/Object.class")) {
                     String str = fm.inferBinaryName(StandardLocation.CLASS_PATH, file);
                     if (!str.equals("java.lang.Object")) {
                         throw new AssertionError("Error in JavacFileManager.inferBinaryName method!");
@@ -40,7 +41,7 @@
                 fm.close();
             }
         }
-        throw new AssertionError("Could not fing java/lang/Object.class while compiling");
+        throw new AssertionError("Could not find java/lang/Object.class while compiling");
     }
 
 }
--- a/test/tools/javac/6627362/T6627362.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6627362/T6627362.java	Mon Sep 21 17:11:48 2009 +0100
@@ -75,7 +75,7 @@
 
         StringWriter sw = new StringWriter();
         javap(new PrintWriter(sw, true), jpArgs);
-        check(sw.toString(), "//Method java/lang/System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V");
+        check(sw.toString(), "// Method java/lang/System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V");
         callValues();
     }
 
@@ -86,26 +86,13 @@
     }
 
     void javap(PrintWriter out, String... args) throws Exception {
-        // for now, we have to exec javap
-        File javaHome = new File(System.getProperty("java.home"));
-        if (javaHome.getName().equals("jre"))
-            javaHome = javaHome.getParentFile();
-        File javap = new File(new File(javaHome, "bin"), "javap");
-        String[] cmd = new String[args.length + 1];
-        cmd[0] = javap.getPath();
-        System.arraycopy(args, 0, cmd, 1, args.length);
-        Process p = new ProcessBuilder(cmd).redirectErrorStream(true).start();
-        p.getOutputStream().close();
-        BufferedReader in = new BufferedReader(new InputStreamReader(p.getInputStream()));
-        String line;
-        while ((line = in.readLine()) != null)
-            out.println(line);
-        int rc = p.waitFor();
+        int rc = com.sun.tools.javap.Main.run(args, out);
         if (rc != 0)
             throw new Error("javap failed: " + Arrays.asList(args) + ": " + rc);
     }
 
     void check(String s, String require) {
+        System.out.println("Checking:\n" + s);
         if (s.indexOf(require) == -1) {
             System.err.println("Can't find " + require);
             errors++;
--- a/test/tools/javac/6717241/T6717241a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6717241/T6717241a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6717241
  * @summary some diagnostic argument is prematurely converted into a String object
  * @author  Maurizio Cimadamore
--- a/test/tools/javac/6717241/T6717241a.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6717241/T6717241a.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,4 +1,4 @@
-T6717241a.java:36:21: compiler.err.cant.resolve: kindname.variable, v, , 
-T6717241a.java:38:10: compiler.err.cant.resolve.args: kindname.method, m1, , int,java.lang.String
-T6717241a.java:40:10: compiler.err.cant.resolve.args.params: kindname.method, m2, java.lang.Integer,java.lang.Double, int,java.lang.String
+T6717241a.java:13:21: compiler.err.cant.resolve: kindname.variable, v, , 
+T6717241a.java:15:10: compiler.err.cant.resolve.args: kindname.method, m1, , int,java.lang.String
+T6717241a.java:17:10: compiler.err.cant.resolve.args.params: kindname.method, m2, java.lang.Integer,java.lang.Double, int,java.lang.String
 3 errors
--- a/test/tools/javac/6717241/T6717241b.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6717241/T6717241b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6717241
  * @summary some diagnostic argument is prematurely converted into a String object
  * @author  Maurizio Cimadamore
--- a/test/tools/javac/6717241/T6717241b.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6717241/T6717241b.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,4 +1,4 @@
-T6717241b.java:35:20: compiler.err.cant.resolve.location: kindname.variable, v, , , kindname.class, T6717241b
-T6717241b.java:37:9: compiler.err.cant.resolve.location.args: kindname.method, m1, , int,java.lang.String, kindname.class, T6717241b
-T6717241b.java:39:18: compiler.err.cant.resolve.location.args.params: kindname.method, m2, java.lang.Integer,java.lang.Double, int,java.lang.String, kindname.class, T6717241b
+T6717241b.java:12:20: compiler.err.cant.resolve.location: kindname.variable, v, , , kindname.class, T6717241b
+T6717241b.java:14:9: compiler.err.cant.resolve.location.args: kindname.method, m1, , int,java.lang.String, kindname.class, T6717241b
+T6717241b.java:16:18: compiler.err.cant.resolve.location.args.params: kindname.method, m2, java.lang.Integer,java.lang.Double, int,java.lang.String, kindname.class, T6717241b
 3 errors
--- a/test/tools/javac/6734819/T6734819c.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6734819/T6734819c.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6734819
  * @summary Javac performs flows analysis on already translated classes
  * @author Maurizio Cimadamore
--- a/test/tools/javac/6734819/T6734819c.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6734819/T6734819c.out	Mon Sep 21 17:11:48 2009 +0100
@@ -4,5 +4,5 @@
 [flow W]
 [attribute Z]
 [flow Z]
-T6734819c.java:38:11: compiler.err.unreachable.stmt
+T6734819c.java:15:11: compiler.err.unreachable.stmt
 1 error
--- a/test/tools/javac/6758789/T6758789a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6758789/T6758789a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6758789
  * @summary 6758789: Some method resolution diagnostic should be improved
  * @author Maurizio Cimadamore
--- a/test/tools/javac/6758789/T6758789a.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6758789/T6758789a.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-T6758789a.java:37:9: compiler.err.cant.apply.symbol: kindname.method, m1, compiler.misc.no.args, int, kindname.class, T6758789a, null
-T6758789a.java:38:9: compiler.err.cant.apply.symbol: kindname.method, m2, int, compiler.misc.no.args, kindname.class, T6758789a, null
-2 errors
\ No newline at end of file
+T6758789a.java:14:9: compiler.err.cant.apply.symbol: kindname.method, m1, compiler.misc.no.args, int, kindname.class, T6758789a, null
+T6758789a.java:15:9: compiler.err.cant.apply.symbol: kindname.method, m2, int, compiler.misc.no.args, kindname.class, T6758789a, null
+2 errors
--- a/test/tools/javac/6758789/T6758789b.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6758789/T6758789b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6758789
  * @summary 6758789: Some method resolution diagnostic should be improved
  * @author Maurizio Cimadamore
--- a/test/tools/javac/6758789/T6758789b.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6758789/T6758789b.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,5 +1,5 @@
-T6758789b.java:39:11: compiler.warn.prob.found.req: (compiler.misc.unchecked.assign), T6758789a.Foo, T6758789a.Foo<X>
-T6758789b.java:39:10: compiler.warn.unchecked.meth.invocation.applied: kindname.method, m, T6758789a.Foo<X>, T6758789a.Foo, kindname.class, T6758789a
+T6758789b.java:16:11: compiler.warn.prob.found.req: (compiler.misc.unchecked.assign), T6758789a.Foo, T6758789a.Foo<X>
+T6758789b.java:16:10: compiler.warn.unchecked.meth.invocation.applied: kindname.method, m, T6758789a.Foo<X>, T6758789a.Foo, kindname.class, T6758789a
 - compiler.err.warnings.and.werror
 1 error
 2 warnings
--- a/test/tools/javac/6840059/T6840059.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6840059/T6840059.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6840059
  * @summary 6758789: Some method resolution diagnostic should be improved
  * @author Maurizio Cimadamore
--- a/test/tools/javac/6840059/T6840059.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/6840059/T6840059.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-T6840059.java:38:9: compiler.err.cant.resolve.location.args: kindname.constructor, T6840059, , java.lang.String, kindname.class, T6840059
-T6840059.java:38:25: compiler.err.cant.resolve.location.args: kindname.constructor, T6840059, , , kindname.class, T6840059
+T6840059.java:15:9: compiler.err.cant.resolve.location.args: kindname.constructor, T6840059, , java.lang.String, kindname.class, T6840059
+T6840059.java:15:25: compiler.err.cant.resolve.location.args: kindname.constructor, T6840059, , , kindname.class, T6840059
 2 errors
--- a/test/tools/javac/ClassPathTest/ClassPathTest.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/ClassPathTest/ClassPathTest.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -56,14 +56,10 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  SunOS | Linux )
-    NULL=/dev/null
-    PS=":"
+  SunOS | Linux | CYGWIN* )
     FS="/"
     ;;
   Windows* )
-    NULL=NUL
-    PS=";"
     FS="\\"
     ;;
   * )
--- a/test/tools/javac/Diagnostics/6722234/T6722234a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6722234
  * @summary javac diagnostics need better integration with the type-system
  * @author  mcimadamore
--- a/test/tools/javac/Diagnostics/6722234/T6722234a_1.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234a_1.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6722234a.java:35:9: compiler.err.cant.apply.symbol: kindname.method, m, compiler.misc.type.var: T, 1, compiler.misc.type.var: T, 2, kindname.class, T6722234a<compiler.misc.type.var: T, 1>, null
+T6722234a.java:12:9: compiler.err.cant.apply.symbol: kindname.method, m, compiler.misc.type.var: T, 1, compiler.misc.type.var: T, 2, kindname.class, T6722234a<compiler.misc.type.var: T, 1>, null
 1 error
--- a/test/tools/javac/Diagnostics/6722234/T6722234a_2.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234a_2.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-T6722234a.java:35:9: compiler.err.cant.apply.symbol: kindname.method, m, compiler.misc.type.var: T, 1, compiler.misc.type.var: T, 2, kindname.class, T6722234a<compiler.misc.type.var: T, 1>, null
+T6722234a.java:12:9: compiler.err.cant.apply.symbol: kindname.method, m, compiler.misc.type.var: T, 1, compiler.misc.type.var: T, 2, kindname.class, T6722234a<compiler.misc.type.var: T, 1>, null
 - compiler.misc.where.description.typevar.1: compiler.misc.type.var: T, 1,compiler.misc.type.var: T, 2,{(compiler.misc.where.typevar: compiler.misc.type.var: T, 1, java.lang.String, kindname.class, T6722234a),(compiler.misc.where.typevar: compiler.misc.type.var: T, 2, java.lang.Integer, kindname.method, <compiler.misc.type.var: T, 2>test(compiler.misc.type.var: T, 2))}
 1 error
--- a/test/tools/javac/Diagnostics/6722234/T6722234b.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6722234
  * @summary javac diagnostics need better integration with the type-system
  * @author  mcimadamore
--- a/test/tools/javac/Diagnostics/6722234/T6722234b_1.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234b_1.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6722234b.java:39:9: compiler.err.cant.apply.symbol: kindname.method, m, List<T>,List<T>, List<compiler.misc.type.captureof: 1, ? extends T6722234b>,List<compiler.misc.type.captureof: 2, ? extends T6722234b>, kindname.class, T6722234b, null
+T6722234b.java:16:9: compiler.err.cant.apply.symbol: kindname.method, m, List<T>,List<T>, List<compiler.misc.type.captureof: 1, ? extends T6722234b>,List<compiler.misc.type.captureof: 2, ? extends T6722234b>, kindname.class, T6722234b, null
 1 error
--- a/test/tools/javac/Diagnostics/6722234/T6722234b_2.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234b_2.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,4 +1,4 @@
-T6722234b.java:39:9: compiler.err.cant.apply.symbol: kindname.method, m, List<T>,List<T>, List<compiler.misc.captured.type: 1>,List<compiler.misc.captured.type: 2>, kindname.class, T6722234b, null
+T6722234b.java:16:9: compiler.err.cant.apply.symbol: kindname.method, m, List<T>,List<T>, List<compiler.misc.captured.type: 1>,List<compiler.misc.captured.type: 2>, kindname.class, T6722234b, null
 - compiler.misc.where.description.typevar: T,{(compiler.misc.where.typevar: T, Object, kindname.method, <T>m(List<T>,List<T>))}
 - compiler.misc.where.description.captured.1: compiler.misc.captured.type: 1,compiler.misc.captured.type: 2,{(compiler.misc.where.captured.1: compiler.misc.captured.type: 1, T6722234b, compiler.misc.type.null, ? extends T6722234b),(compiler.misc.where.captured.1: compiler.misc.captured.type: 2, T6722234b, compiler.misc.type.null, ? extends T6722234b)}
 1 error
--- a/test/tools/javac/Diagnostics/6722234/T6722234c.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234c.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6722234
  * @summary javac diagnostics need better integration with the type-system
  * @author  mcimadamore
--- a/test/tools/javac/Diagnostics/6722234/T6722234c.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234c.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6722234c.java:37:9: compiler.err.cant.apply.symbol: kindname.method, m, T6722234c.String, java.lang.String, kindname.class, T6722234c, null
+T6722234c.java:14:9: compiler.err.cant.apply.symbol: kindname.method, m, T6722234c.String, java.lang.String, kindname.class, T6722234c, null
 1 error
--- a/test/tools/javac/Diagnostics/6722234/T6722234d.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234d.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6722234
  * @summary javac diagnostics need better integration with the type-system
  * @author  mcimadamore
--- a/test/tools/javac/Diagnostics/6722234/T6722234d_1.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234d_1.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-T6722234d.java:41:20: compiler.err.prob.found.req: (compiler.misc.incompatible.types), compiler.misc.intersection.type: 1, T6722234d.A
+T6722234d.java:18:20: compiler.err.prob.found.req: (compiler.misc.incompatible.types), compiler.misc.intersection.type: 1, T6722234d.A
 - compiler.misc.where.description.intersection: compiler.misc.intersection.type: 1,{(compiler.misc.where.intersection: compiler.misc.intersection.type: 1, java.lang.Object,T6722234d.I1,T6722234d.I2)}
 1 error
--- a/test/tools/javac/Diagnostics/6722234/T6722234d_2.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6722234/T6722234d_2.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-T6722234d.java:41:20: compiler.err.prob.found.req: (compiler.misc.incompatible.types), compiler.misc.intersection.type: 1, T6722234d.A
+T6722234d.java:18:20: compiler.err.prob.found.req: (compiler.misc.incompatible.types), compiler.misc.intersection.type: 1, T6722234d.A
 - compiler.misc.where.description.intersection: compiler.misc.intersection.type: 1,{(compiler.misc.where.intersection: compiler.misc.intersection.type: 1, Object,I1,I2)}
 1 error
--- a/test/tools/javac/Diagnostics/6769027/tester.properties	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6769027/tester.properties	Mon Sep 21 17:11:48 2009 +0100
@@ -3,11 +3,11 @@
 
 compiler.err.double=\
     This is a test error message.\n\
-	This is another line of the above error message {0}
+        This is another line of the above error message {0}
 
 compiler.misc.single=\
     This is a test subdiagnostic {0}
 
 compiler.misc.double=\
     This is a test subdiagnostic.\n\
-	This is another line of the above subdiagnostic {0}
+        This is another line of the above subdiagnostic {0}
--- a/test/tools/javac/Diagnostics/6799605/T6799605.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6799605/T6799605.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6799605
  * @summary Basic/Raw formatters should use type/symbol printer instead of toString()
  * @author  mcimadamore
--- a/test/tools/javac/Diagnostics/6799605/T6799605.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6799605/T6799605.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,4 +1,4 @@
-T6799605.java:40:9: compiler.err.cant.resolve.location.args: kindname.method, m, , T6799605<compiler.misc.type.captureof: 1, ?>, kindname.class, T6799605<X>
-T6799605.java:41:9: compiler.err.cant.resolve.location.args: kindname.method, m, , T6799605<compiler.misc.type.captureof: 1, ?>,T6799605<compiler.misc.type.captureof: 2, ?>, kindname.class, T6799605<X>
-T6799605.java:42:9: compiler.err.cant.resolve.location.args: kindname.method, m, , T6799605<compiler.misc.type.captureof: 1, ?>,T6799605<compiler.misc.type.captureof: 2, ?>,T6799605<compiler.misc.type.captureof: 3, ?>, kindname.class, T6799605<X>
+T6799605.java:17:9: compiler.err.cant.resolve.location.args: kindname.method, m, , T6799605<compiler.misc.type.captureof: 1, ?>, kindname.class, T6799605<X>
+T6799605.java:18:9: compiler.err.cant.resolve.location.args: kindname.method, m, , T6799605<compiler.misc.type.captureof: 1, ?>,T6799605<compiler.misc.type.captureof: 2, ?>, kindname.class, T6799605<X>
+T6799605.java:19:9: compiler.err.cant.resolve.location.args: kindname.method, m, , T6799605<compiler.misc.type.captureof: 1, ?>,T6799605<compiler.misc.type.captureof: 2, ?>,T6799605<compiler.misc.type.captureof: 3, ?>, kindname.class, T6799605<X>
 3 errors
--- a/test/tools/javac/Diagnostics/6860795/T6860795.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6860795/T6860795.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6860795
  * @summary NullPointerException when compiling a negative java source
  * @author  mcimadamore
--- a/test/tools/javac/Diagnostics/6860795/T6860795.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6860795/T6860795.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6860795.java:33:27: compiler.err.already.defined: x, foo
+T6860795.java:10:27: compiler.err.already.defined: x, foo
 1 error
--- a/test/tools/javac/Diagnostics/6862608/T6862608a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6862608/T6862608a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6862608
  * @summary rich diagnostic sometimes contain wrong type variable numbering
  * @author  mcimadamore
--- a/test/tools/javac/Diagnostics/6862608/T6862608a.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6862608/T6862608a.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-T6862608a.java:42:41: compiler.err.invalid.inferred.types: T, (compiler.misc.inferred.do.not.conform.to.params: java.lang.Iterable<? extends java.util.Comparator<? super java.lang.String>>, java.util.List<java.util.Comparator<?>>)
+T6862608a.java:19:41: compiler.err.invalid.inferred.types: T, (compiler.misc.inferred.do.not.conform.to.params: java.lang.Iterable<? extends java.util.Comparator<? super java.lang.String>>, java.util.List<java.util.Comparator<?>>)
 - compiler.misc.where.description.typevar: T,{(compiler.misc.where.typevar: T, java.lang.Object, kindname.method, <T>compound(java.lang.Iterable<? extends java.util.Comparator<? super T>>))}
 1 error
--- a/test/tools/javac/Diagnostics/6862608/T6862608b.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6862608/T6862608b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6862608
  * @summary rich diagnostic sometimes contain wrong type variable numbering
  * @author  mcimadamore
--- a/test/tools/javac/Diagnostics/6862608/T6862608b.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6862608/T6862608b.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-T6862608b.java:34:7: compiler.err.cant.apply.symbol: kindname.method, test, compiler.misc.type.var: T, 1, compiler.misc.type.var: T, 2, kindname.class, T66862608b<compiler.misc.type.var: T, 1,compiler.misc.type.var: S, 2>, null
+T6862608b.java:11:7: compiler.err.cant.apply.symbol: kindname.method, test, compiler.misc.type.var: T, 1, compiler.misc.type.var: T, 2, kindname.class, T66862608b<compiler.misc.type.var: T, 1,compiler.misc.type.var: S, 2>, null
 - compiler.misc.where.description.typevar.1: compiler.misc.type.var: T, 1,compiler.misc.type.var: T, 2,compiler.misc.type.var: S, 1,compiler.misc.type.var: S, 2,{(compiler.misc.where.typevar: compiler.misc.type.var: T, 1, java.lang.String, kindname.class, T66862608b),(compiler.misc.where.typevar: compiler.misc.type.var: T, 2, compiler.misc.type.var: S, 1, kindname.method, <compiler.misc.type.var: S, 1,compiler.misc.type.var: T, 2>foo(compiler.misc.type.var: T, 2)),(compiler.misc.where.typevar: compiler.misc.type.var: S, 1, java.lang.Object, kindname.method, <compiler.misc.type.var: S, 1,compiler.misc.type.var: T, 2>foo(compiler.misc.type.var: T, 2)),(compiler.misc.where.typevar: compiler.misc.type.var: S, 2, java.lang.Object, kindname.class, T66862608b)}
 1 error
--- a/test/tools/javac/Diagnostics/6864382/T6864382.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6864382/T6864382.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6864382
  * @summary NullPointerException when compiling a negative java source
  * @author  mcimadamore
--- a/test/tools/javac/Diagnostics/6864382/T6864382.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/Diagnostics/6864382/T6864382.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6864382.java:32:27: compiler.err.type.found.req: (compiler.misc.type.parameter: T), (compiler.misc.type.req.class)
+T6864382.java:9:27: compiler.err.type.found.req: (compiler.misc.type.parameter: T), (compiler.misc.type.req.class)
 1 error
--- a/test/tools/javac/ExtDirs/ExtDirs.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/ExtDirs/ExtDirs.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -55,12 +55,14 @@
 OS=`uname -s`
 case "$OS" in
   SunOS | Linux )
-    NULL=/dev/null
     PS=":"
     FS="/"
     ;;
+  CYGWIN* )
+    PS=";" # native PS, not Cygwin PS
+    FS="/"
+    ;;
   Windows* )
-    NULL=NUL
     PS=";"
     FS="\\"
     ;;
--- a/test/tools/javac/MissingInclude.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/MissingInclude.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -47,14 +47,10 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  SunOS | Linux )
-    NULL=/dev/null
-    PS=":"
+  SunOS | Linux | CYGWIN* )
     FS="/"
     ;;
   Windows* )
-    NULL=NUL
-    PS=";"
     FS="\\"
     ;;
   * )
--- a/test/tools/javac/OverrideChecks/6199153/T6199153.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/OverrideChecks/6199153/T6199153.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6199153
  * @summary Generic throws and overriding
  * @author  mcimadamore
--- a/test/tools/javac/OverrideChecks/6199153/T6199153.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/OverrideChecks/6199153/T6199153.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,4 +1,4 @@
-T6199153.java:41:21: compiler.warn.override.unchecked.thrown: (compiler.misc.cant.override: m(), T6199153.B, <T>m(), T6199153.A), java.io.IOException
+T6199153.java:18:21: compiler.warn.override.unchecked.thrown: (compiler.misc.cant.override: m(), T6199153.B, <T>m(), T6199153.A), java.io.IOException
 - compiler.err.warnings.and.werror
 1 error
 1 warning
--- a/test/tools/javac/OverrideChecks/6400189/T6400189a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/OverrideChecks/6400189/T6400189a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6400189
  * @summary raw types and inference
  * @author  mcimadamore
--- a/test/tools/javac/OverrideChecks/6400189/T6400189a.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/OverrideChecks/6400189/T6400189a.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,4 +1,4 @@
-T6400189a.java:37:35: compiler.warn.unchecked.call.mbr.of.raw.type: <T>getAnnotation(java.lang.Class<T>), java.lang.reflect.Constructor
-T6400189a.java:37:35: compiler.err.prob.found.req: (compiler.misc.incompatible.types), java.lang.annotation.Annotation, java.lang.annotation.Documented
+T6400189a.java:14:35: compiler.warn.unchecked.call.mbr.of.raw.type: <T>getAnnotation(java.lang.Class<T>), java.lang.reflect.Constructor
+T6400189a.java:14:35: compiler.err.prob.found.req: (compiler.misc.incompatible.types), java.lang.annotation.Annotation, java.lang.annotation.Documented
 1 error
 1 warning
--- a/test/tools/javac/OverrideChecks/6400189/T6400189b.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/OverrideChecks/6400189/T6400189b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6400189
  * @summary raw types and inference
  * @author  mcimadamore
--- a/test/tools/javac/OverrideChecks/6400189/T6400189b.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/OverrideChecks/6400189/T6400189b.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,4 +1,4 @@
-T6400189b.java:47:24: compiler.warn.unchecked.call.mbr.of.raw.type: <T>m(T6400189b<T>), T6400189b.B
-T6400189b.java:47:24: compiler.err.prob.found.req: (compiler.misc.incompatible.types), java.lang.Object, java.lang.Integer
+T6400189b.java:24:24: compiler.warn.unchecked.call.mbr.of.raw.type: <T>m(T6400189b<T>), T6400189b.B
+T6400189b.java:24:24: compiler.err.prob.found.req: (compiler.misc.incompatible.types), java.lang.Object, java.lang.Integer
 1 error
 1 warning
--- a/test/tools/javac/ProtectedInnerClass/ProtectedInnerClass.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/ProtectedInnerClass/ProtectedInnerClass.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -53,12 +53,14 @@
 OS=`uname -s`
 case "$OS" in
   SunOS | Linux )
-    NULL=/dev/null
     PS=":"
     FS="/"
     ;;
+  CYGWIN* ) 
+    PS=";" # native PS, not Cygwin PS
+    FS="/"
+    ;;
   Windows* )
-    NULL=NUL
     PS=";"
     FS="\\"
     ;;
--- a/test/tools/javac/T5090006/compiler.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/T5090006/compiler.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -47,14 +47,10 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  SunOS | Linux )
-    NULL=/dev/null
-    PS=":"
+  SunOS | Linux | CYGWIN* )
     FS="/"
     ;;
   Windows* )
-    NULL=NUL
-    PS=";"
     FS="\\"
     ;;
   * )
--- a/test/tools/javac/api/6440333/T6440333.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/api/6440333/T6440333.java	Mon Sep 21 17:11:48 2009 +0100
@@ -33,6 +33,7 @@
 
 import java.io.File;
 import java.io.IOException;
+import java.net.URI;
 import javax.tools.JavaFileObject;
 
 public class T6440333 extends ToolTester {
@@ -40,10 +41,10 @@
         File path = test_src.getCanonicalFile();
         File src = new File(new File(path, "."), "T6440333.java");
         JavaFileObject fo = fm.getJavaFileObjects(src).iterator().next();
-        String expect = src.getCanonicalFile().getPath().replace(File.separatorChar, '/');
+        URI expect = src.getCanonicalFile().toURI();
         System.err.println("Expect " + expect);
-        System.err.println("Got: " +  fo.toUri().getPath());
-        if (!expect.equals(fo.toUri().getPath())) {
+        System.err.println("Found  " + fo.toUri());
+        if (!expect.equals(fo.toUri())) {
             throw new AssertionError();
         }
     }
--- a/test/tools/javac/api/Sibling.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/api/Sibling.java	Mon Sep 21 17:11:48 2009 +0100
@@ -47,10 +47,9 @@
                                                             "foo.bar.baz.Test",
                                                             CLASS,
                                                             sibling);
-        String name =
-            new File("Test.class").getAbsolutePath().replace(File.separatorChar, '/');
-        if (!classFile.toUri().getPath().equals(name))
-            throw new AssertionError("Expected " + name + ", got " +
-                                     classFile.toUri().getPath());
+        File file = new File("Test.class").getAbsoluteFile();
+        if (!classFile.toUri().equals(file.toURI()))
+            throw new AssertionError("Expected " + file.toURI() + ", got " +
+                                     classFile.toUri());
     }
 }
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/api/T6483788.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,70 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug 6483788
+ * @summary DefaultFileManager.ZipFileObject.toUri() fails to escape space characters
+ */
+
+import java.io.*;
+import java.net.*;
+import java.util.Collections;
+import java.util.jar.*;
+import java.util.zip.*;
+import javax.tools.*;
+
+public class T6483788 {
+    public static void main(String[] args) throws Exception {
+        new T6483788().run();
+    }
+
+    void run() throws Exception {
+        File jar = createJar();
+        JavaCompiler c = ToolProvider.getSystemJavaCompiler();
+        StandardJavaFileManager fm = c.getStandardFileManager(null, null, null);
+        fm.setLocation(StandardLocation.CLASS_PATH, Collections.singleton(jar));
+        JavaFileObject fo = fm.getJavaFileForInput(StandardLocation.CLASS_PATH, "dummy", JavaFileObject.Kind.CLASS);
+        System.err.println("file: " + fo);
+        URI uri = fo.toUri();
+        System.err.println("uri: " + uri);
+        if (uri.toString().contains(" "))
+            throw new Exception("unexpected space character found");
+    }
+
+    File createJar() throws IOException {
+        byte[] dummy_data = new byte[10];
+        File f = new File("a b.jar");
+        OutputStream out = new FileOutputStream(f);
+        try {
+            JarOutputStream jar = new JarOutputStream(out);
+            jar.putNextEntry(new ZipEntry("dummy.class"));
+            jar.write(dummy_data);
+            jar.close();
+        } finally {
+            out.close();
+        }
+        return f;
+    }
+}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/api/T6501502.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,72 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug 6501502 6877206 6483788
+ * @summary JSR 199: FileObject.toUri should return file:///c:/ or file:/c:/ not file://c:/
+ */
+
+import java.io.*;
+import java.net.URI;
+import javax.tools.*;
+
+public class T6501502 {
+    public static void main(String... args) throws Exception {
+        new T6501502().run();
+    }
+
+    // The spec for java.io.File includes the following:
+    //      For a given abstract pathname f it is guaranteed that
+    //          new File( f.toURI()).equals( f.getAbsoluteFile())
+    // For JavaFileObject we test as follows:
+    //      new File( CONVERT_TO_FILEOBJECT(f).toURI()).equals( f.getAbsoluteFile())
+    // to verify that we get reasonable URIs returned from toURI.
+    // To make this a general test, and not just a Windows test,
+    // we test a number of platform-independent paths.
+    void run() throws Exception {
+        JavaCompiler c = ToolProvider.getSystemJavaCompiler();
+        fm = c.getStandardFileManager(null, null, null);
+        System.err.println(System.getProperties());
+        File tmpDir = new File(System.getProperty("java.io.tmpdir"));
+        File testSrcDir = new File(System.getProperty("test.src"));
+        File testClassesDir = new File(System.getProperty("test.classes"));
+        test(new File("abc.tmp"));
+        test(new File(tmpDir, "bad.file"));
+        test(new File(testSrcDir, "T6501501.java"));
+        test(new File(testClassesDir, "T6501501.class"));
+        test(new File("a b"));
+    }
+
+    void test(File f) throws Exception {
+        System.err.println("test " + f);
+        FileObject fo = fm.getJavaFileObjects(f).iterator().next();
+        URI uri = fo.toUri();
+        System.err.println("FileObject uri: " + uri);
+        if (!new File(uri).equals(f.getAbsoluteFile()))
+            throw new Exception("unexpected URI returned");
+    }
+
+    StandardJavaFileManager fm;
+}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/api/T6877206.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,263 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug 6877206
+ * @summary JavaFileObject.toUri returns bogus URI (win)
+ */
+
+import java.io.*;
+import java.net.*;
+import java.util.*;
+import java.util.jar.*;
+import java.util.zip.*;
+import javax.tools.*;
+
+import com.sun.tools.javac.file.JavacFileManager;
+import com.sun.tools.javac.util.Context;
+import com.sun.tools.javac.util.Options;
+
+// Test URIs returned from JavacFileManager and its support classes.
+// For a variety of file objects, verify the validity of FileObject.toUri()
+// by verifying the URI exists and points to the same contents as the file
+// object itself
+
+public class T6877206 {
+    public static void main(String... args) throws Exception {
+        new T6877206().run();
+    }
+
+    Set<String> foundClasses = new TreeSet<String>();
+    Set<String> foundJars = new TreeSet<String>();
+
+    void run() throws Exception {
+        File rt_jar = findRtJar();
+
+        // names for entries to be created in directories and jar files
+        String[] entries = { "p/A.class", "p/resources/A-1.jpg" };
+
+        // test various combinations of directories and jar files, intended to
+        // cover all sources of URIs within JavacFileManager's support classes
+
+        test(createFileManager(), createDir("dir", entries), "p", entries.length);
+        test(createFileManager(), createDir("a b/dir", entries), "p", entries.length);
+
+        for (boolean useJavaUtilZip: new boolean[] { false, true }) {
+            test(createFileManager(useJavaUtilZip), createJar("jar", entries), "p", entries.length);
+            test(createFileManager(useJavaUtilZip), createJar("jar jar", entries), "p", entries.length);
+
+            for (boolean useSymbolFile: new boolean[] { false, true }) {
+                test(createFileManager(useJavaUtilZip, useSymbolFile), rt_jar, "java.lang.ref", -1);
+            }
+        }
+
+        // Verify that we hit all the impl classes we intended
+        checkCoverage("classes", foundClasses,
+                "RegularFileObject", "SymbolFileObject", "ZipFileIndexFileObject", "ZipFileObject");
+
+        // Verify that we hit the jar files we intended, specifically ct.sym as well as rt.jar
+        checkCoverage("jar files", foundJars,
+                "ct.sym", "jar", "jar jar", "rt.jar");
+    }
+
+    // use a new file manager for each test
+    void test(StandardJavaFileManager fm, File f, String pkg, int expect) throws Exception {
+        JarURLConnection c;
+        System.err.println("Test " + f);
+        try {
+            fm.setLocation(StandardLocation.CLASS_PATH, Collections.singleton(f));
+
+            int count = 0;
+            for (JavaFileObject fo: fm.list(StandardLocation.CLASS_PATH,
+                    pkg, EnumSet.allOf(JavaFileObject.Kind.class), true)) {
+                System.err.println("checking " + fo);
+                // record the file object class name for coverage checks later
+                foundClasses.add(fo.getClass().getSimpleName());
+                testFileObject(fo);
+                count++;
+            }
+
+            if (expect > 0 && count != expect)
+                throw new Exception("wrong number of entries found: "
+                        + count + ", expected " + expect);
+        } finally {
+            fm.close();
+        }
+    }
+
+    void testFileObject(JavaFileObject fo) throws Exception {
+        // test the validity of the result of toUri() by using URLConnection
+        // and comparing the results of reading from the connection with the
+        // result of reading from the file object directly.
+        URI uri = fo.toUri();
+        System.err.println("uri: " + uri);
+
+        URLConnection urlconn = uri.toURL().openConnection();
+        if (urlconn instanceof JarURLConnection) {
+            JarURLConnection jarconn = (JarURLConnection) urlconn;
+            File f = new File(jarconn.getJarFile().getName());
+            // record access to the jar file for coverage checks later
+            foundJars.add(f.getName());
+        }
+
+        try {
+            byte[] uriData = read(urlconn.getInputStream());
+            byte[] foData = read(fo.openInputStream());
+            if (!Arrays.equals(uriData, foData)) {
+                if (uriData.length != foData.length)
+                    throw new Exception("data size differs: uri data "
+                            + uriData.length + " bytes, fo data " + foData.length+ " bytes");
+                for (int i = 0; i < uriData.length; i++) {
+                    if (uriData[i] != foData[i])
+                    throw new Exception("unexpected data returned at offset " + i
+                            + ", uri data " + uriData[i] + ", fo data " + foData[i]);
+                }
+                throw new AssertionError("cannot find difference");
+            }
+        } finally {
+            // In principle, simply closing the result of urlconn.getInputStream()
+            // should have been sufficient. But the internal JarURLConnection
+            // does not close the JarFile in an expeditious manner, thus preventing
+            // jtreg from deleting the jar file before starting the next test.
+            // Therefore we force access to the JarURLConnection to close the
+            // JarFile when necessary.
+            if (urlconn instanceof JarURLConnection) {
+                JarURLConnection jarconn = (JarURLConnection) urlconn;
+                jarconn.getJarFile().close();
+            }
+        }
+    }
+
+    void checkCoverage(String label, Set<String> found, String... expect) throws Exception {
+        Set<String> e = new TreeSet<String>(Arrays.asList(expect));
+        if (!found.equals(e)) {
+            e.removeAll(found);
+            throw new Exception("expected " + label + " not used: " + e);
+        }
+    }
+
+    JavacFileManager createFileManager() {
+        return createFileManager(false, false);
+    }
+
+    JavacFileManager createFileManager(boolean useJavaUtilZip) {
+        return createFileManager(useJavaUtilZip, false);
+    }
+
+    JavacFileManager createFileManager(boolean useJavaUtilZip, boolean useSymbolFile) {
+        // javac should really not be using system properties like this
+        // -- it should really be using (hidden) options -- but until then
+        // take care to leave system properties as we find them, so as not
+        // to adversely affect other tests that might follow.
+        String prev = System.getProperty("useJavaUtilZip");
+        boolean resetProperties = false;
+        try {
+            if (useJavaUtilZip) {
+                System.setProperty("useJavaUtilZip", "true");
+                resetProperties = true;
+            } else if (System.getProperty("useJavaUtilZip") != null) {
+                System.getProperties().remove("useJavaUtilZip");
+                resetProperties = true;
+            }
+
+            Context c = new Context();
+            if (!useSymbolFile) {
+                Options options = Options.instance(c);
+                options.put("ignore.symbol.file", "true");
+            }
+
+            return new JavacFileManager(c, false, null);
+        } finally {
+            if (resetProperties) {
+                if (prev == null) {
+                    System.getProperties().remove("useJavaUtilZip");
+                } else {
+                    System.setProperty("useJavaUtilZip", prev);
+                }
+            }
+        }
+    }
+
+    File createDir(String name, String... entries) throws Exception {
+        File dir = new File(name);
+        if (!dir.mkdirs())
+            throw new Exception("cannot create directories " + dir);
+        for (String e: entries) {
+            writeFile(new File(dir, e), e);
+        }
+        return dir;
+    }
+
+    File createJar(String name, String... entries) throws IOException {
+        File jar = new File(name);
+        OutputStream out = new FileOutputStream(jar);
+        try {
+            JarOutputStream jos = new JarOutputStream(out);
+            for (String e: entries) {
+                jos.putNextEntry(new ZipEntry(e));
+                jos.write(e.getBytes());
+            }
+            jos.close();
+        } finally {
+            out.close();
+        }
+        return jar;
+    }
+
+    File findRtJar() throws Exception {
+        File java_home = new File(System.getProperty("java.home"));
+        if (java_home.getName().equals("jre"))
+            java_home = java_home.getParentFile();
+        File rt_jar = new File(new File(new File(java_home, "jre"), "lib"), "rt.jar");
+        if (!rt_jar.exists())
+            throw new Exception("can't find rt.jar");
+        return rt_jar;
+    }
+
+    byte[] read(InputStream in) throws IOException {
+        byte[] data = new byte[1024];
+        int offset = 0;
+        try {
+            int n;
+            while ((n = in.read(data, offset, data.length - offset)) != -1) {
+                offset += n;
+                if (offset == data.length)
+                    data = Arrays.copyOf(data, 2 * data.length);
+            }
+        } finally {
+            in.close();
+        }
+        return Arrays.copyOf(data, offset);
+    }
+
+    void writeFile(File f, String s) throws IOException {
+        f.getParentFile().mkdirs();
+        FileWriter out = new FileWriter(f);
+        try {
+            out.write(s);
+        } finally {
+            out.close();
+        }
+    }
+}
--- a/test/tools/javac/cast/6467183/T6467183a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/cast/6467183/T6467183a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @author mcimadamore
  * @bug     6467183
  * @summary
--- a/test/tools/javac/cast/6467183/T6467183a.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/cast/6467183/T6467183a.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,6 +1,6 @@
-T6467183a.java:39:26: compiler.warn.prob.found.req: (compiler.misc.unchecked.cast.to.type), T6467183a<T>.B, T6467183a<T>.A<T>
-T6467183a.java:47:41: compiler.warn.prob.found.req: (compiler.misc.unchecked.cast.to.type), T6467183a<T>.A<java.lang.Integer>, T6467183a<T>.C<? extends java.lang.Number>
-T6467183a.java:51:42: compiler.warn.prob.found.req: (compiler.misc.unchecked.cast.to.type), T6467183a<T>.A<java.lang.Integer>, T6467183a<T>.C<? extends java.lang.Integer>
+T6467183a.java:16:26: compiler.warn.prob.found.req: (compiler.misc.unchecked.cast.to.type), T6467183a<T>.B, T6467183a<T>.A<T>
+T6467183a.java:24:41: compiler.warn.prob.found.req: (compiler.misc.unchecked.cast.to.type), T6467183a<T>.A<java.lang.Integer>, T6467183a<T>.C<? extends java.lang.Number>
+T6467183a.java:28:42: compiler.warn.prob.found.req: (compiler.misc.unchecked.cast.to.type), T6467183a<T>.A<java.lang.Integer>, T6467183a<T>.C<? extends java.lang.Integer>
 - compiler.err.warnings.and.werror
 1 error
 3 warnings
--- a/test/tools/javac/cast/6557182/T6557182.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/cast/6557182/T6557182.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @author Maurizio Cimadamore
  * @bug     6557182
  * @summary  Unchecked warning *and* inconvertible types
--- a/test/tools/javac/cast/6557182/T6557182.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/cast/6557182/T6557182.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,4 +1,4 @@
-T6557182.java:35:56: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T, java.lang.Comparable<java.lang.Integer>
-T6557182.java:39:56: compiler.warn.prob.found.req: (compiler.misc.unchecked.cast.to.type), T, java.lang.Comparable<java.lang.Integer>
+T6557182.java:12:56: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T, java.lang.Comparable<java.lang.Integer>
+T6557182.java:16:56: compiler.warn.prob.found.req: (compiler.misc.unchecked.cast.to.type), T, java.lang.Comparable<java.lang.Integer>
 1 error
 1 warning
--- a/test/tools/javac/cast/6665356/T6665356.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/cast/6665356/T6665356.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008-2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @author Maurizio Cimadamore
  * @bug     6665356
  * @summary Cast not allowed when both qualifying type and inner class are parameterized
@@ -77,4 +54,4 @@
     void cast11(Outer<Integer>.Inner<Long> p) {
         Object o = (Outer<Integer>.Inner<? super String>)p;
     }
-}
\ No newline at end of file
+}
--- a/test/tools/javac/cast/6665356/T6665356.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/cast/6665356/T6665356.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,8 +1,8 @@
-T6665356.java:54:55: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<? super java.lang.Number>.Inner<java.lang.Long>
-T6665356.java:58:58: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<java.lang.Integer>.Inner<? super java.lang.Number>
-T6665356.java:62:65: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<? super java.lang.Number>.Inner<? super java.lang.Number>
-T6665356.java:66:57: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<? extends java.lang.String>.Inner<java.lang.Long>
-T6665356.java:70:60: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<java.lang.Integer>.Inner<? extends java.lang.String>
-T6665356.java:74:55: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<? super java.lang.String>.Inner<java.lang.Long>
-T6665356.java:78:58: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<java.lang.Integer>.Inner<? super java.lang.String>
-7 errors
\ No newline at end of file
+T6665356.java:31:55: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<? super java.lang.Number>.Inner<java.lang.Long>
+T6665356.java:35:58: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<java.lang.Integer>.Inner<? super java.lang.Number>
+T6665356.java:39:65: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<? super java.lang.Number>.Inner<? super java.lang.Number>
+T6665356.java:43:57: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<? extends java.lang.String>.Inner<java.lang.Long>
+T6665356.java:47:60: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<java.lang.Integer>.Inner<? extends java.lang.String>
+T6665356.java:51:55: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<? super java.lang.String>.Inner<java.lang.Long>
+T6665356.java:55:58: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6665356.Outer<java.lang.Integer>.Inner<java.lang.Long>, T6665356.Outer<java.lang.Integer>.Inner<? super java.lang.String>
+7 errors
--- a/test/tools/javac/cast/6795580/T6795580.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/cast/6795580/T6795580.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @author Maurizio Cimadamore
  * @bug     6795580
  * @summary parser confused by square brackets in qualified generic cast
@@ -77,4 +54,4 @@
     void cast11(Outer<Integer>.Inner<Long>[] p) {
         Object o = (Outer<Integer>.Inner<? super String>[])p;
     }
-}
\ No newline at end of file
+}
--- a/test/tools/javac/cast/6795580/T6795580.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/cast/6795580/T6795580.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,8 +1,8 @@
-T6795580.java:54:57: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<? super java.lang.Number>.Inner<java.lang.Long>[]
-T6795580.java:58:60: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<java.lang.Integer>.Inner<? super java.lang.Number>[]
-T6795580.java:62:67: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<? super java.lang.Number>.Inner<? super java.lang.Number>[]
-T6795580.java:66:59: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<? extends java.lang.String>.Inner<java.lang.Long>[]
-T6795580.java:70:62: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<java.lang.Integer>.Inner<? extends java.lang.String>[]
-T6795580.java:74:57: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<? super java.lang.String>.Inner<java.lang.Long>[]
-T6795580.java:78:60: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<java.lang.Integer>.Inner<? super java.lang.String>[]
+T6795580.java:31:57: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<? super java.lang.Number>.Inner<java.lang.Long>[]
+T6795580.java:35:60: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<java.lang.Integer>.Inner<? super java.lang.Number>[]
+T6795580.java:39:67: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<? super java.lang.Number>.Inner<? super java.lang.Number>[]
+T6795580.java:43:59: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<? extends java.lang.String>.Inner<java.lang.Long>[]
+T6795580.java:47:62: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<java.lang.Integer>.Inner<? extends java.lang.String>[]
+T6795580.java:51:57: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<? super java.lang.String>.Inner<java.lang.Long>[]
+T6795580.java:55:60: compiler.err.prob.found.req: (compiler.misc.inconvertible.types), T6795580.Outer<java.lang.Integer>.Inner<java.lang.Long>[], T6795580.Outer<java.lang.Integer>.Inner<? super java.lang.String>[]
 7 errors
--- a/test/tools/javac/code/ArrayClone.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/code/ArrayClone.java	Mon Sep 21 17:11:48 2009 +0100
@@ -47,7 +47,7 @@
         String out = sw.toString();
         System.out.println(out);
 
-        for (String line: out.split("\n")) {
+        for (String line: out.split("(\\n|\\r\\n?)")) {
             String match = "[ \t]+[0-9]+:[ \t]+invokevirtual[ \t]+#[0-9]+[ \t]+// Method \"\\[Ljava/lang/String;\".clone:\\(\\)Ljava/lang/Object;";
             if (line.matches(match))
                 return;
--- a/test/tools/javac/constDebug/ConstDebug.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/constDebug/ConstDebug.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -48,12 +48,14 @@
 OS=`uname -s`
 case "$OS" in
   SunOS | Linux )
-    NULL=/dev/null
     PS=":"
     FS="/"
     ;;
+  CYGWIN* )
+    PS=";" # Platform PS, not Cygwin PS
+    FS="/"
+    ;;
   Windows* )
-    NULL=NUL
     PS=";"
     FS="\\"
     ;;
@@ -69,7 +71,7 @@
 "${TESTJAVA}${FS}bin${FS}javac" ${TESTTOOLVMOPTS} -g -d . -classpath .${PS}${TESTSRC} $1.java 2> ${TMP1}
 result=$?
 if [ $result -ne 0 ]; then exit $result; fi
-if strings $1.class | grep clinit; then
+if "${TESTJAVA}${FS}bin${FS}javap" $1.class | grep clinit; then
   echo "Failed"
   exit 1;
 else
--- a/test/tools/javac/fatalErrors/NoJavaLang.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/fatalErrors/NoJavaLang.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -49,13 +49,13 @@
 OS=`uname -s`
 case "$OS" in
   SunOS | Linux )
-    NULL=/dev/null
-    PS=":"
     FS="/"
     ;;
+  CYGWIN* )
+    FS="/"
+    DIFFOPTS="--strip-trailing-cr"
+    ;;
   Windows* )
-    NULL=NUL
-    PS=";"
     FS="\\"
     ;;
   * )
@@ -98,7 +98,7 @@
 
 # expected message
 cat "${TMP1}"
-diff -c "${TESTSRC}${FS}NoJavaLang.out" "${TMP1}"
+diff ${DIFFOPTS} -c "${TESTSRC}${FS}NoJavaLang.out" "${TMP1}"
 result=$?
 rm "${TMP1}"
 
--- a/test/tools/javac/generics/5009937/T5009937.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/5009937/T5009937.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 5009937
  * @summary hiding versus generics versus binary compatibility
  * @author Maurizio Cimadamore
--- a/test/tools/javac/generics/5009937/T5009937.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/5009937/T5009937.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T5009937.java:39:21: compiler.err.name.clash.same.erasure.no.override: m(T5009937<java.lang.Integer>), T5009937.B, m(T5009937<java.lang.String>), T5009937.A
+T5009937.java:16:21: compiler.err.name.clash.same.erasure.no.override: m(T5009937<java.lang.Integer>), T5009937.B, m(T5009937<java.lang.String>), T5009937.A
 1 error
--- a/test/tools/javac/generics/6182950/T6182950a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6182950/T6182950a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6182950
  * @summary methods clash algorithm should not depend on return type
  * @author  mcimadamore
--- a/test/tools/javac/generics/6182950/T6182950a.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6182950/T6182950a.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6182950a.java:35:12: compiler.err.name.clash.same.erasure: m(java.util.List<java.lang.Integer>), m(java.util.List<java.lang.String>)
+T6182950a.java:12:12: compiler.err.name.clash.same.erasure: m(java.util.List<java.lang.Integer>), m(java.util.List<java.lang.String>)
 1 error
--- a/test/tools/javac/generics/6182950/T6182950b.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6182950/T6182950b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6182950
  * @summary methods clash algorithm should not depend on return type
  * @author  mcimadamore
--- a/test/tools/javac/generics/6182950/T6182950b.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6182950/T6182950b.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6182950b.java:38:16: compiler.err.name.clash.same.erasure.no.override: m(java.util.List<java.lang.Integer>), T6182950b.B, m(java.util.List<java.lang.String>), T6182950b.A
+T6182950b.java:15:16: compiler.err.name.clash.same.erasure.no.override: m(java.util.List<java.lang.Integer>), T6182950b.B, m(java.util.List<java.lang.String>), T6182950b.A
 1 error
--- a/test/tools/javac/generics/6677785/T6677785.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6677785/T6677785.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6677785
  * @summary REGRESSION: StackOverFlowError with Cyclic Class level Type Parameters when used in constructors
  * @author Maurizio Cimadamore
--- a/test/tools/javac/generics/6677785/T6677785.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6677785/T6677785.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6677785.java:31:23: compiler.err.cyclic.inheritance: E
+T6677785.java:8:23: compiler.err.cyclic.inheritance: E
 1 error
--- a/test/tools/javac/generics/6711619/T6711619a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6711619/T6711619a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6711619
  *
  * @summary javac doesn't allow access to protected members in intersection types
@@ -71,4 +48,4 @@
         ta = arg.w.a;
         tb = arg.w.b;
     }
-}
\ No newline at end of file
+}
--- a/test/tools/javac/generics/6711619/T6711619a.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6711619/T6711619a.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,7 +1,7 @@
-T6711619a.java:63:14: compiler.err.cant.resolve.args: kindname.method, a, , 
-T6711619a.java:64:14: compiler.err.cant.resolve.args: kindname.method, b, , 
-T6711619a.java:69:19: compiler.err.report.access: a, private, T6711619a.A
-T6711619a.java:70:19: compiler.err.report.access: b, private, T6711619a.B
-T6711619a.java:71:19: compiler.err.report.access: a, private, T6711619a.A
-T6711619a.java:72:19: compiler.err.report.access: b, private, T6711619a.B
+T6711619a.java:40:14: compiler.err.cant.resolve.args: kindname.method, a, , 
+T6711619a.java:41:14: compiler.err.cant.resolve.args: kindname.method, b, , 
+T6711619a.java:46:19: compiler.err.report.access: a, private, T6711619a.A
+T6711619a.java:47:19: compiler.err.report.access: b, private, T6711619a.B
+T6711619a.java:48:19: compiler.err.report.access: a, private, T6711619a.A
+T6711619a.java:49:19: compiler.err.report.access: b, private, T6711619a.B
 6 errors
--- a/test/tools/javac/generics/6711619/T6711619b.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6711619/T6711619b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6711619
  *
  * @summary javac doesn't allow access to protected members in intersection types
@@ -61,4 +38,4 @@
              return E.i;
          }
     }
-}
\ No newline at end of file
+}
--- a/test/tools/javac/generics/6711619/T6711619b.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6711619/T6711619b.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,5 +1,5 @@
-T6711619b.java:39:22: compiler.err.report.access: i, private, T6711619b.X1
-T6711619b.java:46:22: compiler.err.report.access: i, private, T6711619b.X2
-T6711619b.java:54:22: compiler.err.report.access: i, private, T6711619b.X3
-T6711619b.java:61:22: compiler.err.report.access: i, private, T6711619b.X4
+T6711619b.java:16:22: compiler.err.report.access: i, private, T6711619b.X1
+T6711619b.java:23:22: compiler.err.report.access: i, private, T6711619b.X2
+T6711619b.java:31:22: compiler.err.report.access: i, private, T6711619b.X3
+T6711619b.java:38:22: compiler.err.report.access: i, private, T6711619b.X4
 4 errors
--- a/test/tools/javac/generics/6723444/T6723444.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6723444/T6723444.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008-2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6723444
  *
  * @summary javac fails to substitute type variables into a constructor's throws clause
--- a/test/tools/javac/generics/6723444/T6723444.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/6723444/T6723444.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,13 +1,13 @@
-T6723444.java:65:9: compiler.err.unreported.exception.need.to.catch.or.throw: X2
-T6723444.java:66:9: compiler.err.unreported.exception.need.to.catch.or.throw: X2
-T6723444.java:68:32: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-T6723444.java:69:17: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-T6723444.java:71:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-T6723444.java:72:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-T6723444.java:73:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-T6723444.java:74:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-T6723444.java:75:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-T6723444.java:76:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-T6723444.java:77:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-T6723444.java:78:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
-12 errors
\ No newline at end of file
+T6723444.java:42:9: compiler.err.unreported.exception.need.to.catch.or.throw: X2
+T6723444.java:43:9: compiler.err.unreported.exception.need.to.catch.or.throw: X2
+T6723444.java:45:32: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+T6723444.java:46:17: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+T6723444.java:48:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+T6723444.java:49:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+T6723444.java:50:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+T6723444.java:51:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+T6723444.java:52:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+T6723444.java:53:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+T6723444.java:54:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+T6723444.java:55:9: compiler.err.unreported.exception.need.to.catch.or.throw: java.lang.Throwable
+12 errors
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg01.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,38 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 6840638
+ *
+ * @summary  Project Coin: Improved Type Inference for Generic Instance Creation (aka 'diamond')
+ * @author mcimadamore
+ * @compile/fail/ref=Neg01.out Neg01.java -source 1.7 -XDrawDiagnostics
+ *
+ */
+
+class Neg01<X extends Number> {
+
+    Neg01(X x) {}
+
+    <Z> Neg01(X x, Z z) {}
+
+    void test() {
+        Neg01<String> n1 = new Neg01<>(""); //new Foo<Integer> created
+        Neg01<? extends String> n2 = new Neg01<>(""); //new Foo<Integer> created
+        Neg01<?> n3 = new Neg01<>(""); //new Foo<Object> created
+        Neg01<? super String> n4 = new Neg01<>(""); //new Foo<Object> created
+
+        Neg01<String> n5 = new Neg01<>(""){}; //new Foo<Integer> created
+        Neg01<? extends String> n6 = new Neg01<>(""){}; //new Foo<Integer> created
+        Neg01<?> n7 = new Neg01<>(""){}; //new Foo<Object> created
+        Neg01<? super String> n8 = new Neg01<>(""){}; //new Foo<Object> created
+
+        Neg01<String> n9 = new Neg01<>("", ""); //new Foo<Integer> created
+        Neg01<? extends String> n10 = new Neg01<>("", ""); //new Foo<Integer> created
+        Neg01<?> n11 = new Neg01<>("", ""); //new Foo<Object> created
+        Foo<? super String> n12 = new Neg01<>("", ""); //new Foo<Object> created
+
+        Neg01<String> n13 = new Neg01<>("", ""){}; //new Foo<Integer> created
+        Neg01<? extends String> n14 = new Neg01<>("", ""){}; //new Foo<Integer> created
+        Neg01<?> n15 = new Neg01<>("", ""){}; //new Foo<Object> created
+        Neg01<? super String> n16 = new Neg01<>("", ""){}; //new Foo<Object> created
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg01.out	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,31 @@
+Neg01.java:18:15: compiler.err.not.within.bounds: java.lang.String
+Neg01.java:18:37: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg01<X>, Neg01<java.lang.String>)
+Neg01.java:19:25: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg01.java:19:47: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg01.java:20:23: compiler.err.cant.resolve.location.args: kindname.constructor, Neg01, , java.lang.String, kindname.class, Neg01<java.lang.Number>
+Neg01.java:21:23: compiler.err.not.within.bounds: ? super java.lang.String
+Neg01.java:21:45: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg01<X>, Neg01<? super java.lang.String>)
+Neg01.java:23:15: compiler.err.not.within.bounds: java.lang.String
+Neg01.java:23:37: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg01<X>, Neg01<java.lang.String>)
+Neg01.java:24:25: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg01.java:24:47: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg01.java:25:23: compiler.err.cant.resolve.location.args: kindname.constructor, Neg01, , java.lang.String, kindname.class, Neg01<java.lang.Number>
+Neg01.java:25:38: compiler.err.cant.resolve.location.args: kindname.constructor, Neg01, , , kindname.class, Neg01<java.lang.Number>
+Neg01.java:26:23: compiler.err.not.within.bounds: ? super java.lang.String
+Neg01.java:26:45: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg01<X>, Neg01<? super java.lang.String>)
+Neg01.java:28:15: compiler.err.not.within.bounds: java.lang.String
+Neg01.java:28:37: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg01<X>, Neg01<java.lang.String>)
+Neg01.java:29:25: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg01.java:29:48: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg01.java:30:24: compiler.err.cant.resolve.location.args: kindname.constructor, Neg01, , java.lang.String,java.lang.String, kindname.class, Neg01<java.lang.Number>
+Neg01.java:31:9: compiler.err.cant.resolve.location: kindname.class, Foo, , , kindname.class, Neg01<X>
+Neg01.java:31:35: compiler.err.cant.resolve.location.args: kindname.constructor, Neg01, , java.lang.String,java.lang.String, kindname.class, Neg01<java.lang.Number>
+Neg01.java:33:15: compiler.err.not.within.bounds: java.lang.String
+Neg01.java:33:38: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg01<X>, Neg01<java.lang.String>)
+Neg01.java:34:25: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg01.java:34:48: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg01.java:35:24: compiler.err.cant.resolve.location.args: kindname.constructor, Neg01, , java.lang.String,java.lang.String, kindname.class, Neg01<java.lang.Number>
+Neg01.java:35:43: compiler.err.cant.resolve.location.args: kindname.constructor, Neg01, , , kindname.class, Neg01<java.lang.Number>
+Neg01.java:36:23: compiler.err.not.within.bounds: ? super java.lang.String
+Neg01.java:36:46: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg01<X>, Neg01<? super java.lang.String>)
+30 errors
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg02.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,61 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 6840638
+ *
+ * @summary  Project Coin: Improved Type Inference for Generic Instance Creation (aka 'diamond')
+ * @author mcimadamore
+ * @compile/fail/ref=Neg02.out Neg02.java -source 1.7 -XDrawDiagnostics
+ *
+ */
+
+class Neg02 {
+
+    static class Foo<X extends Number> {
+        Foo(X x) {}
+        <Z> Foo(X x, Z z) {}
+    }
+
+    void testSimple() {
+        Foo<String> f1 = new Foo<>(""); //new Foo<Integer> created
+        Foo<? extends String> f2 = new Foo<>(""); //new Foo<Integer> created
+        Foo<?> f3 = new Foo<>(""); //new Foo<Object> created
+        Foo<? super String> f4 = new Foo<>(""); //new Foo<Object> created
+
+        Foo<String> f5 = new Foo<>(""){}; //new Foo<Integer> created
+        Foo<? extends String> f6 = new Foo<>(""){}; //new Foo<Integer> created
+        Foo<?> f7 = new Foo<>(""){}; //new Foo<Object> created
+        Foo<? super String> f8 = new Foo<>(""){}; //new Foo<Object> created
+
+        Foo<String> f9 = new Foo<>("", ""); //new Foo<Integer> created
+        Foo<? extends String> f10 = new Foo<>("", ""); //new Foo<Integer> created
+        Foo<?> f11 = new Foo<>("", ""); //new Foo<Object> created
+        Foo<? super String> f12 = new Foo<>("", ""); //new Foo<Object> created
+
+        Foo<String> f13 = new Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<? extends String> f14 = new Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<?> f15 = new Foo<>("", ""){}; //new Foo<Object> created
+        Foo<? super String> f16 = new Foo<>("", ""){}; //new Foo<Object> created
+    }
+
+    void testQualified() {
+        Foo<String> f1 = new Neg02.Foo<>(""); //new Foo<Integer> created
+        Foo<? extends String> f2 = new Neg02.Foo<>(""); //new Foo<Integer> created
+        Foo<?> f3 = new Neg02.Foo<>(""); //new Foo<Object> created
+        Foo<? super String> f4 = new Neg02.Foo<>(""); //new Foo<Object> created
+
+        Foo<String> f5 = new Neg02.Foo<>(""){}; //new Foo<Integer> created
+        Foo<? extends String> f6 = new Neg02.Foo<>(""){}; //new Foo<Integer> created
+        Foo<?> f7 = new Neg02.Foo<>(""){}; //new Foo<Object> created
+        Foo<? super String> f8 = new Neg02.Foo<>(""){}; //new Foo<Object> created
+
+        Foo<String> f9 = new Neg02.Foo<>("", ""); //new Foo<Integer> created
+        Foo<? extends String> f10 = new Neg02.Foo<>("", ""); //new Foo<Integer> created
+        Foo<?> f11 = new Neg02.Foo<>("", ""); //new Foo<Object> created
+        Foo<? super String> f12 = new Neg02.Foo<>("", ""); //new Foo<Object> created
+
+        Foo<String> f13 = new Neg02.Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<? extends String> f14 = new Neg02.Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<?> f15 = new Neg02.Foo<>("", ""){}; //new Foo<Object> created
+        Foo<? super String> f16 = new Neg02.Foo<>("", ""){}; //new Foo<Object> created
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg02.out	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,61 @@
+Neg02.java:19:13: compiler.err.not.within.bounds: java.lang.String
+Neg02.java:19:33: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<java.lang.String>)
+Neg02.java:20:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg02.java:20:43: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg02.java:21:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:22:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg02.java:22:41: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<? super java.lang.String>)
+Neg02.java:24:13: compiler.err.not.within.bounds: java.lang.String
+Neg02.java:24:33: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<java.lang.String>)
+Neg02.java:25:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg02.java:25:43: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg02.java:26:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:26:34: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:27:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg02.java:27:41: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<? super java.lang.String>)
+Neg02.java:29:13: compiler.err.not.within.bounds: java.lang.String
+Neg02.java:29:33: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<java.lang.String>)
+Neg02.java:30:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg02.java:30:44: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg02.java:31:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:32:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg02.java:32:42: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<? super java.lang.String>)
+Neg02.java:34:13: compiler.err.not.within.bounds: java.lang.String
+Neg02.java:34:34: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<java.lang.String>)
+Neg02.java:35:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg02.java:35:44: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg02.java:36:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:36:39: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:37:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg02.java:37:42: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<? super java.lang.String>)
+Neg02.java:41:13: compiler.err.not.within.bounds: java.lang.String
+Neg02.java:41:39: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<java.lang.String>)
+Neg02.java:42:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg02.java:42:49: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg02.java:43:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:44:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg02.java:44:47: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<? super java.lang.String>)
+Neg02.java:46:13: compiler.err.not.within.bounds: java.lang.String
+Neg02.java:46:39: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<java.lang.String>)
+Neg02.java:47:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg02.java:47:49: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg02.java:48:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:48:40: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:49:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg02.java:49:47: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<? super java.lang.String>)
+Neg02.java:51:13: compiler.err.not.within.bounds: java.lang.String
+Neg02.java:51:39: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<java.lang.String>)
+Neg02.java:52:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg02.java:52:50: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg02.java:53:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:54:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg02.java:54:48: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<? super java.lang.String>)
+Neg02.java:56:13: compiler.err.not.within.bounds: java.lang.String
+Neg02.java:56:40: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<java.lang.String>)
+Neg02.java:57:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg02.java:57:50: compiler.err.cant.apply.diamond: X, (compiler.misc.no.unique.maximal.instance.exists: X, java.lang.String,java.lang.Number)
+Neg02.java:58:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:58:45: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg02.Foo<java.lang.Number>
+Neg02.java:59:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg02.java:59:48: compiler.err.cant.apply.diamond: X, (compiler.misc.no.conforming.instance.exists: X, Neg02.Foo<X>, Neg02.Foo<? super java.lang.String>)
+60 errors
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg03.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,83 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 6840638
+ *
+ * @summary  Project Coin: Improved Type Inference for Generic Instance Creation (aka 'diamond')
+ * @author mcimadamore
+ * @compile/fail/ref=Neg03.out Neg03.java -source 1.7 -XDrawDiagnostics
+ *
+ */
+
+class Neg03<U> {
+
+    class Foo<V extends Number> {
+        Foo(V x) {}
+        <Z> Foo(V x, Z z) {}
+    }
+
+    void testSimple() {
+        Foo<String> f1 = new Foo<>(""); //new Foo<Integer> created
+        Foo<? extends String> f2 = new Foo<>(""); //new Foo<Integer> created
+        Foo<?> f3 = new Foo<>(""); //new Foo<Object> created
+        Foo<? super String> f4 = new Foo<>(""); //new Foo<Object> created
+
+        Foo<String> f5 = new Foo<>(""){}; //new Foo<Integer> created
+        Foo<? extends String> f6 = new Foo<>(""){}; //new Foo<Integer> created
+        Foo<?> f7 = new Foo<>(""){}; //new Foo<Object> created
+        Foo<? super String> f8 = new Foo<>(""){}; //new Foo<Object> created
+
+        Foo<String> f9 = new Foo<>("", ""); //new Foo<Integer> created
+        Foo<? extends String> f10 = new Foo<>("", ""); //new Foo<Integer> created
+        Foo<?> f11 = new Foo<>("", ""); //new Foo<Object> created
+        Foo<? super String> f12 = new Foo<>("", ""); //new Foo<Object> created
+
+        Foo<String> f13 = new Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<? extends String> f14 = new Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<?> f15 = new Foo<>("", ""){}; //new Foo<Object> created
+        Foo<? super String> f16 = new Foo<>("", ""){}; //new Foo<Object> created
+    }
+
+    void testQualified_1() {
+        Foo<String> f1 = new Neg03<U>.Foo<>(""); //new Foo<Integer> created
+        Foo<? extends String> f2 = new Neg03<U>.Foo<>(""); //new Foo<Integer> created
+        Foo<?> f3 = new Neg03<U>.Foo<>(""); //new Foo<Object> created
+        Foo<? super String> f4 = new Neg03<U>.Foo<>(""); //new Foo<Object> created
+
+        Foo<String> f5 = new Neg03<U>.Foo<>(""){}; //new Foo<Integer> created
+        Foo<? extends String> f6 = new Neg03<U>.Foo<>(""){}; //new Foo<Integer> created
+        Foo<?> f7 = new Neg03<U>.Foo<>(""){}; //new Foo<Object> created
+        Foo<? super String> f8 = new Neg03<U>.Foo<>(""){}; //new Foo<Object> created
+
+        Foo<String> f9 = new Neg03<U>.Foo<>("", ""); //new Foo<Integer> created
+        Foo<? extends String> f10 = new Neg03<U>.Foo<>("", ""); //new Foo<Integer> created
+        Foo<?> f11 = new Neg03<U>.Foo<>("", ""); //new Foo<Object> created
+        Foo<? super String> f12 = new Neg03<U>.Foo<>("", ""); //new Foo<Object> created
+
+        Foo<String> f13 = new Neg03<U>.Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<? extends String> f14 = new Neg03<U>.Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<?> f15 = new Neg03<U>.Foo<>("", ""){}; //new Foo<Object> created
+        Foo<? super String> f16 = new Neg03<U>.Foo<>("", ""){}; //new Foo<Object> created
+    }
+
+    void testQualified_2(Neg03<U> n) {
+        Foo<String> f1 = n.new Foo<>(""); //new Foo<Integer> created
+        Foo<? extends String> f2 = n.new Foo<>(""); //new Foo<Integer> created
+        Foo<?> f3 = n.new Foo<>(""); //new Foo<Integer> created
+        Foo<? super String> f4 = n.new Foo<>(""); //new Foo<Integer> created
+
+        Foo<String> f5 = n.new Foo<>(""){}; //new Foo<Integer> created
+        Foo<? extends String> f6 = n.new Foo<>(""){}; //new Foo<Integer> created
+        Foo<?> f7 = n.new Foo<>(""){}; //new Foo<Integer> created
+        Foo<? super String> f8 = n.new Foo<>(""){}; //new Foo<Integer> created
+
+        Foo<String> f9 = n.new Foo<>("", ""); //new Foo<Integer> created
+        Foo<? extends String> f10 = n.new Foo<>("", ""); //new Foo<Integer> created
+        Foo<?> f11 = n.new Foo<>("", ""); //new Foo<Integer> created
+        Foo<? super String> f12 = n.new Foo<>("", ""); //new Foo<Integer> created
+
+        Foo<String> f13 = n.new Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<? extends String> f14 = n.new Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<?> f15 = n.new Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<? super String> f16 = n.new Foo<>("", ""){}; //new Foo<Integer> created
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg03.out	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,91 @@
+Neg03.java:19:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:19:33: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:20:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:20:43: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:21:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:22:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:22:41: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:24:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:24:33: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:25:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:25:43: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:26:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:26:34: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:27:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:27:41: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:29:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:29:33: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:30:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:30:44: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:31:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:32:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:32:42: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:34:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:34:34: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:35:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:35:44: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:36:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:36:39: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:37:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:37:42: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:41:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:41:42: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:42:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:42:52: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:43:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:44:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:44:50: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:46:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:46:42: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:47:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:47:52: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:48:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:48:43: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:49:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:49:50: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:51:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:51:42: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:52:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:52:53: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:53:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:54:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:54:51: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:56:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:56:43: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:57:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:57:53: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:58:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:58:48: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:59:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:59:51: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:63:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:63:28: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:64:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:64:38: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:65:23: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:66:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:66:36: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:68:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:68:28: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:69:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:69:38: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:70:23: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:70:36: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:71:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:71:36: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:73:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:73:28: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:74:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:74:39: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:75:24: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:76:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:76:37: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+Neg03.java:78:13: compiler.err.not.within.bounds: java.lang.String
+Neg03.java:78:29: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<java.lang.String>)
+Neg03.java:79:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg03.java:79:39: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg03.java:80:24: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:80:41: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Neg03<U>.Foo<java.lang.Number>
+Neg03.java:81:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg03.java:81:37: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Neg03<U>.Foo<V>, Neg03<U>.Foo<? super java.lang.String>)
+90 errors
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg04.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,38 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 6840638
+ *
+ * @summary  Project Coin: Improved Type Inference for Generic Instance Creation (aka 'diamond')
+ * @author mcimadamore
+ * @compile/fail/ref=Neg04.out Neg04.java -source 1.7 -XDrawDiagnostics
+ *
+ */
+
+class Neg04 {
+
+    void test() {
+        class Foo<V extends Number> {
+            Foo(V x) {}
+            <Z> Foo(V x, Z z) {}
+        }
+        Foo<String> n1 = new Foo<>(""); //new Foo<Integer> created
+        Foo<? extends String> n2 = new Foo<>(""); //new Foo<Integer> created
+        Foo<?> n3 = new Foo<>(""); //new Foo<Object> created
+        Foo<? super String> n4 = new Foo<>(""); //new Foo<Object> created
+
+        Foo<String> n5 = new Foo<>(""){}; //new Foo<Integer> created
+        Foo<? extends String> n6 = new Foo<>(""){}; //new Foo<Integer> created
+        Foo<?> n7 = new Foo<>(""){}; //new Foo<Object> created
+        Foo<? super String> n8 = new Foo<>(""){}; //new Foo<Object> created
+
+        Foo<String> n9 = new Foo<>("", ""); //new Foo<Integer> created
+        Foo<? extends String> n10 = new Foo<>("", ""); //new Foo<Integer> created
+        Foo<?> n11 = new Foo<>("", ""); //new Foo<Object> created
+        Foo<? super String> n12 = new Foo<>("", ""); //new Foo<Object> created
+
+        Foo<String> n13 = new Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<? extends String> n14 = new Foo<>("", ""){}; //new Foo<Integer> created
+        Foo<?> n15 = new Foo<>("", ""){}; //new Foo<Object> created
+        Foo<? super String> n16 = new Foo<>("", ""){}; //new Foo<Object> created
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg04.out	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,31 @@
+Neg04.java:18:13: compiler.err.not.within.bounds: java.lang.String
+Neg04.java:18:33: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Foo<V>, Foo<java.lang.String>)
+Neg04.java:19:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg04.java:19:43: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg04.java:20:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Foo<java.lang.Number>
+Neg04.java:21:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg04.java:21:41: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Foo<V>, Foo<? super java.lang.String>)
+Neg04.java:23:13: compiler.err.not.within.bounds: java.lang.String
+Neg04.java:23:33: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Foo<V>, Foo<java.lang.String>)
+Neg04.java:24:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg04.java:24:43: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg04.java:25:21: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String, kindname.class, Foo<java.lang.Number>
+Neg04.java:25:34: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Foo<java.lang.Number>
+Neg04.java:26:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg04.java:26:41: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Foo<V>, Foo<? super java.lang.String>)
+Neg04.java:28:13: compiler.err.not.within.bounds: java.lang.String
+Neg04.java:28:33: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Foo<V>, Foo<java.lang.String>)
+Neg04.java:29:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg04.java:29:44: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg04.java:30:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Foo<java.lang.Number>
+Neg04.java:31:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg04.java:31:42: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Foo<V>, Foo<? super java.lang.String>)
+Neg04.java:33:13: compiler.err.not.within.bounds: java.lang.String
+Neg04.java:33:34: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Foo<V>, Foo<java.lang.String>)
+Neg04.java:34:23: compiler.err.not.within.bounds: ? extends java.lang.String
+Neg04.java:34:44: compiler.err.cant.apply.diamond: V, (compiler.misc.no.unique.maximal.instance.exists: V, java.lang.String,java.lang.Number)
+Neg04.java:35:22: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , java.lang.String,java.lang.String, kindname.class, Foo<java.lang.Number>
+Neg04.java:35:39: compiler.err.cant.resolve.location.args: kindname.constructor, Foo, , , kindname.class, Foo<java.lang.Number>
+Neg04.java:36:21: compiler.err.not.within.bounds: ? super java.lang.String
+Neg04.java:36:42: compiler.err.cant.apply.diamond: V, (compiler.misc.no.conforming.instance.exists: V, Foo<V>, Foo<? super java.lang.String>)
+30 errors
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg05.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,61 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 6840638
+ *
+ * @summary  Project Coin: Improved Type Inference for Generic Instance Creation (aka 'diamond')
+ * @author mcimadamore
+ * @compile/fail/ref=Neg05.out Neg05.java -source 1.7 -XDrawDiagnostics
+ *
+ */
+
+class Neg05<U> {
+
+    class Foo<V> {
+        Foo(V x) {}
+        <Z> Foo(V x, Z z) {}
+    }
+
+    void testRare_1() {
+        Neg05<?>.Foo<String> f1 = new Neg05.Foo<>(""); //new Foo<Integer> created
+        Neg05<?>.Foo<? extends String> f2 = new Neg05.Foo<>(""); //new Foo<Integer> created
+        Neg05<?>.Foo<?> f3 = new Neg05.Foo<>(""); //new Foo<Object> created
+        Neg05<?>.Foo<? super String> f4 = new Neg05.Foo<>(""); //new Foo<Object> created
+
+        Neg05<?>.Foo<String> f5 = new Neg05.Foo<>(""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<? extends String> f6 = new Neg05.Foo<>(""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<?> f7 = new Neg05.Foo<>(""){}; //new Foo<Object> created
+        Neg05<?>.Foo<? super String> f8 = new Neg05.Foo<>(""){}; //new Foo<Object> created
+
+        Neg05<?>.Foo<String> f9 = new Neg05.Foo<>("", ""); //new Foo<Integer> created
+        Neg05<?>.Foo<? extends String> f10 = new Neg05.Foo<>("", ""); //new Foo<Integer> created
+        Neg05<?>.Foo<?> f11 = new Neg05.Foo<>("", ""); //new Foo<Object> created
+        Neg05<?>.Foo<? super String> f12 = new Neg05.Foo<>("", ""); //new Foo<Object> created
+
+        Neg05<?>.Foo<String> f13 = new Neg05.Foo<>("", ""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<? extends String> f14 = new Neg05.Foo<>("", ""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<?> f15 = new Neg05.Foo<>("", ""){}; //new Foo<Object> created
+        Neg05<?>.Foo<? super String> f16 = new Neg05.Foo<>("", ""){}; //new Foo<Object> created
+    }
+
+    void testRare_2(Neg05 n) {
+        Neg05<?>.Foo<String> f1 = n.new Foo<>(""); //new Foo<Integer> created
+        Neg05<?>.Foo<? extends String> f2 = n.new Foo<>(""); //new Foo<Integer> created
+        Neg05<?>.Foo<?> f3 = n.new Foo<>(""); //new Foo<Integer> created
+        Neg05<?>.Foo<? super String> f4 = n.new Foo<>(""); //new Foo<Integer> created
+
+        Neg05<?>.Foo<String> f5 = n.new Foo<>(""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<? extends String> f6 = n.new Foo<>(""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<?> f7 = n.new Foo<>(""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<? super String> f8 = n.new Foo<>(""){}; //new Foo<Integer> created
+
+        Neg05<?>.Foo<String> f9 = n.new Foo<>("", ""); //new Foo<Integer> created
+        Neg05<?>.Foo<? extends String> f10 = n.new Foo<>("", ""); //new Foo<Integer> created
+        Neg05<?>.Foo<?> f11 = n.new Foo<>("", ""); //new Foo<Integer> created
+        Neg05<?>.Foo<? super String> f12 = n.new Foo<>("", ""); //new Foo<Integer> created
+
+        Neg05<?>.Foo<String> f13 = n.new Foo<>("", ""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<? extends String> f14 = n.new Foo<>("", ""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<?> f15 = n.new Foo<>("", ""){}; //new Foo<Integer> created
+        Neg05<?>.Foo<? super String> f16 = n.new Foo<>("", ""){}; //new Foo<Integer> created
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/neg/Neg05.out	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,33 @@
+Neg05.java:19:48: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:20:58: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:21:43: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:22:56: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:24:48: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:25:58: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:26:43: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:27:56: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:29:48: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:30:59: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:31:44: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:32:57: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:34:49: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:35:59: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:36:44: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:37:57: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:41:37: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:42:47: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:43:32: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:44:45: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:46:37: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:47:47: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:48:32: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:49:45: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:51:37: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:52:48: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:53:33: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:54:46: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:56:38: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:57:48: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:58:33: compiler.err.improperly.formed.type.inner.raw.param
+Neg05.java:59:46: compiler.err.improperly.formed.type.inner.raw.param
+32 errors
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/pos/Pos01.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,44 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 6840638
+ *
+ * @summary  Project Coin: Improved Type Inference for Generic Instance Creation (aka 'diamond')
+ * @author mcimadamore
+ * @compile Pos01.java -source 1.7
+ * @run main Pos01
+ *
+ */
+
+public class Pos01<X> {
+
+    Pos01(X x) {}
+
+    <Z> Pos01(X x, Z z) {}
+
+    void test() {
+        Pos01<Integer> p1 = new Pos01<>(1); //new Foo<Integer> created
+        Pos01<? extends Integer> p2 = new Pos01<>(1); //new Foo<Integer> created
+        Pos01<?> p3 = new Pos01<>(1); //new Foo<Object> created
+        Pos01<? super Integer> p4 = new Pos01<>(1); //new Foo<Object> created
+
+        Pos01<Integer> p5 = new Pos01<>(1){}; //new Foo<Integer> created
+        Pos01<? extends Integer> p6 = new Pos01<>(1){}; //new Foo<Integer> created
+        Pos01<?> p7 = new Pos01<>(1){}; //new Foo<Object> created
+        Pos01<? super Integer> p8 = new Pos01<>(1){}; //new Foo<Object> created
+
+        Pos01<Integer> p9 = new Pos01<>(1, ""); //new Foo<Integer> created
+        Pos01<? extends Integer> p10 = new Pos01<>(1, ""); //new Foo<Integer> created
+        Pos01<?> p11 = new Pos01<>(1, ""); //new Foo<Object> created
+        Pos01<? super Integer> p12 = new Pos01<>(1, ""); //new Foo<Object> created
+
+        Pos01<Integer> p13 = new Pos01<>(1, ""){}; //new Foo<Integer> created
+        Pos01<? extends Integer> p14= new Pos01<>(1, ""){}; //new Foo<Integer> created
+        Pos01<?> p15 = new Pos01<>(1, ""){}; //new Foo<Object> created
+        Pos01<? super Integer> p16 = new Pos01<>(1, ""){}; //new Foo<Object> created
+    }
+
+    public static void main(String[] args) {
+        Pos01<String> p1 = new Pos01<>("");
+        p1.test();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/pos/Pos02.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,67 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 6840638
+ *
+ * @summary  Project Coin: Improved Type Inference for Generic Instance Creation (aka 'diamond')
+ * @author mcimadamore
+ * @compile Pos02.java -source 1.7
+ * @run main Pos02
+ */
+
+public class Pos02 {
+
+    static class Foo<X> {
+        Foo(X x) {}
+        <Z> Foo(X x, Z z) {}
+    }
+
+    void testSimple() {
+        Foo<Integer> f1 = new Foo<>(1); //new Foo<Integer> created
+        Foo<? extends Integer> f2 = new Foo<>(1); //new Foo<Integer> created
+        Foo<?> f3 = new Foo<>(1); //new Foo<Object> created
+        Foo<? super Integer> f4 = new Foo<>(1); //new Foo<Object> created
+
+        Foo<Integer> f5 = new Foo<>(1){}; //new Foo<Integer> created
+        Foo<? extends Integer> f6 = new Foo<>(1){}; //new Foo<Integer> created
+        Foo<?> f7 = new Foo<>(1){}; //new Foo<Object> created
+        Foo<? super Integer> f8 = new Foo<>(1){}; //new Foo<Object> created
+
+        Foo<Integer> f9 = new Foo<>(1, ""); //new Foo<Integer> created
+        Foo<? extends Integer> f10 = new Foo<>(1, ""); //new Foo<Integer> created
+        Foo<?> f11 = new Foo<>(1, ""); //new Foo<Object> created
+        Foo<? super Integer> f12 = new Foo<>(1, ""); //new Foo<Object> created
+
+        Foo<Integer> f13 = new Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<? extends Integer> f14 = new Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<?> f15 = new Foo<>(1, ""){}; //new Foo<Object> created
+        Foo<? super Integer> f16 = new Foo<>(1, ""){}; //new Foo<Object> created
+    }
+
+    void testQualified() {
+        Foo<Integer> f1 = new Pos02.Foo<>(1); //new Foo<Integer> created
+        Foo<? extends Integer> f2 = new Pos02.Foo<>(1); //new Foo<Integer> created
+        Foo<?> f3 = new Pos02.Foo<>(1); //new Foo<Object> created
+        Foo<? super Integer> f4 = new Pos02.Foo<>(1); //new Foo<Object> created
+
+        Foo<Integer> f5 = new Pos02.Foo<>(1){}; //new Foo<Integer> created
+        Foo<? extends Integer> f6 = new Pos02.Foo<>(1){}; //new Foo<Integer> created
+        Foo<?> f7 = new Pos02.Foo<>(1){}; //new Foo<Object> created
+        Foo<? super Integer> f8 = new Pos02.Foo<>(1){}; //new Foo<Object> created
+
+        Foo<Integer> f9 = new Pos02.Foo<>(1, ""); //new Foo<Integer> created
+        Foo<? extends Integer> f10 = new Pos02.Foo<>(1, ""); //new Foo<Integer> created
+        Foo<?> f11 = new Pos02.Foo<>(1, ""); //new Foo<Object> created
+        Foo<? super Integer> f12 = new Pos02.Foo<>(1, ""); //new Foo<Object> created
+
+        Foo<Integer> f13 = new Pos02.Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<? extends Integer> f14 = new Pos02.Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<?> f15 = new Pos02.Foo<>(1, ""){}; //new Foo<Object> created
+        Foo<? super Integer> f16 = new Pos02.Foo<>(1, ""){}; //new Foo<Object> created
+    }
+
+    public static void main(String[] args) {
+        Pos02 p2 = new Pos02();
+        p2.testSimple();
+        p2.testQualified();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/pos/Pos03.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,91 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 6840638
+ *
+ * @summary  Project Coin: Improved Type Inference for Generic Instance Creation (aka 'diamond')
+ * @author mcimadamore
+ * @compile Pos03.java -source 1.7
+ * @run main Pos03
+ *
+ */
+
+public class Pos03<U> {
+
+    class Foo<V> {
+        Foo(V x) {}
+        <Z> Foo(V x, Z z) {}
+    }
+
+    void testSimple() {
+        Foo<Integer> f1 = new Foo<>(1); //new Foo<Integer> created
+        Foo<? extends Integer> f2 = new Foo<>(1); //new Foo<Integer> created
+        Foo<?> f3 = new Foo<>(1); //new Foo<Object> created
+        Foo<? super Integer> f4 = new Foo<>(1); //new Foo<Object> created
+
+        Foo<Integer> f5 = new Foo<>(1){}; //new Foo<Integer> created
+        Foo<? extends Integer> f6 = new Foo<>(1){}; //new Foo<Integer> created
+        Foo<?> f7 = new Foo<>(1){}; //new Foo<Object> created
+        Foo<? super Integer> f8 = new Foo<>(1){}; //new Foo<Object> created
+
+        Foo<Integer> f9 = new Foo<>(1, ""); //new Foo<Integer> created
+        Foo<? extends Integer> f10 = new Foo<>(1, ""); //new Foo<Integer> created
+        Foo<?> f11 = new Foo<>(1, ""); //new Foo<Object> created
+        Foo<? super Integer> f12 = new Foo<>(1, ""); //new Foo<Object> created
+
+        Foo<Integer> f13 = new Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<? extends Integer> f14 = new Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<?> f15 = new Foo<>(1, ""){}; //new Foo<Object> created
+        Foo<? super Integer> f16 = new Foo<>(1, ""){}; //new Foo<Object> created
+    }
+
+    void testQualified_1() {
+        Foo<Integer> f1 = new Pos03<U>.Foo<>(1); //new Foo<Integer> created
+        Foo<? extends Integer> f2 = new Pos03<U>.Foo<>(1); //new Foo<Integer> created
+        Foo<?> f3 = new Pos03<U>.Foo<>(1); //new Foo<Object> created
+        Foo<? super Integer> f4 = new Pos03<U>.Foo<>(1); //new Foo<Object> created
+
+        Foo<Integer> f5 = new Pos03<U>.Foo<>(1){}; //new Foo<Integer> created
+        Foo<? extends Integer> f6 = new Pos03<U>.Foo<>(1){}; //new Foo<Integer> created
+        Foo<?> f7 = new Pos03<U>.Foo<>(1){}; //new Foo<Object> created
+        Foo<? super Integer> f8 = new Pos03<U>.Foo<>(1){}; //new Foo<Object> created
+
+        Foo<Integer> f9 = new Pos03<U>.Foo<>(1, ""); //new Foo<Integer> created
+        Foo<? extends Integer> f10 = new Pos03<U>.Foo<>(1, ""); //new Foo<Integer> created
+        Foo<?> f11 = new Pos03<U>.Foo<>(1, ""); //new Foo<Object> created
+        Foo<? super Integer> f12 = new Pos03<U>.Foo<>(1, ""); //new Foo<Object> created
+
+        Foo<Integer> f13 = new Pos03<U>.Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<? extends Integer> f14 = new Pos03<U>.Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<?> f15 = new Pos03<U>.Foo<>(1, ""){}; //new Foo<Object> created
+        Foo<? super Integer> f16 = new Pos03<U>.Foo<>(1, ""){}; //new Foo<Object> created
+    }
+
+    void testQualified_2(Pos03<U> p) {
+        Foo<Integer> f1 = p.new Foo<>(1); //new Foo<Integer> created
+        Foo<? extends Integer> f2 = p.new Foo<>(1); //new Foo<Integer> created
+        Foo<?> f3 = p.new Foo<>(1); //new Foo<Object> created
+        Foo<? super Integer> f4 = p.new Foo<>(1); //new Foo<Object> created
+
+        Foo<Integer> f5 = p.new Foo<>(1){}; //new Foo<Integer> created
+        Foo<? extends Integer> f6 = p.new Foo<>(1){}; //new Foo<Integer> created
+        Foo<?> f7 = p.new Foo<>(1){}; //new Foo<Object> created
+        Foo<? super Integer> f8 = p.new Foo<>(1){}; //new Foo<Object> created
+
+        Foo<Integer> f9 = p.new Foo<>(1, ""); //new Foo<Integer> created
+        Foo<? extends Integer> f10 = p.new Foo<>(1, ""); //new Foo<Integer> created
+        Foo<?> f11 = p.new Foo<>(1, ""); //new Foo<Object> created
+        Foo<? super Integer> f12 = p.new Foo<>(1, ""); //new Foo<Object> created
+
+        Foo<Integer> f13 = p.new Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<? extends Integer> f14 = p.new Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<?> f15 = p.new Foo<>(1, ""){}; //new Foo<Object> created
+        Foo<? super Integer> f16 = p.new Foo<>(1, ""){}; //new Foo<Object> created
+    }
+
+    public static void main(String[] args) {
+        Pos03<String> p3 = new Pos03<>();
+        p3.testSimple();
+        p3.testQualified_1();
+        p3.testQualified_2(p3);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/diamond/pos/Pos04.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,44 @@
+/*
+ * @test /nodynamiccopyright/
+ * @bug 6840638
+ *
+ * @summary  Project Coin: Improved Type Inference for Generic Instance Creation (aka 'diamond')
+ * @author mcimadamore
+ * @compile Pos04.java -source 1.7
+ * @run main Pos04
+ *
+ */
+
+public class Pos04<U> {
+
+    void test() {
+        class Foo<V> {
+            Foo(V x) {}
+            <Z> Foo(V x, Z z) {}
+        }
+        Foo<Integer> p1 = new Foo<>(1); //new Foo<Integer> created
+        Foo<? extends Integer> p2 = new Foo<>(1); //new Foo<Integer> created
+        Foo<?> p3 = new Foo<>(1); //new Foo<Object> created
+        Foo<? super Integer> p4 = new Foo<>(1); //new Foo<Object> created
+
+        Foo<Integer> p5 = new Foo<>(1){}; //new Foo<Integer> created
+        Foo<? extends Integer> p6 = new Foo<>(1){}; //new Foo<Integer> created
+        Foo<?> p7 = new Foo<>(1){}; //new Foo<Object> created
+        Foo<? super Integer> p8 = new Foo<>(1){}; //new Foo<Object> created
+
+        Foo<Integer> p9 = new Foo<>(1, ""); //new Foo<Integer> created
+        Foo<? extends Integer> p10 = new Foo<>(1, ""); //new Foo<Integer> created
+        Foo<?> p11 = new Foo<>(1, ""); //new Foo<Object> created
+        Foo<? super Integer> p12 = new Foo<>(1, ""); //new Foo<Object> created
+
+        Foo<Integer> p13 = new Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<? extends Integer> p14 = new Foo<>(1, ""){}; //new Foo<Integer> created
+        Foo<?> p15 = new Foo<>(1, ""){}; //new Foo<Object> created
+        Foo<? super Integer> p16 = new Foo<>(1, ""){}; //new Foo<Object> created
+    }
+
+    public static void main(String[] args) {
+        Pos04<String> p4 = new Pos04<>();
+        p4.test();
+    }
+}
--- a/test/tools/javac/generics/inference/6302954/T6476073.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6302954/T6476073.java	Mon Sep 21 17:11:48 2009 +0100
@@ -25,7 +25,6 @@
  * @test
  * @bug     6476073
  * @summary Capture using super wildcard of type variables doesn't work
- * @ignore awaiting for 6650759 (see bug report for a detailed evaluation)
  * @compile T6476073.java
  */
 
--- a/test/tools/javac/generics/inference/6315770/T6315770.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6315770/T6315770.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6315770
  * @summary javac inference allows creation of strange types: Integer & Runnable
  * @author Maurizio Cimadamore
--- a/test/tools/javac/generics/inference/6315770/T6315770.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6315770/T6315770.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-T6315770.java:39:42: compiler.err.undetermined.type.1: <T>T6315770<T>, (compiler.misc.no.unique.maximal.instance.exists: T, java.lang.String,java.lang.Integer,java.lang.Runnable)
-T6315770.java:40:40: compiler.err.prob.found.req: (compiler.misc.incompatible.types.1: (compiler.misc.no.conforming.instance.exists: T, T6315770<T>, T6315770<? super java.lang.String>)), <T>T6315770<T>, T6315770<? super java.lang.String>
+T6315770.java:16:42: compiler.err.undetermined.type.1: <T>T6315770<T>, (compiler.misc.no.unique.maximal.instance.exists: T, java.lang.String,java.lang.Integer,java.lang.Runnable)
+T6315770.java:17:40: compiler.err.prob.found.req: (compiler.misc.incompatible.types.1: (compiler.misc.no.conforming.instance.exists: T, T6315770<T>, T6315770<? super java.lang.String>)), <T>T6315770<T>, T6315770<? super java.lang.String>
 2 errors
--- a/test/tools/javac/generics/inference/6611449/T6611449.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6611449/T6611449.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6611449
  * @summary Internal Error thrown during generic method/constructor invocation
  * @compile/fail/ref=T6611449.out -XDstdout -XDrawDiagnostics T6611449.java
--- a/test/tools/javac/generics/inference/6611449/T6611449.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6611449/T6611449.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,5 +1,5 @@
-T6611449.java:41:9: compiler.err.cant.resolve.location.args: kindname.constructor, T6611449, , int, kindname.class, T6611449<S>
-T6611449.java:42:9: compiler.err.cant.resolve.location.args: kindname.constructor, T6611449, , int,int, kindname.class, T6611449<S>
-T6611449.java:43:9: compiler.err.cant.apply.symbol: kindname.method, m1, T, int, kindname.class, T6611449<S>, null
-T6611449.java:44:9: compiler.err.cant.apply.symbol: kindname.method, m2, T,T, int,int, kindname.class, T6611449<S>, null
+T6611449.java:18:9: compiler.err.cant.resolve.location.args: kindname.constructor, T6611449, , int, kindname.class, T6611449<S>
+T6611449.java:19:9: compiler.err.cant.resolve.location.args: kindname.constructor, T6611449, , int,int, kindname.class, T6611449<S>
+T6611449.java:20:9: compiler.err.cant.apply.symbol: kindname.method, m1, T, int, kindname.class, T6611449<S>, null
+T6611449.java:21:9: compiler.err.cant.apply.symbol: kindname.method, m2, T,T, int,int, kindname.class, T6611449<S>, null
 4 errors
--- a/test/tools/javac/generics/inference/6638712/T6638712a.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6638712
  * @author  mcimadamore
  * @summary Inference with wildcard types causes selection of inapplicable method
--- a/test/tools/javac/generics/inference/6638712/T6638712a.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712a.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6638712a.java:39:41: compiler.err.invalid.inferred.types: T, (compiler.misc.inferred.do.not.conform.to.params: java.lang.Iterable<? extends java.util.Comparator<? super java.lang.String>>, java.util.List<java.util.Comparator<?>>)
+T6638712a.java:16:41: compiler.err.invalid.inferred.types: T, (compiler.misc.inferred.do.not.conform.to.params: java.lang.Iterable<? extends java.util.Comparator<? super java.lang.String>>, java.util.List<java.util.Comparator<?>>)
 1 error
--- a/test/tools/javac/generics/inference/6638712/T6638712b.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6638712
  * @author  mcimadamore
  * @summary Inference with wildcard types causes selection of inapplicable method
--- a/test/tools/javac/generics/inference/6638712/T6638712b.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712b.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6638712b.java:37:21: compiler.err.invalid.inferred.types: T, (compiler.misc.inferred.do.not.conform.to.bounds: T6638712b<java.lang.Integer>, T6638712b<java.lang.String>)
+T6638712b.java:14:21: compiler.err.prob.found.req: (compiler.misc.incompatible.types.1: (compiler.misc.no.conforming.instance.exists: T, T, java.lang.String)), <T>T, java.lang.String
 1 error
--- a/test/tools/javac/generics/inference/6638712/T6638712c.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712c.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6638712 6707034
  * @author  mcimadamore
  * @summary Inference with wildcard types causes selection of inapplicable method
--- a/test/tools/javac/generics/inference/6638712/T6638712c.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712c.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6638712c.java:39:9: compiler.err.cant.apply.symbol: kindname.method, sort, T[],java.util.Comparator<? super T>, java.lang.Enum[],java.util.Comparator<java.lang.Enum<?>>, kindname.class, T6638712c, null
+T6638712c.java:16:9: compiler.err.cant.apply.symbol: kindname.method, sort, T[],java.util.Comparator<? super T>, java.lang.Enum[],java.util.Comparator<java.lang.Enum<?>>, kindname.class, T6638712c, null
 1 error
--- a/test/tools/javac/generics/inference/6638712/T6638712d.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712d.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6638712 6730468
  * @author  mcimadamore
  * @summary Inference with wildcard types causes selection of inapplicable method
--- a/test/tools/javac/generics/inference/6638712/T6638712d.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712d.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6638712d.java:39:9: compiler.err.cant.apply.symbol: kindname.method, m, U,java.util.List<java.util.List<U>>, int,java.util.List<java.util.List<java.lang.String>>, kindname.class, T6638712d, null
+T6638712d.java:16:9: compiler.err.cant.apply.symbol: kindname.method, m, U,java.util.List<java.util.List<U>>, int,java.util.List<java.util.List<java.lang.String>>, kindname.class, T6638712d, null
 1 error
--- a/test/tools/javac/generics/inference/6638712/T6638712e.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712e.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6638712 6795689
  * @author  mcimadamore
  * @summary Inference with wildcard types causes selection of inapplicable method
--- a/test/tools/javac/generics/inference/6638712/T6638712e.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6638712/T6638712e.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6638712e.java:40:27: compiler.err.invalid.inferred.types: X, (compiler.misc.inferred.do.not.conform.to.params: T6638712e.Foo<? super java.lang.Object,? extends java.lang.Boolean>, T6638712e.Foo<java.lang.Boolean,java.lang.Boolean>)
+T6638712e.java:17:27: compiler.err.prob.found.req: (compiler.misc.incompatible.types.1: (compiler.misc.no.conforming.instance.exists: X, T6638712e.Foo<X,java.lang.String>, T6638712e.Foo<java.lang.Object,java.lang.String>)), <X>T6638712e.Foo<X,java.lang.String>, T6638712e.Foo<java.lang.Object,java.lang.String>
 1 error
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759a.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,45 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @author  mcimadamore
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759a.java
+ */
+
+class T6650759a {
+
+    public static interface Interface<T> { }
+    public static class IntegerInterface implements Interface<Integer> { }
+
+    <I extends Interface<T>, T> T getGenericValue(I test) { return null; }
+
+    void testSet(Integer test) { }
+
+    void test() {
+        Integer test = getGenericValue(new IntegerInterface());
+        testSet(getGenericValue(new IntegerInterface()));
+    }
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,52 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @author  mcimadamore
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759b.java
+ */
+
+public class T6650759b {
+
+    interface A<X extends A<X, Y>, Y extends B<X>> {}
+
+    static class B<X extends A<X, ?>> {}
+
+    interface C<X extends A<X, Y>, Y extends B<X>> {}
+
+    interface D<X extends A<X, Y>, Y extends B<X>> {}
+
+    static class E<X extends A<X, Y>, Y extends B<X>, W extends C<X, Y>> implements D<X, Y> {
+
+        static <X extends A<X, Y>, Y extends B<X>, W extends C<X, Y>> D<X, Y> of(W w) {
+            return null;
+        }
+    }
+
+    <X extends A<X, Y>, Y extends B<X>, W extends C<X, Y>, Z extends D<X, Y>> Z test(W w) {
+        return (Z) E.of(w);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759c.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,49 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759c.java
+ */
+
+import java.util.Collection;
+import java.util.Collections;
+
+public class T6650759c {
+
+  static interface A {}
+
+  static interface B<X extends A> {}
+
+  static interface C<X extends A, Y extends B<X>> {}
+
+  public static <T extends A, U extends B<T>> Collection<C<T,U>> get(U u) {
+    return null;
+  }
+
+  public <T extends A, U extends B<T>> Collection<C<T,U>> test(U u) {
+    return Collections.unmodifiableCollection(get(u));
+  }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759d.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,51 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759d.java
+ */
+
+public class T6650759d {
+
+    static abstract class A<X> {
+
+        static <T> A<T> m(Iterable<? extends T> elements) {
+            return null;
+        }
+    }
+
+    static abstract class B {}
+
+    static abstract class C<X extends B> {}
+
+    <U extends C<V>, V extends B> Iterable<V> get(U u) {
+        return null;
+    }
+
+    <U extends C<V>, V extends B> void m(U u) {
+        A<V> a = A.m(get(u));
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759e.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,52 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759e.java
+ */
+
+import java.util.List;
+
+public class T6650759e {
+
+    static abstract class A<X extends B> {}
+
+    interface B<X extends A> extends D {}
+
+    static abstract class C<X extends D> {}
+
+    interface D {}
+
+    static abstract class E<X extends C<? extends B<?>>> {}
+
+    <U extends C<V>, V extends B<W>, W extends A<V>> W m1(E<U> e) {
+        return m2(e);
+    }
+
+    <U extends C<V>, V extends B<W>, W extends A<V>> W m2(E<U> e) {
+        return null;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759f.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,50 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759f.java
+ */
+
+import java.util.Collections;
+
+public class T6650759f {
+
+    interface A<X extends A> {}
+
+    static abstract class B<X extends B> implements A<X> {}
+
+    static abstract class C<X extends D> extends B<X> {}
+
+    static class D extends C<D> {}
+
+    <X extends B, Y extends B<X>> Iterable<X> m(Y node) {
+        return null;
+    }
+
+    public void test(D d) {
+        Iterable<D> ops = (true) ? Collections.singletonList(d) : m(d);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759g.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,59 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759g.java
+ */
+
+public class T6650759g {
+
+    static abstract class A<X extends A<X>> {}
+
+    static abstract class B<X extends A<X>> {}
+
+    interface C<X, Y> {}
+
+    static abstract class D<X extends A<X>, Y extends B<X>> implements C<X, Y> {}
+
+    static class E extends A<E> {}
+
+    static class F extends B<E> {}
+
+    static void test(Iterable<E> data) {
+        m3(m2(data, m1(F.class)));
+    }
+
+    static <X extends A<X>, Y extends B<X>> D<X, Y> m1(Class<Y> c) {
+        return null;
+    }
+
+    static <U, V> Iterable<V> m2(Iterable<U> x1, C<? super U, ? extends V> x2) {
+        return null;
+    }
+
+    static void m3(Iterable<F> data) {
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759h.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759h.java
+ */
+class T6650759h<X, Y> {
+
+    <A> Object m(A a, T6650759h<?, ? super A> t) {
+        return null;
+    }
+
+    void test(T6650759h<?, Void> t) {
+        m(null, t);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759i.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,54 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759i.java
+ */
+public class T6650759i {
+
+    static class A<X extends A, Y extends B> {}
+
+    static class B<X extends B> {}
+
+    static class C<X extends A<X, Y>, Y extends B<Y>> {}
+
+    static <U extends A<U, V>, V extends B<V>> Class<U> m1(U x) {
+        return null;
+    }
+
+    static <U extends A<U, V>, V extends B<V>> U m2(Class<U> c) {
+        return null;
+    }
+
+    static <W, U extends A<U, V>, V extends B<V>> W m3(Class<W> c1, C<U, V> c2) {
+        return null;
+    }
+
+    static <U extends A<U, V>, V extends B<V>> void test(U u, C<U, V> c) {
+        m2(m1(u));
+        U res = m3(m1(u), c);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759j.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,54 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759j.java
+ */
+
+public class T6650759j {
+
+    static abstract class A<X extends A<X>> {}
+
+    static abstract class B<X extends B<X, Y>, Y> extends A<X> {}
+
+    static abstract class C<X extends C<X, Y>, Y> extends B<X, Y> {}
+
+    interface D {}
+
+    static class E extends C<E, D> {}
+
+    static abstract class F<X extends F<X, Y>, Y extends A<Y>> extends A<X> {}
+
+    static class G extends F<G, E> {}
+
+    static <X extends F<X, Y>, Y extends A<Y>> X m(Iterable<X> it) {
+        return null;
+    }
+
+    static G test(Iterable<G> c) {
+        return m(c);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759k.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,44 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759k.java
+ */
+
+public class T6650759k {
+
+    static class A<X extends A> {}
+
+    static class B<X extends B, Y extends A> {}
+
+    <U extends A<U>, V extends B<V, U>> Object m(Class<V> c) {
+        return null;
+    }
+
+    <U extends A<U>, V extends B<V, U>> void test(Class<V> c) {
+        m(c);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759l.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,46 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile T6650759l.java
+ */
+
+public class T6650759l {
+
+    public static interface A<X> {}
+
+    public static class B implements A<Integer> {}
+
+    public static <X extends A<Y>, Y> Y m1(X x) {
+        return null;
+    }
+
+    public static void m2(Integer i) {}
+
+    public static void test(B b) {
+        m2(m1(b));
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759m.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,47 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug     6650759
+ * @summary Inference of formal type parameter (unused in formal parameters) is not performed
+ * @compile/fail/ref=T6650759m.out T6650759m.java -XDrawDiagnostics
+ */
+
+import java.util.*;
+
+class T6650759m {
+    <Z> List<? super Z> m(List<? extends List<? super Z>> ls) {
+        return ls.get(0);
+    }
+
+    void test() {
+        ArrayList<ArrayList<Integer>> lli = new ArrayList<ArrayList<Integer>>();
+        ArrayList<Integer> li = new ArrayList<Integer>();
+        li.add(2);
+        lli.add(li);
+        List<? super String> ls = m(lli); //here
+        ls.add("crash");
+        Integer i = li.get(1);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javac/generics/inference/6650759/T6650759m.out	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,2 @@
+T6650759m.java:43:36: compiler.err.prob.found.req: (compiler.misc.incompatible.types), java.util.List<? super java.lang.Integer>, java.util.List<? super java.lang.String>
+1 error
--- a/test/tools/javac/generics/inference/6718364/T6718364.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6718364/T6718364.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6718364
  * @summary inference fails when a generic method is invoked with raw arguments
  * @compile/ref=T6718364.out -XDstdout -XDrawDiagnostics -Xlint:unchecked T6718364.java
--- a/test/tools/javac/generics/inference/6718364/T6718364.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/inference/6718364/T6718364.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-T6718364.java:36:32: compiler.warn.prob.found.req: (compiler.misc.unchecked.assign), T6718364.X, T6718364.X<java.lang.Integer>
-T6718364.java:36:10: compiler.warn.unchecked.meth.invocation.applied: kindname.method, m, T6718364.X<T>,T, T6718364.X<T6718364.X<java.lang.Integer>>,T6718364.X, kindname.class, T6718364
-2 warnings
\ No newline at end of file
+T6718364.java:13:32: compiler.warn.prob.found.req: (compiler.misc.unchecked.assign), T6718364.X, T6718364.X<java.lang.Integer>
+T6718364.java:13:10: compiler.warn.unchecked.meth.invocation.applied: kindname.method, m, T6718364.X<T>,T, T6718364.X<T6718364.X<java.lang.Integer>>,T6718364.X, kindname.class, T6718364
+2 warnings
--- a/test/tools/javac/generics/rare/6665356/T6665356.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/rare/6665356/T6665356.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008-2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @author Maurizio Cimadamore
  * @bug     6665356
  * @summary Cast not allowed when both qualifying type and inner class are parameterized
@@ -50,4 +27,4 @@
         o = (Outer.Inner<?>)null;
         o = (Outer<?>.Inner<?>)null;
     }
-}
\ No newline at end of file
+}
--- a/test/tools/javac/generics/rare/6665356/T6665356.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/rare/6665356/T6665356.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,5 +1,5 @@
-T6665356.java:40:37: compiler.err.improperly.formed.type.param.missing
-T6665356.java:41:40: compiler.err.improperly.formed.type.inner.raw.param
-T6665356.java:49:23: compiler.err.improperly.formed.type.param.missing
-T6665356.java:50:25: compiler.err.improperly.formed.type.inner.raw.param
-4 errors
\ No newline at end of file
+T6665356.java:17:37: compiler.err.improperly.formed.type.param.missing
+T6665356.java:18:40: compiler.err.improperly.formed.type.inner.raw.param
+T6665356.java:26:23: compiler.err.improperly.formed.type.param.missing
+T6665356.java:27:25: compiler.err.improperly.formed.type.inner.raw.param
+4 errors
--- a/test/tools/javac/generics/typevars/6569404/T6569404b.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/typevars/6569404/T6569404b.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6569404
  * @summary Regression: Cannot instantiate an inner class of a type variable
  * @author  mcimadamore
--- a/test/tools/javac/generics/typevars/6569404/T6569404b.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/typevars/6569404/T6569404b.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6569404b.java:36:48: compiler.err.type.var.cant.be.deref
+T6569404b.java:13:48: compiler.err.type.var.cant.be.deref
 1 error
--- a/test/tools/javac/generics/typevars/6680106/T6680106.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/typevars/6680106/T6680106.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6680106
  * @summary StackOverFlowError for Cyclic inheritance in TypeParameters with ArrayType Bounds
  * @author  Maurizio Cimadamore
--- a/test/tools/javac/generics/typevars/6680106/T6680106.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/typevars/6680106/T6680106.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,13 +1,13 @@
-T6680106.java:34:25: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
-T6680106.java:35:25: compiler.err.type.found.req: S[], (compiler.misc.type.req.class)
-T6680106.java:35:40: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
-T6680106.java:36:25: compiler.err.type.found.req: S[], (compiler.misc.type.req.class)
-T6680106.java:36:40: compiler.err.type.found.req: U[], (compiler.misc.type.req.class)
-T6680106.java:36:55: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
-T6680106.java:37:30: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
-T6680106.java:38:30: compiler.err.type.found.req: S[], (compiler.misc.type.req.class)
-T6680106.java:38:50: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
-T6680106.java:39:30: compiler.err.type.found.req: S[], (compiler.misc.type.req.class)
-T6680106.java:39:50: compiler.err.type.found.req: U[], (compiler.misc.type.req.class)
-T6680106.java:39:70: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
-12 errors
\ No newline at end of file
+T6680106.java:11:25: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
+T6680106.java:12:25: compiler.err.type.found.req: S[], (compiler.misc.type.req.class)
+T6680106.java:12:40: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
+T6680106.java:13:25: compiler.err.type.found.req: S[], (compiler.misc.type.req.class)
+T6680106.java:13:40: compiler.err.type.found.req: U[], (compiler.misc.type.req.class)
+T6680106.java:13:55: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
+T6680106.java:14:30: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
+T6680106.java:15:30: compiler.err.type.found.req: S[], (compiler.misc.type.req.class)
+T6680106.java:15:50: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
+T6680106.java:16:30: compiler.err.type.found.req: S[], (compiler.misc.type.req.class)
+T6680106.java:16:50: compiler.err.type.found.req: U[], (compiler.misc.type.req.class)
+T6680106.java:16:70: compiler.err.type.found.req: T[], (compiler.misc.type.req.class)
+12 errors
--- a/test/tools/javac/generics/typevars/6804733/T6804733.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/typevars/6804733/T6804733.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6804733
  * @summary javac generates spourious diagnostics for ill-formed type-variable bounds
  * @author  mcimadamore
--- a/test/tools/javac/generics/typevars/6804733/T6804733.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/generics/typevars/6804733/T6804733.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-T6804733.java:34:20: compiler.err.type.var.may.not.be.followed.by.other.bounds
+T6804733.java:11:20: compiler.err.type.var.may.not.be.followed.by.other.bounds
 1 error
--- a/test/tools/javac/innerClassFile/Driver.java	Fri Sep 04 03:08:16 2009 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,33 +0,0 @@
-/*
- * Copyright 2002 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
- * @bug 4491755 4785453
- * @summary Prob w/static inner class with same name as a regular class
- * @author gafter
- *
- * @run shell Driver.sh
- */
-
-// this is not a real source file, just the tags to run this test.
--- a/test/tools/javac/innerClassFile/Driver.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/innerClassFile/Driver.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -23,6 +23,12 @@
 # have any questions.
 #
 
+# @test
+# @bug 4491755 4785453
+# @summary Prob w/static inner class with same name as a regular class
+# @author gafter
+#
+# @run shell Driver.sh
 
 if [ "${TESTSRC}" = "" ]
 then
@@ -47,14 +53,10 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  SunOS | Linux )
-    NULL=/dev/null
-    PS=":"
+  SunOS | Linux | CYGWIN* )
     FS="/"
     ;;
   Windows* )
-    NULL=NUL
-    PS=";"
     FS="\\"
     ;;
   * )
--- a/test/tools/javac/javazip/Test.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/javazip/Test.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -42,14 +42,16 @@
 OS=`uname -s`
 case "$OS" in
   SunOS | Linux )
-    NULL=/dev/null
-    PS=":"
     FS="/"
+    SCR=`pwd`
+    ;;
+  CYGWIN* )
+    FS="/"
+    SCR=`pwd | cygpath -d`
     ;;
   Windows* )
-    NULL=NUL
-    PS=";"
     FS="\\"
+    SCR=`pwd`
     ;;
   * )
     echo "Unrecognized system!"
--- a/test/tools/javac/meth/InvokeMH_BAD68.java	Fri Sep 04 03:08:16 2009 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,75 +0,0 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * ##test
- * ##bug 6754038
- * ##summary Generate call sites for method handle
- * ##author jrose
- *
- * ##compile/fail -source 7 -target 7 InvokeMH_BAD68.java
- */
-
-/*
- * Standalone testing:
- * <code>
- * $ cd $MY_REPO_DIR/langtools
- * $ (cd make; make)
- * $ ./dist/bootstrap/bin/javac -d dist test/tools/javac/meth/InvokeMH_BAD68.java
- * $ javap -c -classpath dist meth.InvokeMH_BAD68
- * </code>
- */
-
-package meth;
-
-import java.dyn.MethodHandle;
-
-public class InvokeMH_BAD68 {
-    void test(MethodHandle mh_SiO,
-              MethodHandle mh_vS,
-              MethodHandle mh_vi,
-              MethodHandle mh_vv) {
-        Object o; String s; int i;  // for return type testing
-
-        // next five must have sig = (String,int)Object
-        mh_SiO.invoke("world", 123);
-        mh_SiO.invoke("mundus", 456);
-        Object k = "kosmos";
-        mh_SiO.invoke((String)k, 789);
-        o = mh_SiO.invoke((String)null, 000);
-        o = mh_SiO.<Object>invoke("arda", -123);
-
-        // sig = ()String
-        s = mh_vS.<String>invoke();
-
-        // sig = ()int
-        i = mh_vi.<int>invoke();
-        o = mh_vi.<int>invoke();
-    s = mh_vi.<int>invoke(); //BAD
-        mh_vi.<int>invoke();
-
-        // sig = ()void
-        //o = mh_vv.<void>invoke(); //BAD
-        mh_vv.<void>invoke();
-    }
-}
--- a/test/tools/javac/meth/InvokeMH_BAD72.java	Fri Sep 04 03:08:16 2009 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,75 +0,0 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * ##test
- * ##bug 6754038
- * ##summary Generate call sites for method handle
- * ##author jrose
- *
- * ##compile/fail -source 7 -target 7 InvokeMH_BAD72.java
- */
-
-/*
- * Standalone testing:
- * <code>
- * $ cd $MY_REPO_DIR/langtools
- * $ (cd make; make)
- * $ ./dist/bootstrap/bin/javac -d dist test/tools/javac/meth/InvokeMH_BAD72.java
- * $ javap -c -classpath dist meth.InvokeMH_BAD72
- * </code>
- */
-
-package meth;
-
-import java.dyn.MethodHandle;
-
-public class InvokeMH_BAD72 {
-    void test(MethodHandle mh_SiO,
-              MethodHandle mh_vS,
-              MethodHandle mh_vi,
-              MethodHandle mh_vv) {
-        Object o; String s; int i;  // for return type testing
-
-        // next five must have sig = (String,int)Object
-        mh_SiO.invoke("world", 123);
-        mh_SiO.invoke("mundus", 456);
-        Object k = "kosmos";
-        mh_SiO.invoke((String)k, 789);
-        o = mh_SiO.invoke((String)null, 000);
-        o = mh_SiO.<Object>invoke("arda", -123);
-
-        // sig = ()String
-        s = mh_vS.<String>invoke();
-
-        // sig = ()int
-        i = mh_vi.<int>invoke();
-        o = mh_vi.<int>invoke();
-        //s = mh_vi.<int>invoke(); //BAD
-        mh_vi.<int>invoke();
-
-        // sig = ()void
-    o = mh_vv.<void>invoke(); //BAD
-        mh_vv.<void>invoke();
-    }
-}
--- a/test/tools/javac/meth/MakeNegTests.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/meth/MakeNegTests.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -78,7 +78,7 @@
 }
 
 getcasestem() {
-  echo "$1" | sed 's/\.java$//;s/_BAD[0-9]*$//;s/$/_BAD/'
+  echo `basename $1` | sed 's/\.java$//;s/_BAD[0-9]*$//;s/$/_BAD/'
 }
 
 testneg() {
--- a/test/tools/javac/newlines/Newlines.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/newlines/Newlines.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -50,14 +50,10 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  SunOS | Linux )
-    NULL=/dev/null
-    PS=":"
+  SunOS | Linux | CYGWIN* )
     FS="/"
     ;;
   Windows* )
-    NULL=NUL
-    PS=";"
     FS="\\"
     ;;
   * )
--- a/test/tools/javac/processing/environment/round/TestElementsAnnotatedWith.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/processing/environment/round/TestElementsAnnotatedWith.java	Mon Sep 21 17:11:48 2009 +0100
@@ -188,14 +188,18 @@
             // Copy the bytes over
             System.out.println((new File(".")).getAbsolutePath());
             InputStream io = new BufferedInputStream(new FileInputStream(new File(".", "Foo.class")));
-            int datum = io.read();
-            while(datum != -1) {
-                os.write(datum);
-                datum = io.read();
+            try {
+                int datum = io.read();
+                while(datum != -1) {
+                    os.write(datum);
+                    datum = io.read();
+                }
+            } finally {
+                io.close();
             }
             os.close();
-        } catch (IOException io) {
-            throw new RuntimeException(io);
+        } catch (IOException ioe) {
+            throw new RuntimeException(ioe);
         }
 
 
--- a/test/tools/javac/quid/MakeNegTests.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/quid/MakeNegTests.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -77,7 +77,7 @@
 }
 
 getcasestem() {
-  echo "$1" | sed 's/\.java$//;s/_BAD[0-9]*$//;s/$/_BAD/'
+  echo `basename $1` | sed 's/.*\///;s/\.java$//;s/_BAD[0-9]*$//;s/$/_BAD/'
 }
 
 testneg() {
--- a/test/tools/javac/quid/QuotedIdent.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/quid/QuotedIdent.java	Mon Sep 21 17:11:48 2009 +0100
@@ -26,6 +26,9 @@
  * @bug 6746458
  * @summary Verify correct lexing of quoted identifiers.
  * @author jrose
+ * @ignore 6877225 test fails on Windows:
+ *      QuotedIdent.java:81: error while writing QuotedIdent.*86: PATH\QuotedIdent$*86.class
+ *      (The filename, directory name, or volume label syntax is incorrect)
  *
  * @library ..
  * @run main quid.QuotedIdent
--- a/test/tools/javac/quid/QuotedIdent2.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/quid/QuotedIdent2.java	Mon Sep 21 17:11:48 2009 +0100
@@ -26,6 +26,9 @@
  * @bug 6746458
  * @summary Verify correct separate compilation of classes with extended identifiers.
  * @author jrose
+ * @ignore 6877225 test fails on Windows:
+ *      QuotedIdent.java:81: error while writing QuotedIdent.*86: PATH\QuotedIdent$*86.class
+ *      (The filename, directory name, or volume label syntax is incorrect)
  *
  * @library ..
  * @run main quid.QuotedIdent2
--- a/test/tools/javac/quid/QuotedIdent_BAD61.java	Fri Sep 04 03:08:16 2009 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,132 +0,0 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * ##test
- * ##bug 6746458
- * ##summary Verify correct lexing of quoted identifiers.
- * ##author jrose
- *
- * ##library ..
- * ##run main quid.QuotedIdent_BAD61
- */
-
-/*
- * Standalone testing:
- * <code>
- * $ cd $MY_REPO_DIR/langtools
- * $ (cd make; make)
- * $ ./dist/bootstrap/bin/javac -d dist test/tools/javac/quid/QuotedIdent_BAD61.java
- * $ java -version  # should print 1.6 or later
- * $ java -cp dist quid.QuotedIdent_BAD61
- * </code>
- */
-
-package quid;
-
-public class QuotedIdent_BAD61 {
-    static void check(int testid, String have, String expect)
-                throws RuntimeException {
-        if ((have == null && have != expect) ||
-                (have != null && !have.equals(expect))) {
-            String msg =
-                "TEST " + testid + ": HAVE \"" +
-                have + "\" EXPECT \"" + expect + "\"";
-            System.out.println("StringConversion: " + msg);
-            throw new RuntimeException(msg);
-        }
-    }
-
-    // negative tests:
-    static class #"" { } //BAD empty ident name
-    //static class #"<foo>" { } //BAD bad char in ident name
-    /*static class /*(//BAD ident name interrupted by newline) #"jump:
-    " { } /* uncomment previous line to attempt class w/ bad name */
-
-    static class #"int" extends Number {
-        final int #"int";
-        #"int"(int #"int") {
-            this.#"int" = #"int";
-        }
-        static #"int" valueOf(int #"int") {
-            return new #"int"(#"int");
-        }
-        public int intValue() { return #"int"; }
-        public long longValue() { return #"int"; }
-        public float floatValue() { return #"int"; }
-        public double doubleValue() { return #"int"; }
-        public String toString() { return String.valueOf(#"int"); }
-    }
-
-    class #"*86" {
-        String #"555-1212"() { return "[*86.555-1212]"; }
-    }
-    static#"*86"#"MAKE-*86"() {   // note close spacing
-        return new QuotedIdent_BAD61().new#"*86"();
-    }
-
-    static String bar() { return "[bar]"; }
-
-    public static void main(String[] args) throws Exception {
-        String s;
-
-        String #"sticky \' wicket" = "wicked ' stick";
-        s = #"sticky ' wicket";
-        check(11, s, "wicked \' stick");
-        check(12, #"s", s);
-        check(13, #"\163", s);
-
-        s = #"QuotedIdent_BAD61".bar();
-        check(21, s, "[bar]");
-
-        s = #"int".valueOf(123).toString();
-        check(22, s, "123");
-
-        s = #"MAKE-*86"().#"555-1212"();
-        check(23, s, "[*86.555-1212]");
-
-        class#"{{{inmost}}}" { }
-        s = new#"{{{inmost}}}"().getClass().getName();
-        if (!s.endsWith("{{{inmost}}}"))
-            check(24, s, "should end with \"{{{inmost}}}\"");
-
-        s = #"Yog-Shoggoth".#"(nameless ululation)";
-        check(25, s, "Tekeli-li!");
-
-        s = #"int".class.getName();
-        check(31, s, QuotedIdent_BAD61.class.getName()+"$int");
-
-        Class x86 = Class.forName(QuotedIdent_BAD61.class.getName()+"$*86");
-        if (x86 != #"*86".class)
-            check(32, "reflected "+x86, "static "+#"*86".class);
-
-        s = (String) x86.getDeclaredMethod("555-1212").invoke(#"MAKE-*86"());
-        check(31, s, "[*86.555-1212]");
-
-        System.out.println("OK");
-    }
-}
-
-interface #"Yog-Shoggoth" {
-    final String #"(nameless ululation)" = "Tekeli-li!";
-}
--- a/test/tools/javac/quid/QuotedIdent_BAD62.java	Fri Sep 04 03:08:16 2009 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,132 +0,0 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * ##test
- * ##bug 6746458
- * ##summary Verify correct lexing of quoted identifiers.
- * ##author jrose
- *
- * ##library ..
- * ##run main quid.QuotedIdent_BAD62
- */
-
-/*
- * Standalone testing:
- * <code>
- * $ cd $MY_REPO_DIR/langtools
- * $ (cd make; make)
- * $ ./dist/bootstrap/bin/javac -d dist test/tools/javac/quid/QuotedIdent_BAD62.java
- * $ java -version  # should print 1.6 or later
- * $ java -cp dist quid.QuotedIdent_BAD62
- * </code>
- */
-
-package quid;
-
-public class QuotedIdent_BAD62 {
-    static void check(int testid, String have, String expect)
-                throws RuntimeException {
-        if ((have == null && have != expect) ||
-                (have != null && !have.equals(expect))) {
-            String msg =
-                "TEST " + testid + ": HAVE \"" +
-                have + "\" EXPECT \"" + expect + "\"";
-            System.out.println("StringConversion: " + msg);
-            throw new RuntimeException(msg);
-        }
-    }
-
-    // negative tests:
-    //static class #"" { } //BAD empty ident name
-    static class #"<foo>" { } //BAD bad char in ident name
-    /*static class /*(//BAD ident name interrupted by newline) #"jump:
-    " { } /* uncomment previous line to attempt class w/ bad name */
-
-    static class #"int" extends Number {
-        final int #"int";
-        #"int"(int #"int") {
-            this.#"int" = #"int";
-        }
-        static #"int" valueOf(int #"int") {
-            return new #"int"(#"int");
-        }
-        public int intValue() { return #"int"; }
-        public long longValue() { return #"int"; }
-        public float floatValue() { return #"int"; }
-        public double doubleValue() { return #"int"; }
-        public String toString() { return String.valueOf(#"int"); }
-    }
-
-    class #"*86" {
-        String #"555-1212"() { return "[*86.555-1212]"; }
-    }
-    static#"*86"#"MAKE-*86"() {   // note close spacing
-        return new QuotedIdent_BAD62().new#"*86"();
-    }
-
-    static String bar() { return "[bar]"; }
-
-    public static void main(String[] args) throws Exception {
-        String s;
-
-        String #"sticky \' wicket" = "wicked ' stick";
-        s = #"sticky ' wicket";
-        check(11, s, "wicked \' stick");
-        check(12, #"s", s);
-        check(13, #"\163", s);
-
-        s = #"QuotedIdent_BAD62".bar();
-        check(21, s, "[bar]");
-
-        s = #"int".valueOf(123).toString();
-        check(22, s, "123");
-
-        s = #"MAKE-*86"().#"555-1212"();
-        check(23, s, "[*86.555-1212]");
-
-        class#"{{{inmost}}}" { }
-        s = new#"{{{inmost}}}"().getClass().getName();
-        if (!s.endsWith("{{{inmost}}}"))
-            check(24, s, "should end with \"{{{inmost}}}\"");
-
-        s = #"Yog-Shoggoth".#"(nameless ululation)";
-        check(25, s, "Tekeli-li!");
-
-        s = #"int".class.getName();
-        check(31, s, QuotedIdent_BAD62.class.getName()+"$int");
-
-        Class x86 = Class.forName(QuotedIdent_BAD62.class.getName()+"$*86");
-        if (x86 != #"*86".class)
-            check(32, "reflected "+x86, "static "+#"*86".class);
-
-        s = (String) x86.getDeclaredMethod("555-1212").invoke(#"MAKE-*86"());
-        check(31, s, "[*86.555-1212]");
-
-        System.out.println("OK");
-    }
-}
-
-interface #"Yog-Shoggoth" {
-    final String #"(nameless ululation)" = "Tekeli-li!";
-}
--- a/test/tools/javac/quid/QuotedIdent_BAD63.java	Fri Sep 04 03:08:16 2009 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,132 +0,0 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * ##test
- * ##bug 6746458
- * ##summary Verify correct lexing of quoted identifiers.
- * ##author jrose
- *
- * ##library ..
- * ##run main quid.QuotedIdent_BAD63
- */
-
-/*
- * Standalone testing:
- * <code>
- * $ cd $MY_REPO_DIR/langtools
- * $ (cd make; make)
- * $ ./dist/bootstrap/bin/javac -d dist test/tools/javac/quid/QuotedIdent_BAD63.java
- * $ java -version  # should print 1.6 or later
- * $ java -cp dist quid.QuotedIdent_BAD63
- * </code>
- */
-
-package quid;
-
-public class QuotedIdent_BAD63 {
-    static void check(int testid, String have, String expect)
-                throws RuntimeException {
-        if ((have == null && have != expect) ||
-                (have != null && !have.equals(expect))) {
-            String msg =
-                "TEST " + testid + ": HAVE \"" +
-                have + "\" EXPECT \"" + expect + "\"";
-            System.out.println("StringConversion: " + msg);
-            throw new RuntimeException(msg);
-        }
-    }
-
-    // negative tests:
-    //static class #"" { } //BAD empty ident name
-    //static class #"<foo>" { } //BAD bad char in ident name
-    static class /*(//BAD ident name interrupted by newline) #"jump:
-    " { } /* uncomment previous line to attempt class w/ bad name */
-
-    static class #"int" extends Number {
-        final int #"int";
-        #"int"(int #"int") {
-            this.#"int" = #"int";
-        }
-        static #"int" valueOf(int #"int") {
-            return new #"int"(#"int");
-        }
-        public int intValue() { return #"int"; }
-        public long longValue() { return #"int"; }
-        public float floatValue() { return #"int"; }
-        public double doubleValue() { return #"int"; }
-        public String toString() { return String.valueOf(#"int"); }
-    }
-
-    class #"*86" {
-        String #"555-1212"() { return "[*86.555-1212]"; }
-    }
-    static#"*86"#"MAKE-*86"() {   // note close spacing
-        return new QuotedIdent_BAD63().new#"*86"();
-    }
-
-    static String bar() { return "[bar]"; }
-
-    public static void main(String[] args) throws Exception {
-        String s;
-
-        String #"sticky \' wicket" = "wicked ' stick";
-        s = #"sticky ' wicket";
-        check(11, s, "wicked \' stick");
-        check(12, #"s", s);
-        check(13, #"\163", s);
-
-        s = #"QuotedIdent_BAD63".bar();
-        check(21, s, "[bar]");
-
-        s = #"int".valueOf(123).toString();
-        check(22, s, "123");
-
-        s = #"MAKE-*86"().#"555-1212"();
-        check(23, s, "[*86.555-1212]");
-
-        class#"{{{inmost}}}" { }
-        s = new#"{{{inmost}}}"().getClass().getName();
-        if (!s.endsWith("{{{inmost}}}"))
-            check(24, s, "should end with \"{{{inmost}}}\"");
-
-        s = #"Yog-Shoggoth".#"(nameless ululation)";
-        check(25, s, "Tekeli-li!");
-
-        s = #"int".class.getName();
-        check(31, s, QuotedIdent_BAD63.class.getName()+"$int");
-
-        Class x86 = Class.forName(QuotedIdent_BAD63.class.getName()+"$*86");
-        if (x86 != #"*86".class)
-            check(32, "reflected "+x86, "static "+#"*86".class);
-
-        s = (String) x86.getDeclaredMethod("555-1212").invoke(#"MAKE-*86"());
-        check(31, s, "[*86.555-1212]");
-
-        System.out.println("OK");
-    }
-}
-
-interface #"Yog-Shoggoth" {
-    final String #"(nameless ululation)" = "Tekeli-li!";
-}
--- a/test/tools/javac/stackmap/T4955930.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/stackmap/T4955930.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -41,7 +41,7 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  SunOS | Linux )
+  SunOS | Linux | CYGWIN* )
     FS="/"
     ;;
   Windows_95 | Windows_98 | Windows_NT )
--- a/test/tools/javac/typeAnnotations/failures/AnnotationVersion.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/AnnotationVersion.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test that only java 7 allows type annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/AnnotationVersion.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/AnnotationVersion.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-AnnotationVersion.java:32:25: compiler.err.type.annotations.not.supported.in.source: 1.6
+AnnotationVersion.java:9:25: compiler.err.type.annotations.not.supported.in.source: 1.6
 1 error
--- a/test/tools/javac/typeAnnotations/failures/IncompleteArray.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/IncompleteArray.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test incomplete array declaration
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/IncompleteArray.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/IncompleteArray.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-IncompleteArray.java:32:13: compiler.err.illegal.start.of.type
+IncompleteArray.java:9:13: compiler.err.illegal.start.of.type
 1 error
--- a/test/tools/javac/typeAnnotations/failures/IncompleteVararg.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/IncompleteVararg.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test incomplete vararg declaration
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/IncompleteVararg.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/IncompleteVararg.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-IncompleteVararg.java:33:19: compiler.err.illegal.start.of.type
+IncompleteVararg.java:10:19: compiler.err.illegal.start.of.type
 1 error
--- a/test/tools/javac/typeAnnotations/failures/IndexArray.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/IndexArray.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test indexing of an array
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/IndexArray.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/IndexArray.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-IndexArray.java:33:15: compiler.err.illegal.start.of.expr
+IndexArray.java:10:15: compiler.err.illegal.start.of.expr
 1 error
--- a/test/tools/javac/typeAnnotations/failures/LintCast.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/LintCast.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,30 +1,7 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 import java.util.List;
 
 /*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test that compiler doesn't warn about annotated redundant casts
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/LintCast.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/LintCast.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,6 +1,6 @@
-LintCast.java:36:21: compiler.warn.redundant.cast: java.lang.String
-LintCast.java:42:27: compiler.warn.redundant.cast: java.util.List<java.lang.String>
-LintCast.java:48:20: compiler.warn.redundant.cast: int[]
-LintCast.java:60:24: compiler.warn.redundant.cast: java.lang.String
-LintCast.java:61:26: compiler.warn.redundant.cast: java.lang.String
+LintCast.java:13:21: compiler.warn.redundant.cast: java.lang.String
+LintCast.java:19:27: compiler.warn.redundant.cast: java.util.List<java.lang.String>
+LintCast.java:25:20: compiler.warn.redundant.cast: int[]
+LintCast.java:37:24: compiler.warn.redundant.cast: java.lang.String
+LintCast.java:38:26: compiler.warn.redundant.cast: java.lang.String
 5 warnings
--- a/test/tools/javac/typeAnnotations/failures/Scopes.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/Scopes.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check that A is accessible in the class type parameters
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/Scopes.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/Scopes.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-Scopes.java:31:25: compiler.err.cant.resolve: kindname.class, UniqueInner, , 
+Scopes.java:8:25: compiler.err.cant.resolve: kindname.class, UniqueInner, , 
 1 error
--- a/test/tools/javac/typeAnnotations/failures/StaticFields.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/StaticFields.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary static field access isn't a valid location
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/StaticFields.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/StaticFields.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-StaticFields.java:33:17: compiler.err.illegal.start.of.expr
+StaticFields.java:10:17: compiler.err.illegal.start.of.expr
 1 error
--- a/test/tools/javac/typeAnnotations/failures/StaticMethods.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/StaticMethods.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary static methods don't have receivers
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/StaticMethods.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/StaticMethods.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-StaticMethods.java:32:22: compiler.err.annotation.type.not.applicable
+StaticMethods.java:9:22: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/arrayclass/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrayclass/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotation values
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/arrayclass/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrayclass/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:33:45: compiler.err.duplicate.annotation.member.value: value, A
+DuplicateAnnotationValue.java:10:45: compiler.err.duplicate.annotation.member.value: value, A
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/arrayclass/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrayclass/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/arrayclass/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrayclass/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:34:26: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:11:26: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/arrayclass/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrayclass/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/arrayclass/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrayclass/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:34:23: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:11:23: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/arrayclass/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrayclass/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/arrayclass/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrayclass/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:33:23: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:10:23: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/arrays/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrays/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotation values
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/arrays/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrays/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:33:34: compiler.err.duplicate.annotation.member.value: value, A
+DuplicateAnnotationValue.java:10:34: compiler.err.duplicate.annotation.member.value: value, A
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/arrays/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrays/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/arrays/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrays/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:34:15: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:11:15: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/arrays/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrays/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/arrays/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrays/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:34:12: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:11:12: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/arrays/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrays/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/arrays/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/arrays/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:33:12: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:10:12: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/innertypeparams/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/innertypeparams/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotation values for type parameter
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/innertypeparams/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/innertypeparams/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:33:39: compiler.err.duplicate.annotation.member.value: value, A
+DuplicateAnnotationValue.java:10:39: compiler.err.duplicate.annotation.member.value: value, A
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/innertypeparams/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/innertypeparams/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/innertypeparams/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/innertypeparams/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:33:20: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:10:20: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/innertypeparams/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/innertypeparams/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/innertypeparams/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/innertypeparams/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:33:17: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:10:17: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/innertypeparams/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/innertypeparams/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/innertypeparams/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/innertypeparams/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:33:17: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:10:17: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/newarray/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/newarray/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotation values
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/newarray/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/newarray/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:33:51: compiler.err.duplicate.annotation.member.value: value, A
+DuplicateAnnotationValue.java:10:51: compiler.err.duplicate.annotation.member.value: value, A
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/newarray/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/newarray/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/newarray/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/newarray/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:34:32: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:11:32: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/newarray/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/newarray/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/newarray/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/newarray/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:34:29: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:11:29: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/newarray/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/newarray/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/newarray/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/newarray/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:33:29: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:10:29: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/parambounds/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/parambounds/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotation values for type parameter
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/parambounds/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/parambounds/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:31:64: compiler.err.duplicate.annotation.member.value: value, A
+DuplicateAnnotationValue.java:8:64: compiler.err.duplicate.annotation.member.value: value, A
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/parambounds/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/parambounds/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/parambounds/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/parambounds/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:32:38: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:9:38: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/parambounds/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/parambounds/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/parambounds/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/parambounds/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:32:33: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:9:33: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/parambounds/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/parambounds/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/parambounds/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/parambounds/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:31:40: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:8:40: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/receiver/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/receiver/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotation values in receiver
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/receiver/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/receiver/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:32:37: compiler.err.duplicate.annotation.member.value: value, A
+DuplicateAnnotationValue.java:9:37: compiler.err.duplicate.annotation.member.value: value, A
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/receiver/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/receiver/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations in receiver
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/receiver/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/receiver/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:33:18: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:10:18: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/receiver/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/receiver/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/receiver/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/receiver/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:33:15: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:10:15: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/receiver/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/receiver/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/receiver/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/receiver/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:32:15: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:9:15: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/rest/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/rest/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for Duplicate annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/rest/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/rest/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:33:9: compiler.err.annotation.missing.default.value: A, field
+DuplicateAnnotationValue.java:10:9: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/rest/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/rest/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/rest/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/rest/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:34:12: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:11:12: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/rest/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/rest/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/rest/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/rest/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:34:9: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:11:9: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/rest/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/rest/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/rest/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/rest/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:33:9: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:10:9: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/typeArgs/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeArgs/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotation values for type parameter
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/typeArgs/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeArgs/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:32:50: compiler.err.duplicate.annotation.member.value: value, A
+DuplicateAnnotationValue.java:9:50: compiler.err.duplicate.annotation.member.value: value, A
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/typeArgs/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeArgs/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/typeArgs/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeArgs/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:33:24: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:10:24: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/typeArgs/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeArgs/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/typeArgs/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeArgs/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:33:19: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:10:19: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/typeArgs/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeArgs/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/typeArgs/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeArgs/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:32:26: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:9:26: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/typeparams/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeparams/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotation values for type parameter
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/typeparams/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeparams/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:31:54: compiler.err.duplicate.annotation.member.value: value, A
+DuplicateAnnotationValue.java:8:54: compiler.err.duplicate.annotation.member.value: value, A
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/typeparams/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeparams/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/typeparams/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeparams/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:32:28: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:9:28: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/typeparams/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeparams/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/typeparams/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeparams/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:32:23: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:9:23: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/typeparams/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeparams/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/typeparams/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/typeparams/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:31:30: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:8:30: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/wildcards/DuplicateAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/wildcards/DuplicateAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotation values for type parameter
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/wildcards/DuplicateAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/wildcards/DuplicateAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateAnnotationValue.java:32:50: compiler.err.duplicate.annotation.member.value: value, A
+DuplicateAnnotationValue.java:9:50: compiler.err.duplicate.annotation.member.value: value, A
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/wildcards/DuplicateTypeAnnotation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/wildcards/DuplicateTypeAnnotation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for duplicate annotations
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/wildcards/DuplicateTypeAnnotation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/wildcards/DuplicateTypeAnnotation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-DuplicateTypeAnnotation.java:33:24: compiler.err.duplicate.annotation
+DuplicateTypeAnnotation.java:10:24: compiler.err.duplicate.annotation
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/wildcards/InvalidLocation.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/wildcards/InvalidLocation.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for invalid annotatins given the target
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/wildcards/InvalidLocation.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/wildcards/InvalidLocation.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-InvalidLocation.java:33:19: compiler.err.annotation.type.not.applicable
+InvalidLocation.java:10:19: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/common/wildcards/MissingAnnotationValue.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/wildcards/MissingAnnotationValue.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary check for missing annotation value
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/common/wildcards/MissingAnnotationValue.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/common/wildcards/MissingAnnotationValue.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-MissingAnnotationValue.java:32:26: compiler.err.annotation.missing.default.value: A, field
+MissingAnnotationValue.java:9:26: compiler.err.annotation.missing.default.value: A, field
 1 error
--- a/test/tools/javac/typeAnnotations/failures/target/Constructor.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/Constructor.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test invalid location of TypeUse
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/target/Constructor.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/Constructor.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-Constructor.java:36:3: compiler.err.annotation.type.not.applicable
+Constructor.java:13:3: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/target/IncompleteArray.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/IncompleteArray.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test incomplete array declaration
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/target/IncompleteArray.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/IncompleteArray.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-IncompleteArray.java:32:13: compiler.err.illegal.start.of.type
+IncompleteArray.java:9:13: compiler.err.illegal.start.of.type
 1 error
--- a/test/tools/javac/typeAnnotations/failures/target/NotTypeParameter.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/NotTypeParameter.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test invalid location of TypeUse
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/target/NotTypeParameter.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/NotTypeParameter.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,3 +1,3 @@
-NotTypeParameter.java:36:3: compiler.err.annotation.type.not.applicable
-NotTypeParameter.java:35:18: compiler.err.annotation.type.not.applicable
+NotTypeParameter.java:13:3: compiler.err.annotation.type.not.applicable
+NotTypeParameter.java:12:18: compiler.err.annotation.type.not.applicable
 2 errors
--- a/test/tools/javac/typeAnnotations/failures/target/NotTypeUse.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/NotTypeUse.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test invalid location of TypeUse
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/target/NotTypeUse.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/NotTypeUse.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-NotTypeUse.java:36:3: compiler.err.annotation.type.not.applicable
+NotTypeUse.java:13:3: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/typeAnnotations/failures/target/VoidMethod.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/VoidMethod.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6843077
  * @summary test invalid location of TypeUse
  * @author Mahmood Ali
--- a/test/tools/javac/typeAnnotations/failures/target/VoidMethod.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/typeAnnotations/failures/target/VoidMethod.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,2 +1,2 @@
-VoidMethod.java:36:3: compiler.err.annotation.type.not.applicable
+VoidMethod.java:13:3: compiler.err.annotation.type.not.applicable
 1 error
--- a/test/tools/javac/unicode/SupplementaryJavaID6.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/unicode/SupplementaryJavaID6.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -75,6 +75,11 @@
     PS=";"
     FS="\\"
     ;;
+  CYGWIN* )
+    ENV=""
+    PS=";" # platform PS, not cygwin PS
+    FS="/"
+    ;;
   * )
     echo "Unrecognized system!"
     exit 1;
--- a/test/tools/javac/varargs/6806876/T6806876.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/varargs/6806876/T6806876.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
 /*
- * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
-/*
- * @test
+ * @test /nodynamiccopyright/
  * @bug     6806876
  * @author mcimadamore
  * @summary  ClassCastException occurs in assignment expressions without any heap pollutions
@@ -37,4 +14,4 @@
     <T> T[] m(T...a) {
         return null;
     }
-}
\ No newline at end of file
+}
--- a/test/tools/javac/varargs/6806876/T6806876.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/varargs/6806876/T6806876.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,4 +1,4 @@
-T6806876.java:34:32: compiler.warn.unchecked.generic.array.creation: java.lang.Number&java.lang.Comparable<? extends java.lang.Number&java.lang.Comparable<?>>[]
+T6806876.java:11:32: compiler.warn.unchecked.generic.array.creation: java.lang.Number&java.lang.Comparable<? extends java.lang.Number&java.lang.Comparable<?>>[]
 - compiler.err.warnings.and.werror
 1 error
 1 warning
--- a/test/tools/javac/warnings/6747671/T6747671.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/warnings/6747671/T6747671.java	Mon Sep 21 17:11:48 2009 +0100
@@ -1,28 +1,5 @@
-/*
- * Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- */
-
 /**
- * @test
+ * @test /nodynamiccopyright/
  * @bug 6747671
  * @summary -Xlint:rawtypes
  * @compile/ref=T6747671.out -XDrawDiagnostics -Xlint:rawtypes T6747671.java
@@ -55,4 +32,4 @@
         A a2 = new A() {};//raw warning (2)
         a2.new Z() {};//raw warning
     }
-}
\ No newline at end of file
+}
--- a/test/tools/javac/warnings/6747671/T6747671.out	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javac/warnings/6747671/T6747671.out	Mon Sep 21 17:11:48 2009 +0100
@@ -1,12 +1,12 @@
-T6747671.java:42:6: compiler.warn.raw.class.use: T6747671.A.X, T6747671<E>.A<X>.X
-T6747671.java:43:6: compiler.warn.raw.class.use: T6747671.A.Z, T6747671<E>.A<X>.Z<Y>
-T6747671.java:46:13: compiler.warn.raw.class.use: T6747671.B, T6747671.B<X>
-T6747671.java:50:14: compiler.warn.raw.class.use: T6747671.B, T6747671.B<X>
-T6747671.java:50:7: compiler.warn.raw.class.use: T6747671.B, T6747671.B<X>
-T6747671.java:52:28: compiler.warn.raw.class.use: T6747671.B, T6747671.B<X>
-T6747671.java:53:37: compiler.warn.raw.class.use: T6747671.A, T6747671<E>.A<X>
-T6747671.java:54:21: compiler.warn.raw.class.use: T6747671.A, T6747671<E>.A<X>
-T6747671.java:55:9: compiler.warn.raw.class.use: T6747671.A, T6747671<E>.A<X>
-T6747671.java:55:20: compiler.warn.raw.class.use: T6747671.A, T6747671<E>.A<X>
-T6747671.java:56:16: compiler.warn.raw.class.use: T6747671.A.Z, T6747671<E>.A<X>.Z<Y>
-11 warnings
\ No newline at end of file
+T6747671.java:19:6: compiler.warn.raw.class.use: T6747671.A.X, T6747671<E>.A<X>.X
+T6747671.java:20:6: compiler.warn.raw.class.use: T6747671.A.Z, T6747671<E>.A<X>.Z<Y>
+T6747671.java:23:13: compiler.warn.raw.class.use: T6747671.B, T6747671.B<X>
+T6747671.java:27:14: compiler.warn.raw.class.use: T6747671.B, T6747671.B<X>
+T6747671.java:27:7: compiler.warn.raw.class.use: T6747671.B, T6747671.B<X>
+T6747671.java:29:28: compiler.warn.raw.class.use: T6747671.B, T6747671.B<X>
+T6747671.java:30:37: compiler.warn.raw.class.use: T6747671.A, T6747671<E>.A<X>
+T6747671.java:31:21: compiler.warn.raw.class.use: T6747671.A, T6747671<E>.A<X>
+T6747671.java:32:9: compiler.warn.raw.class.use: T6747671.A, T6747671<E>.A<X>
+T6747671.java:32:20: compiler.warn.raw.class.use: T6747671.A, T6747671<E>.A<X>
+T6747671.java:33:16: compiler.warn.raw.class.use: T6747671.A.Z, T6747671<E>.A<X>.Z<Y>
+11 warnings
--- a/test/tools/javah/6257087/foo.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javah/6257087/foo.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -42,12 +42,15 @@
 OS=`uname -s`
 case "$OS" in
   SunOS | Linux )
-    NULL=/dev/null
     PS=":"
     FS="/"
     ;;
+  CYGWIN* )
+    PS=":"
+    FS="/"
+    DIFFOPTS="--strip-trailing-cr"
+    ;;
   Windows* )
-    NULL=NUL
     PS=";"
     FS="\\"
     ;;
@@ -57,9 +60,9 @@
     ;;
 esac
 
-"${TESTJAVA}${FS}bin${FS}javac" ${TESTTOOLVMOPTS} -d "${TC}" "${TS}${FS}foo.java" > ${NULL}
+"${TESTJAVA}${FS}bin${FS}javac" ${TESTTOOLVMOPTS} -d "${TC}" "${TS}${FS}foo.java" 
 "${TESTJAVA}${FS}bin${FS}javah" ${TESTTOOLVMOPTS} -classpath "${TC}" -d "${TC}" foo
-diff -c "${TS}${FS}foo_bar.h" "${TC}${FS}foo_bar.h"
+diff ${DIFFOPTS} -c "${TS}${FS}foo_bar.h" "${TC}${FS}foo_bar.h"
 result=$?
 
 if [ $result -eq 0 ]
--- a/test/tools/javah/ConstMacroTest.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javah/ConstMacroTest.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -57,12 +57,16 @@
 OS=`uname -s`
 case "$OS" in
   SunOS | Linux )
-    NULL=/dev/null
     PS=":"
     FS="/"
     ;;
+  CYGWIN* )
+    PS=":"
+    FS="/"
+    DIFFOPTS="--strip-trailing-cr"
+    EXPECTED_JAVAH_OUT_FILE=SubClassConsts.win
+    ;;
   Windows* )
-    NULL=NUL
     PS=";"
     FS="\\"
     EXPECTED_JAVAH_OUT_FILE=SubClassConsts.win
@@ -85,7 +89,7 @@
 
 "${TESTJAVA}${FS}bin${FS}javah" ${TESTTOOLVMOPTS} SubClassConsts
 
-cmp  "${TESTSRC}${FS}${EXPECTED_JAVAH_OUT_FILE}" "${GENERATED_HEADER_FILE}"
+diff ${DIFFOPTS} "${TESTSRC}${FS}${EXPECTED_JAVAH_OUT_FILE}" "${GENERATED_HEADER_FILE}"
 result=$?
 rm ${GENERATED_HEADER_FILE}
 
--- a/test/tools/javah/MissingParamClassTest.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javah/MissingParamClassTest.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -58,13 +58,11 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  SunOS | Linux )
-    NULL=/dev/null
+  SunOS | Linux | CYGWIN* )
     PS=":"
     FS="/"
     ;;
   Windows* )
-    NULL=NUL
     PS=";"
     FS="\\"
     ;;
--- a/test/tools/javah/ReadOldClass.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javah/ReadOldClass.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -43,13 +43,11 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  SunOS | Linux )
-    NULL=/dev/null
+  SunOS | Linux | CYGWIN* )
     PS=":"
     FS="/"
     ;;
   Windows* )
-    NULL=NUL
     PS=";"
     FS="\\"
     ;;
--- a/test/tools/javah/SubClassConsts.win	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javah/SubClassConsts.win	Mon Sep 21 17:11:48 2009 +0100
@@ -1,31 +1,31 @@
-/* DO NOT EDIT THIS FILE - it is machine generated */
-#include <jni.h>
-/* Header for class SubClassConsts */
-
-#ifndef _Included_SubClassConsts
-#define _Included_SubClassConsts
-#ifdef __cplusplus
-extern "C" {
-#endif
-#undef SubClassConsts_serialVersionUID
-#define SubClassConsts_serialVersionUID 6733861379283244755i64
-#undef SubClassConsts_SUPER_INT_CONSTANT
-#define SubClassConsts_SUPER_INT_CONSTANT 3L
-#undef SubClassConsts_SUPER_FLOAT_CONSTANT
-#define SubClassConsts_SUPER_FLOAT_CONSTANT 99.3f
-#undef SubClassConsts_SUPER_DOUBLE_CONSTANT
-#define SubClassConsts_SUPER_DOUBLE_CONSTANT 33.2
-#undef SubClassConsts_SUPER_BOOLEAN_CONSTANT
-#define SubClassConsts_SUPER_BOOLEAN_CONSTANT 0L
-#undef SubClassConsts_SUB_INT_CONSTANT
-#define SubClassConsts_SUB_INT_CONSTANT 2L
-#undef SubClassConsts_SUB_DOUBLE_CONSTANT
-#define SubClassConsts_SUB_DOUBLE_CONSTANT 2.25
-#undef SubClassConsts_SUB_FLOAT_CONSTANT
-#define SubClassConsts_SUB_FLOAT_CONSTANT 7.9f
-#undef SubClassConsts_SUB_BOOLEAN_CONSTANT
-#define SubClassConsts_SUB_BOOLEAN_CONSTANT 1L
-#ifdef __cplusplus
-}
-#endif
-#endif
+/* DO NOT EDIT THIS FILE - it is machine generated */
+#include <jni.h>
+/* Header for class SubClassConsts */
+
+#ifndef _Included_SubClassConsts
+#define _Included_SubClassConsts
+#ifdef __cplusplus
+extern "C" {
+#endif
+#undef SubClassConsts_serialVersionUID
+#define SubClassConsts_serialVersionUID 6733861379283244755i64
+#undef SubClassConsts_SUPER_INT_CONSTANT
+#define SubClassConsts_SUPER_INT_CONSTANT 3L
+#undef SubClassConsts_SUPER_FLOAT_CONSTANT
+#define SubClassConsts_SUPER_FLOAT_CONSTANT 99.3f
+#undef SubClassConsts_SUPER_DOUBLE_CONSTANT
+#define SubClassConsts_SUPER_DOUBLE_CONSTANT 33.2
+#undef SubClassConsts_SUPER_BOOLEAN_CONSTANT
+#define SubClassConsts_SUPER_BOOLEAN_CONSTANT 0L
+#undef SubClassConsts_SUB_INT_CONSTANT
+#define SubClassConsts_SUB_INT_CONSTANT 2L
+#undef SubClassConsts_SUB_DOUBLE_CONSTANT
+#define SubClassConsts_SUB_DOUBLE_CONSTANT 2.25
+#undef SubClassConsts_SUB_FLOAT_CONSTANT
+#define SubClassConsts_SUB_FLOAT_CONSTANT 7.9f
+#undef SubClassConsts_SUB_BOOLEAN_CONSTANT
+#define SubClassConsts_SUB_BOOLEAN_CONSTANT 1L
+#ifdef __cplusplus
+}
+#endif
+#endif
--- a/test/tools/javap/T4975569.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javap/T4975569.java	Mon Sep 21 17:11:48 2009 +0100
@@ -65,6 +65,7 @@
     int errors;
 
     String javap(String className) {
+        String newline = System.getProperty("line.separator");
         String testClasses = System.getProperty("test.classes", ".");
         StringWriter sw = new StringWriter();
         PrintWriter out = new PrintWriter(sw);
@@ -73,7 +74,7 @@
         if (rc != 0)
             throw new Error("javap failed. rc=" + rc);
         out.close();
-        String output = sw.toString();
+        String output = sw.toString().replaceAll(newline, "\n");
         System.out.println("class " + className);
         System.out.println(output);
         return output;
--- a/test/tools/javap/T6729471.java	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javap/T6729471.java	Mon Sep 21 17:11:48 2009 +0100
@@ -29,6 +29,7 @@
  */
 
 import java.io.*;
+import java.net.*;
 import java.util.*;
 
 public class T6729471
@@ -59,14 +60,22 @@
         if (java_home.getName().equals("jre"))
             java_home = java_home.getParentFile();
         File rt_jar = new File(new File(new File(java_home, "jre"), "lib"), "rt.jar");
-        verify("jar:file:" + rt_jar + "!/java/util/Map.class",
+        try {
+            verify("jar:" + rt_jar.toURL() + "!/java/util/Map.class",
                 "public abstract boolean containsKey(java.lang.Object)");
+        } catch (MalformedURLException e) {
+            error(e.toString());
+        }
 
         // jar url: ct.sym, if it exists
         File ct_sym = new File(new File(java_home, "lib"), "ct.sym");
         if (ct_sym.exists()) {
-            verify("jar:file:" + ct_sym + "!/META-INF/sym/rt.jar/java/util/Map.class",
-                "public abstract boolean containsKey(java.lang.Object)");
+            try {
+                verify("jar:" + ct_sym.toURL() + "!/META-INF/sym/rt.jar/java/util/Map.class",
+                    "public abstract boolean containsKey(java.lang.Object)");
+            } catch (MalformedURLException e) {
+                error(e.toString());
+            }
         } else
             System.err.println("warning: ct.sym not found");
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/javap/T6879371.java	Mon Sep 21 17:11:48 2009 +0100
@@ -0,0 +1,119 @@
+/*
+ * Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ */
+
+/*
+ * @test
+ * @bug 6879371
+ * @summary javap does not close internal default file manager
+ */
+
+import java.io.*;
+import java.util.zip.*;
+
+public class T6879371 {
+    public static void main(String[] args) throws Exception {
+        new T6879371().run();
+    }
+
+    public void run() throws Exception {
+        // create a simple test class which we can put into
+        // a test zip file and know that it will be used by
+        // javap.
+        File classDir = new File("classes");
+        classDir.mkdir();
+
+        String className = "Test";
+        File javaFile = writeTestFile(className);
+        compileTestFile(classDir, javaFile);
+
+        test(classDir, className, false);
+        test(classDir, className, true);
+    }
+
+    void test(File classDir, String className, boolean useJavaUtilZip) throws Exception {
+        // javac should really not be using system properties like this
+        // -- it should really be using (hidden) options -- but until then
+        // take care to leave system properties as we find them, so as not
+        // to adversely affect other tests that might follow.
+        String prev = System.getProperty("useJavaUtilZip");
+        setProperty("useJavaUtilZip", (useJavaUtilZip ? "true" : null));
+        try {
+            File zipFile = zip(classDir, new File(classDir + ".zip"));
+            javap("-classpath", zipFile.getPath(), className);
+
+            if (!zipFile.delete())
+                throw new Exception("failed to delete " + zipFile);
+        } finally {
+            setProperty("useJavaUtilZip", prev);
+        }
+    }
+
+    File writeTestFile(String name) throws IOException {
+        File f = new File(name + ".java");
+        PrintWriter out = new PrintWriter(new BufferedWriter(new FileWriter(f)));
+        out.println("class " + name + " { }");
+        out.close();
+        return f;
+    }
+
+    void compileTestFile(File classDir, File file) {
+        int rc = com.sun.tools.javac.Main.compile(
+           new String[] { "-d", classDir.getPath(), file.getPath() });
+        if (rc != 0)
+            throw new Error("compilation failed. rc=" + rc);
+    }
+
+    File zip(File dir, File zipFile) throws IOException {
+        ZipOutputStream zipOut = new ZipOutputStream(new FileOutputStream(zipFile));
+        for (File file: dir.listFiles()) {
+            if (file.isFile()) {
+                byte[] data = new byte[(int) file.length()];
+                DataInputStream in = new DataInputStream(new FileInputStream(file));
+                in.readFully(data);
+                in.close();
+                zipOut.putNextEntry(new ZipEntry(file.getName()));
+                zipOut.write(data, 0, data.length);
+                zipOut.closeEntry();
+            }
+        }
+        zipOut.close();
+        return zipFile;
+    }
+
+    String javap(String... args) {
+        StringWriter sw = new StringWriter();
+        PrintWriter out = new PrintWriter(sw);
+        int rc = com.sun.tools.javap.Main.run(args, out);
+        if (rc != 0)
+            throw new Error("javap failed. rc=" + rc);
+        out.close();
+        return sw.toString();
+    }
+
+    void setProperty(String key, String value) {
+        if (value != null)
+            System.setProperty(key, value);
+        else
+            System.getProperties().remove(key);
+    }
+}
--- a/test/tools/javap/pathsep.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javap/pathsep.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -40,7 +40,7 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  SunOS | Linux )
+  SunOS | Linux | CYGWIN* )
     FS="/"
     ;;
   Windows* )
--- a/test/tools/javap/stackmap/T6271292.sh	Fri Sep 04 03:08:16 2009 +0100
+++ b/test/tools/javap/stackmap/T6271292.sh	Mon Sep 21 17:11:48 2009 +0100
@@ -53,7 +53,7 @@
 # set platform-dependent variables
 OS=`uname -s`
 case "$OS" in
-  CYGWIN* | Windows* )
+  Windows* )
     FS="\\"
     ;;
   * )