aboutsummaryrefslogtreecommitdiff
path: root/libjava/java/text
diff options
context:
space:
mode:
authorTom Tromey <tromey@cygnus.com>2000-05-04 15:50:34 +0000
committerTom Tromey <tromey@gcc.gnu.org>2000-05-04 15:50:34 +0000
commitf70b7142c2a972ac6071b22ab4cfec672d358240 (patch)
treef8a39214ab1068b5c5daff2e7c514fdafb29c17d /libjava/java/text
parent4aef973c2eae349b95773374d2f8afd0dded3e56 (diff)
downloadgcc-f70b7142c2a972ac6071b22ab4cfec672d358240.zip
gcc-f70b7142c2a972ac6071b22ab4cfec672d358240.tar.gz
gcc-f70b7142c2a972ac6071b22ab4cfec672d358240.tar.bz2
Locale.java (Locale): Don't explicitly check for null.
* java/util/Locale.java (Locale): Don't explicitly check for null. * java/util/Hashtable.java (containsKey): Don't explicitly check for null. (get): Likewise. * java/util/BitSet.java (and, or, xor): Don't explicitly check for null. * java/util/zip/ZipEntry.java (ZipEntry): Don't explicitly check for null. * java/text/StringCharacterIterator.java (StringCharacterIterator): Don't check for null. * java/text/ChoiceFormat.java (setChoices): Don't explicitly check for null pointer. * java/net/MulticastSocket.java (joinGroup): Don't explicitly check for null pointer. (leaveGroup): Likewise. * java/net/DatagramPacket.java (DatagramPacket): Removed erroneous comment. (setData): Likewise. * java/lang/ThreadGroup.java (ThreadGroup): Don't explicitly check for `p==null'. From-SVN: r33671
Diffstat (limited to 'libjava/java/text')
-rw-r--r--libjava/java/text/ChoiceFormat.java4
-rw-r--r--libjava/java/text/StringCharacterIterator.java12
2 files changed, 4 insertions, 12 deletions
diff --git a/libjava/java/text/ChoiceFormat.java b/libjava/java/text/ChoiceFormat.java
index 92b697c..b3bb834 100644
--- a/libjava/java/text/ChoiceFormat.java
+++ b/libjava/java/text/ChoiceFormat.java
@@ -1,6 +1,6 @@
// ChoiceFormat.java - Formatter for `switch'-like string substitution.
-/* Copyright (C) 1999 Free Software Foundation
+/* Copyright (C) 1999, 2000 Free Software Foundation
This file is part of libgcj.
@@ -257,8 +257,6 @@ public class ChoiceFormat extends NumberFormat
public void setChoices (double[] limits, String[] strings)
{
- if (limits == null || strings == null)
- throw new NullPointerException ();
if (limits.length != strings.length)
throw new IllegalArgumentException ();
this.strings = (String[]) strings.clone();
diff --git a/libjava/java/text/StringCharacterIterator.java b/libjava/java/text/StringCharacterIterator.java
index c41ce41..dc02ce8 100644
--- a/libjava/java/text/StringCharacterIterator.java
+++ b/libjava/java/text/StringCharacterIterator.java
@@ -1,6 +1,6 @@
// StringCharacterIterator.java - Iterate over string of Unicode characters.
-/* Copyright (C) 1999 Free Software Foundation
+/* Copyright (C) 1999, 2000 Free Software Foundation
This file is part of libgcj.
@@ -106,20 +106,14 @@ public final class StringCharacterIterator implements CharacterIterator
public StringCharacterIterator (String text)
{
- // FIXME: remove check for null once we have compiler/runtime
- // support for NullPointerException.
- this (text, 0, text == null ? 0 : text.length(), 0);
+ this (text, 0, text.length(), 0);
}
public StringCharacterIterator (String text, int pos)
{
- // FIXME: remove check for null once we have compiler/runtime
- // support for NullPointerException.
- this (text, 0, text == null ? 0 : text.length(), pos);
+ this (text, 0, text.length(), pos);
}
public StringCharacterIterator (String text, int begin, int end, int pos)
{
- if (text == null)
- throw new NullPointerException ();
if (begin < 0 || begin > end || end > text.length()
// In 1.1 we would also throw if `pos == end'.
|| pos < begin || pos > end)