Commit Graph

808 Commits

Author SHA1 Message Date
Jesse Rosenstock
fa295a85b2 For PR libgcj/7292:
2002-07-12  Jesse Rosenstock  <jmr@fulcrummicro.com>

	For PR libgcj/7292:
	* java/lang/Character.java (toString(char)): Now static.

From-SVN: r55428
2002-07-12 21:13:22 +00:00
Adam Megacz
8f083a90c9 natFileDescriptorWin32.cc (open): Disable Win32 file locking, just like the Sun JVM does.
2002-06-06  Adam Megacz <adam@xwt.org>

        * java/io/natFileDescriptorWin32.cc (open): Disable Win32 file
        locking, just like the Sun JVM does.

From-SVN: r54320
2002-06-06 20:06:03 +00:00
Adam King
ceba9d086a File.java (normalizePath): Add Win32 support for auto conversion of a '/' path separator to Win32's '\'...
* java/io/File.java (normalizePath): Add Win32 support for auto
	conversion of a '/' path separator to Win32's '\' separator.

From-SVN: r52446
2002-04-18 00:01:09 +01:00
Adam King
86ba22fb24 natFileWin32.cc (performList): Return the correct array type.
2002-04-16  Adam King <aking@dreammechanics.com>
	    Tom Tromey  <tromey@redhat.com>

	* java/io/natFileWin32.cc (performList): Return the correct array
	type.  Don't duplicate the creation of a File since it's already
	done earlier in the method and the existing code would cause a
	ArrayStoreException.  Don't use fixed-size array.
	(_access, _stat, attr, getCanonicalPath, performMkdir,
	performRenameTo): Don't use fixed-size array.
	(getCanonicalPath): Use throw, not _Jv_Throw.

Co-Authored-By: Tom Tromey <tromey@redhat.com>

