changeset 1208:36fbf759ab8d

8074972: Unused imports, a missing javadoc and a build warning Reviewed-by: hannesw, lagergren
author sundar
date Wed, 11 Mar 2015 16:58:04 +0530
parents 3b5da5474965
children 13b4d61fac98
files src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/scripting/AbstractJSObject.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/BreakTree.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/BreakTreeImpl.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ContinueTree.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ContinueTreeImpl.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/DiagnosticImpl.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForLoopTree.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForLoopTreeImpl.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/NewTree.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/Tree.java src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/ir/ErrorNode.java
diffstat 11 files changed, 9 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/scripting/AbstractJSObject.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/scripting/AbstractJSObject.java	Wed Mar 11 16:58:04 2015 +0530
@@ -250,6 +250,7 @@
      *
      * @return this object's numeric value.
      */
+    @SuppressWarnings("deprecation")
     @Override
     public double toNumber() {
         return Double.NaN;
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/BreakTree.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/BreakTree.java	Wed Mar 11 16:58:04 2015 +0530
@@ -45,5 +45,6 @@
      *
      * @return label associated with this break statement.
      */
+    @Override
     String getLabel();
 }
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/BreakTreeImpl.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/BreakTreeImpl.java	Wed Mar 11 16:58:04 2015 +0530
@@ -26,7 +26,6 @@
 package jdk.nashorn.api.tree;
 
 import jdk.nashorn.internal.ir.BreakNode;
-import jdk.nashorn.internal.ir.IdentNode;
 
 final class BreakTreeImpl extends StatementTreeImpl implements BreakTree {
     private final String label;
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ContinueTree.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ContinueTree.java	Wed Mar 11 16:58:04 2015 +0530
@@ -44,5 +44,6 @@
      *
      * @return label associated with this continue statement.
      */
+    @Override
     String getLabel();
 }
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ContinueTreeImpl.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ContinueTreeImpl.java	Wed Mar 11 16:58:04 2015 +0530
@@ -26,7 +26,6 @@
 package jdk.nashorn.api.tree;
 
 import jdk.nashorn.internal.ir.ContinueNode;
-import jdk.nashorn.internal.ir.IdentNode;
 
 final class ContinueTreeImpl extends StatementTreeImpl implements ContinueTree {
     private final String label;
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/DiagnosticImpl.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/DiagnosticImpl.java	Wed Mar 11 16:58:04 2015 +0530
@@ -27,7 +27,6 @@
 
 import jdk.nashorn.internal.parser.Token;
 import jdk.nashorn.internal.runtime.ParserException;
-import jdk.nashorn.internal.runtime.Source;
 
 final class DiagnosticImpl implements Diagnostic {
     private final ParserException exp;
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForLoopTree.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForLoopTree.java	Wed Mar 11 16:58:04 2015 +0530
@@ -50,6 +50,7 @@
      *
      * @return the condition expression
      */
+    @Override
     ExpressionTree getCondition();
 
     /**
@@ -64,5 +65,6 @@
      *
      * @return the statement
      */
+    @Override
     StatementTree getStatement();
 }
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForLoopTreeImpl.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/ForLoopTreeImpl.java	Wed Mar 11 16:58:04 2015 +0530
@@ -25,7 +25,6 @@
 
 package jdk.nashorn.api.tree;
 
-import java.util.List;
 import jdk.nashorn.internal.ir.ForNode;
 
 final class ForLoopTreeImpl extends StatementTreeImpl implements ForLoopTree {
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/NewTree.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/NewTree.java	Wed Mar 11 16:58:04 2015 +0530
@@ -25,8 +25,6 @@
 
 package jdk.nashorn.api.tree;
 
-import java.util.List;
-
 /**
  * A tree node to declare a new instance of a class.
  *
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/Tree.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/api/tree/Tree.java	Wed Mar 11 16:58:04 2015 +0530
@@ -530,6 +530,10 @@
             associatedInterface = intf;
         }
 
+       /**
+        * Returns the associated interface type that uses this kind.
+        * @return the associated interface
+        */
         public Class<? extends Tree> asInterface() {
             return associatedInterface;
         }
--- a/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/ir/ErrorNode.java	Wed Mar 11 11:08:22 2015 +0100
+++ b/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/internal/ir/ErrorNode.java	Wed Mar 11 16:58:04 2015 +0530
@@ -25,7 +25,6 @@
 
 package jdk.nashorn.internal.ir;
 
-import java.util.function.Function;
 import jdk.nashorn.internal.codegen.types.Type;
 import jdk.nashorn.internal.ir.annotations.Immutable;
 import jdk.nashorn.internal.ir.visitor.NodeVisitor;