This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Patch: cleanup all over


Hi list,


I just merged the attached patch from GNU classpath.


Michael


2004-05-05  Tom Tromey  <tromey@redhat.com>

	* java/text/Format.java: Cleaned up imports.
	* java/text/DecimalFormat.java: Cleaned up imports.
	* java/security/SecureRandom.java: Cleaned up imports.
	(SecureRandom): Removed unused variable.
	* java/security/UnresolvedPermission.java: Cleaned up imports.
	* java/util/Date.java (parse): Removed unused variable.
	* java/util/ResourceBundle.java: Cleaned up imports.
	(getBundle): Removed unused variable.
	(tryBundle): Likewise.
	* java/util/regex/Pattern.java (Pattern): Removed unused constructor.

Index: java/security/SecureRandom.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/security/SecureRandom.java,v
retrieving revision 1.11
diff -u -r1.11 SecureRandom.java
--- java/security/SecureRandom.java	10 May 2003 07:12:47 -0000	1.11
+++ java/security/SecureRandom.java	5 May 2004 06:36:29 -0000
@@ -37,12 +37,11 @@
 
 package java.security;
 
-import java.io.Serializable;
-import java.util.Random;
-import java.util.Enumeration;
-
 import gnu.java.security.Engine;
 
+import java.util.Enumeration;
+import java.util.Random;
+
 /**
  * An interface to a cryptographically secure pseudo-random number
  * generator (PRNG). Random (or at least unguessable) numbers are used
@@ -94,7 +93,7 @@
     String key;
 
     String classname = null;
-    int i, flag = 0;
+    int i;
     Enumeration e;
     for (i = 0; i < p.length; i++)
       {
Index: java/security/UnresolvedPermission.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/security/UnresolvedPermission.java,v
retrieving revision 1.4
diff -u -r1.4 UnresolvedPermission.java
--- java/security/UnresolvedPermission.java	24 May 2002 11:57:25 -0000	1.4
+++ java/security/UnresolvedPermission.java	5 May 2004 06:36:29 -0000
@@ -37,7 +37,6 @@
 
 package java.security;
 
-import java.io.Serializable;
 // All uses of Certificate in this file refer to the one in the listed
 // package, not this one.
 import java.security.cert.Certificate;
Index: java/text/Format.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/text/Format.java,v
retrieving revision 1.12
diff -u -r1.12 Format.java
--- java/text/Format.java	4 May 2004 16:27:20 -0000	1.12
+++ java/text/Format.java	5 May 2004 06:36:29 -0000
@@ -39,11 +39,6 @@
 package java.text;
 
 import gnu.java.text.FormatCharacterIterator;
-
-import java.util.Set;
-import java.util.Map;
-import java.util.HashSet;
-import java.util.HashMap;
 import java.io.Serializable;
 
 /**
Index: java/util/Date.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/util/Date.java,v
retrieving revision 1.12
diff -u -r1.12 Date.java
--- java/util/Date.java	4 Jan 2004 00:32:49 -0000	1.12
+++ java/util/Date.java	5 May 2004 06:36:29 -0000
@@ -460,7 +460,6 @@
 			int curYear = 1900 + new Date().getYear();
 			int firstYear = curYear - 80;
 			year = firstYear / 100 * 100 + num;
-			int yx = year;
 			if (year < firstYear)
 			  year += 100;
 		      }
Index: java/util/ResourceBundle.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/util/ResourceBundle.java,v
retrieving revision 1.24
diff -u -r1.24 ResourceBundle.java
--- java/util/ResourceBundle.java	20 Apr 2004 14:45:06 -0000	1.24
+++ java/util/ResourceBundle.java	5 May 2004 06:36:29 -0000
@@ -42,7 +42,6 @@
 import java.lang.ref.SoftReference;
 import java.io.InputStream;
 import java.io.IOException;
-import gnu.classpath.Configuration;
 
 /**
  * A resource bundle contains locale-specific data. If you need localized
@@ -345,7 +344,6 @@
     else if (cache.containsKey(name))
       {
 	Reference ref = (Reference) cache.get(name);
-	ResourceBundle result = null;
 	// If REF is null, that means that we added a `null' value to
 	// the hash map.  That means we failed to find the bundle
 	// previously, and we cached that fact.  The JDK does this, so
@@ -440,7 +438,6 @@
     if (cache.containsKey(localizedName))
       {
 	Reference ref = (Reference) cache.get(localizedName);
-	ResourceBundle result = null;
 	// If REF is null, that means that we added a `null' value to
 	// the hash map.  That means we failed to find the bundle
 	// previously, and we cached that fact.  The JDK does this, so
Index: java/util/regex/Pattern.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/util/regex/Pattern.java,v
retrieving revision 1.5
diff -u -r1.5 Pattern.java
--- java/util/regex/Pattern.java	22 Apr 2004 06:46:18 -0000	1.5
+++ java/util/regex/Pattern.java	5 May 2004 06:36:29 -0000
@@ -67,12 +67,6 @@
 
   private final RE re;
 
-  private Pattern (String regex)
-    throws PatternSyntaxException
-  {
-    this (regex, 0);
-  }
-
   private Pattern (String regex, int flags)
     throws PatternSyntaxException
   {

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]