From-SVN: r52368
2002-04-16 15:35:20 +00:00
Mark Wielaard
53eca4de73 Integer.java (getInteger(String,Integer): Return def when nm is null or the empty String.
* java/lang/Integer.java (getInteger(String,Integer): Return def when
	nm is null or the empty String.

From-SVN: r52333
2002-04-15 21:06:59 +00:00
Mark Wielaard
8a93a2ec22 natPlainDatagramSocketImpl.cc (close): Set timeout to 0.
* java/net/natPlainDatagramSocketImpl.cc (close): Set timeout to 0.
        * java/net/natSocketImpl.cc (close): Likewise.

From-SVN: r52313
2002-04-15 03:21:58 +00:00
Adam King
42557a76f1 natDouble.cc (parseDouble): Allow a number to end with the f/F/d/D modifiers.
2002-04-13  Adam King <aking@dreammechanics.com>

        * java/lang/natDouble.cc (parseDouble): Allow a number to end with
        the f/F/d/D modifiers.

From-SVN: r52309
2002-04-15 03:12:06 +00:00
Alberto Biancardi
c003db19ed re PR libgcj/6187 (method distance of class java.awt.geom.Point2D causes infinite recursion)
2002-04-08  Alberto Biancardi  <alberto.biancardi@unipv.it>

	Fix for PR libgcj/6187:
	* java/awt/geom/Point2D.java (distance): Call distanceSq, not
	distance.

From-SVN: r52036
2002-04-08 18:48:55 +00:00
Mark Wielaard
158f133541 AbstractMap.java (putAll): Use entrySet size.
* java/util/AbstractMap.java (putAll): Use entrySet size.
	(toString): Explicitly use getKey() and getValue().

From-SVN: r52009
2002-04-08 00:24:46 +00:00
Mark Wielaard
0b9a32abdb Hashtable.java (contains): Remove NullPointer check.
* java/util/Hashtable.java (contains): Remove NullPointer check.
        (containsValue): Add NullPointer check.
        (remove): Always throw NullPointerException when key is null.

From-SVN: r51993
2002-04-07 12:15:36 +00:00
Adam King
fd9aa8924c natSystem.cc (init_properties): Call new function _Jv_platform_initProperties.
2002-04-07  Adam King <aking@dreammechanics.com>

	* java/lang/natSystem.cc (init_properties): Call new function
	_Jv_platform_initProperties.
	* win32.cc (_Jv_platform_initProperties): New function that adds Win32
	support for the System properties os.name, os.arch, os.version,
	user.name, user.home, and user.dir.
	* include/posix.h, include/win32.h, posix.cc: New function
	_Jv_platform_initProperties.

From-SVN: r51990
2002-04-07 12:30:09 +01:00
Mark Wielaard
fa461e07d1 * java/lang/Character,java (isDefined): getType() != UNASSIGNED.
From-SVN: r51981
2002-04-07 07:43:37 +00:00
Mark Wielaard
3e08ac0c2a ArrayList.java (addAll(int,Collection)): System.arraycopy all of the remaining elements.
* java/util/ArrayList.java (addAll(int,Collection)): System.arraycopy
        all of the remaining elements.
        * java/util/Vector.java (addAll(int,Collection)): Likewise.
        (removeRange): If toIndex == fromIndex do
        nothing, if toIndex < fromIndex throw IndexOutIfBoundsException.
        (removeAll): Always throw NullPointerException when collection is
        null.
        (retrainAll): Likewise.

From-SVN: r51980
2002-04-07 07:42:30 +00:00
Mark Wielaard
4436d35624 ArrayList.jva (removeRange): If toIndex == fromIndex do nothing...
* java/util/ArrayList.jva (removeRange): If toIndex == fromIndex do
        nothing, if toIndex < fromIndex throw IndexOutIfBoundsException.

From-SVN: r51948
2002-04-06 08:27:28 +00:00
Bryce McKinlay
d9d5895444 Arrays.java (qsort): Fix off-by-one errors and use of incorrect "hi" value when count > 40.
* java/util/Arrays.java (qsort): Fix off-by-one errors and use of
	incorrect "hi" value when count > 40.

From-SVN: r51855
2002-04-04 13:02:36 +01:00
Mark Wielaard
e0d07e6486 Modifier.java (toString(int,StringBuffer)): Fix ordering.
* java/lang/reflect/Modifier.java (toString(int,StringBuffer)): Fix
	ordering.

From-SVN: r51849
2002-04-04 08:32:33 +00:00
Mark Wielaard
cb7a4711c8 Long.java (getLong(String,Long)): Actually decode property value, not key.
* java/lang/Long.java (getLong(String,Long)): Actually decode property
	value, not key.

From-SVN: r51803
2002-04-03 08:23:48 +00:00
Tom Tromey
c702347dc1 natClassLoader.cc (findClass): Compare against 3', not 0'.
* java/lang/natClassLoader.cc (findClass): Compare against `3',
	not `0'.

From-SVN: r51763
2002-04-02 22:19:55 +00:00
Bryce McKinlay
c8d9e398e3 IdentityHashMap.java (put): Set new threshold correctly when resizing table.
* java/util/IdentityHashMap.java (put): Set new threshold correctly
	when resizing table.

From-SVN: r51752
2002-04-02 14:56:44 +01:00
Mark Wielaard
9995e40e0e BitSet.java (BitSet(int)): if nbits < 0 throw NegativeArraySizeException
* java/util/BitSet.java (BitSet(int)): if nbits < 0 throw
        NegativeArraySizeException
        (clear(int)): Use sign extended shift.
        (flip(int)): Likewise.
        (get(int)): Likewise.
        (nextClearBit(int)): Likewise.
        (nextSetBit(int)): Likewise.
        (set(int)): Likewise.

From-SVN: r51702
2002-04-01 20:00:31 +00:00
Mark Wielaard
2a60079ccc Integer.java (decode): Throw NullPointerException when argument is null.
* java/lang/Integer.java (decode): Throw NullPointerException when
        argument is null. A minus sign can precede other leading characters.

From-SVN: r51697
2002-04-01 19:11:16 +00:00
Tom Tromey
061768b07d natPlainDatagramSocketImpl.cc (close): New function.
* java/net/natPlainDatagramSocketImpl.cc (close): New function.
	* java/net/natPlainSocketImpl.cc (close): Indentation fix.

From-SVN: r51561
2002-03-29 17:05:56 +00:00
Jeff Sturm
64cd9fccd5 * java/net/PlainDatagramSocketImpl.java
(close): Use native implementation.
	(finalize): New method.

	* java/net/PlainSocketImpl.java (finalize): New method.

	* java/net/natPlainDatagramSocketImpl.cc
	(java/io/FileDescriptor.h): Don't include.
	(close): Implement method here.
	(create): Don't assign fd.

	* java/net/natPlainSocketImpl.cc
	(java/io/FileDescriptor.h): Don't include.
	(create): Don't assign fd.
	(accept): Likewise.
	(close): Synchronize.

From-SVN: r51493
2002-03-28 02:36:51 +00:00
Bryce McKinlay
606796523a Based on patch from Intel's ORP team:
* java/io/PushbackInputStream.java (available): Calculate correct
	number of bytes in buffer.
	(read): Remove redundant bound check. Return bytes from both the
	buffer and the stream.

From-SVN: r51295
2002-03-25 02:28:02 +00:00
Bryce McKinlay
8ab498c8b1 PushbackReader.java: Reformat.
* java/io/PushbackReader.java: Reformat.

	* java/io/FileInputStream.java (skip): Call fd.getFilePointer() and
	calculate correct number of bytes skipped.

From-SVN: r51292
2002-03-25 01:59:54 +00:00
Mark Wielaard
632dcb12dd [multiple changes]
2002-03-24  Eric Blake  <ebb9@email.byu.edu>

        * java/beans/IntrospectionException.java: Update to 1.4.
        * java/beans/PropertyVetoException.java: Ditto.

2002-03-24  Eric Blake  <ebb9@email.byu.edu>

        * gnu/java/beans/BeanInfoEmbryo.java (hasMethod): Use
        Arrays.equals instead of ArrayHelper.equalsArray.

2002-03-24  C. Brian Jones <cbj@gnu.org>

        * java/beans/Introspector.java: added new static final fields
        introduced in 1.2, lots of other updates remain to be done

2002-03-24  C. Brian Jones <cbj@gnu.org>

        * java/beans/Introspector.java: reformatting

2002-03-24  C. Brian Jones <cbj@gnu.org>

        * java/beans/Introspector.java: default beanInfoSearchPath will
        not include sun.beans.infos given we provide no such package and
        the API doesn't really require it; gnu.java.beans.info is the
        default.

2002-03-24  Mark Wielaard  <mark@klomp.org>

        Thanks to Orp developers
        * gnu/java/beans/editors/NativeBooleanEditor.java (setAsText(String)):
        switch TRUE and FALSE return values.

From-SVN: r51274
2002-03-24 21:32:22 +00:00
Michael Smith
7fdaac3d3b re PR libgcj/6045 (GregorianCalendar: getMinimum() and getMaximum() incorrect for month)
2002-03-23  Michael Smith  <msmith@spinnakernet.com>

	* java/util/GregorianCalendar.java (minimums, maximums): Correct
	MONTH entry.  Fixes PR libgcj/6045.

From-SVN: r51233
2002-03-23 16:12:49 +00:00
Jeff Sturm
48e4beeca8 * java/nat/natPlainSocketImpl.cc (write): Abort loop on error.
From-SVN: r51231
2002-03-23 15:05:30 +00:00
Bryce McKinlay
4e3a413813 natSystem.cc (init_properties): Update VM version properties.
* java/lang/natSystem.cc (init_properties): Update VM version
	properties.
	* configure.in: Set GCJVERSION.
	* acconfig.h: Add GCJVERSION.
	* configure: Rebuilt.
	* include/config.h.in: Rebuilt.

From-SVN: r50945
2002-03-18 06:30:26 +00:00
Anthony Green
3243420704 Add arm thumb support
From-SVN: r50919
2002-03-17 16:16:58 +00:00
Adam Megacz
c025d051a3 natPlainSocketImpl.cc: Removed #include "posix.h".
2002-03-10  Adam Megacz <adam@xwt.org>

        * java/net/natPlainSocketImpl.cc: Removed #include "posix.h".

From-SVN: r50558
2002-03-11 03:43:56 +00:00
Adam Megacz
413a6730fc natPlainSocketImpl.cc: Added #include <platform.h>.
2002-03-10  Adam Megacz <adam@xwt.org>

        * java/net/natPlainSocketImpl.cc: Added #include <platform.h>.

From-SVN: r50555
2002-03-11 01:30:45 +00:00
Tom Tromey
48ddaff99e Win32Process.java: Added comment.
* java/lang/Win32Process.java: Added comment.
	* include/posix.h (_Jv_platform_close_on_exec): New function.
	Include fcntl.h.
	* include/win32.h (_Jv_platform_close_on_exec): New function.
	* java/net/natPlainSocketImpl.cc (create): Set close-on-exec
	flag.
	(accept): Likewise.
	* java/net/natPlainDatagramSocketImpl.cc (create): Set
	close-on-exec flag.
	* java/io/natFileDescriptorPosix.cc (open): Set close-on-exec
	flag.

From-SVN: r50537
2002-03-10 18:00:06 +00:00
Bryce McKinlay
9475af48ce ImageMediaEntry: Removed.
* java/awt/ImageMediaEntry: Removed.
	* java/awt/MediaEntry: Removed.

From-SVN: r50525
2002-03-10 03:58:01 +00:00
Adam Megacz
5b4d22efbc natFileDescriptorWin32.cc (read): Return -1 if zero bytes read and no failure code returned.
2002-03-09  Adam Megacz  <adam@xwt.org>

        * java/io/natFileDescriptorWin32.cc (read): Return -1 if zero
        bytes read and no failure code returned.

From-SVN: r50520
2002-03-10 03:34:59 +00:00
Bryce McKinlay
811f17ca56 configure.in: Define SLOW_PTHREAD_SELF if configure.host set slow_pthread_self.
libjava:
	* configure.in: Define SLOW_PTHREAD_SELF if configure.host set
	slow_pthread_self. Set up symlink for sysdeps directory.
	* configure.host: Document more shell variables. Set sysdeps_dir
	for most platforms. Set slow_pthread_self for i686. Set
	enable_hash_synchronization_default and slow_pthread_self for PowerPC.
	* posix-threads.cc (_Jv_ThreadSelf_out_of_line): Use release_set so
	that memory barrier is emitted where required.
	* include/posix-threads.h (_Jv_ThreadSelf for SLOW_PTHREAD_SELF): Add
	read_barrier() to enforce ordering of reads.
	* sysdep/powerpc/locks.h: New file. Implementation of synchronization
	primitives for PowerPC.
	* sysdep/i386/locks.h: New file. Synchronization primitives for i386
	moved from natObject.cc.
	* sysdep/alpha/locks.h: Likewise.
	* sysdep/ia64/locks.h: Likewise.
	* sysdep/generic/locks.h: Likewise.
	* java/lang/natObject.cc: Move thread synchronization primitives to
	system-dependent headers.

gcc/java:
	* decl.c (java_init_decl_processing): Make sure class_type_node
	alignment is not less than 64 bits if hash synchronization is enabled.

boehm-gc:
	* include/gc_priv.h: Define ALIGN_DOUBLE on 32 bit targets if GCJ
	support is enabled, for hash synchronization.

[[Split portion of a mixed commit.]]

From-SVN: r50518.1
2002-03-10 03:31:08 +00:00
Adam Megacz
6d4433fe19 Win32Process.java (ConcreteProcess): Now throws an IOException so that Throwable.printStackTrace fails correctly.
2002-03-09  Adam Megacz  <adam@xwt.org>

        * java/lang/Win32Process.java (ConcreteProcess): Now throws an
        IOException so that Throwable.printStackTrace fails correctly.

From-SVN: r50487
2002-03-09 08:46:55 +00:00
Adam Megacz
f2ad476b51 natPlainSocketImpl.cc (read, [...]): Formatting fixed.
2002-03-08  Adam Megacz  <adam@xwt.org>

        * java/net/natPlainSocketImpl.cc (read, write, close): Formatting
        fixed.

From-SVN: r50482
2002-03-09 07:57:14 +00:00
Adam Megacz
c362baed87 natSystem.cc (currentTimeMillis): Now uses updated _Jv_platform_gettimeofday signature.
2002-03-07  Adam Megacz  <adam@xwt.org>

        * java/lang/natSystem.cc (currentTimeMillis): Now uses updated
       _Jv_platform_gettimeofday signature.

From-SVN: r50420
2002-03-08 02:31:13 +00:00
Adam Megacz
4a9f4b09f0 natPlainSocketImpl.cc: Changed USE_WINSOCK to WIN32, and added thunks for read(), write(), and close().
2002-03-07  Adam Megacz  <adam@xwt.org>

        * java/net/natPlainSocketImpl.cc: Changed USE_WINSOCK to
        WIN32, and added thunks for read(), write(), and close().
        * java/net/natPlainSocketImpl.cc (accept, read, read):
        Disabled timeouts on WIN32 pending discussion.

From-SVN: r50417
2002-03-08 01:45:59 +00:00
Adam Megacz
85975a39c0 FileDescriptor.java: Initialize in/out/err in init().
2002-03-07  Adam Megacz  <adam@xwt.org>

        * java/io/FileDescriptor.java: Initialize in/out/err in init().
        * java/io/natFileDescriptorWin32.cc (init()): Added function.
        * java/io/natFileDescriptorPosix.cc (init()): Added function.
        * java/io/natFileDescriptorEcos.cc (init()): Added function.

From-SVN: r50415
2002-03-08 00:43:29 +00:00
Bryce McKinlay
cafb78f86b natPlainSocketImpl.cc (_Jv_recv): Removed.
* java/net/natPlainSocketImpl.cc (_Jv_recv): Removed.
	(read): Call recv() directly, not _Jv_recv().

From-SVN: r50389
2002-03-07 01:51:45 +00:00
Eric Blake
74b1875a09 unicode-decomp.pl: Move from chartables.pl...
2002-03-06  Eric Blake  <ebb9@email.byu.edu>

	* scripts/unicode-decomp.pl: Move from chartables.pl, and remove
	the code for generating include/java-chartables.h.
	* scripts/unicode-blocks.pl: Move from scripts/blocks.pl, and
	merge with Classpath.
	* scripts/unicode-muncher.pl: Copy from Classpath.
	* scritps/MakeCharTables.java: New file.
	* gnu/gcj/convert/Blocks-3.txt: New file.
	* gnu/gcj/convert/UnicodeData-3.0.0.txt: New file.
	* gnu/gcj/convert/UnicodeCharacterDatabase-3.0.0.html: New file.
	* gnu/java/lang/CharData.java: Copy from Classpath.
	* Makefile.am (ordinary_java_source_files): Add
	gnu/java/lang/CharData.java.
	* configure.in: Remove --enable-fast-character option.
	* java/lang/Character.java: Merge algorithms and Javadoc with
	Classpath.
	* java/lang/natCharacter.cc: Implement Unicode lookup table more
	efficiently.
	* include/java-chardecomp.h: Regenerate.
	* include/java-chartables.h: Regenerate.

From-SVN: r50370
2002-03-06 19:13:01 +00:00
Bryce McKinlay
c8ce58256f MediaTracker.java: Implemented.
* java/awt/MediaTracker.java: Implemented.
        * Makefile.am: Add MediaTracker.
        * Makefile.in: Rebuilt.

From-SVN: r50348
2002-03-06 08:08:19 +00:00
Tom Tromey
2fadde235c natPosixProcess.cc (fail): Removed.
* java/lang/natPosixProcess.cc (fail): Removed.
	(startProcess): Simplified error-handling.  Preserve
	LD_LIBRARY_PATH across exec.

From-SVN: r50343
2002-03-06 05:14:38 +00:00
Adam Megacz
b1286bac46 natInetAddress.cc: Changed USE_WINSOCK to WIN32, added '#undef STRICT'.
2002-03-04  Adam Megacz <adam@xwt.org>

	* java/net/natInetAddress.cc: Changed USE_WINSOCK to WIN32, added
	'#undef STRICT'.

From-SVN: r50286
2002-03-04 20:02:19 +00:00
Mark Wielaard
677b388b0f * java/util/Timer (TaskQueue.stop): set elements to zero.
From-SVN: r50267
2002-03-03 23:21:35 +00:00
Anthony Green
21956ee220 FFI_TYPE_POINTER fix
From-SVN: r50195
2002-03-01 13:41:16 +00:00
Tom Tromey
9d0142a0d1 natSystem.cc (init_properties): Use __VERSION__.
* java/lang/natSystem.cc (init_properties): Use __VERSION__.
	* gij.cc (version): Use __VERSION__.
	* include/config.h.in: Rebuilt.
	* acconfig.h (GCJVERSION): Removed.
	* configure: Rebuilt.
	* configure.in (GCJVERSION): Removed.

From-SVN: r50089
2002-02-27 05:37:47 +00:00
Tom Tromey
d5694d9aad natPosixProcess.cc (startProcess): Use FD_CLOEXEC, not `1'.
* java/lang/natPosixProcess.cc (startProcess): Use FD_CLOEXEC, not
	`1'.

From-SVN: r50080
2002-02-27 01:38:57 +00:00