jni.cc (ThrowableClass): New define.
[gcc.git] / libjava / ChangeLog
1 2000-02-07 Tom Tromey <tromey@cygnus.com>
2
3 * jni.cc (ThrowableClass): New define.
4 (_Jv_JNI_Throw): Check argument.
5 (_Jv_JNI_ThrowNew): Likewise.
6 (wrap_value): Don't wrap object if it is NULL.
7 (_Jv_JNI_DefineClass): Use wrap_value.
8 (_Jv_JNI_FindClass): Likewise.
9 (_Jv_JNI_GetSuperclass): Likewise.
10 (_Jv_JNI_ExceptionOccurred): Likewise.
11 (_Jv_JNI_AllocObject): Likewise.
12 (_Jv_JNI_GetObjectClass): Likewise.
13 (_Jv_JNI_NewString): Likewise.
14 (_Jv_JNI_NewStringUTF): Likewise.
15 (_Jv_JNI_NewObjectArray): Likewise.
16 (_Jv_JNI_GetObjectArrayElement): Likewise.
17 (_Jv_JNI_NewPrimitiveArray): Likewise.
18 (_Jv_JNI_ToReflectedField): Likewise.
19 (_Jv_JNI_ToReflectedMethod): Likewise.
20 (_Jv_JNI_AllocObject): Check argument.
21 (_Jv_JNI_NewObjectV): Likewise.
22 (_Jv_JNI_NewObject): Likewise.
23 (_Jv_JNI_NewObjectA): Likewise.
24 (_Jv_JNI_GetObjectClass): Likewise.
25 (_Jv_JNI_GetField): Likewise.
26 (_Jv_JNI_SetField): Likewise.
27
28 * interpret.cc (PUSHL): Don't use expression statement.
29 (PUSHD): Likewise.
30 (LOADL): Likewise.
31 (STOREL): Likewise.
32
33 * jni.cc (add_char): Conditional on INTERPRETER.
34 (mangled_name): Likewise.
35 (call): Likewise.
36 * include/java-interp.h (class _Jv_MethodBase): Conditional on
37 INTERPRETER.
38 (class _Jv_JNIMethod): Likewise.
39
40 2000-02-04 Warren Levy <warrenl@cygnus.com>
41
42 * Makefile.am: Added MPN.java and BigInteger.java.
43 * Makefile.in: Rebuilt.
44 * gnu/gcj/math/MPN.java: New file. From Kawa by Per Bothner
45 <per@bothner.com>.
46 * java/math/BigInteger.java: New file. Based primarily on
47 Kawa's IntNum.java by Per Bothner <per@bothner.com>.
48
49 2000-02-04 Tom Tromey <tromey@cygnus.com>
50
51 * defineclass.cc (handleMethodsBegin): Allocate _Jv_MethodBase
52 pointers.
53 (handleMethodsEnd): Fixed error messages. Create a _Jv_JNIMethod
54 if the method is native.
55 * resolve.cc (ncode): Don't handle native methods.
56 (_Jv_JNIMethod::ncode): New method.
57 (_Jv_PrepareClass): Handle native methods.
58 * jni.cc (call): Renamed from _Jv_JNI_conversion_call.
59 Include AbstractMethodError.h.
60 (add_char): New function.
61 (mangled_name): Likewise.
62 * include/java-interp.h (class _Jv_JNIMethod): New class.
63 (class _Jv_MethodBase): New class.
64 (class _Jv_InterpMethod): Derive from _Jv_MethodBase.
65 (_Jv_InterpClass): Changed `interpreted_methods' field to type
66 `_Jv_MethodBase'.
67
68 * include/jvm.h (_Jv_FindSymbolInExecutable): Declare.
69 * java/lang/natRuntime.cc (libraries_size, libraries_count,
70 libraries): New globals.
71 (add_library): New function.
72 (_Jv_FindSymbolInExecutable): New function.
73
74 * java/lang/natClassLoader.cc (initiated_classes, loaded_classes):
75 Now static.
76
77 2000-02-04 Andrew Haley <aph@cygnus.com>
78
79 * java/lang/Throwable.java (CPlusPlusDemangler): New class.
80 (printStackTrace): Use a CPlusPlusDemangler to demangle names.
81 * java/lang/natThrowable.cc (printRawStackTrace): Rename
82 printStackTrace to printRawStackTrace.
83
84 2000-02-03 Tom Tromey <tromey@cygnus.com>
85
86 * java/util/Calendar.java (toString): New method.
87 * java/util/SimpleTimeZone.java (clone): New method.
88 (toString): New method.
89 * java/util/TimeZone.java (clone): New method.
90 * java/text/SimpleDateFormat.java (clone): New method.
91 * java/text/NumberFormat.java (clone): New method.
92 (equals): New method.
93 * java/text/Format.java (clone): New method.
94 * java/text/DateFormatSymbols.java (DateFormatSymbols): New
95 constructor.
96 (clone): New method.
97 * java/text/DateFormat.java (clone): New method.
98 * java/text/Collator.java (clone): New method.
99
100 2000-02-03 Tom Tromey <tromey@cygnus.com>
101
102 * java/io/PipedOutputStream.java (write(byte[], int, int)): New
103 method.
104
105 2000-02-01 Tom Tromey <tromey@cygnus.com>
106
107 * include/java-interp.h (_Jv_JNI_conversion_call): Declare.
108 * resolve.cc (ncode): Use _Jv_JNI_conversion_call when
109 constructing the closure if the function is native.
110 * jni.cc (_Jv_JNI_conversion_call): Now returns `void'. No longer
111 a template function, #if'd out, or static.
112 Include <java-interp.h>.
113
114 * include/jni.h (class _Jv_JNIEnv): Corrected calls using `...'.
115
116 * include/jni.h (class _Jv_JNIEnv): Added all C++ inline methods.
117
118 * jni.cc (_Jv_JNI_PopLocalFrame): Leave loop when `n == NULL'.
119 (_Jv_JNI_conversion_call): _Jv_JNI_PopLocalFrame will never leave
120 `locals == NULL'.
121 (wrap_value): New function.
122 (_Jv_JNI_CallAnyMethodV): Use it.
123 (_Jv_JNI_CallAnyMethodA): Likewise.
124 (_Jv_JNI_GetField): Use wrap_value; removed specialized version.
125 (_Jv_JNI_GetStaticField): Likewise.
126
127 * jni.cc (_Jv_JNI_GetField): Specialize for jobject.
128 (_Jv_JNI_GetStaticField): Likewise.
129
130 2000-01-31 Tom Tromey <tromey@cygnus.com>
131
132 * prims.cc (_Jv_MallocUnchecked): New function.
133 (main_init): Call _Jv_JNI_Init.
134 * include/jvm.h (_Jv_MallocUnchecked): Declare.
135 (_Jv_JNI_Init): Declare.
136 * jni.cc: Include Hashtable.h, OutOfMemoryError.h, Integer.h,
137 <string.h>.
138 (_Jv_JNI_NewGlobalRef): New function.
139 (_Jv_JNI_DeleteGlobalRef): New function.
140 (_Jv_JNI_DeleteLocalRef): New function.
141 (_Jv_JNI_conversion_call): Initialize and clear local reference
142 frame.
143 (_Jv_JNI_NewLocalRef): New function.
144 (struct _Jv_JNI_LocalFrame): New structure.
145 (_Jv_JNI_PushLocalFrame): New function.
146 (_Jv_JNI_EnsureLocalCapacity): New function.
147 (FRAME_SIZE): New define.
148 (_Jv_JNI_GetStringChars): Mark string, not characters.
149 (_Jv_JNI_ReleaseStringChars): Unmark string, not characters.
150 (_Jv_JNI_GetPrimitiveArrayElements): Mark array, not elements.
151 (_Jv_JNI_ReleasePrimitiveArrayElements): Unmark array, not
152 elements.
153 (_Jv_JNI_DefineClass): Make return value a local ref.
154 (_Jv_JNI_FindClass): Likewise.
155 (_Jv_JNI_GetSuperclass): Likewise.
156 (_Jv_JNI_ExceptionOccurred): Likewise.
157 (_Jv_JNI_AllocObject): Likewise.
158 (_Jv_JNI_GetObjectClass): Likewise.
159 (_Jv_JNI_CallAnyMethodV): Likewise.
160 (_Jv_JNI_NewString): Likewise.
161 (_Jv_JNI_NewStringUTF): Likewise.
162 (_Jv_JNI_NewObjectArray): Likewise.
163 (_Jv_JNI_GetObjectArrayElement): Likewise.
164 (_Jv_JNI_ToReflectedField): Likewise.
165 (_Jv_JNI_ToReflectedMethod): Likewise.
166 (_Jv_JNIFunctions): Updated table for new functions.
167 (_Jv_JNI_Init): New function.
168 (mark_for_gc): Wrote.
169 (unmark_for_gc): Wrote.
170 * include/jni.h (struct JNINativeInterface): Removed name from
171 PopLocalFrame parameter.
172 (class _Jv_JNIEnv): Added `locals' field.
173
174 Mon Jan 31 00:43:15 2000 Anthony Green <green@redhat.com>
175
176 * gnu/gcj/convert/natIconv.cc (read): Minor fixes.
177 (write): Ditto.
178
179 2000-01-30 Tom Tromey <tromey@cygnus.com>
180
181 * include/config.h.in: Rebuilt.
182 * acconfig.h (HAVE_ICONV): Define.
183 * configure: Rebuilt.
184 * configure.in: Check for `iconv' function.
185 * gnu/gcj/convert/BytesToUnicode.java (getDecoder): Try iconv if
186 no specific encoder exists.
187 * gnu/gcj/convert/UnicodeToBytes.java (getEncoder): Try iconv if
188 no specific encoder exists.
189 * Makefile.in: Rebuilt.
190 * Makefile.am (convert_source_files): Mention Input_iconv.java and
191 Output_iconv.java.
192 (nat_source_files): Added natIconv.cc.
193 * gnu/gcj/convert/natIconv.cc: New file.
194 * gnu/gcj/convert/Input_iconv.java: New file.
195 * gnu/gcj/convert/Output_iconv.java: New file.
196
197 2000-01-28 Tom Tromey <tromey@cygnus.com>
198
199 * Makefile.in: Rebuilt.
200 * Makefile.am (LIBFFIINCS): Added MULTIBUILDTOP.
201
202 2000-01-26 Tom Tromey <tromey@cygnus.com>
203
204 * gcj/method.h (JvNumMethods): Moved from Class.h.
205 (JvGetFirstMethod): Likewise.
206 * java/lang/Class.h (Object): Updated decl of
207 _Jv_JNI_ToReflectedField.
208 (Object): Added _Jv_JNI_ToReflectedMethod as a friend.
209 * Makefile.in: Rebuilt.
210 * Makefile.am (java/lang/reflect/Field.h): Added `jboolean'
211 argument of _Jv_JNI_ToReflectedField.
212 (java/lang/reflect/Constructor.h): Added _Jv_JNI_ToReflectedMethod
213 as a friend.
214 (java/lang/reflect/Method.h): Likewise.
215 * include/jni.h (class _Jv_JNIEnv): Added `klass' member. Use
216 __GCJ_JNI_IMPL__.
217 (jweak): New typedef.
218 (struct JNINativeInterface): Correctly declare remaining entries.
219 * jni.cc: Include Class.h, ClassLoader.h.
220 (_Jv_JNI_FindClass): New function.
221 (_Jv_JNI_DefineClass): New function.
222 (_Jv_JNI_conversion_call): New function.
223 (_Jv_JNI_FindClass): Use current class loader to find class.
224 (_Jv_JNI_ExceptionCheck): New function.
225 (_Jv_JNI_FromReflectedField): Now static.
226 (MethodClass): New define.
227 (_Jv_JNI_FromReflectedMethod): New function.
228 (_Jv_JNI_ToReflectedMethod): Likewise.
229 Include Method.h.
230 (_Jv_JNI_IsAssignableFrom): Renamed.
231 (_Jv_JNI_GetStringRegion): New function.
232 Include StringIndexOutOfBoundsException.h.
233 (_Jv_JNI_GetStringUTFRegion): New function.
234 (_Jv_JNIFunctions): Updated for new functions.
235 (_Jv_JNI_GetPrimitiveArrayCritical): New function
236 (_Jv_JNI_ReleasePrimitiveArrayCritical): Likewise.
237 (_Jv_JNI_GetStringCritical): New function.
238 (_Jv_JNI_ReleaseStringCritical): Likewise.
239 (get_throwable): Removed.
240 (GCJ_JV_JNIENV_FRIEND): Removed.
241 (__GCJ_JNI_IMPL__): Define.
242 Include method.h.
243
244 * resolve.cc (get_ffi_type_from_signature): Handle case where
245 boolean is an int.
246
247 Tue Jan 25 08:51:16 2000 Tom Tromey <tromey@ferrule.cygnus.com>
248
249 * interpret.cc (run): Don't call println.
250 Don't include PrintStream.h.
251
252 * gcj/field.h (struct _Jv_Field): Use "jshort" as type for
253 nameIndex. Use "jint" as type for boffset.
254 * java/lang/Class.h (struct _Jv_Method): Made accflags a
255 _Jv_ushort.
256 (Class): Likewise. Also changed type of method_count,
257 vtable_method_count, size_in_bytes, field_count,
258 static_field_count, interface_count.
259 * gcj/array.h (__JArray): Made `length' a const jsize, not an
260 int.
261
262 2000-01-21 Tom Tromey <tromey@cygnus.com>
263
264 * java/lang/reflect/natConstructor.cc (newInstance): Use
265 _Jv_CallAnyMethodA.
266 * include/jvm.h: Declare _Jv_CallAnyMethodA.
267 * java/lang/reflect/natMethod.cc (_Jv_CallAnyMethodA): Renamed
268 from _Jv_CallNonvirtualMethodA. Changed interface; overloaded.
269 Include <jni.h>.
270 (COPY): Removed.
271 (invoke): Use _Jv_CallAnyMethodA.
272 (VAL): Redefined.
273 * java/lang/Class.h (Class): Declare JvGetFirstStaticField,
274 JvNumStaticFields, JvNumMethods, and JvGetFirstMethod as friend
275 functions.
276 (struct _Jv_Method): Added getNextMethod method.
277 (JvNumMethods): New function.
278 (JvGetFirstMethod): Likewise.
279 * gcj/field.h (JvGetFirstStaticField): New function.
280 (JvNumStaticFields): Likewise.
281 (getNextField): Renamed from getNextInstanceField.
282 (struct _Jv_Field): New method getClass.
283 * jni.cc: Wrote many new functions.
284 * include/jni.h (JNI_TRUE): Define.
285 (JNI_FALSE): Likewise.
286 (jobject, jclass, jstring, jarray, jthrowable, jobjectArray,
287 jbyteArray, jshortArray, jintArray, jlongArray, jbooleanArray,
288 jcharArray, jfloatArray, jdoubleArray): New typedefs.
289 (jfieldID, jmethodID): Likewise.
290 (JNI_COMMIT, JNI_ABORT): New defines.
291 (JNINativeMethod): New struct.
292 (struct JNINativeInterface): Correctly declared more entries.
293 (class _Jv_JNIEnv): Added `ex' member.
294 (JNI_VERSION_1_1): New define.
295 (JNI_VERSION_1_2): Likewise.
296
297 * boehm.cc (_Jv_MarkObj): Use getNextField, not
298 getNextInstanceField.
299
300 2000-01-20 Tom Tromey <tromey@cygnus.com>
301
302 * resolve.cc (StringClass): Removed.
303 * defineclass.cc (StringClass): Removed.
304
305 2000-01-19 Bryce McKinlay <bryce@albatross.co.nz>
306
307 * NEWS: updated.
308
309 2000-01-19 Tom Tromey <tromey@cygnus.com>
310
311 * interpret.cc (PC_REGISTER_ASM): Removed.
312
313 * java/lang/natThrowable.cc: Don't use `#pragma implementation'.
314 From Bryce McKinlay.
315
316 * All files: Updated copyright to reflect Cygnus purchase.
317
318 2000-01-18 Bryce McKinlay <bryce@albatross.co.nz>
319
320 * configure: Rebuilt.
321 * configure.in: Recognize --disable-interpreter.
322
323 2000-01-18 Andrew Haley <aph@cygnus.com>
324
325 * name-finder.cc (lookup): Check for dladdr function.
326 acconfig.h (HAVE_DLADDR): Add.
327 configure.in: Check for HAVE_DLADDR
328 configure: Rebuilt.
329 include/config.h.in: Rebuilt.
330
331 2000-01-17 Andrew Haley <aph@cygnus.com>
332
333 * prims.cc (_Jv_RunMain): Set the name of this executable.
334
335 2000-01-17 Tom Tromey <tromey@cygnus.com>
336
337 * java/lang/natThrowable.cc (fillInStackTrace): Return `this' even
338 when backtrace can't be computed.
339
340 * configure: Rebuilt.
341 * configure.in: Fixed typo in AC_CONFIG_SUBDIRS call.
342
343 * java/lang/Runtime.java (loadLibraryInternal): Declare.
344 * java/lang/natClassLoader.cc (_Jv_FindClass): Removed dead copy.
345 (_Jv_FindClassInCache): Likewise.
346 (_Jv_FindClass): Don't conditionalize body on INTERPRETER.
347 (findSystemClass): Try to load class from compiled module.
348 Include Runtime.h.
349 * java/lang/natRuntime.cc (load): Use UTF-8 copy of filename.
350 (loadLibrary): Likewise.
351 (lt_preloaded_symbols): Define.
352 (loadLibraryInternal): New method.
353 * include/config.h.in: Rebuilt.
354 * acconfig.h (USE_LTDL): Added.
355 * Makefile.am (SUBDIRS): Added $(DIRLTDL).
356 (INCLUDES): Added $(INCLTDL).
357 (libgcj_la_DEPENDENCIES): Added $(LIBLTDL).
358 (libgcj_la_LIBADD): Likewise.
359 * aclocal.m4, configure: Rebuilt.
360 * configure.in: Added libltdl support.
361
362 2000-01-15 Tom Tromey <tromey@cygnus.com>
363
364 * prims.cc (_Jv_PrimClass): Use `JV_STATE_NOTHING', not `0'.
365
366 2000-01-14 Andrew Haley <aph@cygnus.com>
367
368 * java/lang/natThrowable.cc: New file.
369
370 * java/lang/Throwable.java (fillInStackTrace): Make native.
371 (printStackTrace): Call native method to do this.
372 (Throwable): Call fillInStackTrace.
373 (stackTrace): New variable.
374
375 * include/jvm.h: Add _Jv_ThisExecutable functions.
376
377 * prims.cc: (_Jv_execName): New variable.
378 (catch_segv): Call fillInStackTrace.
379 (catch_fpe): Ditto.
380 (_Jv_ThisExecutable): New functions.
381 (JvRunMain): Set the name of this executable.
382
383 * Makefile.am: Add java/lang/natThrowable.cc.
384 Add name-finder.cc.
385 * Makefile.in: Rebuilt.
386
387 * acconfig.h: Add HAVE_PROC_SELF_EXE.
388
389 * configure.in: Force link with __frame_state_for in
390 FORCELIBGCCSPEC. Add new checks for backtrace.
391 * include/config.h.in: Rebuilt.
392
393 * name-finder.cc: New file.
394 * include/name-finder.h: New file.
395
396 2000-01-16 Anthony Green <green@cygnus.com>
397
398 * java/lang/StringBuffer.java (StringBuffer): Don't special case
399 null argument.
400
401 2000-01-16 Jeff Sturm <jsturm@sigma6.com>
402
403 * java/io/StreamTokenizer.java (nextToken): Avoid unread(TT_EOF).
404
405 2000-01-13 Tom Tromey <tromey@cygnus.com>
406
407 * java/lang/natClassLoader.cc (_Jv_FindClass): Register `loader',
408 not system loader, as initiating loader.
409
410 2000-01-11 Tom Tromey <tromey@cygnus.com>
411
412 * java/lang/natSystem.cc (getpwuid_adaptor): New adaptor for
413 HP/UX. From David Scott Urban.
414
415 2000-01-10 Jeff Sturm <jsturm@sigma6.com>
416
417 * java/lang/natMath.cc (pow): Cast args to `double', not
418 `jdouble'.
419 (atan2): Likewise.
420 (IEEEremainder): Likewise.
421 * java/lang/mprec.h: Don't wrap includes in `extern "C"'.
422 * java/lang/fdlibm.h: Don't wrap includes in `extern "C"'.
423
424 2000-01-09 Anthony Green <green@cygnus.com>
425
426 * java/lang/natString.cc (init): Test for overflow condition
427 during out of bounds check.
428 (getChars): Throw StringIndexOutOfBoundsException, not
429 ArrayIndexOutOfBoundsException.
430 (getBytes): Ditto.
431 (regionMatches): Obey case option during string comparison.
432
433 * configure.host (ligcj_interpreter): New variable. Enable
434 interpreter by default on IA-32.
435 * configure.in: Examine libgcj_interpreter.
436 * configure: Rebuilt.
437
438 2000-01-07 Tom Tromey <tromey@cygnus.com>
439
440 * mauve-libgcj: Don't disable ClassTest.
441
442 * java/lang/natClass.cc (getClasses): Wrote.
443
444 2000-01-06 Tom Tromey <tromey@cygnus.com>
445
446 * java/lang/natClass.cc (_getConstructors): Correctly check
447 whether method name is the init name.
448 (getMethod): Look at accflags on method in `klass', not `this'.
449
450 2000-01-05 Tom Tromey <tromey@cygnus.com>
451
452 * java/lang/natClass.cc (getMethod): Compute offset relative to
453 `klass's methods table, not `this's table.
454
455 * java/lang/reflect/natMethod.cc (_Jv_CallNonvirtualMethodA):
456 In unwrapping/widening case, check whether `k' is null, not
457 whether it is primitive. Initialize `num' from `argelts', not
458 `paramelts'. Correct create and pass arguments to ffi_call.
459 Don't let presence of `this' argument affect index used to look in
460 argument arrays.
461 (COPY): Set appropriate element in `values' vector.
462
463 * java/lang/natClass.cc: Include <gcj/method.h>.
464
465 * java/lang/Class.h (_getMethods): Correctly declare as private,
466 not public.
467
468 * java/lang/Class.h (_getMethods): Declare.
469 * java/lang/Class.java (_getMethods): Declare.
470 * java/lang/natClass.cc (getDeclaringClass): Always return NULL.
471 (getDeclaredClasses): Always return empty array.
472 (_getMethods): New method.
473 (getMethods): Wrote.
474 (getDeclaredMethod): Return `rmethod'.
475 (finit_name): New global.
476 (getDeclaredMethods): Check for finit_name.
477 (_getMethods): Likewise.
478 (getMethod): Only return public methods.
479
480 * java/lang/reflect/natMethod.cc (get_ffi_type): Test size of
481 jboolean and select correct ffi type on that basis.
482 (_Jv_CallNonvirtualMethodA): Handle `void' return type.
483 Constructor call always has `void' return type.
484
485 2000-01-04 Tom Tromey <tromey@cygnus.com>
486
487 * java/lang/Class.h (getSignature): Updated.
488 * java/lang/Class.java (getSignature): Updated.
489 * java/lang/natClass.cc (getSignature): Added `is_constructor'
490 argument.
491 (getConstructor): Ensure constructor is public.
492 (_getConstructors): Check for public-ness of constructor when
493 `declared' is false, not when it is true.
494
495 2000-01-04 Warren Levy <warrenl@cygnus.com>
496
497 * java/net/natPlainDatagramSocketImpl.cc (peek): Removed unnecesary
498 comment.
499 (receive): Set the sender's address in the DatagramPacket.
500
501 2000-01-04 Tom Tromey <tromey@cygnus.com>
502
503 * java/lang/reflect/natConstructor.cc (newInstance): Pass
504 declaring class as return_type argument to
505 _Jv_CallNonvirtualMethodA.
506 * java/lang/reflect/natMethod.cc (_Jv_CallNonvirtualMethodA): In
507 constructor case, create object and use it as `this' argument.
508 * java/lang/Class.h (_getConstructors): Declare.
509 (_getFields): Declare.
510 * java/lang/Class.java (getConstructors): Wrote.
511 (_getConstructors): New native method.
512 (getDeclaredConstructors): Wrote.
513 (_getFields): Declare new native method.
514 * java/lang/natClass.cc (_Jv_LookupInterfaceMethod): Removed
515 incorrect comment.
516 (getMethod): Work correctly when class is primitive.
517 (getDeclaredMethods): Likewise. Compute offset using `method',
518 not `mptr'.
519 (getDeclaredMethod): Likewise.
520 (getConstructor): Wrote.
521 (ConstructorClass): New define.
522 (getDeclaredConstructor): Wrote.
523 (_getConstructors): New method.
524 (_getFields): New method.
525 (getFields): Wrote.
526
527 * Makefile.in: Rebuilt.
528 * Makefile.am (AM_CXXFLAGS): Added -D_GNU_SOURCE.
529
530 * prims.cc: Remove `#pragma implementation'.
531 * gcj/array.h: Remove `#pragma interface'.
532
533 * prims.cc (_Jv_equaln): New function.
534 * java/lang/Class.java (getSignature): Declare.
535 * resolve.cc (_Jv_LookupDeclaredMethod): Moved to natClass.cc.
536 * java/lang/natClass.cc (_Jv_LookupDeclaredMethod): Moved from
537 resolve.cc.
538 (getSignature): New method.
539 (getDeclaredMethod): Wrote.
540 (getMethod): Wrote.
541 Include StringBuffer.h.
542 * java/lang/Class.h (Class): Added _Jv_FromReflectedConstructor
543 as a friend. Unconditionally declare _Jv_LookupDeclaredMethod as
544 a friend.
545 (getSignature): Declare.
546 * include/jvm.h (_Jv_GetTypesFromSignature): Declare.
547 (_Jv_equaln): Declare.
548 (_Jv_CallNonvirtualMethodA): Declare.
549 * Makefile.in: Rebuilt.
550 * Makefile.am (nat_source_files): Added natConstructor.cc.
551 (java/lang/reflect/Constructor.h): New target.
552 * java/lang/reflect/natConstructor.cc: New file.
553 * java/lang/reflect/Constructor.java (newInstance): Now native.
554 (declaringClass): Renamed from decl_class.
555 (offset): Renamed from index.
556 (getType): New native method.
557 (getModifiers): Now native.
558 (getParameterTypes): Call getType if required.
559 (hashCode): Include hash code from declaring class.
560 (modifiers): Removed.
561 (toString): Call getType if required.
562 * gcj/method.h (_Jv_FromReflectedConstructor): New function.
563 * java/lang/reflect/natMethod.cc (hack_call): New method.
564 Removed `#if 0' around FFI code.
565 Include <gnu/gcj/RawData.h>.
566 (invoke): Use _Jv_CallNonvirtualMethodA. Throw
567 IllegalArgumentException when argument object and class disagree.
568 (_Jv_GetTypesFromSignature): New function.
569 (getType): Use it.
570 (ObjectClass): New define.
571 (_Jv_CallNonvirtualMethodA): New function.
572 * java/lang/reflect/Method.java (hack_trampoline): New method.
573 (hack_call): New native method.
574
575 1999-12-21 Per Bothner <per@bothner.com>
576
577 * java/lang/natClass.cc (getDeclaredMethods): Correctly compute
578 offset in new Method.
579
580 1999-12-22 Bryce McKinlay <bryce@albatross.co.nz>
581
582 * java/lang/natObject.cc (notify): Throw message with
583 IllegalMonitorStateException.
584 (notifyAll): Ditto.
585 (wait): Ditto.
586 * java/lang/Thread.java (isInterrupted): Don't clear interrupt_flag.
587 (isInterrupted_): New function, which does clear interrupt_flag.
588 (interrupt): Use `isInterrupted_'.
589 * java/lang/natThread.cc (interrupt): Add comment.
590 (join): Set `prev' in joiner loop.
591 Change various calls to `isInterrupted' to use `isInterrupted_'.
592 * posix-threads.cc (_Jv_CondWait): Allways use pthread_cond_timedwait
593 on linux. Set result to 0 on an interrupt. Test interrupted status
594 of java Thread object directly.
595 FLAG_INTERRUPTED: removed.
596 (_Jv_ThreadStart): Throw OutOfMemoryError if pthread_create fails.
597 (_Jv_ThreadInterrupt): Don't set FLAG_INTERRUPTED.
598 (_Jv_InitThreads): Don't block SIGINT.
599 (_Jv_ThreadWait): Don't configure SIGINT handler.
600
601 1999-12-21 Tom Tromey <tromey@cygnus.com>
602
603 * mauve-libgcj: Added java.lang.reflect.Modifier.toString12.
604
605 1999-12-20 Tom Tromey <tromey@cygnus.com>
606
607 * java/lang/reflect/Modifier.java (STRICT): New constant.
608 (isStrict): New method.
609 (toString): Added `strict'.
610
611 1999-12-23 Anthony Green <green@cygnus.com>
612
613 * configure: Rebuilt.
614 * configure.in (LIBDATASTARTSPEC): Force data_start in with
615 linker trick.
616
617 1999-12-19 Anthony Green <green@cygnus.com>
618
619 * libgcjdata.c: New file.
620 * libgcj.spec.in: Use @LIBDATASTARTSPEC@ in startfile.
621 * configure: Rebuilt.
622 * configure.in (LIBDATASTARTSPEC): Force data with a known name
623 into the program.
624 * Makefile.in: Rebuilt.
625 * Makefile.am: Build libgcjdata.a.
626
627 * libgcj.spec.in: Use @FORCELIBGCCSPEC@ in startfile.
628 * configure: Rebuilt.
629 * configure.in (FORCELIBGCCSPEC): Force important parts of libgcc
630 into every program.
631
632 1999-12-17 Tom Tromey <tromey@cygnus.com>
633
634 * java/lang/reflect/Method.java (toString): Call getType if
635 required. Partial fix for PR libgcj/111. From Per Bothner.
636
637 * java/lang/natPosixProcess.cc (startProcess): Don't use sprintf.
638
639 1999-12-16 Bryce McKinlay <bryce@albatross.co.nz>
640
641 * java/lang/Boolean.java (Boolean(String)): Set `value' to false on a
642 null String constructor parameter.
643 * java/net/natPlainSocketImpl.cc: Remove unneccessary sprintf calls
644 for exception messages.
645 BooleanClass: declare.
646 (setOption): Use BooleanClass instead of Class.forName() for
647 instanceof test.
648 (bind): Cast 4th parameter of setsockopt to `char *' for
649 compatibility with older Solaris headers.
650 * java/net/natPlainDatagramSocketImpl.cc: Remove unneccessary
651 sprintf calls for exception messages.
652 BooleanClass, IntegerClass: declare.
653 (setOption): Use BooleanClass and IntegerClass, not Class.forName()
654 for instanceof test.
655
656 1999-12-15 Tom Tromey <tromey@cygnus.com>
657
658 * java/lang/natSystem.cc (init_properties): Don't set user.name or
659 user.home if NO_GETUID defined. Only set user.dir if getcwd
660 exists.
661
662 * include/config.h.in: Rebuilt.
663 * acconfig.h (NO_GETUID): New define.
664 * configure.in: Rebuilt.
665 * configure.in: Define NO_GETUID in cross case. Check for getcwd
666 in native case.
667
668 1999-12-08 Tom Tromey <tromey@cygnus.com>
669
670 * include/posix-threads.h (_Jv_PthreadCheckMonitor): Handle case
671 where no recursive mutexes exist. Fixes PR libgcj/117.
672
673 1999-12-05 Anthony Green <green@cygnus.com>
674
675 * include/jvm.h: Declare many functions with
676 __attribute__((__malloc__)).
677 * gcj/javaprims.h: Ditto.
678
679 Thu Dec 2 17:26:47 1999 Anthony Green <green@cygnus.com>
680
681 * THANKS: Giving credit where credit is due.
682
683 1999-12-02 Bryce McKinlay <bryce@albatross.co.nz>
684
685 * java/net/ServerSocket.java (ServerSocket): Bind to any interface
686 if bindAddr is null.
687 * java/lang/natString.cc (equalsIgnoreCase): return false if
688 anotherString is null.
689 * java/lang/Boolean.java (valueOf): return FALSE if argument is
690 null.
691
692 1999-11-30 Tom Tromey <tromey@cygnus.com>
693
694 * posix-threads.cc (_Jv_MutexInit): Use _Jv_PthreadGetMutex to get
695 mutex to initialize. Initialize `count' if required.
696 Fixes PR libgcj/98.
697
698 1999-11-27 Per Bothner <per@bothner.com>
699
700 * exception.cc: Remove prototype declarations for malloc and free.
701 These clash with recent versions of glibc, which specifies `throws ()'
702 when __cplusplus is defined. Instead, #include <stdlib.h>.
703
704 1999-11-24 Tom Tromey <tromey@cygnus.com>
705
706 * prims.cc (_Jv_NewObjectArray): Use
707 _Jv_GetArrayElementFromElementType.
708 (_Jv_NewPrimArray): Likewise.
709 * java/lang/natObject.cc (clone): Use
710 _Jv_GetArrayElementFromElementType instead of sizeof.
711 * java/lang/natSystem.cc (arraycopy): Use
712 _Jv_GetArrayElementFromElementType.
713 * include/jvm.h (_Jv_GetArrayElementFromElementType): New
714 function.
715
716 1999-11-23 Bryce McKinlay <bryce@albatross.co.nz>
717
718 * java/net/natPlainSocketImpl.cc: Fix potential buffer overruns in
719 Exception messages. PR java.net/57.
720 (bind): set SO_REUSEADDR before bind.
721 * java/net/natPlainDatagramSocketImpl.cc: Fix potential buffer
722 overruns. PR java.net/57.
723
724 1999-11-19 Tom Tromey <tromey@cygnus.com>
725
726 * Makefile.am (DIVIDESPEC): Removed.
727 (EXCEPTIONSPEC): Removed.
728
729 1999-11-19 Andrew Haley <aph@cygnus.com>
730
731 * Makefile.am (JCFLAGS): Add -L$(here)
732 (JC1FLAGS): Ditto.
733 * Makefile.in: Rebuild.
734
735 1999-11-18 Tom Tromey <tromey@cygnus.com>
736
737 * java/lang/natDouble.cc: Include <config.h>.
738
739 * include/config.h.in: Rebuilt.
740 * acconfig.h (SJLJ_EXCEPTIONS): Undefine.
741 * configure.host: Force -fsjlj-exceptions on non-sparc, non-x86
742 targets.
743 * configure: Rebuilt.
744 * configure.in (EXCEPTIONSPEC): Allow -fsjlj-exceptions to be
745 requested by configure.host. Don't put `-D' option into
746 libgcj.spec; instead, define SJLJ_EXCEPTIONS with AC_DEFINE.
747
748 * configure: Rebuilt.
749 * configure.in (EXCEPTIONSPEC): Changed `_' to `-' in
750 sjlj-exceptions.
751
752 1999-11-18 Andrew Haley <aph@cygnus.com>
753
754 * Makefile.am: rename SJLJ_EXCEPTIONS to EXCEPTIONSPEC.
755 (AM_CFLAGS): remove SJLJ_EXCEPTIONS.
756 (JC1FLAGS): Ditto.
757 * Makefile.in: Rebuild
758 * acconfig.h: remove SJLJ_EXCEPTIONS
759 * configure.in: rename SJLJ_EXCEPTIONS to EXCEPTIONSPEC.
760 Do not AC_DEFINE SJLJ_EXCEPTIONS.
761 * libgcj.spec.in: Add EXCEPTIONSPEC to jc1.
762 * gcj/Makefile.in, include/Makefile.in: rebuild.
763 * include/config.h.in: remove SJLJ_EXCEPTIONS.
764
765 1999-11-18 Andrew Haley <aph@cygnus.com>
766
767 * gij.cc (main): Rename label to prevent conflict.
768
769 * exception.cc (_Jv_type_matcher): Don't check the table if we're
770 using setjmp/longjmp exceptions: there isn't one.
771
772 1999-11-17 Andrew Haley <aph@cygnus.com>
773
774 * exception.cc (_Jv_type_matcher): Ignore null exception tables.
775 (_Jv_Throw ): Add SJLJ_EXCEPTIONS.
776 (__sjthrow): Add declaration.
777 * Makefile.am (JCFLAGS): Add SJLJ_EXCEPTIONS
778 (JC1FLAGS): Ditto
779 (AM_CFLAGS): Ditto
780 (AM_CXXFLAGS): Ditto
781 * Makefile.in: Rebuild
782 * acconfig.h: Add SJLJ_EXCEPTIONS
783 * configure.in: Add SJLJ_EXCEPTIONS
784 * configure: Rebuild.
785 * gcj/Makefile.in: Rebuild.
786 * gcj/cni.h: Add support for sjlj-exceptions.
787 * gcj/javaprims.h: Add _Jv_Sjlj_Throw.
788 * include/Makefile.in: Rebuild.
789 * include/default-signal.h: Add support for sjlj-exceptions.
790
791 1999-11-18 Tom Tromey <tromey@cygnus.com>
792
793 * no-threads.cc (_Jv_ThreadStart): Use JvFail and not JvAssert.
794
795 * java/lang/natClass.cc (MCACHE_SIZE): Define as a power of 2
796 minus 1.
797 (method_cache): Made larger.
798
799 1999-11-11 Tom Tromey <tromey@cygnus.com>
800
801 * posix-threads.cc (_Jv_MutexInit): Use _Jv_PthreadGetMutex when
802 initializing mutex. Initialize `count' when required.
803
804 1999-11-07 Anthony Green <green@trip.cygnus.com>
805
806 * java/util/zip/ZipFile.java: Compute the offset of the ZipEntry
807 data correctly.
808
809 1999-11-05 Tom Tromey <tromey@cygnus.com>
810
811 * java/lang/natThread.cc (destroy): Removed incorrect comment.
812
813 1999-11-05 Jeff Sturm <jsturm@sigma6.com>
814
815 * boehm.cc (_Jv_GCSetInitialHeapSize): Swapped size & current.
816 * prims.cc (parse_heap_size): Use end, not spec. Use 1024
817 multipler for `k'.
818
819 1999-11-05 Tom Tromey <tromey@cygnus.com>
820
821 * java/lang/natThread.cc (stop): Removed argument name.
822
823 * java/lang/ThreadGroup.java (ThreadGroup(int)): No longer
824 `private'; now has default access.
825 * Makefile.in: Rebuilt.
826 * Makefile.am (java/lang/ThreadGroup.h): Removed.
827
828 1999-11-04 Tom Tromey <tromey@cygnus.com>
829
830 * java/lang/natClass.cc (method_cache_count): Removed.
831 (_Jv_FindMethodInCache): Don't loop looking for the hash entry.
832 (_Jv_AddMethodToCache): Don't loop.
833
834 * configure.in: Removed `qt' threads case.
835 * include/quick-threads.h: Removed.
836 * quick-threads.cc: Removed.
837
838 * include/quick-threads.h (_Jv_ThreadCancel): Removed.
839 (_Jv_ThreadDestroy): Likewise.
840 * include/no-threads.h (_Jv_ThreadCancel): Removed.
841 (_Jv_ThreadDestroy): Likewise.
842 * include/posix-threads.h (struct _Jv_Thread_t): Removed
843 `exception' field.
844 (_Jv_ThreadCancel): Removed decl.
845 (_Jv_ThreadDestroy): Removed.
846 * posix-threads.cc (_Jv_ThreadCancel): Removed.
847 (throw_cleanup): Removed.
848 (really_start): Don't push or pop cleanup.
849 (_Jv_ThreadInitData): Don't initialize `exception' field.
850 * java/lang/Thread.java (stop): Officially unimplemented.
851 * java/lang/natThread.cc (stop): Officially unimplemented.
852
853 1999-11-02 Bryce McKinlay <bryce@albatross.co.nz>
854
855 * posix-threads.cc: Don't include boehm-config.h. Include gcconfig.h
856 instead.
857
858 1999-11-02 Tom Tromey <tromey@cygnus.com>
859
860 * boehm.cc: Don't include boehm-config.h.
861
862 1999-11-01 Tom Tromey <tromey@cygnus.com>
863
864 * boehm.cc (_Jv_InitGC): Set GC_java_finalization.
865 (sum_blocks): Removed.
866 (_Jv_GCFreeMemory): Use GC_get_free_bytes.
867
868 1999-11-01 Bryce McKinlay <bryce@albatross.co.nz>
869
870 * java/io/PrintStream (PrintStream): Fix illegal usage of "this"
871 before "super".
872 * java/io/OutputStreamWriter (OutputStreamWriter): ditto.
873 * java/io/InputStreamReader (InputStreamReader): ditto.
874
875 1999-10-22 Tom Tromey <tromey@cygnus.com>
876
877 * Makefile.in: Rebuilt.
878 * Makefile.am (java/lang/ClassLoader.h): New target.
879 * java/lang/natClassLoader.cc (_Jv_FindClass): Removed reference
880 to `redirect'.
881
882 * include/java-props.h (_Jv_Compiler_Properties): Changed
883 declaration.
884 * gcj/array.h (JvRunMain, _Jv_RunMain): Don't declare.
885 * include/jvm.h (_Jv_GCSetInitialHeapSize,
886 _Jv_GCSetMaximumHeapSize): Declare.
887 (JvRunMain, _Jv_RunMain): Declare.
888 (_Jv_SetMaximumHeapSize, _Jv_SetInitialHeapSize): Declare.
889 * nogc.cc (_Jv_GCSetInitialHeapSize): New function.
890 (_Jv_GCSetMaximumHeapSize): Likewise.
891 * boehm.cc (_Jv_GCSetInitialHeapSize): New function.
892 (_Jv_GCSetMaximumHeapSize): Likewise.
893 * prims.cc (parse_heap_size): New function.
894 (_Jv_SetInitialHeapSize): Likewise.
895 (_Jv_SetMaximumHeapSize): Likewise.
896 (_Jv_Compiler_Properties): New global.
897 * gij.cc (help): New function.
898 (version): Likewise.
899 (heap_size): Likewise.
900 (heap_max_size): Likewise.
901 (main): Parse arguments. Set _Jv_Compiler_Properties.
902 Include <config.h>, <java-props.h>.
903 (_Jv_Compiler_Properties): Removed.
904
905 1999-10-18 Tom Tromey <tromey@cygnus.com>
906
907 * gnu/gcj/runtime/VMClassLoader.java (getVMClassLoader): New
908 method.
909 (redirect): New static field.
910 * java/lang/ClassLoader.java (getSystemClassLoader): Now
911 native
912 (getVMClassLoader0): Removed.
913 * java/lang/natClassLoader.cc (getVMClassLoader0): Removed.
914 (redirect): Removed.
915 (getSystemClassLoader): Implemented.
916
917 1999-10-16 Anthony Green <green@cygnus.com>
918
919 * java/lang/ClassLoader.java (getSystemResource): Use
920 getSystemClassLoader instead of ClassLoader.system.
921 (getSystemResourceAsStream): Ditto.
922
923 * java/lang/natClassLoader.cc (redirect): Make static and
924 remove #ifdef INTERPRETER so it is always defined.
925 (getVMClassLoader0): Remove #ifdef INTERPRETER so it always
926 returns a VMClassLoader.
927
928 * java/util/ResourceBundle.java (trySomeGetBundle): Create a
929 PropertyResourceBundle if a properties file is found before a
930 ResourceBundle class.
931
932 1999-10-15 Tom Tromey <tromey@cygnus.com>
933
934 * gij.cc (main): Formatting fixes.
935 (_Jv_Compiler_Properties): Define.
936 * java/lang/natSystem.cc (_Jv_Environment_Properties): Don't
937 declare.
938 (init_properties): Set properites from _Jv_Compiler_Properties.
939 * include/java-props.h (_Jv_Compiler_Properties,
940 _Jv_Environment_Properties): Declare.
941
942 * include/java-props.h: Added copyright.
943
944 1999-10-13 Anthony Green <green@cygnus.com>
945
946 * libtool-version: Catch up by incrementing current.
947
948 * configure.host: Disable use of GCJ_PROPERTIES for mips-tx39.
949 * configure, include/config.h.in: Rebuilt.
950 * acconfig.h (DISABLE_GETENV_PROPERTIES): Undefine.
951 * configure.in: Added --disable-getenv-properties and new define
952 `DISABLE_GETENV_PROPERTIES'.
953
954 * prims.cc (PROCESS_GCJ_PROPERTIES): Define.
955 (next_property_key): New function.
956 (next_property_value): New function.
957 (process_gcj_properties): New function.
958 (JvRunMain): Call process_gcj_properties.
959 (_JvRunMain): Ditto.
960
961 * java/lang/natSystem.cc (init_properties): Set properties defined
962 in GCJ_PROPERTIES.
963
964 * include/java-props.h: New file.
965
966 * java/lang/natSystem.cc (init_properties): Add new properties to
967 conform with Java Product Versioning Specification.
968
969 1999-10-12 Tom Tromey <tromey@cygnus.com>
970
971 * configure: Rebuilt.
972 * configure.in: Fixed test for --disable-java-net.
973
974 1999-10-06 Tom Tromey <tromey@cygnus.com>
975
976 * configure.in (GCJ): Define as "target-gcj", not "target/gcj"
977 when building Canadian cross.
978 (NATIVE): Don't define when cross-compiling.
979
980 1999-10-04 Tom Tromey <tromey@cygnus.com>
981
982 * java/net/natPlainSocketImpl.cc: Don't include headers if
983 java.net is disabled.
984
985 * Makefile.in: Rebuilt.
986 * Makefile.am (ZINCS): Removed. This is defined in configure.in
987 when needed, and must be left empty when not needed.
988
989 1999-10-01 Anthony Green <green@cygnus.com>
990
991 * THANKS: Refreshed from htdocs version.
992
993 1999-10-01 Steve Chamberlain <sac@pobox.com>
994
995 * Makefile.in: Rebuilt.
996 * Makefile.am (ZINCS): Define
997
998 * configure: Rebuilt.
999 * configure.in (ZLIBSPEC): Spell -lzgcj correctly.
1000
1001 * java/lang/ieeefp.h: Add definitions for picoJava.
1002
1003 1999-10-01 Tom Tromey <tromey@cygnus.com>
1004
1005 * configure: Rebuilt.
1006 * configure.in: Set classpath when invoking gcj. Use changequote
1007 around sed invocation.
1008
1009 * java/net/natPlainSocketImpl.cc: Stub native functions if
1010 DISABLE_JAVA_NET is defined.
1011 * java/net/natPlainDatagramSocketImpl.cc (setTimeToLive): Fixed
1012 typo in exception string.
1013 (getTimeToLive): Likewise.
1014 Stub native functions if DISABLE_JAVA_NET is defined.
1015 * java/net/natInetAddress.cc: Stub native functions if
1016 DISABLE_JAVA_NET is defined.
1017 * configure.host: Disable java.net for mips-tx39.
1018 * configure, include/config.h.in: Rebuilt.
1019 * acconfig.h (DISABLE_JAVA_NET): Undefine.
1020 * configure.in: Added --disable-java-net and new define
1021 `DISABLE_JAVA_NET'.
1022
1023 1999-09-30 Tom Tromey <tromey@cygnus.com>
1024
1025 * java/net/natPlainDatagramSocketImpl.cc: Indentation fix.
1026
1027 1999-09-29 Bryce McKinlay <bryce@albatross.co.nz>
1028
1029 * README: New file.
1030
1031 1999-09-28 Tom Tromey <tromey@cygnus.com>
1032
1033 * configure: Rebuilt.
1034 * configure.in (PROCESS): In POSIX case, only set if not already
1035 set.
1036 * configure.host (PROCESS): Set in mips-tx39 case.
1037
1038 * aclocal.m4, configure: Rebuilt.
1039 * acinclude.m4 (LIB_AC_PROG_CC, LIB_AC_PROG_CXX): Provide
1040 appropriate AC_PROG_ symbol.
1041
1042 1999-09-24 Tom Tromey <tromey@cygnus.com>
1043
1044 * include/sparc-signal.h (SIGNAL_HANDLER): Third argument now a
1045 `void *'.
1046 (MAKE_THROW_FRAME): Cast third argument back to `ucontext_t *'.
1047
1048 Fix for PR java.util/47:
1049 * configure, include/config.h: Rebuilt.
1050 * configure.in: Don't look for ctime or ctime_r.
1051 * Makefile.in: Rebuilt.
1052 * Makefile.am (nat_source_files): Don't mention natDate.cc.
1053 * java/util/natDate.cc: Removed.
1054 * java/util/TimeZone.java (tzIDs, rawOffsets, timeZones): New
1055 static fields.
1056 (getAvailableIDs): Rewrote.
1057 (getTimeZone): Rewrote.
1058 * java/util/Date.java (toGMTString): New method.
1059 (toLocaleString): New method.
1060 (toString): Rewrote.
1061
1062 1999-09-23 Tom Tromey <tromey@cygnus.com>
1063
1064 * configure: Rebuilt.
1065 * configure.in: Print message when checking to see if gcj can
1066 handle -fuse-divide-subroutine.
1067
1068 * java/lang/natFirstThread.cc (run): Renamed from `run0'. Removed
1069 dead code.
1070 * java/lang/FirstThread.java (run0): Renamed to `run'.
1071 (run): Removed.
1072
1073 * prims.cc (main_init): New function.
1074 (JvRunMain): Call it.
1075 (_Jv_RunMain): Likewise.
1076 Include <signal.h>.
1077 (main_init): Ignore SIGPIPE. Fixes PR 51.
1078
1079 1999-09-22 Tom Tromey <tromey@cygnus.com>
1080
1081 * libgcj.spec.in: Use `jc1' spec, not `cc1' spec.
1082
1083 1999-09-16 Bryce McKinlay <bryce@albatross.co.nz>
1084
1085 * java/text/MessageFormat.java (MessageFormat(String)): Set the
1086 default locale.
1087 * java/text/NumberFormat.java: Check that object is a Number. If
1088 not, throw IllegialArgumentException.
1089
1090 1999-09-21 Tom Tromey <tromey@cygnus.com>
1091
1092 * gnu/gcj/convert/Output_UTF8.java (write): Don't exit loop unless
1093 both `inlength' and `bytes_todo' are 0. Simplified 2-byte case.
1094
1095 * include/posix-threads.h (_Jv_MutexDestroy): Use
1096 _Jv_PthreadGetMutex.
1097 (_Jv_MutexLock): Likewise.
1098 (_Jv_MutexUnlock): Likewise.
1099
1100 * java/io/OutputStreamWriter.java (OutputStreamWriter): Reverted
1101 previous patch; it too was incorrect.
1102 * java/io/PrintStream.java (PrintStream): Likewise.
1103
1104 * java/io/OutputStreamWriter.java (OutputStreamWriter): Don't
1105 refer to `this' before calling superclass constructor.
1106 * java/io/PrintStream.java (PrintStream): Don't refer to `this'
1107 before calling superclass constructor.
1108
1109 1999-09-20 Tom Tromey <tromey@cygnus.com>
1110
1111 * configure: Rebuilt.
1112 * configure.in: Send output of `-fuse-divide-subroutine' test
1113 compilation to /dev/null.
1114
1115 1999-09-14 Tom Tromey <tromey@cygnus.com>
1116
1117 * include/java-insns.h: Turned constants into an enum. Added
1118 multiple-inclusion protection.
1119
1120 1999-09-10 Tom Tromey <tromey@cygnus.com>
1121
1122 * configure: Rebuilt.
1123 * configure.in: Build include/Makefile.
1124 * Makefile.in: Rebuilt.
1125 * Makefile.am (SUBDIRS): Added gcj and include.
1126 (install-data-local): New target.
1127 (extra_headers): New macro.
1128 * include/Makefile.in: New file.
1129 * include/Makefile.am: New file.
1130
1131 * interpret.cc: Don't include gcj/field.h or gcj/cni.h.
1132 * java/lang/reflect/natField.cc: Don't include gcj/field.h or
1133 gcj/cni.h.
1134 * boehm.cc: Don't include java-threads.h or gcj/field.h.
1135 * resolve.cc: Include config.h.
1136 * defineclass.cc: Include config.h.
1137 * include/java-interp.h: Don't include config.h.
1138 * include/jvm.h: Include java-threads.h, Object.h, java-gc.h,
1139 cni.h.
1140
1141 * gcj/javaprims.h: Regenerated namespace decls.
1142 * classes.pl (scan): Don't put `;' after closing brace.
1143
1144 * Makefile.in: Rebuilt.
1145 * Makefile.am (INCLUDES): Added -I for top_srcdir.
1146 * configure.in: Create gcj/Makefile.
1147 * gcj/Makefile.in: New file.
1148 * gcj/Makefile.am: New file.
1149 * java/lang/Object.h: Don't include any other headers.
1150 * gcj/array.h: Renamed from include/java-array.h.
1151 * gcj/field.h: Renamed from include/java-field.h.
1152 * gcj/method.h: Renamed from include/java-method.h.
1153 * gcj/cni.h, gcj/javaprims.h: Moved from include/.
1154 Updated all files to reflect new include structure.
1155
1156 1999-09-09 Tom Tromey <tromey@cygnus.com>
1157
1158 * configure: Rebuilt.
1159 * configure.in: Fixed typo; variable is THREADSPEC and not
1160 THREADSPECS.
1161
1162 1999-09-08 Tom Tromey <tromey@cygnus.com>
1163
1164 * include/posix-threads.h (_Jv_PthreadCheckMonitor): Reverted
1165 previous change and implemented a correct test in the __m_count
1166 case.
1167
1168 * include/posix-threads.h (_Jv_PthreadCheckMonitor): Changed test
1169 in __m_count case.
1170
1171 1999-09-07 Tom Tromey <tromey@cygnus.com>
1172
1173 * posix-threads.cc (_Jv_CondWait): pthread_ calls return error
1174 code and don't set errno.
1175
1176 * posix-threads.cc (_Jv_CondWait): Check `errno' against EINTR,
1177 not `r'. Changed `done_sleeping' to a `bool'.
1178
1179 1999-09-07 Matt Welsh <mdw@cs.berkeley.edu>
1180
1181 * libjava/posix-threads.cc: Added _Jv_ThreadDataKey.
1182 Added FLAG_INTERRUPTED to indicate that a thread was interrupted
1183 by another thread, rather than by the GC.
1184 (_Jv_CondWait): Prevent premature thread wakeup by GC.
1185 (_Jv_InitThreads): Initialize _Jv_ThreadDataKey.
1186 * libjava/include/posix-threads.h (_Jv_ThreadCurrentData): New
1187 function.
1188
1189 1999-09-03 Tom Tromey <tromey@cygnus.com>
1190
1191 * configure: Rebuilt.
1192 * configure.in: Check for fstat function.
1193 * java/io/natFileDescriptorPosix.cc (available): Use fstat() if
1194 FIONREAD fails.
1195
1196 1999-09-02 Tom Tromey <tromey@cygnus.com>
1197
1198 * include/java-array.h (jobjectArrayjchar): Removed unused
1199 declaration.
1200
1201 * java/lang/natClassLoader.cc (_Jv_WaitForState): Call
1202 _Jv_PrepareCompiledClass while holding class mutex.
1203
1204 1999-09-01 Tom Tromey <tromey@cygnus.com>
1205
1206 * include/posix-threads.h (PTHREAD_MUTEX_IS_STRUCT): New define.
1207 (_Jv_PthreadGetMutex): Use it.
1208 (_Jv_PthreadCheckMonitor): Use new M_COUNT macros.
1209 (_Jv_MutexInit): Use PTHREAD_MUTEX_IS_STRUCT.
1210 (_Jv_MutexLock): Likewise.
1211 (_Jv_MutexUnlock): Likewise.
1212 * include/config.h.in: Rebuilt.
1213 * acconfig.h (PTHREAD_MUTEX_HAVE_M_COUNT,
1214 PTHREAD_MUTEX_HAVE___M_COUNT): New undefs.
1215 * configure: Rebuilt.
1216 * libgcj.spec.in: Don't mention INTERPSPEC.
1217 * configure.in (INTERPSPEC): Removed.
1218 Only run pthreads-related checks when using POSIX threads. Check
1219 for m_count and __m_count in mutex structure.
1220
1221 1999-09-01 Matt Welsh <mdw@cs.berkeley.edu>
1222
1223 * java/lang/natClass.cc: Fixed notification of threads
1224 when class initialization is complete.
1225
1226 1999-09-01 Tom Tromey <tromey@cygnus.com>
1227
1228 * java/lang/reflect/Modifier.java (ALL_FLAGS): New constant.
1229 * resolve.cc: Removed constants defined by
1230 java.lang.reflect.Modifier.
1231 Include <java/lang/reflect/Modifier.h>.
1232 (_Jv_ResolvePoolEntry): Use values from Modifier.
1233 (_Jv_DetermineVTableIndex): Likewise.
1234 (_Jv_PrepareClass): Likewise.
1235 (ncode): Likewise.
1236 * defineclass.cc (_Jv_ClassReader): Removed constants defined by
1237 java.lang.reflect.Modifier.
1238 Include <java/lang/reflect/Modifier.h>.
1239 (checkExtends): Use values from Modifier.
1240 (checkImplements): Likewise.
1241 (handleField): Likewise.
1242 (handleConstantValueAttribute): Likewise.
1243 (handleFieldsEnd): Likewise.
1244 (handleMethod ): Likewise.
1245 (handleMethodsEnd): Likewise.
1246 (handleClassBegin): Likewise.
1247 * interpret.cc: Removed constants defined by
1248 java.lang.reflect.Modifier.
1249 (continue1): Use values from Modifier.
1250 * java/lang/natClassLoader.cc: Removed constants defined by
1251 java.lang.reflect.Modifier.
1252
1253 * java/lang/natClassLoader.cc (_Jv_NewClass): Use
1254 JV_STATE_NOTHING, not `0'.
1255 * java/lang/Class.h: Replaced JV_STATE_ defines with enum.
1256
1257 * posix-threads.cc (_Jv_CondWait): Use _Jv_PthreadGetMutex.
1258 * include/posix-threads.h (_Jv_Mutex_t): Define as structure,
1259 except on Linux.
1260 (_Jv_PthreadGetMutex): New function.
1261 (_Jv_PthreadCheckMonitor): Use it.
1262 (_Jv_MutexInit): Likewise. ALso, initialize `count'.
1263 (_Jv_MutexLock): Update `count'.
1264 (_Jv_MutexUnlock): Likewise.
1265 (_Jv_PthreadCheckMonitor): Use Linux-specific knowledge when
1266 appropriate.
1267
1268 1999-09-01 Kresten Krab Thorup <krab@gnu.org>
1269
1270 * Makefile.am (.java.lo): Add rule.
1271
1272 * Makefile.in: Rebuilt.
1273
1274 1999-09-01 Tom Tromey <tromey@cygnus.com>
1275
1276 * posix-threads.cc (_Jv_CondWait): Call _Jv_PthreadCheckMonitor.
1277 * include/posix-threads.h (_Jv_PthreadCheckMonitor): New
1278 function.
1279 (_Jv_CondNotify): Use it.
1280 (_Jv_CondNotifyAll): Likewise.
1281
1282 * java/lang/Class.h (JV_STATE_NOTHING): Correct misspelling.
1283
1284 1999-08-31 Tom Tromey <tromey@cygnus.com>
1285
1286 * include/jvm.h (_Jv_makeUtf8TypeConst): Removed unused
1287 declaration.
1288
1289 1999-08-24 Bryce McKinlay <bryce@albatross.co.nz>
1290
1291 * posix-threads.cc: Include <errno.h>.
1292
1293 1999-08-23 Tom Tromey <tromey@cygnus.com>
1294
1295 * boehm.cc: Undefine TRUE and FALSE.
1296
1297 * posix-threads.cc (_Jv_CondWait): Use ETIMEDOUT, not ETIME.
1298
1299 1999-08-21 Tom Tromey <tromey@cygnus.com>
1300
1301 * posix-threads.cc (_Jv_CondWait): Treat a timeout as a normal
1302 result. PR 40.
1303
1304 1999-08-21 Alexandre Oliva <oliva@dcc.unicamp.br>
1305
1306 * configure.in: Check for in_addr_t in netinet/in.h too. Check
1307 for ip_mreq too.
1308 * acconfig.h: Define HAVE_IN_ADDR_T instead of in_addr_t.
1309 (HAVE_STRUCT_IP_MREQ): Added.
1310 * configure, include/config.h.in: Rebuilt.
1311 * java/net/natInetAddress.cc (aton): Typedef in_addr_t to jint
1312 if needed.
1313 * java/net/natPlainDatagramSocketImpl.cc (McastReq, mcastGrp):
1314 Disable if ip_mreq is not available.
1315
1316 * configure.in: Check types ssize_t and in_addr_t.
1317 * acconfig.h: Undefine them.
1318 * configure, include/config.h.in: Rebuilt.
1319
1320 * java/lang/natSystem.cc (getpwuid_adaptor): New overloaded
1321 function that detects the signature of getpwuid_r.
1322 (init_properties): Use it.
1323 * java/util/natDate.cc (ctime_adaptor): Likewise for ctime_r.
1324 (toString): Use it.
1325
1326 1999-08-20 Kresten Krab Thorup <krab@samam.daimi.au.dk>
1327
1328 * interpret.cc (continue1): Implement explicit dispatch table.
1329 insn_target: Explicit interpreter switch table.
1330 SAVE_PC: New macro, moves pc saving code into instructions that
1331 require so.
1332 NEXT_INSN: New macro, replaces `goto next_insn' in all insns.
1333 PC_REGISTER_ASM: New macro.
1334 INLINE_SWITCH: New macro. Constrols dispatching strategy.
1335 opcode: Remove local variable.
1336 {i,l,f,d}{load,store}_{0,1,2,3}: Expand definitions.
1337 (POKEI): Use _Jv_word.
1338 (iinc): Use _Jv_word.
1339 (dupx): Change reference argument (sp) to pointer.
1340 (jvdump): Remove
1341
1342 * interpret.cc: Remove instruction timing instrumentation.
1343
1344 * java/lang/natClassLoader.cc (_Jv_PrepareCompiledClass): Changed
1345 comment. Don't use _Jv_ClassNameSamePackage.
1346
1347 * gnu/gcj/util/path/{SearchPath,ZipFileEntry,DirectoryPathEntry,
1348 URLPathEntry, CacheEntry}: Removed.
1349
1350 * Makefile.am (ordinary_java_source_files): Remove gnu/gcj/util/path
1351 package.
1352 (.java.lo): Rule removed.
1353
1354 * Makefile.in: Rebuilt.
1355
1356 1999-08-19 Tom Tromey <tromey@cygnus.com>
1357
1358 * java/lang/natThread.cc (class locker): New class.
1359 (join): Use a locker around _Jv_CondWait.
1360 (sleep): Likewise.
1361
1362 1999-08-18 Tom Tromey <tromey@cygnus.com>
1363
1364 * java/lang/ThreadGroup.java: Fixed now-erroneous comment.
1365 * java/lang/natThread.cc (finish_): Call ThreadGroup.remove.
1366
1367 1999-08-18 Tom Tromey <tromey@cygnus.com>
1368
1369 * include/javaprims.h ("Java"): Regenerated namespace decls.
1370
1371 1999-08-18 Kresten Krab Thorup <krab@gnu.org>
1372
1373 * java/lang/natClassLoader.cc (_Jv_PrepareCompiledClass): Renamed
1374 from _Jv_InternClassStrings.
1375
1376 * prims.cc (_Jv_RunMain): New function.
1377 (JvRunMain): Remove gij-support.
1378
1379 * gij.cc (main): Use _Jv_RunMain.
1380
1381 * java/util/zip/ZipFile.java: Call readDirectory in constructor.
1382
1383 * interpret.cc (PUSHA, PUSHI, PUSHF, PUSHL, PUSHD): Don't store
1384 argument in temp variable.
1385 (continue1): For all op_x2y insns, use temp variable for
1386 intermediate value. Also remove some comments.
1387
1388 * java/lang/natClass.cc (newInstance): Call _Jv_InitClass.
1389 (forName): Don't call _Jv_InitClass.
1390
1391 * java/lang/Class.java (getResource,getResourceAsStream): Implement.
1392
1393 * java/util/zip/ZipEntry.java (ZipEntry(ZipEntry)): New construcor.
1394
1395 * java/util/jar/JarInputStream.java: New file.
1396
1397 * java/util/jar/JarEntry.java: New file.
1398
1399 * java/util/jar/JarFile.java: New file.
1400
1401 * java/net/URLClassLoader.java: New file.
1402
1403 * java/net/JarURLConnection.java: New file.
1404
1405 * gnu/gcj/protocol/jar/Handler.java: New file.
1406
1407 * gnu/gcj/protocol/jar/Connection.java: New file.
1408
1409 * java/security/SecureClassLoader.java: New file.
1410
1411 * java/lang/ClassLoader.java (parent): New variable.
1412 (ClassLoader (ClassLoader)): new constructor.
1413 (findClass): New method.
1414 (loadClass): Add default 1.2 implementation.
1415 (getSystemResourceAsBytes, getResourceAsBytes): Removed.
1416 (readfully): Removed.
1417
1418 * gnu/gcj/runtime/VMClassLoader.java: Moved from java/lang.
1419 (findSystemClass): New method.
1420 (VMClassLoader): Constructor rewritten.
1421 (init): New method.
1422 All other methods removed.
1423
1424 * java/lang/natClassLoader.cc: Change use of java::lang::VMClassLoader
1425 to gnu::gcj::runtime::VMClassLoader.
1426 (_Jv_InternClassStrings): Use _Jv_ResolvePoolEntry. Also handle
1427 class entries.
1428 (VMClassLoader::findSystemClass): renamed from findBootClass.
1429
1430 * Makefile.am: Add new files.
1431 (FirstThread.h, ThreadGroup.h): Add _Jv_Main friend.
1432
1433 * Makefile.in: Rebuilt.
1434
1435 1999-08-17 Tom Tromey <tromey@cygnus.com>
1436
1437 * java/lang/natThread.cc (sleep): Turn 0 millis and 0 nanos into 1
1438 nano.
1439 * include/quick-threads.h (_Jv_CondWait): Don't round to 0
1440 inappropriately.
1441
1442 1999-08-16 Tom Tromey <tromey@cygnus.com>
1443
1444 * configure: Rebuilt.
1445 * configure.in: Set DIVIDESPEC to empty string if compiler does
1446 not support -fuse-divide-subroutine.
1447
1448 1999-08-14 Per Bothner <per@bothner.com>
1449
1450 * resolve.cc (_Jv_PrepareClass): Use ClassLoader::resolveClass0.
1451 * java/lang/natClass.cc (initializeClass): Likewise.
1452 * java/lang/ClassLoader.java (resolveClass0): New static method.
1453 (resolveClass): Call resolveClass0.
1454 (findSystemClass): No longer static.
1455
1456 1999-08-12 Alexandre Oliva <oliva@dcc.unicamp.br>
1457
1458 * include/javaprims.h (TRUE, FALSE): Redefine as themselves.
1459
1460 1999-08-11 Bryce McKinlay <bryce@albatross.co.nz>
1461
1462 * java/util/BitSet.java (set, clear, hashCode): specify "1" constant
1463 as long.
1464
1465 Mon Aug 9 18:33:38 1999 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
1466
1467 * Makefile: Rebuilt.
1468 * Makefile.am (toolexeclibdir): Add $(MULTISUBDIR) even for native
1469 builds.
1470
1471 * java/net/natPlainSocketImpl.cc: Include <sys/select.h> only if
1472 present.
1473
1474 * configure: Rebuilt.
1475 * configure.in: Properly align --help output, fix capitalization
1476 and punctuation.
1477 * acinclude.m4: Likewise.
1478
1479 1999-08-09 Kresten Krab Thorup <krab@gnu.org>
1480
1481 * include/javaprims.h (_Jv_word, _Jv_word2): New types.
1482
1483 * include/java-interp.h (_Jv_InterpMethodInvocation): Use _Jv_word.
1484 (_Jv_callInterpretedMethod): Unused. Remove.
1485 (_Jv_InterpMethod::run,run_normal,run_synch_object,run_synch_class):
1486 Use ffi_raw.
1487 * include/java-cpool.h (_Jv_get, _Jv_put): Remove.
1488 (_Jv_{store,load}{Indexes,Int,Float,Long,Double}): Use _Jv_word.
1489 * boehm.cc (_Jv_MarkObj): Use _Jv_word.
1490 * interpret.cc: use _Jv_word.
1491 * defineclass.cc: use_Jv_word.
1492 * resolve.cc: Use _Jv_word.
1493 (_Jv_ResolvePoolEntry): Return _Jv_word.
1494 * java/lang/Class.h (_Jv_Constants): Use _Jv_word for cpool.
1495 * java/lang/natClassLoader.cc (_Jv_InternClassStrings): Use _Jv_word.
1496
1497 * interpret.cc (gnu::gcj::runtime::MethodInvocation::continue1):
1498 Change comment.
1499
1500 Mon Aug 9 18:33:38 1999 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
1501
1502 * configure: Rebuilt.
1503 * configure.in (sched_yield): Try librt first, then libposix4.
1504 Add -lrt, -lposix4 to THREADSPEC.
1505
1506 1999-08-08 Anthony Green <green@cygnus.com>
1507
1508 * gnu/gcj/util/path/SearchPath.java: Comment out verbose output.
1509
1510 1999-08-08 Anthony Green <green@cygnus.com>
1511
1512 * defineclass.cc (_Jv_VerifyClassName): Verify array names
1513 correctly.
1514
1515 1999-08-08 Anthony Green <green@cygnus.com>
1516
1517 * gij.cc: New file.
1518
1519 * include/config.h.in: Rebuilt.
1520 * acconfig.h: Add INTERPRETER.
1521
1522 * Makefile.in: Rebuilt.
1523 * Makefile.am (libffi_files): Identify the libffi object files for
1524 inclusion in libgcj.
1525 (LIBFFIINCS): Define.
1526
1527 * interpret.cc (gnu::gcj::runtime::MethodInvocation::continue1):
1528 Dummy definition for configurations without an interpreter.
1529
1530 * java/net/natPlainSocketImpl.cc (getOption): Disamiguate call to
1531 java::lang::Boolean constructor.
1532
1533 * include/java-interp.h: Always include java-cpool.h.
1534
1535 * java/lang/natClassLoader.cc (getVMClassLoader0): Always return 0
1536 when INTERPRETER not defined.
1537
1538 * java/lang/Class.h (finalize): Define.
1539
1540 * gnu/gcj/util/path/DirectoryPathEntry.java (getURL): Catch
1541 IOException from File.getCanonicalPath.
1542 (getStream): Likewise.
1543
1544 * NEWS: More news.
1545 * THANKS: More thanks.
1546
1547 1999-08-08 Kresten Krab Thorup <krab@gnu.org>
1548
1549 * resolve.cc (get_ffi_type_from_signature): Generate uint16 for
1550 jchar type.
1551 (_Jv_PrepareClass): Allow non-abstract classes to
1552 have abstract subclasses.
1553 (_Jv_ResolvePoolEntry): Revert subclass check for protected
1554 fields and methods.
1555 * interpret.cc (continue1/perform_invoke): Don't sign extend
1556 uint16 return val.
1557 (continue1/lshl,lshr): Push long, not int.
1558 (continue1/ulshr): Use UINT64, not long long.
1559 * defineclass.cc (handleFieldsEnd): Handle case when all fields
1560 are static.
1561 * java/lang/natClass.cc (forName): Add call to _Jv_InitClass.
1562 * java/lang/FirstThread.java (run): Add top-level exception
1563 handler.
1564 (run0): Renamed from run.
1565
1566 1999-08-08 Kresten Krab Thorup <krab@gnu.org>
1567
1568 * configure.in (--with-interpreter): Added.
1569 * include/config.h.in (INTERPRETER): Added.
1570
1571 * java/lang/ClassLoader.java: File replaced.
1572 * java/lang/VMClassLoader.java: New file.
1573 * java/lang/natClassLoader.cc: New file.
1574 * gnu/gcj/runtime/MethodInvocation.java: New file.
1575 * gnu/gcj/util/path/SearchPath.java: New file.
1576 * gnu/gcj/util/path/PathEntry.java: New file.
1577 * gnu/gcj/util/path/DirectoryPathEntry.java: New file.
1578 * gnu/gcj/util/path/ZipPathEntry.java: New file.
1579 * gnu/gcj/util/path/URLPathEntry.java: New file.
1580 * gnu/gcj/util/path/CacheEntry.java: New file.
1581 * include/java-interp.h: New file.
1582 * include/java-cpool.h: New file.
1583 * include/java-insns.h: New file.
1584 * defineclass.cc: New file.
1585 * interpret.cc: New file.
1586 * resolve.cc: New file.
1587
1588 * java/lang/natClass.cc (loaded_classes, _Jv_RegisterClass,
1589 _Jv_RegisterClasses, _Jv_FindClassInCache, _Jv_FindClass,
1590 _Jv_NewClass, _Jv_FindArrayClass): Moved to natClassLoader.cc.
1591 (finalize): New.
1592 (STATE_NOTHING, STATE_RESOLVED, STATE_IN_PROGRESS, STATE_DONE,
1593 STATE_ERROR): Moved to java/lang/Class.h and renamed with JV_
1594 prefix.
1595 (initializeClass): Use new JV_ prefixed names. Also, call
1596 ClassLoader::resolveClass instead of _Jv_ResolveClass.
1597
1598 * java/lang/Class.h (JV_STATE_PRELOADING, JV_STATE_LOADING,
1599 JV_STATE_LOADED, JV_STATE_COMPILED, JV_STATE_PREPARED,
1600 JV_STATE_LINKED): New.
1601 (_Jv_WaitForState, _Jv_RegisterInitiatingLoader,
1602 _Jv_UnregisterClass, _Jv_InternClassStrings): New friends.
1603 (_Jv_IsInterpretedClass, _Jv_InitField, _Jv_LookupDeclaredMethod,
1604 _Jv_DetermineVTableIndex, _Jv_ResolvePoolEntry, _Jv_PrepareClass,
1605 _Jv_ClassReader, _Jv_InterpClass, _Jv_InterpMethod,
1606 _Jv_InterpMethodInvocation): New friends for interpreter.
1607 (finalize): New.
1608 (CONSTANT_Class, CONSTANT_String, etc.): Moved to
1609 include/java-cpool.h and renamed with JV_ prefix.
1610
1611 * include/jvm.h (_Jv_makeUtf8Const, _Jv_makeUtf8TypeConst): New
1612 decls.
1613 (_Jv_UnregisterClass): New decl.
1614
1615 * java/lang/natClassLoader.cc (_Jv_FindArrayClass): Added
1616 class loader argument.
1617 (_Jv_FindClass): Use class loader.
1618
1619 * prims.cc (_Jv_makeUtf8Const): New function.
1620 (_Jv_NewObjectArray): Change use of _Jv_FindArrayClass.
1621 (_Jv_NewPrimArray): Ditto.
1622 (_Jv_FindClassFromSignature): Ditto.
1623 * java/lang/reflect/natArray.cc (newInstance): Ditto.
1624 * java/lang/reflect/natMethod.cc (getType): Ditto.
1625
1626 * include/java-field.h (_Jv_Field::isRef): Make robust for
1627 non-resolved contexts.
1628
1629 * boehm.cc (_Jv_MarkObj): Mark interpreter-related fields.
1630 Also, don't mark class->next field.
1631
1632 * java/lang/VirtualMachineError.java: Added FIXME note.
1633
1634 * configure.in (INTERPSPEC): New spec.
1635 * libgcj.spec.in: Added INTERPSPEC.
1636 * Makefile.am: Added gcjh friends for java/lang/VMClassLoader and
1637 gnu/gcj/runtime/MethodInvocation.
1638 (libgcj_la_SOURCES): Added resolve.cc defineclass.cc interpret.cc.
1639 (ordinary_java_source_files): Added above mentioned java classes.
1640
1641 * configure: Rebuilt.
1642 * Makefile.in: Rebuilt.
1643
1644 1999-08-06 Tom Tromey <tromey@cygnus.com>
1645
1646 * configure: Rebuilt.
1647 * configure.in: Look for sched_yield in -lrt.
1648
1649 1999-08-06 Mojo Jojo <mojojojo@pacbell.net>
1650
1651 * java/util/Locale.java, CHINESE, ENGLISH, FRENCH, GERMAN,
1652 ITALIAN, JAPANESE, KOREAN, CANADA_FRENCH, GERMANY, ITALY, KOREA,
1653 SIMPLIFIED_CHINESE, TRADITIONAL_CHINESE, PRC, TAIWAN, CHINA): New
1654 locales.
1655 (toString): Print correctly when `country' is empty.
1656
1657 1999-08-04 Per Bothner <per@bothner.com>
1658
1659 * configure.in: Also do AC_SUBST for DIVIDESPEC.
1660
1661 1999-08-02 Tom Tromey <tromey@cygnus.com>
1662
1663 * aclocal.m4, configure: Rebuilt for new libtool.
1664
1665 1999-08-02 Bryce McKinlay <bryce@albatross.co.nz>
1666
1667 * boehm.cc (_Jv_RegisterFinalizer): Cast `meth' to GC_PTR.
1668 * exception.cc (_Jv_Throw): Cast `_Jv_type_matcher' to __eh_matcher.
1669 * java/net/ServerSocket.java: Define ANY_IF.
1670 (ServerSocket (int,int)): Use ANY_IF instead of null to bind to
1671 all network interfaces.
1672 * java/net/DatagramSocket.java (DatagramSocket): ditto.
1673 * java/net/natPlainSocketImpl.cc (bind): Expect `0.0.0.0' instead of
1674 null.
1675 * java/net/natPlainDatagramSocketImpl (bind): Expect `0.0.0.0'
1676 instead of null.
1677 * java/io/natFile.cc (performMkdir): Remove FIXME.
1678 * java/io/natFileDescriptorPosix.cc (open): Use 0644 file mode.
1679
1680 1999-08-01 Alexandre Oliva <oliva@dcc.unicamp.br>
1681
1682 * configure.in: Check for bstring.h.
1683 * configure, include/config.h.in: Rebuilt.
1684 * java/net/natPlainDatagramSocketImpl.cc: #include bstring.h.
1685 * java/net/natPlainSocketImpl.cc: Likewise.
1686
1687 1999-07-31 Tom Tromey <tromey@cygnus.com>
1688
1689 * NEWS: Likewise.
1690 * THANKS: New file.
1691
1692 1999-07-31 Alexandre Oliva <oliva@dcc.unicamp.br>
1693
1694 * configure.in: Check for struct hostent_data and need for
1695 -D_REENTRANT for gethostbyname_r declaration.
1696 * java/net/natInetAddress.cc: Define _REENTRANT if needed.
1697 (lookup): Use hostent_data for fixed_buffer.
1698 * configure, include/config.h.in: Rebuilt.
1699
1700 1999-07-31 Alexandre Oliva <oliva@dcc.unicamp.br>
1701
1702 * java/lang/natSystem.cc (arraycopy): Use bcopy if memmove is not
1703 available. Don't cast memmove args to (void*).
1704 * configure.in: Do not abort if memmove is not available.
1705
1706 1999-07-22 Bryce McKinlay <bryce@albatross.co.nz>
1707
1708 * java/lang/natString.cc (substring): optimize where substring is
1709 entire String.
1710 * java/io/File.java (getName): don't return separator with file name.
1711 * java/io/natFile.cc (attr): fix overflow.
1712
1713 Sun Jul 25 01:43:34 1999 Anthony Green <green@cygnus.com>
1714
1715 * mauve-libgcj: Disable Object Serialization tests.
1716
1717 1999-07-20 Warren Levy <warrenl@cygnus.com>
1718
1719 * java/net/DatagramSocket.java (DatagramSocket(int, InetAddress)):
1720 Default to using PlainDatagramSocketImpl.
1721 * java/net/PlainDatagramSocketImpl.java (close): Catch IOException.
1722
1723 1999-07-19 Tom Tromey <tromey@cygnus.com>
1724
1725 * include/stamp-h.in: New file.
1726
1727 1999-07-12 Tom Tromey <tromey@cygnus.com>
1728
1729 * java/lang/mprec.h: Protect definition of uint32_t with #ifndef
1730 _UINT32_T.
1731
1732 1999-07-07 Andrew Haley <aph@cygnus.com>
1733
1734 * include/i386-signal.h (MAKE_THROW_FRAME): Advance EIP by two
1735 bytes to make it point after the instruction where the trap
1736 occurred.
1737 (HANDLE_DIVIDE_OVERFLOW): Ditto.
1738
1739 1999-07-07 Tom Tromey <tromey@cygnus.com>
1740
1741 * mauve-libgcj: Explicitly enable formerly disabled java.text
1742 tests.
1743
1744 * mauve-libgcj: Turn off ClassTest test. Enable java.text tests
1745 again.
1746
1747 Mon Jul 5 12:01:35 1999 Anthony Green <green@cygnus.com>
1748
1749 * java/net/URL.java (equals): Compare strings using String.equals.
1750 * java/net/URL.java (sameFile): Ditto.
1751
1752 1999-07-02 Warren Levy <warrenl@cygnus.com>
1753
1754 * configure: Rebuilt.
1755 * configure.in: Added inet_ntoa to AC_CHECK_FUNCS.
1756 * include/config.h.in: Rebuilt.
1757 * java/net/natPlainDatagramSocketImpl.cc: Added header checking.
1758 (mcastGrp): Updated FIXME comments.
1759 (setOption): Fixed typo.
1760 (getOption):Implemented IP_MULTICAST_IF.
1761
1762 1999-07-02 Warren Levy <warrenl@cygnus.com>
1763
1764 * java/net/PlainDatagramSocketImpl.java (ttl): Removed.
1765 * java/net/natPlainDatagramSocketImpl.cc (setTimeToLive): Implemented.
1766 (getTimeToLive): Implemented.
1767 (setOption): Implemented IP_MULTICAST_IF.
1768
1769 1999-07-01 Bryce McKinlay <bryce@albatross.co.nz>
1770
1771 * java/lang/String.java (toString): Check for this == null and throw
1772 NullPointerException.
1773
1774 1999-07-01 Warren Levy <warrenl@cygnus.com>
1775
1776 * gnu/gcj/convert/BytesToUnicode.java (read): Changed outlength
1777 to count and revised comments to match.
1778 * gnu/gcj/convert/Input_EUCJIS.java (read): Same as Input_8859_1.java.
1779 * gnu/gcj/convert/Input_JavaSrc.java (read): ditto.
1780 * gnu/gcj/convert/Input_SJIS.java (read): ditto.
1781 * gnu/gcj/convert/Input_UTF8.java (read): ditto.
1782 * gnu/gcj/convert/natInput_EUCJIS.cc (read): ditto.
1783 * gnu/gcj/convert/natInput_SJIS.cc (read): ditto.
1784
1785 1999-07-01 John-Marc Chandonia <jmc@cmpharm.ucsf.edu>
1786
1787 * gnu/gcj/convert/Input_8859_1.java (read): Use 3rd parameter
1788 properly as count rather than outlength.
1789 * java/io/BufferedOutputStream.java (write(byte[],int,int): Flush
1790 output on overflow rather than buffer fill.
1791 * java/io/BufferedReader.java (fill): Don't clear out the buffer
1792 if markPos is 0 and there is still room in the buffer.
1793
1794 1999-07-01 Andrew Haley <aph@cygnus.com>
1795
1796 * include/i386-signal.h: Replace sigaction () with __sigaction ().
1797 This is a workaround for a bug in glibc's pthreads package which
1798 doesn't deliver any sigcontext information to a signal handler.
1799
1800 1999-06-24 Tom Tromey <tromey@cygnus.com>
1801
1802 * java/lang/e_asin.c: Don't use __int32_t or __uint32_t.
1803 * java/lang/fdlibm.h (HUGE): Conditionally define.
1804
1805 Fri May 28 22:20:03 1999 Anthony Green <green@cygnus.com>
1806
1807 * java/lang/fdlibm.h: Don't use __uint32_t. Include mprec.h.
1808 * java/lang/e_log.c: Don't use __uint32_t.
1809
1810 1999-05-27 Eric Christopher <echristo@cygnus.com>
1811
1812 * configure: Rebuilt
1813 * configure.in: Fixed ISO C9X and namespace collision with __uint32_t
1814 * acconfig.h: Rebuilt
1815 * include/config.h.in: Rebuilt
1816
1817 * java/lang/mprec.h, java/lang/e_acos.c, java/lang/e_asin.c,
1818 java/lang/e_atan2.c, java/lang/e_exp.c, java/lang/e_fmod.c,
1819 e_log.c, java/lang/e_pow.c, java/lang/e_rem_pio2.c,
1820 java/lang/e_remainder.c, java/lang/e_sqrt.c, java/lang/fdlibm.h,
1821 k_tan.c, java/lang/mprec.h, java/lang/s_atan.c,
1822 java/lang/s_ceil.c, java/lang/s_copysign.c, java/lang/s_fabs.c,
1823 s_floor.c, java/lang/s_rint.c, java/lang/sf_rint.c: Fixed ISO C9X
1824 and namespace collision with __uint32_t
1825
1826 1999-06-23 Tom Tromey <tromey@cygnus.com>
1827
1828 * java/util/zip/InflaterInputStream.java (read): Throw
1829 ZipException if inflater throws a DataFormatException.
1830
1831 1999-06-23 Warren Levy <warrenl@cygnus.com>
1832
1833 * java/net/DatagramSocketImpl.java (localPort): Fixed typo to match JDK.
1834 * java/net/natPlainDatagramSocketImpl.cc (bind): ditto.
1835 * java/text/ChoiceFormat.java (nextDouble(double, boolean)): Method
1836 is not final per JDK.
1837 * java/util/PropertyResourceBundle.java (handleGetObject): Method is
1838 public per JDK.
1839 * java/util/zip/DataFormatException.java: Class extends Exception.
1840 * java/util/zip/Deflater.java (finalize): Method is protected per JDK.
1841 * java/util/zip/ZipEntry.java: Class implements ZipConstants.
1842 * java/util/zip/ZipInputStream.java: ditto.
1843 (closeEntry): Changed method name to match JDK spec.
1844
1845 1999-06-21 Tom Tromey <tromey@cygnus.com>
1846
1847 * java/lang/ieeefp.h (__IEEE_LITTLE_ENDIAN): Define for alpha.
1848 From Jeff Sturm.
1849
1850 * Makefile.in: Rebuilt.
1851 * Makefile.am (toolexeclibdir): Define as libdir when
1852 appropriate.
1853 * configure: Rebuilt.
1854 * configure.in (USE_LIBDIR): New conditional.
1855
1856 1999-06-18 Bryce McKinlay <bryce@albatross.co.nz>
1857
1858 * java/net/natInetAddress.cc (lookup): Preserve caller-supplied
1859 hostname in returned InetAddress objects.
1860 (getLocalHostname): Fix typo.
1861 * java/net/InetAddress.java (getByName): Set hostname on return
1862 object.
1863 (getLocalHost): Call lookup directly to ensure that a fully-qualified
1864 name is returned.
1865
1866 1999-06-17 Bryce McKinlay <bryce@albatross.co.nz>
1867
1868 * java/net/natPlainSocketImpl.cc (bind): Bind to any/all network
1869 interfaces if host==NULL.
1870 (accept): Throw message with InterruptedIOException.
1871 (getOption): Cache localAddress.
1872 * java/net/natPlainDatagramSocketImpl.cc (bind): Don't need
1873 'address' for DatagramSocket.
1874 (setTimeToLive): Fix compiler warnings.
1875 (getOption): Cache localAddress.
1876 * java/net/Socket.java (getLocalAddress): Don't need local
1877 InetAddress object. Add FIXME comment about calling checkConnect().
1878 * java/net/ServerSocket.java (ServerSocket(int)): Initialize
1879 connection queue to 50 as per JDK 1.2 docs.
1880 (ServerSocket(int,int)): Listen on all network interfaces by
1881 default, per JDK 1.2 docs.
1882 * java/net/PlainDatagramSocketImpl.java: Don't need 'address'.
1883 Add localAddress caching.
1884
1885 1999-06-15 Bryce McKinlay <bryce@albatross.co.nz>
1886
1887 * java/io/FilterOutputStream.java (write(byte[])): Rewrite according
1888 to JDK 1.2 docs.
1889 (write(byte[],int,int)): ditto.
1890
1891 1999-06-14 Bryce McKinlay <bryce@albatross.co.nz>
1892
1893 * posix-threads.cc (_Jv_CondWait): Fix currentTimeMillis() overflow.
1894
1895 1999-06-11 Warren Levy <warrenl@cygnus.com>
1896
1897 * mauve-libgcj: Activated java.net Mauve tests.
1898
1899 1999-06-10 Bryce McKinlay <bryce@albatross.co.nz>
1900
1901 * java/net/natInetAddress.cc (aton): Fix typos.
1902 (lookup): Use a bigger buffer size for gethostbyname_r on all
1903 versions of glibc. Updated FIXME comment explaining this.
1904 Modified while loops to not set herr = ERANGE to work around glibc
1905 problems. Use user specified hostname in InetAddress result when
1906 available (consistent with JDK).
1907
1908 1999-06-10 Warren Levy <warrenl@cygnus.com>
1909
1910 * java/io/FileDescriptor.java (FileDescriptor(String, int)):
1911 Throw FileNotFoundException instead of IOException.
1912 (open): ditto.
1913 * java/io/FileInputStream.java (FileInputStream): Doesn't throw
1914 IOException.
1915 * java/text/Collator.java (CANONICAL_DECOMPOSITION): Fixed typo
1916 in static field name.
1917 * java/text/DecimalFormat.java: Throw IllegalArgumentException
1918 throughout rather than ParseException.
1919
1920 1999-06-09 Bryce McKinlay <bryce@albatross.co.nz>
1921
1922 * java/lang/Runtime.java (exec): Convert prog name and arguments
1923 to string array.
1924 * java/lang/natPosixProcess.cc (startProcess): Fix typo in
1925 environment array conversion. Preserve current environment if envp
1926 not passed. Preserve PATH unless explicitly specified.
1927 * java/io/DataInputStream.java (readLine): Fix case where '\r' is
1928 followed by EOF. Set a flag when a line is terminated by '\r' and
1929 ignore following '\n' if set.
1930
1931 1999-06-02 Warren Levy <warrenl@cygnus.com>
1932
1933 * java/net/URL.java (URL(URL,String)): Initialize port to -1.
1934 Ignore context if spec is an absolute URL. Fix braindead
1935 string comparison.
1936 (hashCode): Use JDK 1.2 style algorithm.
1937 * java/net/URLStreamHandler.java (parseURL): Reimplement to handle
1938 context URL properly.
1939
1940 1999-05-30 Anthony Green <green@cygnus.com>
1941
1942 * java/net/URLStreamHandler.java (parseURL): Parse relative URLs
1943 correctly. Clean up "/../" an\e[Bd "/./" path fragments.
1944
1945 1999-05-28 Warren Levy <warrenl@cygnus.com>
1946
1947 * java/net/DatagramSocket.java (laddr): Removed.
1948 (DatagramSocket): Removed attempts to get or set laddr if null.
1949 (getLocalAddress): Reimplemented per spec.
1950 * java/net/MulticastSocket.java (setTimeToLive): Throw exception
1951 when ttl is 0.
1952 (joinGroup): Throw NullPointerException if any argument is null.
1953 (leaveGroup): ditto.
1954 * java/net/PlainDatagramSocketImpl.java: Updated comments.
1955 * java/net/PlainSocketImpl.java (timeout): Added.
1956 (getInputStream): Added FIXME comment on how to support timeouts
1957 for TCP.
1958 * java/net/ServerSocket.java (ServerSocket): Added FIXME comment.
1959 * java/net/Socket.java: Added FIXME comments to identify
1960 conflicting specs between the JCL and JDK 1.2 documents.
1961 * java/net/natPlainDatagramSocketImpl.cc (bind): Use INADDR_ANY
1962 if host is null. Get localport value resolved by kernel if bind
1963 lport is 0.
1964 (receive): Implemented support for timeouts in UDP.
1965 (setOption): Implemented based on natPlainSocketImpl version.
1966 (getOption): ditto.
1967 * java/net/natPlainSocketImpl.cc (bind): Get localport value
1968 resolved by kernel if bind lport is 0.
1969 (connect): Get localport value resolved by kernel if bind wasn't
1970 done to set localport.
1971 (accept): Implemented support for timeouts for ServerSocket.
1972 (setOption): Save value for SO_TIMEOUT.
1973 (getOption): Return timeout for SO_TIMEOUT.
1974
1975 1999-05-26 Bryce McKinlay <bryce@albatross.co.nz>
1976
1977 * java/net/DatagramSocket.java (getSoTimeout): Verify class type.
1978 * java/net/DatagramSocketImpl.java (getOption): Made abstract.
1979 (setOption): Made abstract.
1980 * java/net/PlainDatagramSocketImpl.java: Mirror SocketOptions fields
1981 to avoid cpp conflicts in native code.
1982 * java/net/PlainSocketImpl.java: Mirror SocketOptions fields to avoid
1983 cpp conflicts in native code.
1984 * java/net/ServerSocket.java (toString): Prepended "ServerSocket".
1985 * java/net/Socket.java (getLocalAddress): Implemented.
1986 (setTcpNoDelay): Implemented.
1987 (getTcpNoDelay): Implemented.
1988 (setSoLinger): Implemented.
1989 (getSoLinger): Implemented.
1990 (getSoTimeout): Verify class type.
1991 (setSendBufferSize): Implemented.
1992 (getSendBufferSize): Implemented.
1993 (setReceiveBufferSize): Implemented.
1994 (getReceiveBufferSize): Implemented.
1995 (toString): Prepended "Socket".
1996 * java/net/SocketImpl.java (toString): Rewritten.
1997 (getOption): Made abstract.
1998 (setOption): Made abstract.
1999 * java/net/natPlainSocketImpl.cc (connect): Set localport properly.
2000 (setOption): Implemented.
2001 (getOption): Implemented.
2002
2003 1999-05-26 Warren Levy <warrenl@cygnus.com>
2004
2005 * java/net/DatagramSocket.java (DatagramSocket): Get local host
2006 address when null. Set SO_REUSEADDR for multicasts.
2007 (getSoTimeout): Implemented.
2008 (setSoTimeout): Implemented.
2009 * java/net/DatagramSocketImpl.java: Implement SocketOptions interface.
2010 * java/net/MulticastSocket.java (getInterface): Implemented.
2011 (setInterface): Implemented.
2012 (setTimeToLive): Check for invalid ttl.
2013 (joinGroup): Verify multicast address and security.
2014 (leaveGroup): Verify multicast address and security.
2015 (send): Implemented.
2016 * java/net/PlainDatagramSocketImpl.java (timeout): Added.
2017 (iface): Added.
2018 (ttl): Added.
2019 (setOption): Added.
2020 (getOption): Added.
2021 (mcastGrp): Added.
2022 (getTTL): Implemented as non-native.
2023 (setTTL): ditto.
2024 (join): ditto.
2025 (leave): ditto.
2026 * java/net/ServerSocket.java (setSoTimeout): Implemented.
2027 (getSoTimeout): Implemented.
2028 (setSocketFactory): Made synchronized.
2029 * java/net/Socket.java (setSoTimeout): Implemented.
2030 (getSoTimeout): Implemented.
2031 (close): Made synchronized.
2032 (setSocketImplFactory): Made synchronized.
2033 * java/net/SocketImpl.java: Implement SocketOptions interface.
2034 * java/net/natInetAddress.cc: Corrected module name at top of file.
2035 * java/net/natPlainDatagramSocketImpl.cc (McastReq): Added union.
2036 (bind): Added FIXME.
2037 (peek): Implemented.
2038 (setTTL): Removed.
2039 (getTTL): Removed.
2040 (join): Removed.
2041 (leave): Removed.
2042 (mcastGrp): Added.
2043 (setOption): Implemented for SO_REUSEADDR.
2044 (getOption): Implemented for SO_REUSEADDR.
2045
2046 1999-05-24 Tom Tromey <tromey@cygnus.com>
2047
2048 * java/util/ResourceBundle.java (getBundle): Throw
2049 NullPointerException if baseName is null.
2050
2051 1999-05-22 Tom Tromey <tromey@cygnus.com>
2052
2053 * java/util/zip/ZipInputStream.java (fill): New method.
2054 (compressed_len): New instance variable.
2055 (getNextStream): Set it.
2056 (read): Reset inflater on EOF. Only read via `super' if entry is
2057 deflated.
2058 (skip): Only skip via `super' if entry is deflated.
2059 * java/util/zip/Deflater.java (last_input_count): Removed.
2060 * java/util/zip/natDeflater.cc (deflate): Return 0 if input array
2061 is length 0.
2062 (needsInput): Don't use last_input_count.
2063 (setInput): Don't set last_input_count.
2064 * java/util/zip/natInflater.cc (getRemaining): Return correct
2065 result.
2066 (inflate): Return 0 if input array is length 0.
2067 (setInput): Don't set last_input_count.
2068 * java/util/zip/Inflater.java (last_input_count): Removed.
2069
2070 1999-05-21 Tom Tromey <tromey@cygnus.com>
2071
2072 * Makefile.in: Rebuilt.
2073 * Makefile.am (INCLUDES): Added $(ZINCS).
2074 * configure: Rebuilt.
2075 * configure.in (ZINCS): New subst.
2076
2077 1999-05-21 Andrew Haley <aph@cygnus.com>
2078
2079 * include/sparc-signal.h (INIT_FPE, INIT_SEGV): SA_NODEFER added
2080 to signal options to allow the same exceptions to be rethrown
2081 later.
2082
2083 1999-05-20 Andrew Haley <aph@cygnus.com>
2084
2085 * libjava/prims.cc (catch_fpe): Call to HANDLE_DIVIDE_OVERFLOW
2086 added.
2087 * include/i386-signal.h (HANDLE_DIVIDE_OVERFLOW): New macro.
2088 (INIT_FPE): Exception string made more informative.
2089 * include/sparc-signal.h (INIT_FPE): Exception string made more
2090 informative.
2091 * testsuite/libjava.lang/Divide_1.java: New file.
2092 * testsuite/libjava.lang/Divide_1.out: New file.
2093
2094 1999-05-19 Tom Tromey <tromey@cygnus.com>
2095
2096 * aclocal.m4, configure: Rebuilt.
2097 * acinclude.m4 (version): New variable; pass to AM_INIT_AUTOMAKE.
2098
2099 * java/util/zip/GZIPOutputStream.java (write(byte[])): New
2100 method.
2101
2102 * java/util/zip/natInflater.cc (inflate): Cast `len' to unsigned.
2103 Include <stdlib.h>.
2104 * java/util/zip/natDeflater.cc (deflate): Cast `len' to unsigned.
2105 Include <stdlib.h>.
2106 (update): Fail in default case. Always initialize `strat'.
2107
2108 * mauve-libgcj: Enable java.util.zip.
2109
2110 1999-05-18 Warren Levy <warrenl@cygnus.com>
2111
2112 * Makefile.am (ordinary_java_source_files): Added DatagramPacket.java,
2113 DatagramSocket.java, DatagramSocketImpl.java, MulticastSocket.java,
2114 PlainDatagramSocketImpl.java, and SocketOptions.java.
2115 (nat_source_files): Added natPlainDatagramSocketImpl.cc.
2116 * Makefile.in: Rebuilt.
2117
2118 * java/net/DatagramPacket.java: New file.
2119 * java/net/DatagramSocket.java: New file.
2120 * java/net/DatagramSocketImpl.java: New file.
2121 * java/net/MulticastSocket.java: New file.
2122 * java/net/PlainDatagramSocketImpl.java: New file.
2123 * java/net/SocketOptions.java: New file.
2124 * java/net/natPlainDatagramSocketImpl.cc: New file.
2125
2126 1999-05-18 Tom Tromey <tromey@cygnus.com>
2127
2128 * java/util/zip/ZipOutputStream.java (level): Initial value is
2129 Deflater.DEFAULT_COMPRESSION.
2130 (close): New method.
2131 (closeEntry): Likewise.
2132 (finish): Likewise.
2133 (put_version): Likewise.
2134 (write_entry): Likewise.
2135 (put2, put4): Now return `int'.
2136 (comment): Default to empty string.
2137 (bytes_written): New instance variable.
2138 (chain): Likewise.
2139 * java/util/zip/ZipEntry.java (setComment): Limit length of
2140 comment string.
2141 (setCrc): Check CRC validity.
2142 (setExtra): Check argument validity.
2143 (setMethod): Likewise.
2144 (setSize): Likewise.
2145 (ZipEntry): Likewise.
2146 * include/javaprims.h: Updated namespace declarations.
2147 * Makefile.in: Rebuilt.
2148 * Makefile.am (ordinary_java_source_files): Mention new files.
2149 (nat_source_files): Likewise.
2150 * java/util/zip/ZipFile.java (readu2): Throw ZipException, not
2151 EOFException.
2152 (read4): Likewise.
2153 (getInputStream): Handle compressed entries.
2154 * java/util/zip/GZIPOutputStream.java: New file.
2155 * java/util/zip/GZIPInputStream.java: New file.
2156 * java/util/zip/DataFormatException.java: New file.
2157 * java/util/zip/CheckedInputStream.java: New file.
2158 * java/util/zip/CheckedOutputStream.java: New file.
2159 * java/util/zip/InflaterInputStream.java: Implemented.
2160 * java/util/zip/natInflater.cc: New file.
2161 * java/util/zip/Deflater.java: Implemented.
2162 * java/util/zip/natDeflater.cc: New file.
2163 * java/util/zip/DeflaterOutputStream.java: Implemented.
2164
2165 * java/util/zip/ZipInputStream.java (closeZipEntry): Throw
2166 ZipException, not IOException.
2167 * java/util/zip/ZipFile.java (readDirectory): Throw ZipException,
2168 not IOException.
2169
2170 1999-05-17 Tom Tromey <tromey@cygnus.com>
2171
2172 * java/lang/natSystem.cc (init_properties): URL now points to
2173 sourceware.
2174
2175 1999-05-12 Per Bothner <bothner@cygnus.com>
2176
2177 * java/util/Calendar.java (set): First call computeFields if needed.
2178 * java/util/natGregorianCalendar.cc (computeTime): Cast 1000 to jlong.
2179
2180 1999-05-12 Tom Tromey <tromey@cygnus.com>
2181
2182 * configure: Rebuilt.
2183 * configure.in: Look for -ldl when using the Boehm collector.
2184 Look for sched_yield in -lposix4.
2185
2186 1999-05-12 Per Bothner <bothner@cygnus.com>
2187
2188 * java/io/File.java (mkdirs): Handle a null parent directory.
2189
2190 1999-05-12 Tom Tromey <tromey@cygnus.com>
2191
2192 * include/javaprims.h: Updated namespace declarations.
2193 * classes.pl (scan): Uniquify class list.
2194 * Makefile.in, configure: Rebuilt.
2195 * Makefile.am (nat_source_files): Added natConcreteProcess.cc.
2196 (built_java_source_files): New macro.
2197 (nat_headers): Added built_java_source_files.
2198 (javao_files): Likewise.
2199 (EXTRA_libgcj_la_SOURCES): Likewise.
2200 (libgcj.zip): Create built class files.
2201 ($(built_java_source_files:.java=.class)): New target.
2202 (jv_convert_LDADD): Added -L$(here)/.libs.
2203 * configure.in: Create links for ConcreteProcess.java and
2204 natConcreteProcess.cc.
2205 * java/lang/Runtime.java (exec): Create a ConcreteProcess.
2206 * java/lang/natEcosProcess.cc: New file.
2207 * java/lang/EcosProcess.java: New file.
2208 * java/lang/PosixProcess.java: New file.
2209 * java/lang/natPosixProcess.cc: New file.
2210
2211 1999-05-12 Warren Levy <warrenl@cygnus.com>
2212
2213 * java/net/PlainSocketImpl.java: Corrected copyright & header comments.
2214 * java/net/SocketImpl.java: Added marker for JDK 1.2 work.
2215 * java/net/natPlainSocketImpl.cc (bind): Throw BindException.
2216 (connect): Throw ConnectException.
2217
2218 1999-05-11 Tom Tromey <tromey@cygnus.com>
2219
2220 * Makefile.in: Rebuilt.
2221 * Makefile.am (jv_convert_DEPENDENCIES): Include libgcj.spec.
2222 * libgcj.spec.in: Don't use `+'. Instead, put old lib spec after
2223 our libraries.
2224
2225 * Makefile.in: Rebuilt.
2226 * Makefile.am (jv_convert_LDADD): Removed `-L.'; it is not needed
2227 and it causes problems with libtool.
2228
2229 * Makefile.in, configure: Rebuilt.
2230 * Makefile.am (jv_convert_LDFLAGS): Removed -nodefaultlibs.
2231 (jv_convert_LDADD): Added ZLIBS. Removed -lm, -lc, -lgcc.
2232 (jv_convert_DEPENDENCIES): Added ZDEPS.
2233 * configure.in (GCSPEC): Added `-L' to point to boehm-gc build
2234 directory.
2235 (THREADSPEC): Added `-L' to point to qthreads build directory.
2236 (ZLIBS): New subst.
2237 (ZDEPS): New subst.
2238
2239 * configure, Makefile.in: Rebuilt.
2240 * Makefile.am (toolexeclib_DATA): New macro.
2241 * configure.in: Create libgcj.spec. Look for -lsocket and -lnsl.
2242 Recognize --with-system-zlib.
2243 (GCSPEC): New subst.
2244 (THREADSPEC): New subst.
2245 (SYSTEMSPEC): New subst.
2246 (ZLIBSPEC): New subst.
2247 * libgcj.spec.in: New file.
2248
2249 1999-05-10 Tom Tromey <tromey@cygnus.com>
2250
2251 * java/io/InputStreamReader.java (read): If length is 0, return
2252 0. Reset `wpos' and `wcount' when buffer has been filled and
2253 emptied.
2254
2255 * java/util/Properties.java (save): Removed `FIXME' comment.
2256 (load): Invalid characters in \u now treated as terminators.
2257 Make sure to append character resulting from `\' handling.
2258 Cast to `char' when appending to key or value.
2259 (skip_ws): Inverted test for whitespace.
2260
2261 * java/io/RandomAccessFile.java (RandomAccessFile): Removed
2262 `FIXME' comment.
2263 (readLine): Likewise.
2264 (readFully): Implemented.
2265
2266 * java/lang/natObject.cc (sync_init): Use _Jv_AllocBytesChecked.
2267
2268 * java/awt/natToolkit.cc: Added copyright header.
2269 * java/util/zip/InflaterInputStream.java: Added copyright header.
2270
2271 * java/io/FilterWriter.java (FilterWriter): Removed `FIXME'
2272 comment.
2273 * java/io/SequenceInputStream.java (SequenceInputStream): Removed
2274 `FIXME' comment.
2275 (getNextStream): Likewise.
2276
2277 * java/util/ResourceBundle.java (partialGetBundle): Explicitly use
2278 locale.toString().
2279 (getBundle): Don't explicitly throw null pointer exception.
2280
2281 * gnu/gcj/RawData.java: Added copyright header.
2282
2283 * include/jni.h (_Jv_va_list): Always define as va_list.
2284
2285 1999-05-9 Anthony Green <green@cygnus.com>
2286
2287 * java/text/DateFormat.java (computeInstance): Separate time
2288 and date styles.
2289 (getDateTimeInstance): Ditto.
2290 (getDateTimeInstance(int,int)): New method.
2291
2292 * Makefile.in: Rebuilt.
2293 * Makefile.am (ordinary_java_source_files): Add new classes.
2294
2295 * java/util/PropertyResourceBundle.java: New file.
2296 * gnu/gcj/util/EnumerationChain.java: New file.
2297
2298 1999-05-07 Tom Tromey <tromey@cygnus.com>
2299
2300 * acconfig.h (GCJVERSION): New undef.
2301 * java/lang/natSystem.cc (init_properties): Define java.version,
2302 java.class.version, os.name, os.arch, os.version.
2303 Include <sys/utsname.h> if required.
2304 * configure: Rebuilt.
2305 * configure.in: Compute and define GCJVERSION.
2306
2307 * java/lang/natSystem.cc (default_file_encoding): Now static.
2308
2309 * java/lang/natCharacter.cc (isLowerCase): Use a binary search.
2310
2311 * libtool-version: New file.
2312 * Makefile.in: Rebuilt.
2313 * Makefile.am (libgcj_la_LDFLAGS): Use -version-info, not
2314 -release.
2315
2316 * mauve-libgcj: Don't omit Utf8Encoding or StringTest.
2317 Comment out FieldPosition, ParsePosition, and SimpleDateFormat
2318 again (oops).
2319
2320 * mauve-libgcj: Test more from java.text. Don't mention 1.1 tests
2321 (we pick those up already).
2322
2323 1999-05-05 Per Bothner <bothner@cygnus.com>
2324
2325 * java/awt/*: Check a bunch of classes, a few complete, but mostly
2326 stub classes. (This is enough to get Kawa to compile against libgcj.)
2327
2328 * gnu/gcj/RawData.java: New class.
2329 * doc/cni.sgml: Document RawData.
2330
2331 * java/util/zip/InflaterInputStream.java: New stub class.
2332 * java/util/zip/ZipInputStream.java: New class. Partly works.
2333 * java/util/zip/ZipConstants.java: Add two (internal) constants.
2334 * java/util/zip/ZipEntry.java (timeFromDOS): New static method.
2335 * java/util/zip/ZipFile.java: Now mostly works (unless compressed).
2336 * java/util/zip/ZipOutputStream.java: Start implementation.
2337
2338 * java/lang/natSystem.cc (DEFAULT_FILE_ENCODING): New macro.
2339 (default_file_encoding): New global, initial value is above macro.
2340 (init_properties): Default file.encoding to default_file_encoding.
2341
2342 * Makefile.am: Add new classes.
2343
2344 1999-05-05 Tom Tromey <tromey@cygnus.com>
2345
2346 * Makefile.in: Rebuilt.
2347 * Makefile.am (CLEANFILES): Don't mention $(class_files).
2348 (clean-local): New target
2349
2350 * java/lang/natRuntime.cc: Include <ltdl.h> if required.
2351 (load, loadLibrary): Now native.
2352 (init): New method.
2353 * java/lang/Runtime.java (load, loadLibrary): Now native.
2354 (init): New native method.
2355 (Runtime): Use init.
2356 * prims.cc: Include <ltdl.h> if required.
2357 (JvRunMain): Call LTDL_SET_PRELOADED_SYMBOLS.
2358
2359 1999-05-05 Gilles Zunino <Gilles.Zunino@hei.fr>
2360
2361 * configure.in: Switch from irix threads to posix threads
2362 * configure: Regenerate.
2363
2364 1999-04-30 Tom Tromey <tromey@cygnus.com>
2365
2366 * Makefile.in: Rebuilt.
2367 * Makefile.am (jv_convert_LDADD): Added -lgcc.
2368
2369 1999-04-29 Tom Tromey <tromey@cygnus.com>
2370
2371 * java/lang/StringBuffer.java (ensureCapacity): Don't resize
2372 vector when shared.
2373
2374 * java/util/Locale.java (Locale(String,String)): Implement in
2375 terms of 3-argument version; variant now defaults to empty
2376 string.
2377 (toString): Assume variant is not null.
2378 (equals): Assume all strings are not null.
2379 (Locale): Throw NullPointerException if any argument is null.
2380
2381 * java/util/ResourceBundle.java (getBundle): Don't try the base
2382 name; now implicit in partialGetBundle call.
2383 (trySomeGetBundle): Search for parent bundles and call setParent
2384 as required.
2385 (partialGetBundle): Added `langStop' argument. Use
2386 `Locale.toString' to compute bundleName.
2387 (resource_cache): New static field.
2388 (partialGetBundle): Cache the returned resource bundle. Now
2389 synchronized.
2390
2391 * gnu/gcj/text/LocaleData_en.java (contents): [collatorRule] Added
2392 missing `<'.
2393
2394 * mauve-libgcj: Enable Collator and RuleBasedCollator.
2395 * java/text/natCollator.cc (decomposeCharacter): `base' now
2396 `const'.
2397 * Makefile.in: Rebuilt.
2398 * Makefile.am (ordinary_java_source_files): Added
2399 CollationElementIterator, CollationKey, Collator,
2400 RuleBasedCollator.
2401 (nat_source_files): Added natCollator.cc.
2402 * java/text/RuleBasedCollator.java (ceiNext): No longer static.
2403 (compare): Pass `this' to CollationElementIterator constructor.
2404 (getCollationElementIterator): Likewise.
2405 (ceiNext): Fix off-by-one error when finding initial substring.
2406 (next): Correctly mask off bits when computing return value.
2407 Fixed return values when one string is shorter than the other.
2408 * java/text/CollationElementIterator.java (collator): New field.
2409 (CollationElementIterator): Added collator argument.
2410 (next): Call ceiNext on collator object.
2411
2412 1999-04-26 Tom Tromey <tromey@cygnus.com>
2413
2414 * natCollator.cc: New file.
2415
2416 * java/util/GregorianCalendar.java (setDefaultTime): New method.
2417 (GregorianCalendar): Use it in all constructors.
2418 * java/util/Calendar.java (Calendar): Changed argument name to
2419 `zone' to match code.
2420
2421 * gnu/gcj/text/LocaleData_en.java: Added collatorRule element.
2422 * java/text/CollationKey.java: New file.
2423 * java/text/CollationElementIterator.java: New file.
2424 * java/text/Collator.java: New file.
2425 * java/text/RuleBasedCollator.java: New file.
2426
2427 * Makefile.in: Rebuilt.
2428 * Makefile.am (jv_convert_LDFLAGS): Added -nodefaultlibs.
2429 (jv_convert_LDADD): Explicltly add -lm -lc.
2430
2431 1999-04-26 Tom Tromey <tromey@cygnus.com>
2432
2433 * configure, Makefile.in: Rebuilt.
2434 * configure.in: Added AM_PROG_LIBTOOL.
2435 (GCOBJS): Use `.lo' form of files.
2436 (THREADOBJS): Likewise.
2437 (GCDEPS): Use `.la' form of library.
2438 (GCLIBS): Set to be the same as GCDEPS.
2439 (THREADDEPS): Use `.la' form of library.
2440 (THREADLIBS): Set to be the same as THREADDEPS.
2441 * Makefile.am (toolexeclib_LTLIBRARIES): Renamed from
2442 toolexeclib_LIBRARIES.
2443 (libgcj_la_SOURCES): Renamed for libtoolization.
2444 (EXTRA_libgcj_la_SOURCES): Likewise.
2445 (libgcj_la_DEPENDENCIES): Likewise.
2446 (libgcj_la_LIBADD): Likewise.
2447 ($(nat_files)): Use LTCXXCOMPILE.
2448 ($(c_files)): Use LTCOMPILE.
2449 (GCJCOMPILE): New macro.
2450 (.class.o): Use it.
2451 (.java.o): Likewise.
2452 ($(javao_files)): Likewise.
2453 (jv_convert_LINK): Use LIBTOOL.
2454 (nat_files): Use `.lo' files.
2455 (c_files): Likewise.
2456 (javao_files): Likewise.
2457 (.class.lo): Renamed.
2458 (.java.lo): Likewise.
2459 ($(nat_files)): Depend on %.lo.
2460 ($(c_files)): Likewise.
2461 ($(javao_files)): Likewise.
2462 (jv_convert_LDADD): Link against .lo files.
2463 (jv_convert_DEPENDENCIES): Depend on .lo files.
2464 (maintainer-check): Depend on libgcj.la, but examine .a file.
2465 (jv_convert_DEPENDENCIES): Depend on libgcj.la.
2466 (libgcj_la_LDFLAGS): New macro.
2467
2468 1999-04-23 Warren Levy <warrenl@cygnus.com>
2469
2470 * Makefile.am: Added URLDecoder and URLEncoder.
2471 * Makefile.in: Rebuilt.
2472
2473 * java/net/ServerSocket.java (setSocketFactory): Renamed from
2474 setSocketImplFactory to match spec.
2475 * java/net/Socket.java (getSoLinger): Changed return type to
2476 match spec.
2477
2478 * java/net/URLDecoder.java: New file.
2479 * java/net/URLEncoder.java: New file.
2480
2481 1999-04-21 Tom Tromey <tromey@cygnus.com>
2482
2483 * java/lang/natString.cc (getBytes): Reverted earlier change and
2484 applied correct fix from Per Bothner.
2485
2486 * java/lang/String.java: Don't throw
2487 UnsupportedEncodingException.
2488
2489 * java/lang/natString.cc (getBytes): Correctly size result
2490 buffer. From Bryce McKinlay <bryce@albatross.co.nz>.
2491
2492 1999-04-20 Andrew Haley <aph@cygnus.com>
2493
2494 * include/sparc-signal.h: new file.
2495 * configure.in: include/sparc-signal.h added.
2496 * configure: regenerated.
2497 * prims.cc (JvRunMain): signal handling code rewritten to be more
2498 portable.
2499 (catch_segv): ditto.
2500 (catch_fpe): ditto.
2501 * include/i386-signal.h: reorganized.
2502 * include/default-signal.h: reorganized.
2503
2504 1999-04-19 Tom Tromey <tromey@cygnus.com>
2505
2506 * java/lang/natSystem.cc (init_properties): Only declare pwd_entry
2507 once. From Anthony Green.
2508
2509 1999-04-19 Andrew Haley <aph@cygnus.com>
2510
2511 * Makefile.in: Processed with new automake.
2512
2513 1999-04-19 Tom Tromey <tromey@cygnus.com>
2514
2515 * include/javaprims.h: Removed security namespace.
2516
2517 1999-04-20 Anthony Green <green@cygnus.com>
2518
2519 * java/io/PrintStream.java (println): Remove extra println.
2520
2521 1999-04-19 Anthony Green <green@cygnus.com>
2522
2523 * Makefile.in: Rebuilt.
2524 * Makefile.am (ordinary_java_source_files): Add new security files.
2525
2526 * java/security/NoSuchAlgorithmException.java,
2527 java/security/MessageDigest.java: New files.
2528
2529 * include/javaprims.h: Add security namespace.
2530
2531 1999-04-16 Per Bothner <bothner@cygnus.com>
2532
2533 * gnu/gcj/convert/JIS0201.h: New file, generated from Unicode table.
2534 * gnu/gcj/convert/Input_JavaSrc.java: New BytesToUnicode class.
2535 * gnu/gcj/convert/Input_SJIS.java: New BytesToUnicode class.
2536 * gnu/gcj/convert/Output_EUCJIS.java: New UnicodeToBytes class.
2537 * gnu/gcj/convert/Output_SJIS.java: New UnicodeToBytes class.
2538 * gnu/gcj/convert/natInput_EUCJIS.cc: New file.
2539 * gnu/gcj/convert/natInput_SJIS.cc: New file.
2540 * gnu/gcj/convert/natOutput_EUCJIS.cc: New file.
2541 * gnu/gcj/convert/natOutput_SJIS.cc: New file.
2542 * gnu/gcj/convert/make-trie.c: New file: functions to make a trie.
2543 * gnu/gcj/convert/gen-from-JIS.c: Invoke make-trie for output.
2544 * gnu/gcj/convert/Unicode_to_JIS.cc: New generated trie table.
2545 * Makefile.am: Various changes for new files and conversions.
2546
2547 * gnu/gcj/convert/UnicodeToBytes.java (write(String,int,int,char[])):
2548 New overloading, allows greater efficiency.
2549 * gnu/gcj/convert/Output_8859_1.java (write(String,int,int,char[])):
2550 New overloading (for efficiency - avoids copying).
2551
2552 * gnu/gcj/convert/Output_UTF8.java: Fix typo: 0xC0 -> 0c3F.
2553 * gnu/gcj/convert/Input_UTF8.java: Fix typos in bit masks.
2554
2555 * java/io/InputStreamReader.java (<init>): Set super.in correctly.
2556 * java/io/OutputStreamWriter.java (<init>): Set super.in correctly.
2557 (writeChars): Don't be quite so eager to flush.
2558 * java/io/PrintStream.java: Rewrite. Now more similar to
2559 OutputStreamWriter, using explicit UnicodeToBytes converter.
2560 Also, autoflush does not need to flush so often.
2561 * java/lang/natString.cc (getBytes): More efficient algorithm.
2562 (init(jbyteArray,jint,jint,jstring)): More efficient.
2563
2564 1999-04-15 Warren Levy <warrenl@cygnus.com>
2565
2566 * Makefile.am (ordinary_java_source_files): Added new Connection
2567 and Handler classes in gnu.gcj.protocol.file package.
2568 * Makefile.in: Rebuilt.
2569
2570 * gnu/gcj/protocol/file/Connection.java: New file.
2571 * gnu/gcj/protocol/file/Handler.java: New file.
2572 * gnu/gcj/protocol/http/Connection.java (getInputStream): Check
2573 if doInput allows input.
2574 (getOutputStream): Check if doOutput allows output.
2575 * java/net/URLStreamHandler.java (parseURL): Fix indentation.
2576
2577 1999-04-14 Tom Tromey <tromey@cygnus.com>
2578
2579 * java/net/natInetAddress.cc (lookup): On glibc2.0 systems, make
2580 buffer larger to work around bug.
2581 From Bryce McKinlay <bryce@albatross.co.nz>.
2582
2583 1999-04-14 Andrew Haley <aph@cygnus.com>
2584
2585 * java/lang/natDouble.java (doubleToLongBits): ensure that all
2586 NaNs are always converted to the same long value.
2587 * java/lang/natFloat.java (floatToIntBits): ditto, but for float
2588 converted to int.
2589
2590 1999-04-13 Tom Tromey <tromey@cygnus.com>
2591
2592 * java/lang/natSystem.cc (arraycopy): Don't always use jbyteArray;
2593 instead switch on actual element type.
2594
2595 * Makefile.in: Rebuilt.
2596 * Makefile.am (AM_MAKEFLAGS): Added JC1FLAGS.
2597
2598 1999-04-13 Andrew Haley <aph@cygnus.com>
2599
2600 * include/i386-signal.h, include/default-signal.h: New files.
2601 * prims.cc (catch_segv): Call MAKE_THROW_FRAME in exception
2602 handler.
2603 (catch_fpe): New function.
2604 * configure.in: Make link to appropriate include/java-signal.h.
2605 * configure: Rebuilt.
2606 * Makefile.am: include/java-signal.h added to dependency list.
2607 * Makefile.in: Rebuilt.
2608
2609 1999-04-12 Urban Widmark <urban@svenskatest.se>
2610
2611 * java/io/DataInputStream.java (readLine): Corrected handling of
2612 empty lines, from null to "".
2613
2614 1999-04-12 Tom Tromey <tromey@cygnus.com>
2615
2616 * Makefile.in: Rebuilt.
2617 * Makefile.am (libgcj.zip): Put `gnu' classes into zip file.
2618
2619 * java/lang/natSystem.cc (SystemClass): New define.
2620 (init_properties): Synchronize.
2621
2622 1999-04-08 Geoff Berry <gcb@gnu.org>
2623
2624 * natInetAddress.cc (lookup): Fix typo (AF_INET16 -> AF_INET6).
2625 * natPlainSocketImpl.cc (accept): Add missing else if check
2626 for AF_INET6.
2627
2628 1999-04-08 Tom Tromey <tromey@cygnus.com>
2629
2630 * java/lang/Long.java (parseLong): Corrected overflow detection
2631 code.
2632 * java/lang/Integer.java (parseInt): Corrected overflow detection
2633 code.
2634
2635 * java/io/PrintStream.java (print): Handle null string argument.
2636 (println): Likewise.
2637
2638 1999-04-07 Warren Levy <warrenl@cygnus.com>
2639
2640 * java/lang/natString.cc (init(jbyteArray,jint,jint,jstring)):
2641 Set count to 0 when InputStreamReader returns -1 for EOF.
2642
2643 1999-04-07 Tom Tromey <tromey@cygnus.com>
2644
2645 * mauve-libgcj: Omit java.text.Collator,
2646 java.text.RuleBasedCollator.
2647
2648 1999-04-06 Tom Tromey <tromey@cygnus.com>
2649
2650 * gnu/gcj/protocol/http/Connection.java (getHeaderField): Catch
2651 IOException from getHttpHeaders().
2652 (getHeaderFieldKey): Likewise.
2653
2654 * include/javaprims.h: Regenerated declarations.
2655
2656 * Makefile.in: Rebuilt.
2657 * Makefile.am (ordinary_java_source_files): Updated for removed
2658 files.
2659
2660 1999-04-06 Per Bothner <bothner@cygnus.com>
2661
2662 * java/util/zip/Adler32.java: New class.
2663 * java/util/zip/CRC32.java: Add working method bodies.
2664 * Makefile.am (ordinary_java_source_files): Add new Adler32 class.
2665 * Makefile.in: Re-generate.
2666
2667 Tue Apr 6 18:28:42 1999 Warren Levy <warrenl@cygnus.com>
2668
2669 * gnu/gcj/protocol/http/Connection.java: New file. Rewritten
2670 from version in removed www hierarchy.
2671 * gnu/gcj/protocol/http/Handler.java: New file. Copied from
2672 version in removed www hierarchy.
2673
2674 * gnu/gcj/www/protocol/http/Connection.java: Removed.
2675 * gnu/gcj/www/protocol/http/Handler.java: Removed.
2676 * gnu/gcj/www/protocol/http: Removed dir.
2677 * gnu/gcj/www/protocol: Removed dir.
2678 * gnu/gcj/www: Removed dir.
2679
2680 * java/net/HttpURLConnection.java: Revised comments to indicate
2681 missing JDK 1.2 methods.
2682
2683 * java/net/URL.java (setURLStreamHandler): Look in gnu/gcj/protocol
2684 hierarchy rather than the gnu/gcj/www/protocol one.
2685 * java/net/URLConnection.java: Updated status comments.
2686 (setContentHandler): Look in gnu/gcj/content hierarchy rather than
2687 the gnu/gcj/www/content one.
2688
2689 1999-04-06 Per Bothner <bothner@cygnus.com>
2690
2691 * Makefile.am (JIS0208_to_Unicode.cc, JIS0212_to_Unicode.cc):
2692 The gen-from-JIS program is in $(CONVERT_DIR).
2693
2694 1999-04-06 Tom Tromey <tromey@cygnus.com>
2695
2696 * mauve-libgcj: Renamed from mauve-libjava.
2697
2698 Tue Apr 6 03:18:38 1999 Warren Levy <warrenl@cygnus.com>
2699
2700 * java/net/HttpURLConnection.java (getResponseCode): Implemented.
2701 (getResponseMessage): Implemented.
2702 (getResponseVals): New private method.
2703
2704 * java/net/URLConnection.java (getContent): Implemented.
2705 (setContentHandler): Convert non-alphabetic/numeric chars per spec.
2706
2707 1999-04-05 Tom Tromey <tromey@cygnus.com>
2708
2709 * Makefile.am (bin_PROGRAMS): Renamed convert to jv-convert.
2710 (jv_convert_SOURCES): Renamed.
2711 (EXTRA_jv_convert_SOURCES): Likewise.
2712 (jv_convert_LDFLAGS): Likewise.
2713 (jv_convert_LINK): Likewise.
2714 (jv_convert_LDADD): Likewise.
2715 (jv_convert_DEPENDENCIES): Likewise.
2716
2717 * Makefile.in: Rebuilt.
2718 * Makefile.am (toolexeclibdir): Reference toolexecdir, not
2719 tooldir.
2720
2721 Mon Apr 5 02:14:35 1999 Warren Levy <warrenl@cygnus.com>
2722
2723 * java/net/HttpURLConnection.java (setRequestMethod): Use String.equals
2724 method for comparison.
2725
2726 * java/net/URLConnection.java (getContentLength): Implemented.
2727 (getContentType): Implemented.
2728 (getContentEncoding): Implemented.
2729 (getExpiration): Implemented.
2730 (getDate): Implemented.
2731 (getLastModified): Implemented.
2732 (getHeaderFieldInt): Implemented.
2733 (getHeaderFieldDate): Implemented.
2734
2735 Fri Apr 2 18:04:52 1999 Warren Levy <warrenl@cygnus.com>
2736
2737 * java/net/URLConnection.java (toString): Implemented.
2738 (setContentHandlerFactory): Implemented.
2739 (setContentHandler): Wrote new private helper method.
2740
2741 1999-04-01 Tom Tromey <tromey@cygnus.com>
2742
2743 * Makefile.in: Rebuilt.
2744 * Makefile.am ($(java_source_files:.java=.class): Reverted change
2745 of 1999-03-31; we always want to build all the .class files.
2746 Depend on java_source_files, not libgcj.zip.
2747 (nat_headers): Define in terms of ordinary_java_source_files.
2748
2749 1999-03-31 Tom Tromey <tromey@cygnus.com>
2750
2751 * Makefile.in: Rebuilt.
2752 * Makefile.am (special_java_source_files): New macro.
2753 (java_source_files): Use it.
2754 (ordinary_java_source_files): New macro.
2755 (java_source_files): Use it.
2756 ($(ordinary_java_source_files:.java=.class)): Renamed to avoid
2757 creating headers for those files with hand-maintained headers.
2758
2759 * include/javaprims.h: Regenerated namespace declarations.
2760 * classes.pl (scan): Include [0-9] in regexp for matching class
2761 names; for java.util.zip.CRC32.
2762
2763 * Makefile.in: Rebuilt.
2764 * Makefile.am (nat_headers): Redefined to generate all possible
2765 header files.
2766
2767 * java/util/zip/ZipException.java: In package java.util.zip, not
2768 java.net.
2769
2770 1999-03-30 Tom Tromey <tromey@cygnus.com>
2771
2772 * configure: Rebuilt.
2773 * configure.in (EH_COMMON_INCLUDE): Look in ../compat-include for
2774 eh-common.h when not building in tree with gcc.
2775
2776 * Makefile.in: Rebuilt.
2777 * Makefile.am ($(nat_files) $(GCOBJS) $(THREADOBJS)
2778 $(libgcj_a_OBJECTS)): Changed how we list files that depend on
2779 nat_headers.
2780 ($(java_source_files:.java=.class)): New target.
2781
2782 * Makefile.in: Rebuilt.
2783 * Makefile.am (java_source_files): Added
2784 java/net/HttpURLConnection.java and
2785 gnu/gcj/www/protocol/http/Connection.java.
2786
2787 Tue Mar 30 15:20:45 1999 Warren Levy <warrenl@cygnus.com>
2788
2789 * gnu/gcj/www/protocol/http/Connection.java: New file.
2790 * gnu/gcj/www/protocol/http/Handler.java (openConnection): Implemented.
2791 * java/net/HttpURLConnection.java: New file.
2792 * java/net/URLConnection.java (getHeaderField): Implemented default.
2793 (getHeaderFieldKey): Implemented default method.
2794
2795 1999-03-30 Tom Tromey <tromey@cygnus.com>
2796
2797 * gnu/gcj/convert/JIS0212.h, gnu/gcj/convert/JIS0208.h: Rebuilt.
2798
2799 * java/util/zip/Deflater.java: Added copyright header.
2800 * java/util/zip/CRC32.java: Added copyright header.
2801
2802 * Makefile.am ($(srcdir)/$(CONVERT_DIR)/JIS0208.h): Note in file
2803 that it is automatically generated.
2804 ($(srcdir)/$(CONVERT_DIR)/JIS0212.h): Likewise.
2805
2806 * gnu/gcj/convert/BytesToUnicode.java,
2807 gnu/gcj/convert/Convert.java, gnu/gcj/convert/Input_8859_1.java,
2808 gnu/gcj/convert/Input_EUCJIS.java,
2809 gnu/gcj/convert/Input_UTF8.java,
2810 gnu/gcj/convert/JIS0208_to_Unicode.cc,
2811 gnu/gcj/convert/JIS0212_to_Unicode.cc,
2812 gnu/gcj/convert/Output_8859_1.java,
2813 gnu/gcj/convert/Output_JavaSrc.java,
2814 gnu/gcj/convert/Output_UTF8.java,
2815 gnu/gcj/convert/UnicodeToBytes.java,
2816 gnu/gcj/convert/natInput_EUCJIS.cc: Added copyright headers.
2817
2818 * gnu/gcj/convert/gen-from-JIS.c (main): Fixed incorrect fprintf.
2819
2820 * Makefile.in, configure: Rebuilt.
2821 * configure.in (TESTSUBDIR): Enable if testsuite subdir exists,
2822 not if test subdir exists.
2823 (--enable-gcj-classes): Removed; gcj always used to generate
2824 .class files.
2825 (JAVA, JAVAC): Removed.
2826 (--enable-single-compilation, --enable-source-compilation):
2827 Removed.
2828 (here): New subst.
2829 (NATIVE): New conditional.
2830 * Makefile.am (toolexecdir): Renamed from tooldir to allow
2831 `install-exec' to work.
2832 (toolexeclibdir): Likewise.
2833 (toollib_LIBRARIES): Likewise.
2834 (AM_MAKEFLAGS): Don't pass tooldir.
2835 (JAVAC): New macro.
2836 (javao_files): Redefined.
2837 (java_source_files): New macro.
2838 (c_source_files): New macro.
2839 (c_files): Redefined in terms of c_source_files.
2840 (java_io_files, java_lang_files, java_net_files, java_text_files,
2841 java_util_files, gnu_files, java_files): Removed.
2842 (class_io_files, class_lang_files, class_net_files,
2843 class_text_files, class_util_files, class_gnu_files, class_files):
2844 Removed.
2845 (nat_source_files): New macro.
2846 (nat_files): Redefined in terms of nat_source_files.
2847 (EXTRA_libgcj_a_SOURCES): Added c_source_files,
2848 java_source_files. Removed no-such-file.c.
2849 (here): Removed.
2850 (ETAGS_ARGS): Removed.
2851 (TAGS_DEPENDENCIES): Likewise.
2852 (libgcj.zip): Depend on java_source_files. Use $(here) and not
2853 pwd in rule.
2854 (src_io_files, src_lang_files, src_text_files, src_util_files,
2855 src_gnu_files): Removed.
2856 Removed ALL_AT_ONCE and COMPILE_FROM_CLASS code.
2857 (BUILT_SOURCES): Removed.
2858 (header-check): New target.
2859 (javadir): Removed.
2860 (noinst_PROGRAMS): New macro.
2861 ($(srcdir)/$(CONVERT_DIR)/JIS0208_to_Unicode.cc): Conditionalize
2862 on MAINTAINER_MODE.
2863 ($(srcdir)/$(CONVERT_DIR)/JIS0212_to_Unicode.cc): Likewise.
2864 (gen-from-JIS): Build in top directory.
2865 (convert_source_files): New macro.
2866 (convert_SOURCES): New macro.
2867 (convert_LDFLAGS): Likewise.
2868 (convert_LINK): Likewise.
2869 (convert_LDADD): Likewise.
2870 (convert_DEPENDENCIES): Likewise.
2871 (convert): Removed.
2872 (gen-from-JIS): Removed.
2873 (gen_from_JIS_SOURCES): New macro.
2874 (gen_from_JIS_LDADD): Likewise.
2875 (gen_from_JIS_DEPENDENCIES): Likewise.
2876
2877 * configure: Rebuilt.
2878 * configure.in (CANADIAN): Set to `yes', not `canadian'.
2879 (NULL_TARGET): Initialize to `no'. Correctly examine $NULL_TARGET
2880 when defining conditional.
2881
2882 Tue Mar 30 10:36:27 1999 Per Bothner <bothner@cygnus.com>
2883
2884 * gnu/gcj/convert/{JIS0208.TXT,JIS0212.TXT}: Remove these files.
2885 The Unicode Consortium does not permit their re-distribution.
2886 * Makefile.am, Makefile.in: Add comments with URLs for removed files.
2887 (JIS0208.h, JIS0212.h): Do not depend on removed files.
2888
2889 Mon Mar 29 18:58:13 1999 Per Bothner <bothner@cygnus.com>
2890
2891 * natSystem.c (init_properties): Use malloc, realloc, free after all.
2892
2893 Mon Mar 29 13:41:02 1999 Per Bothner <bothner@cygnus.com>
2894
2895 * gnu/gcj/convert/{JIS0208.TXT,JIS0212.TXT}: New mapping tables
2896 from Unicode Consortium.
2897 * gnu/gcj/convert/{JIS0208.h,JIS0212.h}: New generated headers.
2898 * gnu/gcj/convert/gen-from-JIS.c: New utility for maintainers only.
2899 * gnu/gcj/convert/{JIS0208_to_Unicode.cc,JIS0212_to_Unicode.cc}:
2900 New tables, generated using gen-from-JIS.
2901 * gnu/gcj/convert/Output_JavaSrc.java: New UnicodeToBytes class.
2902 * gnu/gcj/convert/Output_UTF8.java: Fix bug.
2903 * gnu/gcj/convert/Input_EUCJIS.java: New BytesToUnicode class.
2904 * gnu/gcj/convert/natInput_EUCJIS.cc: Native methods for new class.
2905
2906 * gnu/gcj/convert/Convert.java: New application.
2907 * Makefile.am, Makefile.in (convert): New program, using Convert.
2908 Build the various JIS conversion tables (in maintainer mode).
2909
2910 Fri Mar 26 16:51:30 1999 Warren Levy <warrenl@cygnus.com>
2911
2912 * gnu/gcj/www/protocol/http/Handler.java: New file - stubbed.
2913
2914 * java/net/URL.java (URL): Deal with null property value. Use "."
2915 as separator in building class name.
2916 * java/net/URLConnection.java: Implemented majority of stubbed methods.
2917 * java/net/URLStreamHandler.java (parseURL): Use "" in string
2918 manipulations instead of 'null'. Comment cleanup. Use 0 for the
2919 beginning of the substring rather than 'start'.
2920
2921 1999-03-26 Tom Tromey <tromey@cygnus.com>
2922
2923 * include/java-chartables.h: Rebuilt.
2924 * include/java-chardecomp.h: New file.
2925 * chartables.pl: Generate output files directly. Added support
2926 for generating decomposition header.
2927 (canonical_decomposition, full_decomposition): New globals.
2928 (DECOMPOSITION): New constant.
2929 (process_char): Call add_decomposition.
2930 (add_decomposition): New sub.
2931 (write_decompositions): New sub.
2932
2933 1999-03-25 Tom Tromey <tromey@cygnus.com>
2934
2935 * java/text/CollationElementIterator.java: New file.
2936
2937 * mauve-libjava: Omit StringTest.
2938
2939 Wed Mar 24 15:17:49 1999 Warren Levy <warrenl@cygnus.com>
2940
2941 * java/net/URL.java (URL(URL, String, URLStreamHandler)): Allow URLs
2942 without a '/' when parsing protocol. Handle ref outside of parseURL.
2943 (hashCode): Implemented.
2944 (set): Don't expand -1 to default port.
2945 (getDefaultPort): Removed.
2946
2947 * java/net/URLStreamHandler.java (parseURL): Implemented.
2948 (toExternalForm): Implemented.
2949
2950 1999-03-23 Tom Tromey <tromey@cygnus.com>
2951
2952 * java/text/BreakIterator.java (getSentenceInstance):
2953 Implemented.
2954 * gnu/gcj/text/SentenceBreakIterator.java: New file.
2955
2956 * Makefile.in: Rebuilt.
2957 * Makefile.am (nat_headers): Added IllegalAccessException.
2958 * java/lang/natClass.cc (newInstance): Throw
2959 IllegalAccessException, not IllegalAccessError.
2960 Include IllegalAccessException.h.
2961
2962 1999-03-22 Tom Tromey <tromey@cygnus.com>
2963
2964 * gnu/gcj/text/LineBreakIterator.java: New file.
2965 * java/text/BreakIterator.java (getLineInstance): Implemented.
2966
2967 * gnu/gcj/text/WordBreakIterator.java (WordBreakIterator): Made
2968 copy constructor private.
2969 (previous, next): Removed erroneous comment about line
2970 separators.
2971 (previous): Correctly recognize break between non-letter on the
2972 left and letter on the right. Handle apostrophes correctly.
2973
2974 * java/text/BreakIterator.java (getWordInstance): Implemented.
2975 * gnu/gcj/text/WordBreakIterator.java: New file.
2976 * gnu/gcj/text/CharacterBreakIterator.java: Extend
2977 BaseBreakIterator.
2978 * gnu/gcj/text/BaseBreakIterator.java: New file.
2979
2980 1999-03-19 Tom Tromey <tromey@cygnus.com>
2981
2982 * java/text/BreakIterator.java: New file (partially stubbed out).
2983 * gnu/gcj/text/CharacterBreakIterator.java: New file.
2984
2985 * include/config.h.in: Rebuilt.
2986 * acconfig.h (STRUCT_TM_HAS_GMTOFF): New define.
2987 (HAVE_TIMEZONE): Likewise.
2988 * configure: Rebuilt.
2989 * configure.in: Added timezone checks.
2990 * java/util/natGregorianCalendar.cc (computeTime): Adjust for
2991 timezone.
2992
2993 Fri Mar 19 15:26:35 1999 Per Bothner <bothner@cygnus.com>
2994
2995 * gnu/gcj/convert/BytesToUnicode.java: New abstract class.
2996 * gnu/gcj/convert/UnicodeToBytes.java: New abstract class.
2997 * gnu/gcj/convert/Input_8859_1.java: New BytesToUnicode sub-class.
2998 * gnu/gcj/convert/Input_UTF8.java: New BytesToUnicode sub-class.
2999 * gnu/gcj/convert/Output_8859_1.java: New UnicodeToBytes sub-class.
3000 * gnu/gcj/convert/Output_UTF8.java: New UnicodeToBytes sub-class.
3001 * java/io/InputStreamReader.java: Rewrite to use BytesToUnicode.
3002 * java/io/OutputStreamWriter.java: Rewrite to use UnicodeToBytes.
3003
3004 * java/io/natFileDescriptorPosix.cc (open): Use O_BINARY flag.
3005 (BSD_COMP): Kludge needed for Solaris2.
3006
3007 Fri Mar 19 01:49:46 1999 Warren Levy <warrenl@cygnus.com>
3008
3009 * java/net/URL.java (URL(java.net.URL, string): Moved code to
3010 URL(java.net.URL, string, URLStreamHandler) and call it with a
3011 null handler. In latter constructor, added SecurityManager check.
3012 (set): Expect null handler on bad protocol rather than an exception.
3013 (setURLStreamHandler): Simplified exception handling; return null
3014 on invalid protocol.
3015
3016 1999-03-18 Tom Tromey <tromey@cygnus.com>
3017
3018 * java/text/DecimalFormat.java (format(long,...)): Rewrote.
3019
3020 * java/lang/natSystem.cc (setOut, setIn, setErr): New native
3021 methods.
3022 Include PrintStream.h, InputStream.h.
3023 * java/lang/System.java (ForwardingInputStream,
3024 ForwardingOutputStream): Removed.
3025 (setErr, setIn, setOut): Now native.
3026
3027 Reverted patch from 1999-02-12 to work around problem in
3028 libgcc2.c.
3029 * exception.cc (_Jv_eh_alloc): Use malloc, not _Jv_AllocBytes.
3030 (_Jv_eh_free): Use free.
3031
3032 * java/io/natFileDescriptorPosix.cc (open): Allocate enough space
3033 for path name. Minor formatting fixes.
3034
3035 * boehm.cc (_Jv_MarkObj): Always mark `methods' field.
3036
3037 * prims.cc (fail_on_finalization): New function.
3038 (_Jv_GCWatch): Likewise.
3039
3040 * prims.cc (JvRunMain): Initialize `nullp'.
3041 (nullp): New global.
3042 (catch_segv): Throw nullp.
3043
3044 * Makefile.in: Rebuilt.
3045 * Makefile.am (ZIP): In "null target" case, zip is found in the
3046 build tree.
3047
3048 * prims.cc (_Jv_PrimClass): Initialize all elements of class
3049 object.
3050 Include Modifier.h.
3051
3052 * java/lang/StringBuffer.java (StringBuffer): Don't use
3053 ensureCapacity to set initial capacity.
3054 (capacity): Subtract `length' from return result.
3055
3056 Thu Mar 18 01:53:35 1999 Warren Levy <warrenl@cygnus.com>
3057
3058 * java/io/natFileDescriptorPosix.cc (open): Throw
3059 FileNotFoundException, but with filename and errno in msg.
3060
3061 Wed Mar 17 11:09:30 1999 Warren Levy <warrenl@cygnus.com>
3062
3063 * gnu/gcj/www/protocol/URLStreamHandlerFactory.java: Removed;
3064 functionality folded into java/net/URL.java per spec.
3065
3066 * java/io/natFileDescriptorPosix.cc (open): Check for ENOENT rather
3067 than EEXIST for throwing FileNotFoundException.
3068
3069 * java/net/URL.java: Folded in default URLStreamHandlerFactory
3070 algorithm per JDK 1.2 doc. Added SecurityManager checks.
3071
3072 * java/net/URLStreamHandler.java (parseURL): Added stub.
3073
3074 1999-03-15 Andrew Haley <aph@cygnus.com>
3075
3076 * java/text/ChoiceFormat.java (nextDouble): Simplify and fix off
3077 by one errors.
3078
3079 1999-03-15 Andrew Haley <aph@cygnus.com>
3080
3081 * java/lang/natSystem.cc (currentTimeMillis): Restore eCos clock
3082 support.
3083
3084 1999-03-12 Tom Tromey <tromey@cygnus.com>
3085
3086 * prims.cc (catch_segv): New function.
3087 Include <signal.h> if HANDLE_SEGV defined. Include
3088 NullPointerException.h.
3089 (JvRunMain): If HANDLE_SEGV defined, install catch_segv as SIGSEGV
3090 handler.
3091
3092 * java/text/SimpleDateFormat.java (equals): Ensure that object is
3093 a SimpleDateFormat, not just a DateFormat.
3094 (defaultCenturyStart, formatData, pattern): Now private.
3095 (append): Now `final'. Use `NumberFormat.format'.
3096 (parse): Wrote.
3097 (SimpleDateFormat): Turn off groupin in NumberFormat object.
3098
3099 * java/lang/natString.cc (indexOf): Add `fromIndex' to successful
3100 result.
3101
3102 * java/text/MessageFormat.java (format): Use default MessageFormat
3103 constructor.
3104 (parse, parseObject): Wrote.
3105
3106 * java/text/SimpleDateFormat.java (SimpleDateFormat): Wrote no-arg
3107 constructor.
3108
3109 1999-03-12 Andrew Haley <aph@cygnus.com>
3110
3111 * java/lang/String.java (indexOf): Replace with native method for
3112 better performance.
3113 * java/lang/natString.cc (IndexOf): As above.
3114
3115 * java/lang/natString.cc (init(jbyteArray,jint,jint,jint)):
3116 Argument check corrected.
3117 (init(jbyteArray,jint,jint,jstring)): Likewise.
3118
3119 * java/lang/StringBuffer.java (ensureCapacity): Replace with JDK
3120 1.2 compliant method.
3121
3122 * java/lang/Double.java (byteValue, shortValue): JDK 1.1 methods
3123 added.
3124 * java/lang/Float.java (byteValue, shortValue): Likewise.
3125
3126 1999-03-11 Tom Tromey <tromey@cygnus.com>
3127
3128 * java/text/DecimalFormat.java (parse): Wrote.
3129
3130 * java/text/ChoiceFormat.java (parse): Set error index on
3131 ParsePosition object.
3132
3133 * java/lang/Integer.java (parseInt): Throw exception on overflow
3134 when intermediate result is most negative number. Changed
3135 overflow detection as well.
3136 * java/lang/Long.java (parseLong): Likewise.
3137
3138 * configure, Makefile.in: Rebuilt.
3139 * configure.in (NULL_TARGET, CANADIAN): New conditionals. Set
3140 CANADIAN when building in source tree that doesn't include gcc.
3141 * Makefile.am (ZIP, GCJ, GCJH): Use automake conditionals to
3142 define.
3143
3144 * java/text/ChoiceFormat.java (nextDouble): Correct some
3145 off-by-one errors when masking or adding.
3146
3147 * java/text/DecimalFormat.java (format): Fill in FieldPosition
3148 parameter, if given. Use `%', not IEEEremainder.
3149 (scanFix): Throw error if multiplier already set.
3150 (computePattern): Wrote.
3151
3152 1999-03-11 Andrew Haley <aph@cygnus.com>
3153
3154 * java/text/ChoiceFormat.java (mantissaBits): Use correct value of
3155 52.
3156 (nextDouble): Corrected masking logic. Handle interaction between
3157 `next' and negative numbers.
3158
3159 Wed Mar 10 18:58:37 1999 Warren Levy <warrenl@cygnus.com>
3160
3161 * gnu/gcj/www/protocol/URLStreamHandlerFactory.java: Created.
3162 * java/net/URL.java: Added general comments.
3163
3164 1999-03-10 Tom Tromey <tromey@cygnus.com>
3165
3166 * java/text/ChoiceFormat.java (parse): Wrote.
3167
3168 * java/text/ChoiceFormat.java (toPattern): Use `#', not `<'.
3169
3170 * java/text/MessageFormat.java (MessageFormatElement.setLocale):
3171 Create ChoiceFormat objects.
3172 (format): Special-case ChoiceFormat.
3173 (scanFormatElement): Include { and } in generated style string.
3174
3175 1999-03-09 Tom Tromey <tromey@cygnus.com>
3176
3177 * java/text/ChoiceFormat.java: New file.
3178
3179 Tue Mar 9 17:09:18 1999 Warren Levy <warrenl@cygnus.com>
3180
3181 * java/net/BindException.java: Created.
3182 * java/net/ConnectException.java: Created.
3183 * java/net/ContentHandler.java: Created.
3184 * java/net/ContentHandlerFactory.java: Created.
3185 * java/net/FileNameMap.java: Created.
3186 * java/net/MalformedURLException.java: Created.
3187 * java/net/NoRouteToHostException.java: Created.
3188 * java/net/ProtocolException.java: Created.
3189 * java/net/ServerSocket.java (@author): Fixed typo.
3190 * java/net/Socket.java (@author): Fixed typo.
3191 * java/net/SocketImpl.java (@author): Fixed typo.
3192 * java/net/SocketImplFactory.java (@author): Fixed typo.
3193 * java/net/URL.java: Created - nearly complete.
3194 * java/net/URLConnection.java: Created - near-empty stub.
3195 * java/net/URLStreamHandler.java: Created - incomplete stub.
3196 * java/net/URLStreamHandlerFactory.java: Created.
3197 * java/net/UnknownServiceException.java: Created.
3198
3199 1999-03-09 Tom Tromey <tromey@cygnus.com>
3200
3201 * java/lang/System.java (ForwardingInputStream): New class.
3202 (ForwardingOutputStream): Likewise.
3203 (in, out, err): Now `final' forwarding streams.
3204 (setIn, setOut, setErr): Use appropriate method on forwarding
3205 streams.
3206
3207 * java/text/MessageFormat.java (MessageFormatElement): Now `final'
3208 class.
3209
3210 Tue Mar 9 12:16:53 1999 Per Bothner <bothner@cygnus.com>
3211
3212 * java/util/zip/CRC32.java: New class (just an incomplete stub).
3213 * java/util/zip/Checksum.java: New interface (complete).
3214 * java/util/zip/Deflater.java: New class (near-empty stub).
3215 * java/util/zip/DeflaterOutputStream.java: New class (incomplete stub).
3216 * java/util/zip/ZipConstants.java: New interface (near-empty stub).
3217 * java/util/zip/ZipEntry.java: New class (complete).
3218 * java/util/zip/ZipException.java: New class (complete).
3219 * java/util/zip/ZipFile.java: New class (incomplete stub).
3220 * java/util/zip/ZipOutputStream.java: New class (incomplete stub).
3221
3222 1999-03-09 Tom Tromey <tromey@cygnus.com>
3223
3224 * java/text/MessageFormat.java (MessageFormatElement): Removed
3225 `public' specifiers.
3226
3227 * java/text/DecimalFormat.java (scanFormat): Increment index
3228 before processing exponential format. Fixed a couple typos in
3229 exception messages.
3230 (format): Correct normalization of exponent.
3231
3232 1999-03-08 Tom Tromey <tromey@cygnus.com>
3233
3234 * java/text/SimpleDateFormat.java (parse): Throw
3235 IllegalArgumentException, not ParseException.
3236
3237 1999-03-05 Tom Tromey <tromey@cygnus.com>
3238
3239 * java/text/SimpleDateFormat.java (SimpleDateFormat): Use locale
3240 when constructing DateFormatSymbols. Initialize numberFormat
3241 field of superclass.
3242
3243 * java/text/DateFormat.java (equals): Rewrote.
3244 (getAvailableLocales): New method.
3245 (getDateInstance): New methods.
3246 (getDateTimeInstance): Likewise.
3247 (getTimeInstance): Likewise.
3248 (getInstance): New method.
3249 (computeInstance): New method.
3250
3251 * java/text/DateFormatSymbols.java (zoneStringsDefault): Completed
3252 for US.
3253 (safeGetResource): New method.
3254 (DateFormatSymbols): Use Locale paramater.
3255 (equals): Now protected.
3256 Made instance variables private.
3257
3258 1999-03-04 Tom Tromey <tromey@cygnus.com>
3259
3260 * java/text/DecimalFormat.java: New file.
3261
3262 * java/text/NumberFormat.java (groupingUsed,
3263 maximumFractionDigits, maximumIntegerDigits,
3264 minimumFractionDigits, minimumIntegerDigits, parseIntegerOnly):
3265 New fields.
3266 (setDecimalSeparatorAlwaysShown, setMultiplier,
3267 setPositivePrefix): Removed.
3268 (setMinimumFractionDigits, setMaximumFractionDigits):
3269 Implemented.
3270 (format): Now final.
3271 Added many new methods.
3272
3273 * Makefile.in: Rebuilt.
3274 * Makefile.am (gnu_files): New macro.
3275 (java_files): Added gnu_files.
3276 (class_gnu_files): New macro.
3277 (class_files): Use it.
3278 (src_gnu_files): New macro.
3279 (gnu.o): New target.
3280 (javao_files): Added gnu.o.
3281
3282 * gnu/gcj/text/LocaleData_en_US.java: New file.
3283 * gnu/gcj/text/LocaleData_en.java: New file.
3284 * java/text/DecimalFormatSymbols.java: Import ResourceBundle.
3285 (DecimalFormatSymbols): Use ResourceBundle to find resources.
3286 (safeGetString): New method.
3287 (safeGetChar): Likewise.
3288
3289 1999-03-03 Tom Tromey <tromey@cygnus.com>
3290
3291 * java/text/NumberFormat.java (INTEGER_FIELD, FRACTION_FIELD): New
3292 constants.
3293
3294 * java/text/FieldPosition.java (equals): Don't check for null
3295 object; instanceof does this.
3296
3297 * java/util/Locale.java (clone): New method.
3298 (equals): Likewise.
3299
3300 Wed Mar 3 17:20:15 1999 Anthony Green <green@cygnus.com>
3301
3302 * doc/cni.sgml: New file.
3303
3304 1999-03-03 Tom Tromey <tromey@cygnus.com>
3305
3306 * prims.cc (_Jv_Abort): Mention libgcj, not libjava.
3307
3308 * java/text/DecimalFormatSymbols.java: New file.
3309
3310 1999-03-02 Tom Tromey <tromey@cygnus.com>
3311
3312 * java/io/natFileDescriptorPosix.cc: Include sys/filio.h if it
3313 exists.
3314 * configure: Rebuilt.
3315 * configure.in: Check for sys/filio.h.
3316
3317 * java/lang/Runtime.java (checkLink): Throw NullPointerException
3318 if required.
3319 (load): Always throw UnsatisfiedLinkError.
3320 (loadLibrary): Likewise.
3321
3322 1999-03-02 Anthony Green <green@cygnus.com>
3323
3324 * LIBGCJ_LICENSE: New file.
3325 * LIBJAVA_LICENSE: Removed.
3326 * Many files: libjava now libgcj.
3327
3328 1999-03-02 Tom Tromey <tromey@cygnus.com>
3329
3330 * include/java-chartables.h: Rebuilt.
3331 * chartables.pl (print_block): Make table `const'.
3332 (print_numerics): Likewise.
3333 (print_single_map): Likewise.
3334 (print_all_block): Likewise.
3335 (print_case_table): Likewise.
3336 (print_fast_tables): Likewise.
3337 * java/lang/natCharacter.cc (table_search): `table' argument now
3338 const.
3339
3340 1999-03-01 Tom Tromey <tromey@cygnus.com>
3341
3342 * java/util/Date.java (before, after): Inverted logic.
3343
3344 * java/util/Date.java (parse): Handle case where first character
3345 in string is open parenthesis.
3346 (skipParens): Rewrote.
3347
3348 * java/lang/reflect/natArray.cc: Include <stdlib.h>.
3349 * java/lang/reflect/natField.cc: Include <stdlib.h>.
3350
3351 * java/util/Date.java (parse): Correctly compute beginning of
3352 punctuation.
3353
3354 * java/util/Hashtable.java (get): Throw NullPointerException if
3355 key is null.
3356 (containsKey): Likewise.
3357
3358 * java/util/Properties.java (list): Truncate value to 37
3359 characters and add `...'.
3360
3361 * java/lang/Byte.java (parseByte): Pass `radix' to
3362 Integer.parseInt.
3363
3364 * prims.cc (_Jv_Abort): In non-DEBUG case, use System.err, not
3365 fprintf.
3366 Include System.h, PrintStream.h.
3367
3368 * java/lang/natSystem.cc (init_properties): Don't use malloc,
3369 realloc, or free.
3370
3371 * java/lang/natSystem.cc (init_properties): Use getpwuid_r if it
3372 exists.
3373 * configure: Rebuilt.
3374 * configure.in: Check for getpwuid_r. Look for `pwd.h', not
3375 `pwd.d'.
3376
3377 * mauve-libjava: Omit AttibutedCharacterIterator, ACIAttribute.
3378
3379 * java/lang/SecurityManager.java: Import java.net.*.
3380 (checkMulticast): New methods.
3381
3382 Fri Feb 26 14:54:52 1999 Per Bothner <bothner@cygnus.com>
3383
3384 * Makefile.am, Makefile.in (java/lang/reflect/Method.h): New rule.
3385 (nat_files): Add java/lang/reflect/natArray.o.
3386 (nat_headers): Add Field.h and NoSuchFieldException.h.
3387
3388 * include/java-field.h (_Jv_GetStaticLongField, _Jv_GetStaticIntField,
3389 _Jv_GetStaticShortField, _Jv_GetStaticByteField): New inline methods.
3390 (_Jv_FromReflectedField): Fix buglet.
3391 * include/jvm.h (_Jv_NewMultiArray): New declaration.
3392 * include/java-assert.h (JvFail): Pass message string to _Jv_Abort.
3393 * prims.cc (_Jv_Abort): Include message in print-out.
3394
3395 * prims.cc (_Jv_equal): New method (compare Utf8Const and jstring).
3396 (new_multi_array): Rename to _Jv_NewMultiArray. Make non-static.
3397 * include/jvm.h (_Jv_NewMultiArray, _Jv_equal): New declarations.
3398
3399 * configure.in (AC_CHECK_HEADERS), configure: Add pwd.h.
3400 * include/config.h.in (HAVE_PWD_H): New feature macro.
3401 * java/lang/natSystem.cc (init_properties): Set file.encoding,
3402 user.name, user.home, user.dir.
3403
3404 * java/lang/reflect/Array.java: New class.
3405 * java/lang/reflect/natArray.cc: New native methods.
3406 * include/javaprims.h: Declare java::lang::reflect::Array.
3407
3408 * java/lang/Class.h (getField): New private method. Add friends.
3409 * java/lang/Class.java (getField): Add private overload.
3410 * java/lang/natClass.cc (getField, getField, getDeclaredField,
3411 getDeclaredMethods): Add working implementations.
3412 * java/lang/reflect/Field.java, java/lang/reflect/natField.cc:
3413 Finish implementation, except for access control.
3414
3415 * java/lang/reflect/Modifier.java (toString): New overload.
3416 * include/java-method.h: New file.
3417 * java/lang/reflect/Method.java (index): Replaced by offset field.
3418 Remove various private fields - get them from _Jv_Field instead.
3419 * java/lang/reflect/natMethod.cc (getModifiers, getName, getType):
3420 New method implementations.
3421
3422 * java/text/NumberFormat.java: Add a bunch of methods.
3423
3424 Mon Feb 22 17:52:34 1999 Per Bothner <bothner@cygnus.com>
3425
3426 * java/lang/StringBuffer.java (getChars): Fix bounds checks.
3427
3428 1999-02-26 Tom Tromey <tromey@cygnus.com>
3429
3430 * include/config.h.in: Rebuilt.
3431 * acconfig.h (GETHOSTBYNAME_R_RETURNS_INT,
3432 GETHOSTBYADDR_R_RETURNS_INT, HAVE_GETHOSTBYNAME_R,
3433 HAVE_GETHOSTBYADDR_R): New defines.
3434 * java/net/natInetAddress.cc (lookup): Use gethostbyname_r and
3435 gethostbyaddr_r if available.
3436 Include <errno.h>.
3437 * configure: Rebuilt.
3438 * configure.in: Check for gethostbyname_r, gethostbyaddr_r.
3439
3440 * java/net/natInetAddress.cc (aton): Use _Jv_AllocBytesChecked.
3441 Don't use JvFree.
3442 (lookup): Likewise.
3443 Include <jvm.h>.
3444 * include/jvm.h (_Jv_AllocBytesChecked): Declare.
3445 * prims.cc (_Jv_AllocBytesChecked): New function.
3446
3447 * Makefile.in: Rebuilt.
3448 * Makefile.am (SUBDIRS): Removed `test'.
3449 * configure: Rebuilt.
3450 * configure.in: Don't build test/Makefile.
3451 * test/*: Removed all files.
3452
3453 Thu Feb 25 17:27:37 1999 Warren Levy <warrenl@cygnus.com>
3454
3455 * java/lang/reflect/Constructor.java: Make class final to match spec.
3456 * java/lang/reflect/Method.java: Ditto.
3457
3458 1999-02-25 Tom Tromey <tromey@cygnus.com>
3459
3460 * java/net/natInetAddress.cc: Include <sys/types.h> before
3461 <sys/socket.h>.
3462 * java/net/natPlainSocketImpl.cc: Include <sys/types.h> before
3463 <sys/socket.h>.
3464
3465 * java/net/natInetAddress.cc: Declare gethostname if required.
3466 * include/config.h.in: Rebuilt.
3467 * acconfig.h (HAVE_GETHOSTNAME_DECL): New define.
3468 * configure: Rebuilt.
3469 * configure.in: Define HAVE_GETHOSTNAME_DECL when gethostname is
3470 declared in unistd.h.
3471
3472 1999-02-24 Tom Tromey <tromey@cygnus.com>
3473
3474 * Makefile.in: Rebuilt.
3475 * Makefile.am (java/io/FileDescriptor.h): Removed target.
3476 * java/io/FileDescriptor.java (FileDescriptor): Changed protection
3477 from private to "none".
3478
3479 * include/javaprims.h: Regenerated class declarations with new
3480 classes.pl.
3481 * classes.pl (scan): Only generate decls for java.lang, java.io,
3482 and java.util.
3483
3484 1999-02-24 Tom Tromey <tromey@cygnus.com>
3485
3486 * posix-threads.cc (_Jv_InitThreads): Mask SIGINT in all threads.
3487 (_Jv_ThreadWait): Allow SIGINT to be delivered to waiting thread.
3488
3489 1999-02-23 Tom Tromey <tromey@cygnus.com>
3490
3491 * java/util/natGregorianCalendar.cc (_REENTRANT): Only define if
3492 not already defined.
3493 * java/io/natFile.cc (_REENTRANT): Only define if not already
3494 defined.
3495 * include/config.h.in: Rebuilt.
3496 * acconfig.h (HAVE_BOEHM_GC): New define.
3497 * configure: Rebuilt.
3498 * configure.in: Define HAVE_BOEHM_GC if using it.
3499 * posix-threads.cc: Include boehm-config.h and gc.h if
3500 HAVE_BOEHM_GC.
3501 * include/posix-threads.h: Added explanatory note about Boehm GC.
3502
3503 * java/io/BufferedReader.java (readLine): Only return null when
3504 EOF seen before any characters read. (In particular, an empty
3505 line should not return null.)
3506
3507 * java/io/BufferedInputStream.java (read): Only refill once per
3508 invocation.
3509
3510 * mauve-libjava: Added java.text.StringCharacterIterator.iter,
3511 java.lang.Character.classify12, java.lang.String.hash,
3512 java.text.FieldPosition.Test, java.text.ParsePosition.Test,
3513 java.text.SimpleDateFormat.getAndSet2DigitYearStart
3514
3515 * java/text/StringCharacterIterator.java (setIndex): No error if
3516 index == end.
3517 (next): Check for `pos == end', not `end - 1'.
3518 (StringCharacterIterator): Allow `pos == end'. Explicitly check
3519 for null text in each constructor.
3520 (clone): Fixed order of arguments to constructor.
3521
3522 1999-02-22 Tom Tromey <tromey@cygnus.com>
3523
3524 * include/config.h.in: Rebuilt.
3525 * acconfig.h (HAVE_INET6): New define.
3526 (HAVE_SOCKLEN_T): Likewise.
3527 * java/net/PlainSocketImpl.java: Added copyright header.
3528 * java/net/natPlainSocketImpl.cc: Added copyright header.
3529 (union SockAddr): Use HAVE_INET6, not AF_INET6.
3530 (bind): Likewise.
3531 (connect): Likewise.
3532 (accept): Likewise.
3533 (socklen_t): New typedef.
3534 (accept): Use socklen_t.
3535 * java/net/natInetAddress.cc: Added copyright header.
3536 (HAVE_GETHOSTNAME): Don't define.
3537 (HAVE_INET_ADDR): Likewise.
3538 (lookup): Fixed typo.
3539 (aton): Don't use `address' as name of local variable.
3540 (lookup): Use HAVE_INET6, not AF_INET6.
3541
3542 * configure: Rebuilt.
3543 * configure.in: Look for functions inet_aton, inet_addr,
3544 gethostname, inet_pton, uname. Check for sockaddr_in6 structure.
3545 Check for socklen_t typedef.
3546
3547 * exception.cc (__throw): Declare as __noreturn__.
3548
3549 Mon Feb 22 15:27:35 1999 Per Bothner <bothner@cygnus.com>
3550
3551 * Makefile.am, Makefile.in: Also build java/net.
3552 (java/io/FileDescriptor.h): Add friend java::net::PlainSocketImpl.
3553
3554 * java/io/natFile.cc: #define _POSIX_PTHREAD_SEMANTICS and _REENTRANT.
3555 * java/util/natGregorianCalendar.cc: #define _REENTRANT.
3556
3557 * prims.cc (_Jv_malloc, _Jv_Free): New functions.
3558 * include/cni.h (JvMalloc, JvFree): New inline functions.
3559 (JvThrow): Add __noreturn__ attribute.
3560 * include/javaprims.h (_Jv_Malloc, _Jv_Free): New declarations.
3561 (_Jv_Throw): Add __noreturn__ attribute.
3562
3563 * java/net/PlainSocketImpl.java: Init fnum to -1.
3564 * java/net/ServerSocket.java: Add missing throws clauses.
3565 * java/lang/Socket.java: For the constructor taking a SocketImpl,
3566 don't call create on the latter. Instead, other constructors
3567 have to explicitly call SocketImpl.create.
3568 * java/net/natPlainSocketImpl.cc (accept): Change variable addrlen
3569 from size_t to int, to match ::accept prototype.
3570 * java/net/natInetAddress.cc: Use JvFree rather than free.
3571
3572
3573 1999-02-22 Tom Tromey <tromey@cygnus.com>
3574
3575 * include/javaprims.h: Added new classes.
3576 * java/text/StringCharacterIterator.java: New file.
3577 * java/text/CharacterIterator.java: New file.
3578
3579 * java/text/ParseException.java (errorOffset): Now private.
3580
3581 Mon Feb 22 12:54:53 1999 Per Bothner <bothner@cygnus.com>
3582
3583 * java/net: New package.
3584 * java/net/{InetAddress.java,PlainSocketImpl.java,ServerSocket.java,
3585 Socket.java,SocketException.java,SocketImpl.java,
3586 SocketImplFactory.java,UnknownHostException.java,natInetAddress.cc,
3587 natPlainSocketImpl.cc}: New classes.
3588
3589 * configure.in (AC_CHECK_HEADERS): Also check for <sys/socket.h>,
3590 <netinet.in.h>, <arpa/inet.h> and <netdb.h>.
3591 * include/config.h.in: Add place-holders for HAVE_ARPA_INET_H,
3592 HAVE_NETDB_H, HAVE_NETINET_IN_H, and HAVE_SYS_SOCKET_H.
3593
3594 * classes.pl: Translate package into "namespace", not "class".
3595 * include/javaprims.h: Update class list, using "namespace".
3596
3597 1999-02-21 Tom Tromey <tromey@cygnus.com>
3598
3599 * java/util/natGregorianCalendar.cc (_POSIX_PTHREAD_SEMANTICS):
3600 Define when appropriate.
3601
3602 1999-02-20 Tom Tromey <tromey@cygnus.com>
3603
3604 * java/lang/natString.cc (_Jv_GetStringUTFRegion): Encode \u007f
3605 as a single byte and \u07ff as two bytes.
3606 (_Jv_GetStringUTFLength): Likewise.
3607 * include/jvm.h (UTF8_GET): Mask first byte of 3-byte encoding
3608 with 0x0f, not 0x1f.
3609
3610 1999-02-19 Tom Tromey <tromey@cygnus.com>
3611
3612 * java/io/DataOutputStream.java (writeUTF): When encoding
3613 character as 3 bytes, `or' first byte with 0xe0, not 0xc0.
3614 * java/io/DataInputStream.java (readUTF): Mask second byte of
3615 3-byte character with 0x3f, not 0x1f.
3616
3617 * java/io/DataInputStream.java (readLong): Cast result of
3618 readUnsignedByte to long before using.
3619
3620 * java/io/FileInputStream.java (finalize): Only finalize `fd' if
3621 it is not null.
3622
3623 * mauve-libjava: Re-enabled java.io.DataInputOutput.
3624 * include/no-threads.h (_Jv_ThreadInterrupt): Removed name of
3625 argument to avoid warning.
3626 * include/quick-threads.h (_Jv_ThreadInterrupt): Removed name of
3627 argument to avoid warning.
3628
3629 1999-02-18 Tom Tromey <tromey@cygnus.com>
3630
3631 * mauve-libjava: Omit java.io.DataInputOutput and
3632 java.io.Utf8Encoding.
3633
3634 1999-02-17 Tom Tromey <tromey@cygnus.com>
3635
3636 * Makefile.in: Rebuilt.
3637 * Makefile.am (nat_headers): Added InterruptedIOException.h.
3638 * java/io/natFileDescriptorPosix.cc: Include
3639 InterruptedIOException.h, Thread.h.
3640 (write): Throw InterruptedIOException when required.
3641 (read): Likewise.
3642 * posix-threads.cc: Include <signal.h>.
3643 (_Jv_ThreadInterrupt): New function.
3644 (INTR): New define.
3645 (handle_intr): New function.
3646 (_Jv_InitThreads): Register handle_intr via sigaction.
3647 * java/lang/natThread.cc (interrupt): Call _Jv_ThreadInterrupt.
3648 * include/posix-threads.h (_Jv_ThreadInterrupt): Declare.
3649 * include/quick-threads.h (_Jv_ThreadInterrupt): New function.
3650 * include/no-threads.h (_Jv_ThreadInterrupt): New function.
3651
3652 1999-02-19 Andrew Haley <aph@cygnus.com>
3653
3654 * java/lang/ThreadGroup (setMaxPriority): Set the maximum priority
3655 of subgroups.
3656 (ThreadGroup (int)): Set the maximum priority of the initial
3657 ThreadGroup.
3658
3659 1999-02-18 Andrew Haley <aph@cygnus.com>
3660
3661 * java/lang/natClass.cc (forName): Check for the case where a
3662 classname is the name of an array and call FindClassFromSignature
3663 to find the Class.
3664
3665 1999-02-18 Andrew Haley <aph@cygnus.com>
3666
3667 * java/lang/StringBuffer (insert (int, String)): Move up any
3668 characters above the insert position and increase the length of
3669 the string buffer by the length of the argument.
3670 (insert (int, char[])): Likewise.
3671 (insert (int, char)): Likewise.
3672 (StringBuffer (String)): The initial capacity of the string buffer
3673 is 16 plus the length of the argument.
3674 (getChars): Add a JDK 1.2 FIXME.
3675
3676 1999-02-18 Andrew Haley <aph@cygnus.com>
3677
3678 * java/lang/Short.java (parseShort(String, int)): Pass radix to
3679 Integer.parseInt.
3680
3681 1999-02-18 Andrew Haley <aph@cygnus.com>
3682
3683 * java/lang/Double.java (equals): Use a bit-by-bit comparision
3684 instead of floating-point equality. This is necessary for
3685 correct floating-point Hashtables.
3686 * java/lang/Float.java (equals): Ditto.
3687
3688 1999-02-16 Tom Tromey <tromey@cygnus.com>
3689
3690 * java/util/Properties.java (list): Truncate value to 37
3691 characters and add "...".
3692
3693 1999-02-16 Tom Tromey <tromey@cygnus.com>
3694
3695 * java/util/Vector.java (Vector): Throw IllegalArgumentException
3696 if initCap is negative.
3697 (contains): Implement JDK1.2-style handling of null argument.
3698 (removeElement): Likewise.
3699 (indexOf): Likewise. Also, correctly handle case where idx is
3700 negative.
3701 (lastIndexOf): Likewise.
3702
3703 1999-02-16 Tom Tromey <tromey@cygnus.com>
3704
3705 * java/lang/natString.cc (init): Increment source pointer in
3706 loop.
3707
3708 1999-02-16 Tom Tromey <tromey@cygnus.com>
3709
3710 * exception.cc: Include NullPointerException.h.
3711 (_Jv_Throw): If `value' is NULL, throw a NullPointerException.
3712
3713 1999-02-16 Tom Tromey <tromey@cygnus.com>
3714
3715 * Makefile.in: Rebuilt.
3716 * Makefile.am (AUTOMAKE_OPTIONS): Added `no-installinfo.
3717
3718 Sat Feb 13 20:25:09 1999 Bonzo Armstrong <bonzo@cygnus.com>
3719
3720 * configure.in: Don't undefine EH_COMMON_INCLUDE just because
3721 we're compiling canadian.
3722 * configure: Regenerated.
3723
3724 1999-02-12 Andrew Haley <aph@cygnus.com>
3725
3726 * java/lang/sf_rint.c: Resurrected. This file shouldn't have been
3727 deleted from libgcj.
3728
3729 1999-02-12 Tom Tromey <tromey@cygnus.com>
3730
3731 * exception.cc (_Jv_eh_alloc): Use _Jv_AllocBytes, not malloc.
3732 (_Jv_eh_free): Don't call free.
3733 Don't declare malloc or free.
3734
3735 1999-02-11 Tom Tromey <tromey@cygnus.com>
3736
3737 * configure.host: Use `libgcj', not `libjava'. Removed `echo'.
3738
3739 1999-02-11 Andrew Haley <aph@cygnus.com>
3740
3741 * ef_fmod.c, sf_ceil.c, sf_fabs.c, sf_floor.c, sf_rint.c,
3742 wf_fmod.c: Deleted. These are all files from fdlibm which aren't
3743 needed by java.lang.*.
3744 * Makefile.am: ef_fmod.o, sf_ceil.o, sf_fabs.o, sf_floor.o, sf_rint.o,
3745 wf_fmod.o: Removed from libjava.a.
3746
3747 1999-02-11 Tom Tromey <tromey@cygnus.com>
3748
3749 * include/javaprims.h: Reverted previous change; with it
3750 exception.cc can't compile.
3751
3752 * include/javaprims.h (_Jv_Throw): Mark as noreturn.
3753
3754 * include/config.h.in: Rebuilt.
3755 * include/posix-threads.h (_Jv_ThreadYield): Conditionalize on
3756 HAVE_SCHED_YIELD.
3757 * configure: Rebuilt.
3758 * configure.in: Check for sched_yield. Look in thread library for
3759 all thread functions.
3760
3761 * posix-threads.cc (_Jv_MutexInit): Handle case where system has
3762 no recursive mutexes.
3763 (_Jv_MutexDestroy): Define when required.
3764 (_Jv_MutexLock): Likewise.
3765 (_Jv_MutexUnlock): Likewise.
3766 (_Jv_CondWait): Conditionalize on HAVE_RECURSIVE_MUTEX.
3767 * include/posix-threads.h (HAVE_RECURSIVE_MUTEX): New define.
3768 (_Jv_Mutex_t): New structure.
3769 (_Jv_MutexDestroy): Only define if recursive mutexes available.
3770 (_Jv_MutexLock): Likewise.
3771 (_Jv_MutexUnlock): Likewise.
3772
3773 1999-02-10 Tom Tromey <tromey@cygnus.com>
3774
3775 * aclocal.m4, configure, Makefile.in: Rebuilt.
3776 * acinclude.m4: Renamed libjava to libgcj. Updated to use
3777 automake 1.4.
3778 * configure.in: Changed to track library changes.
3779 * Makefile.am (toollib_LIBRARIES): Renamed libjava to libgcj.
3780 (AM_CXXFLAGS): Likewise.
3781 (data_DATA): Likewise.
3782 (AM_CFLAGS): Likewise.
3783 (JC1FLAGS): Likewise.
3784 (libgcj_a_SOURCES): Likewise.
3785 (EXTRA_libgcj_a_SOURCES): Likewise.
3786 (libgcj_a_DEPENDENCIES): Likewise.
3787 (libgcj_a_LIBADD): Likewise.
3788 (libgcj.zip): Likewise.
3789 (CLEANFILES): Likewise.
3790 ($(nat_headers)): Likewise.
3791 (java/lang/FirstThread.h): Likewise.
3792 (java/lang/ThreadGroup.h): Likewise.
3793 (java/lang/String.h): Likewise.
3794 (java/lang/reflect/Field.h): Likewise.
3795 (BUILT_SOURCES): Likewise.
3796 (maintainer-check): Likewise.
3797 (CONFIG_STATUS_DEPENDENCIES): Likewise.
3798 Tue Feb 9 11:06:38 1999 Anthony Green <green@cygnus.com>
3799
3800 * java/util/natGregorianCalendar.cc (computeFields): Only use
3801 gmtime_r and localtime_r when configured for posix threads.
3802
3803 * java/io/natFile.cc (get_entry): Only use readdir_r when
3804 configured for posix threads.
3805
3806 * java/util/natGregorianCalendar.cc: Update copyright notice.
3807 * java/util/TimeZone.java: Ditto.
3808 * java/util/SimpleTimeZone.java: Ditto.
3809
3810 1999-02-08 Tom Tromey <tromey@cygnus.com>
3811
3812 * java/io/PrintStream.java (line_separator): New constant.
3813 (print): Use line_separator, not `file.separator' property.
3814 (println): Use line_separator.
3815
3816 * java/lang/natClass.cc (newInstance): Throw IllegalAccessError
3817 when trying to instantiate Class.
3818
3819 * java/lang/ThreadGroup.java (ThreadGroup): Throw
3820 NullPointerException if argument is null.
3821
3822 * java/lang/Thread.java (setName): Throw NullPointerException, not
3823 IllegalArgumentException.
3824 (Thread): Likewise.
3825
3826 1999-02-08 Andrew Haley <aph@cygnus.com>
3827
3828 * java/lang/natClass.cc (newInstance): Don't allow anyone to
3829 create new Classes with Class.newInstance().
3830
3831 * java/lang/natClass.cc (_Jv_FindArrayClass): Only add a
3832 semiciolon to end of an array Class's signature if the elements of
3833 the array aren't themselves arrays.
3834
3835 * java/lang/natSystem.cc (arraycopy): The size of an element of an
3836 array of objects is always sizeof(jobject), not the size of the
3837 object to which the reference points.
3838
3839 1999-02-08 Tom Tromey <tromey@cygnus.com>
3840
3841 * java/util/BitSet.java (and): Throw NullPointerException when
3842 required.
3843 (or): Likewise.
3844 (xor): Likewise.
3845
3846 * java/util/BitSet.java (BitSet): Throw NegativeArraySizeException
3847 if argument is negative.
3848 (clear): Correctly compute `offset'. Throw
3849 IndexOutOfBoundsException when required.
3850 (set): Likewise.
3851 (get): Likewise. Also, return correct value.
3852 (ensure): Changed meaning of argument.
3853 (toString): Wrap contents in `{}'; put spaces after commas.
3854 (hashCode): Don't try to examine elements off the end of array.
3855 (or): Correctly include bits past the end of this bit set.
3856 (xor): Likewise.
3857
3858 Thu Feb 4 12:48:03 1999 Warren Levy <warrenl@cygnus.com>
3859
3860 * configure.host (mips-tx39-*): Use jmr3904dram.ld link script
3861 instead of the jmr3904app.ld script (i.e. use DRAM instead of SRAM).
3862
3863 1999-02-04 Andrew Haley <aph@cygnus.com>
3864
3865 * java/lang/natClass.cc (Class::forName): Remove code which mapped
3866 '/' in signatures to '.'
3867 (Class::getName): Likewise,
3868 (_Jv_FindArrayClass): Add a semiciolon to end of an array Class's
3869 signature.
3870 * java/lang/natFirstThread.cc (run): Change '/' in main's
3871 signature to '.'.
3872
3873 1999-02-03 Andrew Haley <aph@cygnus.com>
3874
3875 * configure.host: -ffloat-store added when compiling libjava on
3876 x86. fdlibm apparently relies on this.
3877
3878 * java/lang/ThreadGroup.java (add): throw an exception if the
3879 ThreadGroup has been destroyed.
3880
3881 * java/lang/natMath.cc (round): Ensure correct NaN and overflow
3882 behaviour.
3883
3884 1999-01-27 Tom Tromey <tromey@cygnus.com>
3885
3886 * java/lang/StringBuffer.java (StringBuffer): Handle null
3887 argument.
3888
3889 1999-01-21 Tom Tromey <tromey@cygnus.com>
3890
3891 * java/lang/natFirstThread.cc (run): Don't require main to be
3892 public.
3893
3894 Wed Jan 20 15:44:56 1999 Anthony Green <green@cygnus.com>
3895
3896 * boehm.cc (_Jv_InitGC): Clear out the free lists correctly.
3897
3898 1999-01-20 Tom Tromey <tromey@cygnus.com>
3899
3900 * java/lang/natString.cc (_Jv_StringFindSlot): Synchronize on
3901 StringClass.
3902 (rehash): Likewise.
3903 (intern): Likewise.
3904 (unintern): Likewise.
3905 (_Jv_NewStringUtf8Const): Likewise.
3906
3907 * java/text/SimpleDateFormat.java (format): Use [a-zA-z], not
3908 Character.isLetter, to see if character is self-quoting. Also,
3909 correctly handle quoted characters.
3910 (parse): Fixed typo. Also now throws ParseException.
3911
3912 1999-01-15 Tom Tromey <tromey@cygnus.com>
3913
3914 * java/lang/natObject.cc (INIT_NEEDED): Added missing close paren.
3915
3916 * java/lang/natObject.cc (INIT_NEEDED): Added cast in case where
3917 _Jv_SyncInfo has `init' member.
3918
3919 * include/quick-threads.h (_Jv_MutexUnlock): Return result of
3920 coop_mutex_unlock.
3921
3922 * java/lang/natObject.cc (_Jv_MonitorExit): Throw
3923 IllegalMonitorStateException if unlock fails.
3924
3925 * prims.cc (_Jv_NewPrimArray): Assume allocated memory is all
3926 zero.
3927 (_Jv_NewObjectArray): Likewise.
3928
3929 1999-01-14 Tom Tromey <tromey@cygnus.com>
3930
3931 * java/lang/Character.java (isJavaIdentifierPart): Allow
3932 LETTER_NUMBER characters.
3933
3934 * chartables.pl (process_char): Fixed error messages.
3935
3936 * include/java-chartables.h: Rebuilt with UniData 2.1.8.
3937 * chartables.pl: Updated comments. Changed detection of non-digit
3938 numeric values (no longer miss \u00b2 and friends).
3939
3940 * java/lang/Character.java (isJavaIdentifierPart): Recognize
3941 currency symbols and connector punctuation.
3942 (isIdentifierIgnorable): Make 7f-9f ignorable.
3943
3944 * prims.cc (_Jv_NewObjectArray): Check for overflow.
3945 (_Jv_NewPrimArray): Likewise.
3946 (SIZE_T_MAX): New define.
3947
3948 * java/lang/ClassLoader.java (system): Now private and final.
3949
3950 * boehm.cc (_Jv_MarkObj): Handle case where object's class is
3951 null.
3952
3953 * configure: Rebuilt.
3954 * configure.in (EH_COMMON_INCLUDE): Add -I for `../include' as
3955 well.
3956 * exception.cc: Include gansidecl.h.
3957
3958 1999-01-14 Andrew Haley <aph@cygnus.com>
3959
3960 * java/lang/Math.java, java/lang/natMath.cc: min and max routines
3961 corrected: they didn't treat -0.0 and NaNs correctly.
3962
3963 Wed Jan 13 13:32:22 1999 Anthony Green <green@cygnus.com>
3964
3965 * nogc.cc: Use calloc to zero out memory.
3966
3967 1999-01-11 Tom Tromey <tromey@cygnus.com>
3968
3969 * java/lang/natClass.cc (isInstance): Return false if this class
3970 is primitive, not if class of `obj' is primitive.
3971 (_Jv_IsInstanceOf): Rewrote to use Class.isInstance.
3972
3973 * java/io/SequenceInputStream.java (close): Handle case where `in'
3974 is already null.
3975
3976 * java/text/DateFormat.java (format): New method.
3977
3978 * mauve-libjava: Omit java.text.DateFormat.
3979
3980 1999-01-08 Tom Tromey <tromey@cygnus.com>
3981
3982 * posix-threads.cc (_Jv_ThreadInitData): Removed name of unused
3983 argument.
3984 * include/posix-threads.h (_Jv_CondNotify): Removed name of unused
3985 argument.
3986 (_Jv_CondNotifyAll): Likewise.
3987
3988 * configure: Rebuilt.
3989 * configure.in: Change --enable-source-compilation logic to work
3990 correctly.
3991
3992 1999-01-07 Andrew Haley <aph@cygnus.co.uk>
3993
3994 * Makefile.am (AM_MAKEFLAGS): Remove RUNTEST, EXPECT,
3995 and RUNTESTFLAGS from AM_MAKEFLAGS.
3996 * configure.in: AM_RUNTESTFLAGS added.
3997 * configure.host: AM_RUNTESTFLAGS added.
3998 * Makefile.in, test/Makefile.in, testsuite/Makefile.in: rebuilt.
3999 * configure: rebuilt.
4000 * testsuite/Makefile.am: RUNTESTFLAGS set from AM_RUNTESTFLAGS.
4001
4002 * testsuite/libjava.mauve/DejaGNUTestHarness.java (main): use of
4003 argv[] made conditional because embedded targets may not have
4004 argv[].
4005 * testsuite/libjava.mauve/DejaGNUTestHarness.java (main):
4006 explanatory comments added in call to super.
4007
4008 * testsuite/libjava.mauve/test.exp (test_mauve): Test for an
4009 exception thrown in the test harness itself added.
4010 * testsuite/libjava.mauve/test.exp (test_mauve_sim): New routine.
4011
4012 Wed Jan 6 17:27:39 1999 Per Bothner <bothner@cygnus.com>
4013
4014 * java/text/DateFormatSymbols.java (zoneStringsDefault): Make static.
4015
4016 1999-01-06 Tom Tromey <tromey@cygnus.com>
4017
4018 * java/io/natFile.cc (get_entry): New function.
4019 (performList): Use get_entry.
4020 * include/config.h.in: Rebuilt.
4021 * acconfig.h (HAVE_READDIR_R): New define.
4022 * configure: Rebuilt.
4023 * configure.in: Look for readdir_r.
4024
4025 * java/util/natGregorianCalendar.cc (computeFields): Fixed comment.
4026
4027 * java/util/natDate.cc: Added copyright header.
4028
4029 1999-01-05 Tom Tromey <tromey@cygnus.com>
4030
4031 * include/config.h.in: Rebuilt.
4032 * acconfig.h (HAVE_ACCESS, HAVE_STAT, HAVE_REALPATH, HAVE_MKDIR,
4033 HAVE_REALPATH, HAVE_RMDIR, HAVE_UNLINK): New macros.
4034 * configure: Rebuilt.
4035 * configure.in: Check for access, stat, mkdir, rename, rmdir,
4036 unlink, and realpath.
4037 * java/io/natFile.cc (access): Conditionalize on HAVE_ACCESS.
4038 (stat): Conditionalize on HAVE_STAT.
4039 (attr): Likewise.
4040 (getCanonicalPath): Conditionalize on HAVE_REALPATH.
4041 (performMkdir): Conditionalize on HAVE_MKDIR.
4042 (performRenameTo): Conditionalize on HAVE_RENAME.
4043 (performDelete): Conditionalize on HAVE_RMDIR and HAVE_UNLINK.
4044
4045 * include/config.h.in: Rebuilt.
4046 * acconfig.h (HAVE_GMTIME_R, HAVE_LOCALTIME_R): New defines.
4047 * configure: Rebuilt.
4048 * configure.in: Check for gmtime_r and localtime_r. For cross
4049 builds, assume they exist.
4050
4051 * mauve-libjava: Include java.text.DateFormatSymbols again.
4052 * java/text/DateFormatSymbols.java (setLocalPatternChars): Renamed
4053 from setAmPmStrings.
4054
4055 * mauve-libjava: Omit java.text.DateFormatSymbols.
4056
4057 1999-01-04 Tom Tromey <tromey@cygnus.com>
4058
4059 * java/io/PushbackReader.java: `off' already includes `numBytes'.
4060
4061 * java/io/LineNumberReader.java (read): Decrement `count' in
4062 loop.
4063
4064 * java/io/BufferedWriter.java (write): Correctly determine when
4065 incoming data would overrun buffer. Flush buffer if write causes
4066 it to become full.
4067
4068 * java/io/BufferedOutputStream.java (write): Increment `count'
4069 after copying data into buffer.
4070
4071 * java/io/FilterOutputStream.java (close): Call flush first.
4072
4073 * java/io/PipedReader.java (read): If read causes `out' to catch
4074 up with `in', then set `in' to -1.
4075
4076 * java/io/LineNumberInputStream.java (read): If no bytes read,
4077 return -1. If no bytes requested, return 0.
4078
4079 * java/lang/StringBuffer.java (insert): If `str' is null, use
4080 string "null".
4081
4082 1998-12-30 Anthony Green <green@cygnus.com>
4083
4084 * README: Removed.
4085 * LIBJAVA_LICENSE, COPYING.LIB: Created.
4086
4087 1998-12-23 Tom Tromey <tromey@cygnus.com>
4088
4089 * java/io/PushbackInputStream.java (read): `off' already includes
4090 `numBytes'.
4091
4092 1998-12-17 Tom Tromey <tromey@cygnus.com>
4093
4094 * Makefile.in: Rebuilt.
4095 * Makefile.am (GCJ_canadian): Include target_alias.
4096
4097 * java/lang/natFirstThread.cc (run): Require main's class to be
4098 public.
4099
4100 1998-12-16 Tom Tromey <tromey@cygnus.com>
4101
4102 * java/util/Locale.java (JAPAN): Language is `ja', not `jp'.
4103
4104 * java/util/ResourceBundle.java (getBundle): Throw
4105 NullPointerException if locale argument is null.
4106
4107 * java/lang/natClass.cc (forName): Throw NullPointerException if
4108 argument is null.
4109 Include NullPointerException.h.
4110
4111 1998-12-14 Tom Tromey <tromey@cygnus.com>
4112
4113 * java/lang/Character.java (Character): Implement Comparable.
4114 (compareTo): New methods.
4115
4116 * java/util/Locale.java (CANADA, FRANCE, JAPAN): Now `final'. Use
4117 correct country and language codes.
4118 (UK, US): New constants.
4119 (setDefault): Language codes are lower-case.
4120
4121 * java/lang/natClass.cc (getDeclaredConstructor): New method.
4122 (getDeclaredConstructors): Likewise.
4123 (getDeclaredField): Likewise.
4124 (getDeclaredFields): Likewise.
4125 (getDeclaredMethod): Likewise.
4126 (getDeclaredMethods): Likewise.
4127 (getField): Likewise.
4128 (getFields): Likewise.
4129 (getMethod): Likewise.
4130 (getMethods): Likewise.
4131 * java/lang/Class.java: Declare new methods.
4132 * java/lang/Class.h: Declare new methods.
4133
4134 * java/lang/natString.cc: Removed `#pragma implementation'.
4135 * include/cni.h (_Jv_GetStringChars): New function.
4136 * Makefile.in: Rebuilt.
4137 * Makefile.am (java/lang/String.h): Don't generate definition for
4138 _Jv_GetStringChars.
4139
4140 * java/lang/natString.cc: Added `#pragma implementation'.
4141
4142 * Makefile.in: Rebuilt.
4143 * Makefile.am (libjava.zip): Put build directory first in class
4144 path to avoid bug in compiler.
4145
4146 1998-12-14 Anthony Green <green@cygnus.com>
4147
4148 * java/util/Locale.java: Add CANADA, FRANCE and JAPAN.
4149
4150 * include/javaprims.h: Add EventObject, ListResourceBundle and
4151 ResourceBundle.
4152
4153 1998-12-13 Anthony Green <green@cygnus.com>
4154
4155 * mauve-libjava: Run the ResourceBundle tests.
4156
4157 * java/lang/natClass.cc (_Jv_FindClass): Don't fail when loader is
4158 NULL.
4159
4160 Sun Dec 13 18:11:21 1998 Per Bothner <bothner@cygnus.com>
4161
4162 * configure.in, configure: Make --enable-gcj-classes and
4163 --enable-source-compilation the default. (Nervously...) Yeah!
4164 Based on a patch from Tom Tromey.
4165
4166 1998-12-13 Tom Tromey <tromey@cygnus.com>
4167
4168 * java/util/EventObject.java: New file.
4169 * java/util/EventListener.java: New file.
4170
4171 * include/javaprims.h: Updated class declarations.
4172 * Makefile.in: Rebuilt.
4173 * Makefile.am (nat_headers): Added Constructor.h.
4174 (java/lang/String.h): Don't inline String::length().
4175 * java/lang/Class.h (getConstructor, getConstructors): Declare.
4176 * java/lang/Class.java (initializeClass, hackRunInitializers,
4177 hackTrampoline): No need to mark `final'.
4178 (getConstructor, getConstructors): Declare.
4179 * java/lang/reflect/Field.java (equals): New method.
4180 * java/lang/natClass.cc (getConstructor): New method.
4181 (getConstructors): Likewise.
4182 Include Method.h, Field.h, Constructor.h.
4183 * java/lang/reflect/Constructor.java: New file.
4184 * java/lang/reflect/Method.java (toString): No space before open
4185 paren.
4186 (equals): Simplified.
4187
4188 1998-12-13 Anthony Green <green@cygnus.com>
4189
4190 * java/util/ResourceBundle.java: New file.
4191 * java/util/ListResourceBundle.java: New file.
4192
4193 1998-12-12 Tom Tromey <tromey@cygnus.com>
4194
4195 * java/lang/System.java (in, out, err): Now buffered streams by
4196 default.
4197
4198 * include/javaprims.h: Updated class declarations.
4199 * Makefile.in: Rebuilt.
4200 * Makefile.am (nat_headers): Added AccessibleObject.h, Method.h,
4201 InvocationTargetException.h, Void.h, Byte.h, Short.h, Integer.h,
4202 Long.h, Boolean.h.
4203 (nat_files): Added natMethod.o.
4204 * java/lang/reflect/natMethod.cc: New file.
4205 * java/lang/reflect/Field.java (Field): Now extends
4206 AccessibleObject.
4207 * java/lang/reflect/AccessibleObject.java: New file.
4208 * java/lang/reflect/InvocationTargetException.java: New file.
4209
4210 1998-12-11 Tom Tromey <tromey@cygnus.com>
4211
4212 * boehm.cc, prims.cc, include/jvm.h, java/lang/Class.h,
4213 java/lang/Object.h, java/lang/natClass.cc, java/lang/natObject.cc:
4214 Renamed dtable -> vtable and _Jv_DispatchTable -> _Jv_VTable.
4215
4216 * java/io/OutputStreamWriter.java (buffer): Size at 8192 bytes.
4217
4218 1998-12-09 Tom Tromey <tromey@cygnus.com>
4219
4220 * java/util/natDate.cc (_POSIX_THREAD_SEMANTICS): Define if
4221 HAVE_CTIME_R.
4222
4223 * java/lang/natCharacter.cc (toTitleCase): Handle case where
4224 character is already titlecase.
4225
4226 * java/lang/Character.java (isJavaLetter): Follow spec.
4227 (isJavaLetterOrDigit): Likewise.
4228
4229 * java/util/GregorianCalendar.java (gregorianCutover): Append
4230 `L'.
4231
4232 * java/lang/Character.java (isWhitespace): Use \r and not \u000d.
4233
4234 1998-12-08 Tom Tromey <tromey@cygnus.com>
4235
4236 * java/lang/reflect/Modifier.java (toString): Replace second
4237 `static' with `synchronized'.
4238
4239 * java/lang/natObject.cc (_Jv_FinalizeObject): Call hack12_6.
4240 * java/lang/Object.h (Object::hack12_6): Declare.
4241 * java/lang/Object.java (hack12_6): New function.
4242
4243 1998-12-07 Tom Tromey <tromey@cygnus.com>
4244
4245 * include/java-array.h (__JArray::clone): Removed decl.
4246 * prims.cc (__JArray::clone): Removed.
4247 * java/lang/natObject.cc (clone): Incorporate code to clone an
4248 array.
4249
4250 * java/lang/natClass.cc (_Jv_NewClass): Set class loader.
4251 (_Jv_FindArrayClass): Set dtable_method_count on new class.
4252 Correctly use dtable_method_count.
4253
4254 1998-12-07 Andrew Haley <aph@cygnus.co.uk>
4255
4256 * java/lang/Double.java (isInfinite, isNaN): Handle correct
4257 IEEE754 values.
4258
4259 1998-12-06 Anthony Green <green@cygnus.com>
4260
4261 * mauve-libjava: Don't test ResourceBundle.
4262
4263 1998-12-04 Tom Tromey <tromey@cygnus.com>
4264
4265 More JDK 1.2 spec fixes:
4266 * java/util/Date.java (millis): Now private.
4267 * java/text/DateFormat.java (DateFormat): Constructor now
4268 protected.
4269 * java/lang/Void.java (Void): New private constructor.
4270 * java/lang/System.java (System): New private constructor.
4271 * java/lang/SecurityManager.java (classLoaderDepth): Uncommented
4272 body.
4273 (currentClassLoader): New method.
4274 (currentLoadedClass): New method.
4275 * java/lang/Math.java (Math): New private constructor.
4276 * java/lang/Compiler.java (Compiler): New private constructor.
4277 * java/lang/Class.java (Class): New private constructor.
4278 * java/lang/Double.java (toString): Removed access specifier from
4279 two-argument `toString' method.
4280
4281 1998-12-04 Andrew Haley <aph@cygnus.co.uk>
4282
4283 * java/lang/s_rint.c (rint): Make the variable w volatile; this
4284 causes it to be flushed from an fp register (where it may be
4285 longer than double precision) to a double in memory. This is
4286 essential to ensure correct rounding behaviour.
4287
4288 1998-12-04 Tom Tromey <tromey@cygnus.com>
4289
4290 * include/java-assert.h (_Jv_Abort): Declare as `noreturn'
4291 function.
4292
4293 * java/lang/Character.java (isIdentifierIgnorable): Added comment
4294 explaining apparent divergence from JDK 1.2.
4295
4296 1998-12-04 Per Bothner <bothner@cygnus.com>
4297
4298 * include/no-threads.h: Remove unused parameter names.
4299 This silences a bunch of warnings.
4300
4301 1998-12-04 Tom Tromey <tromey@cygnus.com>
4302
4303 * include/config.h.in: Rebuilt.
4304 * acconfig.h (HAVE_CTIME_R): New symbol.
4305
4306 1998-12-03 Tom Tromey <tromey@cygnus.com>
4307
4308 * mauve-libjava: Added many more categories to reject.
4309
4310 Changes to follow JDK1.2 spec:
4311 * java/lang/System.java (arraycopy, init_properties, checkSetIO,
4312 setErr, setIn, setOut): No need to be `final'.
4313 * java/lang/natObject.cc (wait): `nanos' argument is an int.
4314 * java/lang/Object.h (Object::wait): `nanos' argument is an int.
4315 * java/lang/Object.java (wait): `nanos' argument is an int.
4316 * java/lang/VirtualMachineError.java: Class is abstract.
4317 * java/lang/ThreadDeath.java: Made constructors public.
4318 * java/io/FileDescriptor.java (FileDescriptor): Added missing
4319 constructor.
4320
4321 Thu Dec 3 20:29:38 1998 Warren Levy <warrenl@cygnus.com>
4322
4323 * java/text/DateFormatSymbols.java (getAmPmStrings,
4324 getLocalPatternChars, setShortWeekdays): Fixed typos in method names.
4325
4326 Thu Dec 3 19:21:53 1998 Warren Levy <warrenl@cygnus.com>
4327
4328 * java/io/RandomAccessFile.java (writeInt, writeLong, writeFloat,
4329 writeDouble, writeByte, writeBytes, writeChar, writeChars,
4330 writeShort, writeUTF): Added 'final' to signature to match JDK 1.1
4331 and 1.2.
4332
4333 * java/lang/IllegalThreadStateException.java
4334 (IllegalThreadStateException): Changed extending class to match spec.
4335
4336 * java/lang/NumberFormatException.java
4337 (java/lang/NumberFormatException): Changed extending class to match
4338 spec.
4339
4340 * java/util/Observer.java (Observer): Changed sig to match JCL.
4341
4342 Thu Dec 3 19:05:26 1998 Warren Levy <warrenl@cygnus.com>
4343
4344 * java/io/DataOutputStream.java (writeInt, writeLong, writeFloat,
4345 writeDouble, writeBytes, writeChars, writeUTF): Added 'final' to
4346 signature to match JDK 1.1 and 1.2.
4347
4348 Thu Dec 3 16:47:42 1998 Warren Levy <warrenl@cygnus.com>
4349
4350 * Makefile.am: Changed to use $(PERL) rather than hardcoded 'perl'.
4351 * configure.in (PERL): Added AC_CHECK_PROGS to look for installed perl.
4352 * Makefile.in, configure: Rebuilt.
4353
4354 * java/text/ParsePosition.java (setErrorIndex): Fixed typo in method
4355 name.
4356
4357 1998-12-02 Tom Tromey <tromey@cygnus.com>
4358
4359 * mauve-libjava: New file.
4360
4361 The remaining `-W -Wall' fixes:
4362 * java/lang/e_sqrt.c (__ieee754_sqrt): Added cast to unsigned to
4363 avoid warning.
4364 * java/lang/s_scalbn.c (scalbn): Added braces to avoid ambiguous
4365 `else'.
4366 * java/lang/s_floor.c (floor): Added cast to unsigned to avoid
4367 warning.
4368 * java/lang/e_pow.c (__ieee754_pow): Added cast to unsigned to
4369 avoid warning.
4370 * java/lang/e_log.c (__ieee754_log): Added braces to avoid
4371 ambiguous `else'.
4372 * java/lang/s_ceil.c (ceil): Cast `i1' to unsigned to avoid
4373 warning.
4374 * java/lang/e_atan2.c (__ieee754_atan2): Added parentheses per gcc
4375 suggestion.
4376 * java/lang/strtod.c (_strtod_r): Added parentheses per gcc
4377 suggestion.
4378 * java/lang/mprec.c (Balloc): Removed unused variable.
4379 (mult): Added parentheses per gcc suggestion.
4380 (pow5mult): Likewise.
4381 (lshift): Likewise.
4382 (ulp): Likewise.
4383 (b2d): Likewise.
4384 (d2b): Likewise.
4385 * java/lang/dtoa.c (_dtoa_r): Added some parentheses per gcc
4386 suggestion. Added cast to `int' to avoid signed/unsigned
4387 comparison.
4388 * jni.cc (_Jv_JNI_GetSuperclass): Removed name of unused
4389 parameter.
4390 (IsAssignableFrom): Likewise.
4391 (_Jv_JNI_GetObjectField): Likewise.
4392 (_Jv_JNI_GetByteField): Likewise.
4393 (_Jv_JNI_GetShortField): Likewise.
4394 (_Jv_JNI_GetIntField): Likewise.
4395 (_Jv_JNI_GetLongField): Likewise.
4396 (_Jv_JNI_GetStringLength): Likewise.
4397 (_Jv_JNI_ToReflectedField): Likewise.
4398 (_Jv_JNI_FromReflectedField): Likewise.
4399 (_Jv_JNIFunctions): Uncommented IsAssignableFrom.
4400
4401 * Makefile.in: Rebuilt.
4402 * Makefile.am (AM_CFLAGS): Define conditionally.
4403 (WARNINGS): New macro.
4404 (AM_CXXFLAGS): Include WARNINGS.
4405 * configure: Rebuilt.
4406 * configure.in (USING_GCC): New conditional.
4407
4408 * prims.cc (_Jv_Abort): Declare twice, to avoid warnings.
4409
4410 * java/lang/Character.java: Changed classification constants to
4411 type `byte' to match JDK 1.2 docs.
4412
4413 1998-12-01 Tom Tromey <tromey@cygnus.com>
4414
4415 Some fixes to be `-W -Wall' clean:
4416 * boehm.cc (_Jv_MarkObj): Removed name of unused parameter.
4417 (_Jv_MarkArray): Likewise.
4418 * java/lang/natCharacter.cc (to_lower_title): `i' is unsigned.
4419 (to_upper_title): Likewise.
4420 (isTitleCase): Likewise.
4421 (toTitleCase): Likewise.
4422 (getNumericValue): Likewise.
4423 (isLowerCase): Likewise.
4424 * java/lang/natString.cc (charAt): Don't cast `i' to unsigned
4425 (avoids compiler warning).
4426 * java/lang/natClass.cc (getDeclaredClasses): Always return a
4427 value.
4428 (getDeclaringClass): Likewise.
4429 (_Jv_LookupInterfaceMethod): Likewise.
4430 (_Jv_NewClass): Removed name of unused parameter.
4431 * exception.cc (_Jv_type_matcher): Removed unused variable.
4432 (_Jv_setup_eh_info): Removed name of unused parameter.
4433 * prims.cc (_Jv_NewArray): Always return a value.
4434 (_Jv_FindClassFromSignature): Likewise.
4435 * include/java-field.h (getNameUtf8Const): Removed name of unused
4436 parameter.
4437 * include/quick-threads.h (_Jv_ThreadInitData): Removed name of
4438 unused parameter.
4439 (_Jv_ThreadSetPriority): Likewise.
4440
4441 * java/lang/natString.cc (hashChars): Now static.
4442
4443 * java/lang/FirstThread.java (FirstThread): Now final.
4444
4445 * java/io/File.java (performMkdir, performRenameTo): Now private.
4446
4447 * java/lang/natSystem.cc (currentTimeMillis): Return a value even
4448 if no time function defined.
4449
4450 * configure: Rebuilt.
4451 * configure.in: Look for ctime_r, ctime.
4452 * java/util/Date.java (toString): Now native.
4453 * java/util/natDate.cc (toString): Rewrote.
4454
4455 1998-11-27 Andrew Haley <aph@viagra.cygnus.co.uk>
4456
4457 * Add LDFLAGS line to allow TX39 test cases to link when cross
4458 compiling.
4459
4460 1998-11-23 Anthony Green <green@cygnus.com>
4461
4462 * boehm.cc, chartables.pl, classes.pl, exception.cc, jni.cc,
4463 no-threads.cc, nogc.cc, posix-threads.cc, prims.cc,
4464 quick-threads.cc, include/boehm-gc.h, include/cni.h,
4465 include/java-array.h, include/java-assert.h, include/java-field.h,
4466 include/javaprims.h, include/jni.h, include/jvm.h,
4467 include/no-gc.h, include/no-threads.h, include/posix-threads.h,
4468 include/quick-threads.h, java/io/BufferedInputStream.java,
4469 java/io/BufferedOutputStream.java, java/io/BufferedReader.java,
4470 java/io/BufferedWriter.java, java/io/ByteArrayInputStream.java,
4471 java/io/ByteArrayOutputStream.java, java/io/CharArrayReader.java,
4472 java/io/CharArrayWriter.java,
4473 java/io/CharConversionException.java, java/io/DataInput.java,
4474 java/io/DataInputStream.java, java/io/DataOutput.java,
4475 java/io/DataOutputStream.java, java/io/EOFException.java,
4476 java/io/File.java, java/io/FileDescriptor.java,
4477 java/io/FileInputStream.java, java/io/FileNotFoundException.java,
4478 java/io/FileOutputStream.java, java/io/FileReader.java,
4479 java/io/FileWriter.java, java/io/FilenameFilter.java,
4480 java/io/FilterInputStream.java, java/io/FilterOutputStream.java,
4481 java/io/FilterReader.java, java/io/FilterWriter.java,
4482 java/io/IOException.java, java/io/InputStream.java,
4483 java/io/InputStreamReader.java,
4484 java/io/InterruptedIOException.java,
4485 java/io/LineNumberInputStream.java, java/io/LineNumberReader.java,
4486 java/io/OutputStream.java, java/io/OutputStreamWriter.java,
4487 java/io/PipedInputStream.java, java/io/PipedOutputStream.java,
4488 java/io/PipedReader.java, java/io/PipedWriter.java,
4489 java/io/PrintStream.java, java/io/PrintWriter.java,
4490 java/io/PushbackInputStream.java, java/io/PushbackReader.java,
4491 java/io/RandomAccessFile.java, java/io/Reader.java,
4492 java/io/SequenceInputStream.java, java/io/Serializable.java,
4493 java/io/StreamTokenizer.java,
4494 java/io/StringBufferInputStream.java, java/io/StringReader.java,
4495 java/io/StringWriter.java, java/io/SyncFailedException.java,
4496 java/io/UTFDataFormatException.java,
4497 java/io/UnsupportedEncodingException.java, java/io/Writer.java,
4498 java/io/natFile.cc, java/io/natFileDescriptorEcos.cc,
4499 java/io/natFileDescriptorPosix.cc,
4500 java/lang/AbstractMethodError.java,
4501 java/lang/ArithmeticException.java,
4502 java/lang/ArrayIndexOutOfBoundsException.java,
4503 java/lang/ArrayStoreException.java, java/lang/Boolean.java,
4504 java/lang/Byte.java, java/lang/Character.java, java/lang/Class.h,
4505 java/lang/Class.java, java/lang/ClassCastException.java,
4506 java/lang/ClassCircularityError.java,
4507 java/lang/ClassFormatError.java, java/lang/ClassLoader.java,
4508 java/lang/ClassNotFoundException.java,
4509 java/lang/CloneNotSupportedException.java,
4510 java/lang/Cloneable.java, java/lang/Comparable.java,
4511 java/lang/Compiler.java, java/lang/Double.java,
4512 java/lang/Error.java, java/lang/Exception.java,
4513 java/lang/ExceptionInInitializerError.java,
4514 java/lang/FirstThread.java, java/lang/Float.java,
4515 java/lang/IllegalAccessError.java,
4516 java/lang/IllegalAccessException.java,
4517 java/lang/IllegalArgumentException.java,
4518 java/lang/IllegalMonitorStateException.java,
4519 java/lang/IllegalStateException.java,
4520 java/lang/IllegalThreadStateException.java,
4521 java/lang/IncompatibleClassChangeError.java,
4522 java/lang/IndexOutOfBoundsException.java,
4523 java/lang/InstantiationError.java,
4524 java/lang/InstantiationException.java, java/lang/Integer.java,
4525 java/lang/InternalError.java, java/lang/InterruptedException.java,
4526 java/lang/LinkageError.java, java/lang/Long.java,
4527 java/lang/Math.java, java/lang/NegativeArraySizeException.java,
4528 java/lang/NoClassDefFoundError.java,
4529 java/lang/NoSuchFieldError.java,
4530 java/lang/NoSuchFieldException.java,
4531 java/lang/NoSuchMethodError.java,
4532 java/lang/NoSuchMethodException.java,
4533 java/lang/NullPointerException.java, java/lang/Number.java,
4534 java/lang/NumberFormatException.java, java/lang/Object.h,
4535 java/lang/Object.java, java/lang/OutOfMemoryError.java,
4536 java/lang/Process.java, java/lang/Runnable.java,
4537 java/lang/Runtime.java, java/lang/RuntimeException.java,
4538 java/lang/SecurityException.java, java/lang/SecurityManager.java,
4539 java/lang/Short.java, java/lang/StackOverflowError.java,
4540 java/lang/String.java, java/lang/StringBuffer.java,
4541 java/lang/StringIndexOutOfBoundsException.java,
4542 java/lang/System.java, java/lang/Thread.java,
4543 java/lang/ThreadDeath.java, java/lang/ThreadGroup.java,
4544 java/lang/Throwable.java, java/lang/UnknownError.java,
4545 java/lang/UnsatisfiedLinkError.java,
4546 java/lang/UnsupportedOperationException.java,
4547 java/lang/VerifyError.java, java/lang/VirtualMachineError.java,
4548 java/lang/Void.java, java/lang/natCharacter.cc,
4549 java/lang/natClass.cc, java/lang/natDouble.cc,
4550 java/lang/natFirstThread.cc, java/lang/natFloat.cc,
4551 java/lang/natMath.cc, java/lang/natObject.cc,
4552 java/lang/natRuntime.cc, java/lang/natString.cc,
4553 java/lang/natSystem.cc, java/lang/natThread.cc,
4554 java/lang/reflect/Field.java, java/lang/reflect/Member.java,
4555 java/lang/reflect/Modifier.java, java/lang/reflect/natField.cc,
4556 java/text/DateFormat.java, java/text/DateFormatSymbols.java,
4557 java/text/FieldPosition.java, java/text/Format.java,
4558 java/text/NumberFormat.java, java/text/ParseException.java,
4559 java/text/ParsePosition.java, java/text/SimpleDateFormat.java,
4560 java/util/BitSet.java, java/util/Calendar.java,
4561 java/util/ConcurrentModificationException.java,
4562 java/util/Date.java, java/util/Dictionary.java,
4563 java/util/EmptyStackException.java, java/util/Enumeration.java,
4564 java/util/GregorianCalendar.java, java/util/Hashtable.java,
4565 java/util/Locale.java, java/util/MissingResourceException.java,
4566 java/util/NoSuchElementException.java, java/util/Observable.java,
4567 java/util/Observer.java, java/util/Properties.java,
4568 java/util/Random.java, java/util/SimpleTimeZone.java,
4569 java/util/Stack.java, java/util/StringTokenizer.java,
4570 java/util/TimeZone.java, java/util/TooManyListenersException.java,
4571 java/util/Vector.java, java/util/natGregorianCalendar.cc: Updated
4572 copyright notices.
4573
4574 * exception.cc: Include eh-common.h instead of duplicating
4575 code.
4576
4577 1998-11-23 Tom Tromey <tromey@cygnus.com>
4578
4579 * configure.host: Don't add `-O2' to libjava_flags. Only add
4580 `-Os' to libjava_flags once.
4581
4582 1998-11-17 Andrew Haley <aph@viagra.cygnus.co.uk>
4583
4584 * Makefile.am: add LIBJAVA_JAVAFLAGS.
4585 * Makefile.in: likewise
4586 * acconfig.h: add ECOS conditional for configure.h
4587 * config.h.in: likewise
4588 * configure: add test for --with-ecos
4589 * configure.in: likewise
4590 * java/io/natFileDescriptorEcos.cc (java::io::FileDescriptor::write):
4591 rename call to avoid name clash.
4592 * java/lang/natSystem.cc: add eCos clock support.
4593 * java/util/natGregorianCalendar.cc: add eCos support.
4594
4595 1998-11-20 Andrew Haley <aph@viagra.cygnus.co.uk>
4596
4597 * Makefile.am, Makefile.in, configure.host: tx39 build option
4598 "-G 0" added.
4599
4600 Wed Nov 18 18:55:25 1998 Warren Levy <warrenl@cygnus.com>
4601
4602 * java/io/BufferedReader.java: Added more comments for clarity.
4603 (mark): Used more mnemonic name for local var extraBuffSpace.
4604
4605 * java/io/LineNumberReader.java (lineEnd): Removed method to avoid
4606 confusion with private method of same name in superclass.
4607 (skipRedundantLF): Set fields in special case to avoid infinite
4608 recursion. Check if markPos has been invalidated in special case.
4609 (readLine): Rewritten to use readLine method of superclass.
4610 (skip): Incorporated code from lineEnd.
4611
4612 Wed Nov 18 02:46:03 1998 Warren Levy <warrenl@cygnus.com>
4613
4614 * java/io/BufferedReader.java (readLine): New method.
4615 (lineEnd): new private method.
4616 (mark): Track special case for readLine of getting '\r' at the
4617 end of the buffer.
4618 (reset): Ditto.
4619 (read): Ditto.
4620 (fill): Ditto.
4621 (skip): Ditto.
4622
4623 * java/io/InputStreamReader.java (read): Return number chars skipped
4624 rather than requested.
4625
4626 * java/lang/StringBuffer.java (append): Update count and differentiate
4627 between field and local variable.
4628
4629 * java/util/Date.java (parseTz): Evaluate in minutes rather than
4630 seconds. Deal with military style time.
4631 (parse): Consistently treat all timezones in minutes until final
4632 calculation. Flag as non-local timezone. Return value in milliseconds.
4633 (setTime): Adjust for year offset from 1900.
4634 (UTC): Adjust for year offset from 1900.
4635
4636 1998-11-17 Tom Tromey <tromey@cygnus.com>
4637
4638 * configure: Rebuilt.
4639 * configure.in: Switch on host, not target.
4640
4641 * Makefile.in: Rebuilt.
4642 * Makefile.am (GCJ_no): New macro.
4643 (GCJ): Use @CANADIAN@.
4644 (GCJH_no): New macro
4645 (GCJH_canadian): New macro.
4646 (GCJH): Use @CANADIAN@.
4647 (ZIP_no): New macro.
4648 (ZIP_canadian): New macro.
4649 (ZIP): Use @CANADIAN@.
4650 * aclocal.m4, configure: Rebuilt.
4651 * configure.in (CANADIAN): Compute and subst.
4652
4653 Tue Nov 17 12:44:37 1998 Anthony Green <green@cygnus.com>
4654
4655 * java/io/FileDescriptor.java (finalize): Only close file
4656 descriptor if valid.
4657
4658 1998-11-17 Tom Tromey <tromey@cygnus.com>
4659
4660 * prims.cc (_Jv_InitRuntime): Removed.
4661
4662 1998-11-16 Tom Tromey <tromey@cygnus.com>
4663
4664 * java/io/FileOutputStream.java (close): Only close file
4665 descriptor if valid.
4666 (finalize): New method.
4667
4668 * prims.cc (_Jv_NewObjectArray): Set vtbl last.
4669 (_Jv_NewPrimArray): Likewise.
4670 * boehm.cc (_Jv_RegisterFinalizer): Use
4671 GC_REGISTER_FINALIZER_NO_ORDER.
4672 (GC_GENERIC_MALLOC): New define.
4673 (_Jv_AllocObj): Use it.
4674 (_Jv_AllocArray): Likewise.
4675 (_Jv_AllocBytes): Likewise.
4676 (_Jv_MarkObj): Just return if vtbl not set.
4677 (_Jv_MarkArray): Likewise.
4678 (MAYBE_MARK): New macro; use everywhere.
4679 (_Jv_MarkObj): Mark fields belonging to superclasses as well.
4680
4681 Mon Nov 16 14:57:53 1998 Warren Levy <warrenl@cygnus.com>
4682
4683 * java/util/natGregorianCalendar.cc (computeTime): Cast a time_t
4684 to a jlong before calculation to prevent overflow.
4685
4686 1998-11-16 Tom Tromey <tromey@cygnus.com>
4687
4688 * Makefile.in: Rebuilt.
4689 * Makefile.am (nat_headers): Fixed typo.
4690
4691 1998-11-15 Tom Tromey <tromey@cygnus.com>
4692
4693 * java/lang/Class.h (Class::getName): Removed definition.
4694 * Makefile.in: Rebuilt.
4695 * Makefile.am (nat_headers): Added InstantiationException.h,
4696 NoSuchMethodException.h.
4697 * java/lang/natClass.cc (clinit_name): Renamed from init_name.
4698 (init_name): New global.
4699 (hackRunInitializers): Use clinit_name.
4700 Include InstantiationException.h, NoSuchMethodException.h.
4701 (newInstance): Do some error checking (but not all). Call
4702 constructor.
4703 (forName): Throw exception if class not found.
4704 (getName): New method.
4705 (forName): Transform class name from external format to internal
4706 format before lookup.
4707
4708 1998-11-15 Anthony Green <green@cygnus.com>
4709
4710 * java/lang/Class.h (Class::forName): Method is static.
4711
4712 * java/lang/natClass.cc (newInstance): Add simple implementation.
4713 (forName): Ditto.
4714
4715 Sat Nov 14 18:25:13 1998 Per Bothner <bothner@cygnus.com>
4716
4717 * java/lang/Class.h (Class::accflags): Must be unsigned short (not
4718 int), for compatibility with jc1.
4719
4720 1998-11-14 Tom Tromey <tromey@cygnus.com>
4721
4722 * include/config.h.in: Rebuilt.
4723 * acconfig.h (LINUX_THREADS): New define.
4724 * configure: Rebuilt.
4725 * configure.in: Define LINUX_THREADS if using POSIX threads on
4726 Linux. Look for pthread_mutexattr_setkind_np function.
4727 * posix-threads.cc (throw_cleanup): New function.
4728 (really_start): Push cleanup function.
4729 (_Jv_ThreadCancel): New function.
4730 (daemon_mutex, daemon_cond, non_daemon_count): New globals.
4731 (_Jv_ThreadInitData): Set `exception' field in new structure.
4732 (_Jv_ThreadStart): Increment non_daemon_count if not a daemon
4733 thread.
4734 (_Jv_ThreadWait): New function.
4735 (_Jv_InitThreads): Initialize daemon globals.
4736 (FLAG_DAEMON): New macro.
4737 (really_start): Notify daemon_cond when non-daemon thread exits.
4738 Include <java/lang/System.h>.
4739 (struct starter): `object' field now a thread.
4740 (_Jv_MutexInit): Use pthread_mutexattr_setkind_np if it exists.
4741 * include/posix-threads.h (_Jv_CondInit): Use `0', not NULL.
4742 (_Jv_ThreadWait): Removed definition.
4743 (_Jv_Thread_t): Added `exception' field.
4744 (_Jv_ThreadCancel): Removed definition.
4745
4746 1998-11-13 Tom Tromey <tromey@cygnus.com>
4747
4748 * Makefile.in: Rebuilt.
4749 * Makefile.am (libjava.zip): Compute javac before changing
4750 directory.
4751
4752 * Makefile.in: Rebuilt.
4753 * Makefile.am (libjava.zip): Include directory entries.
4754
4755 * Makefile.in: Rebuilt.
4756 * Makefile.am (expanded): New macro.
4757 (GCJ): Use it.
4758
4759 1998-11-12 Tom Tromey <tromey@cygnus.com>
4760
4761 * prims.cc (clone): New function.
4762 * include/java-array.h (__JArray::clone): Removed definition.
4763
4764 * java/lang/natObject.cc (clone): Don't assert that class is not
4765 an array; array's `clone' method just calls this one.
4766
4767 * Makefile.in: Rebuilt.
4768 * Makefile.am (libjava.zip): Renamed target from classes.stamp.
4769 Now creates zip file. Changed all users.
4770 (ZIP): New macro.
4771 (data_DATA): New macro.
4772
4773 1998-11-11 Tom Tromey <tromey@cygnus.com>
4774
4775 * configure: Rebuilt.
4776 * configure.in: Recognize --enable-java-gc, not --enable-gc.
4777
4778 Wed Nov 11 18:13:46 1998 Warren Levy <warrenl@cygnus.com>
4779
4780 * java/io/InputStream.java (reset): Add msg to thrown exception.
4781
4782 Wed Nov 11 17:57:02 1998 Warren Levy <warrenl@cygnus.com>
4783
4784 * java/io/LineNumberInputStream.java: Rewritten.
4785
4786 * java/io/StringBufferInputStream.java: Removed extraneous import.
4787
4788 Wed Nov 11 15:19:33 1998 Warren Levy <warrenl@cygnus.com>
4789
4790 * java/io/StringBufferInputStream.java: Rewritten.
4791
4792 * java/util/Date.java (parseMonth): Optimize.
4793 (parseDayOfWeek): Created.
4794 (parse): Optimize to use parseDayOfWeek.
4795
4796 1998-11-11 Tom Tromey <tromey@cygnus.com>
4797
4798 * java/lang/StringBuffer.java (append): Handle case where STR is
4799 `null'.
4800
4801 * include/javaprims.h: Regenerated class declarations.
4802
4803 * configure: Rebuilt.
4804 * configure.in: Added --enable-gcj-classes,
4805 --enable-single-compilation, --enable-source-compilation flags.
4806 * Makefile.in: Rebuilt.
4807 * Makefile.am (java_io_files): New macro.
4808 (java_lang_files): Likewise.
4809 (java_text_files): Likewise.
4810 (java_util_files): Likewise.
4811 (java_files): Use new macros.
4812 (java-io.o): New target.
4813 (java-lang.o): Likewise.
4814 (java-text.o): Likewise.
4815 (java-util.o): Likewise.
4816 (src_io_files): New macro.
4817 (src_lang_files): Likewise.
4818 (src_text_files): Likewise.
4819 (src_util_files): Likewise.
4820 (class_io_files): New macro.
4821 (class_lang_files): Likewise.
4822 (class_text_files): Likewise.
4823 (class_util_files): Likewise.
4824 (class_files): Use new macros.
4825 (javao_files): Define conditionally.
4826 (.java.o): New target.
4827 ($(javao_files)): New target.
4828 (GCJ): new macro.
4829 (GCJH): Added $(EXEEXT).
4830 (CLASSPATH_ENV): Removed.
4831 (GCJCOMPILE): New macro.
4832
4833 Wed Nov 11 12:03:15 1998 Warren Levy <warrenl@cygnus.com>
4834
4835 * java/util/Date.java (parse): Written from scratch.
4836
4837 1998-11-11 Tom Tromey <tromey@cygnus.com>
4838
4839 * java/lang/Throwable.java (toString): Correct sense of test for
4840 determining when to include detail message in result.
4841
4842 * java/lang/ThreadDeath.java (ThreadDeath): Added missing
4843 constructor.
4844
4845 Fri Nov 6 16:30:20 1998 Tom Tromey <tromey@ferrule.cygnus.com>
4846
4847 * java/lang/Class.h: Use _Jv_RegisterClasses, not
4848 _Jv_RegisterClass.
4849 * java/lang/natClass.cc (_Jv_RegisterClasses): New function.
4850 (_Jv_RegisterClass): Use it.
4851 * include/jvm.h (_Jv_RegisterClasses): Declare.
4852 * java/lang/natObject.cc (init): Removed.
4853 (sync_init): Never call _Jv_InitializeSyncMutex.
4854 (_Jv_InitializeSyncMutex): Don't set `init'.
4855 * prims.cc (JvRunMain): Don't run init functions.
4856
4857 Thu Nov 5 17:14:37 1998 Tom Tromey <tromey@sanguine.cygnus.com>
4858
4859 * java/lang/natClass.cc (initializeClass): Set state before
4860 resolving constants.
4861
4862 * java/lang/natClass.cc (STATE_CONST_INIT): Removed.
4863 (STATE_RESOLVED): New macro.
4864 (initializeClass): Call resolveConstants.
4865 (hackRunInitializers): Don't call resolveConstants.
4866 (_Jv_FindArrayClass): Move short-circuit return for primitive
4867 element types earlier in function.
4868
4869 1998-11-03 Tom Tromey <tromey@hoser.cygnus.com>
4870
4871 * prims.cc (no_memory): New global.
4872 (_Jv_makeUtf8Const): Throw no_memory.
4873 (_Jv_AllocObject): Likewise.
4874 (_Jv_NewObjectArray): Likewise.
4875 (_Jv_NewPrimArray): Likewise.
4876 (JvRunMain): Initialize no_memory.
4877
4878 Tue Nov 3 17:15:45 1998 Warren Levy <warrenl@cygnus.com>
4879
4880 * java/io/FileInputStream.java: Corrected date comment.
4881 * java/io/SequenceInputStream.java: Rewritten.
4882
4883 Mon Nov 2 17:20:31 1998 Tom Tromey (tromey@cygnus.com)
4884
4885 * java/lang/FirstThread.java (die): New method.
4886 * java/lang/natFirstThread.cc (die): Removed.
4887 (DIE): New macro.
4888 (run): Use `DIE', not `die'.
4889
4890 Mon Nov 2 16:23:41 1998 Warren Levy <warrenl@cygnus.com>
4891
4892 * java/io/CharArrayReader.java (read): Move check into synchronized
4893 block to prevent a close while in progress.
4894 (reset): Ditto.
4895 (skip): Ditto.
4896 * java/io/PushbackReader.java (read): Ditto.
4897 (ready): Ditto.
4898 (unread): Ditto.
4899 * java/io/StringReader.java (mark): Ditto.
4900 (read): Ditto.
4901 (reset): Ditto.
4902 (skip): Ditto.
4903
4904 Mon Nov 2 15:56:20 1998 Warren Levy <warrenl@cygnus.com>
4905
4906 * java/io/PipedInputStream.java: Updated status.
4907 (connect): Added code to prevent infinite recursion and to
4908 differentiate exception causes.
4909 (read): Added code to differentiate exception causes.
4910 (receive): Made exception pass string with the cause.
4911
4912 * java/io/PipedOutputStream.java: Updated status.
4913 (connect): Added code to call connect at the other end of the pipe.
4914
4915 Mon Nov 2 00:22:12 1998 Warren Levy <warrenl@cygnus.com>
4916
4917 * java/io/PipedInputStream.java (connect): Throw exception if
4918 already connected to the same output stream.
4919 (read): Do bounds checking first.
4920
4921 Sun Nov 1 22:48:55 1998 Warren Levy <warrenl@cygnus.com>
4922
4923 * java/io/PipedInputStream.java: Added private boolean outClosed.
4924 (available): Removed check if output stream is open.
4925 (close): Mark the buffer as empty so available returns 0.
4926 (read): Check if the output stream was closed and then return EOF
4927 when the buffer is empty.
4928 (receive): Mark the output stream as closed when passed a -1.
4929
4930 * java/io/PipedOutputStream.java (close): Notify the input stream
4931 that there's no more data coming.
4932 (connect): Added a FIXME comment to note more coordination needed
4933 with PipedInputStream.
4934 (flush): Added a FIXME comment to mark what this method might do
4935 instead of nothing.
4936
4937 Fri Oct 30 14:27:21 1998 Warren Levy <warrenl@cygnus.com>
4938
4939 * java/io/PipedInputStream.java: Rewritten.
4940
4941 1998-10-30 Tom Tromey <tromey@cygnus.com>
4942
4943 * java/lang/Throwable.java: Rewrote from scratch.
4944
4945 * java/lang/Class.h (Class): Don't mention newMultiArray.
4946 * prims.cc (newMultiArray): Removed.
4947 (_Jv_NewMultiArray): Removed.
4948 (newArray): Removed.
4949 (new_multi_array): New function.
4950 (_Jv_NewMultiArray): Rewrote from scratch.
4951
4952 * include/javaprims.h: Regenerated class declarations.
4953 * classes.pl (scan): Don't declare PrimClass.
4954 * include/cni.h (JvPrimClass): Use new names for classes.
4955 * java/lang/Class.h (Class): Removed _Jv_initPrimClass as friend;
4956 added _Jv_PrimClass.
4957 * prims.cc (_Jv_PrimClass): Renamed from PrimClass.
4958 (_Jv_initPrimClass): Removed.
4959 (DECLARE_PRIM_TYPE): Generated globals now start with `_Jv_'.
4960 (_Jv_AllocObject): Added comment.
4961 (_Jv_NewObjectArray): Likewise.
4962 (_Jv_NewPrimArray): Likewise.
4963
4964 1998-10-29 Tom Tromey <tromey@cygnus.com>
4965
4966 * java/lang/natClass.cc (_Jv_NewClass): Initialize new field.
4967 (_Jv_FindArrayClass): Use dtable_method_count to compute size of
4968 new dtable.
4969 * java/lang/Class.h (Class): Added `dtable_method_count' field.
4970
4971 * java/lang/natObject.cc (init): New global.
4972 (sync_init): Call _Jv_InitializeSyncMutex if required.
4973
4974 * Makefile.in: Rebuilt.
4975 * Makefile.am (nat_headers): Added ClassLoader.h.
4976 * include/jvm.h (_Jv_FindClassFromSignature): Declare.
4977 * java/lang/Class.h (Class): simpleLookupClass, insertClass,
4978 internalAddClass, lookupArray no longer friends.
4979 _Jv_RegisterClass, _Jv_FindClassInCache, _Jv_NewClass,
4980 _Jv_FindArrayClass now friends.
4981 * java/lang/natClass.cc (HASH_LEN): New macro.
4982 (HASH_UTF): Likewise.
4983 (loaded_classes): New global.
4984 (_Jv_FindClass): New function.
4985 (ClassClass): New define.
4986 (_Jv_FindClassInCache): New function.
4987 (_Jv_RegisterClass): Likewise.
4988 (_Jv_NewClass): Likewise.
4989 Include <string.h>
4990 (ObjectClass): New define.
4991 (CloneableClass): New define.
4992 * prims.cc (_Jv_FindClass): Removed.
4993 (simpleLookupClass): Removed.
4994 (insertClass): Removed.
4995 (CLASSHASHSZ): Removed.
4996 (classPool): Removed.
4997 (_Jv_RegisterClass): Removed.
4998 (internalAddClass): Removed.
4999 (ClassClass): Removed.
5000 (RuntimeClass): Removed.
5001 (lookupArray): Removed.
5002 (CloneableClass): Removed.
5003 (CLASSMAXSIG): Removed.
5004 Rearranged file to group related functions together.
5005 (_Jv_IsInstanceOf): Moved to natClass.cc.
5006 (abort_final): Removed.
5007 Removed some unused includes.
5008 (classFromSig): Removed.
5009 (_Jv_FindClassFromSignature): New function.
5010 (_Jv_initPrimClass): Renamed.
5011 (getClass): Removed.
5012
5013 Thu Oct 29 23:17:17 1998 Warren Levy <warrenl@cygnus.com>
5014
5015 * java/io/FileDescriptor.java (finalize): Throws IOException
5016 instead of Throwable.
5017
5018 * java/io/FileInputStream.java: Rewritten.
5019
5020 * java/io/StreamTokenizer.java (nextToken): Unread newline character
5021 at the end of a comment.
5022
5023 1998-10-29 Tom Tromey <tromey@cygnus.com>
5024
5025 * include/javaprims.h: Regenerated class declarations.
5026 * classes.pl (scan): Don't special-case ClassLoader.
5027
5028 * prims.cc (processClass): Removed.
5029 (_Jv_InitClass): Removed.
5030 Removed all CSTATE_ macros.
5031 (resolveConstants): Removed.
5032 (MAXDIMS): Removed.
5033 (_Jv_NewMultiArray): Cleaned up.
5034 * Makefile.in: Rebuilt.
5035 * Makefile.am (nat_headers): Added NoClassDefFoundError.h.
5036 * java/lang/Class.h (Class): Declare new methods. processClass no
5037 longer a friend.
5038 * java/lang/Class.java (hackTrampoline): New method.
5039 (initializeClass): Declare.
5040 (hackRunInitializers): Declare.
5041 * java/lang/natClass.cc (getClassLoader): Moved into Class.h.
5042 (initializeClass): New method.
5043 (hackRunInitializers): New method.
5044 (init_name, void_signature): Moved from prims.cc.
5045 (_Jv_InitClass): New function.
5046 (isAssignableFrom): Don't call processClass.
5047 (STATE_NOTHING): New macro.
5048 (resolveConstants): New function.
5049 Include Thread.h.
5050 (ErrorClass): New define.
5051
5052 * java/lang/Class.java (getClassLoader): Declare.
5053 * java/lang/ClassLoader.java: Rewrote from scratch.
5054
5055 * java/lang/natClass.cc: Include IncompatibleClassChangeError.h,
5056 AbstractMethodError.h, IllegalAccessError.h,
5057 NoClassDefFoundError.h.
5058 * include/jvm.h (StringClass): Declare _Jv_equalUtf8Consts.
5059 * prims.cc (_Jv_equalUtf8Consts): Renamed from equalUtf8Consts; no
5060 longer static. Changed return type.
5061 * java/lang/natFirstThread.cc (run): Use _Jv_GetMethodLocal.
5062 * java/lang/Class.h (Class): findMethodLocal no longer a friend.
5063 * prims.cc (findMethodLocal): Removed.
5064 (processClass): Use _Jv_GetMethodLocal.
5065
5066 1998-10-28 Tom Tromey <tromey@cygnus.com>
5067
5068 * prims.cc (_Jv_LookupInterfaceMethod): Removed.
5069 * java/lang/Class.h (Class): Declare _Jv_GetMethodLocal as
5070 friend.
5071 * java/lang/natClass.cc (_Jv_GetMethodLocal): New function.
5072 (_Jv_LookupInterfaceMethod): New function (rewrote from scratch).
5073
5074 * include/jni.h: Added copyright header.
5075 * include/javaprims.h: Added copyright header.
5076 * include/java-field.h: Added copyright header.
5077 * include/java-array.h: Added copyright header.
5078 * include/cni.h: Added copyright header.
5079
5080 * include/javaprims.h: Regenerated class declarations using
5081 classes.pl; now they are complete.
5082 * classes.pl: New file.
5083
5084 * java/lang/natMath.cc: Include <config.h>.
5085 * java/lang/reflect/natField.cc: Include <config.h>.
5086 * java/util/NativeUtil.java: Removed.
5087 * Makefile.in: Rebuilt.
5088 * Makefile.am (nat_headers): Added Math.h.
5089 * java/lang/Math.h: Removed.
5090 * java/util/natGregorianCalendar.cc: Added copyright header.
5091 Include <config.h>.
5092 * java/lang/natFloat.cc: Added copyright header.
5093 * java/lang/Byte.java: Added copyright header.
5094 * java/lang/Void.java: Added copyright header.
5095 * java/lang/Short.java: Added copyright header.
5096
5097 Wed Oct 28 12:55:47 1998 Warren Levy <warrenl@cygnus.com>
5098
5099 * include/javaprims.h (java::io): Added bunch of missing classes.
5100
5101 * java/io/DataInputStream.java (readLine): Added a special case
5102 for handling BufferedInputStream data to reduce the likelihood
5103 of a pushback error.
5104 (skipBytes): Added code to handle negative number of skip bytes.
5105
5106 * java/io/StreamTokenizer.java: Rewritten.
5107
5108 1998-10-28 Tom Tromey <tromey@cygnus.com>
5109
5110 * java/util/natGregorianCalendar.cc (computeFields): Call
5111 getRawOffset as a method.
5112
5113 * include/javaprims.h (java::io): Added FilterOutputStream.
5114 * Makefile.in: Rebuilt.
5115 * Makefile.am (nat_headers): Added PrintStream.h,
5116 FilterOutputStream.h.
5117 * java/lang/natFirstThread.cc: Include System.h, Modifier.h,
5118 PrintStream.h.
5119 (die): New function.
5120 (run): Die if `main' not found, is not public, or is not static.
5121
5122 * boehm.cc (_Jv_MarkObj): Use new field names.
5123 * include/java-field.h (JvGetFirstInstanceField): Use new field
5124 names.
5125 (JvNumInstanceFields): Likewise.
5126 * java/lang/natClass.cc (isAssignableFrom): Use new field names.
5127 (getInterfaces): Likewise.
5128 * prims.cc (CLASS_CONSTANTS): Removed.
5129 (CLASS_CONST_SIZE): Likewise.
5130 (CLASS_CONST_TAG): Likewise.
5131 (CLASS_CONST_DATA): Likewise.
5132 (CLASS_CONST_UTF8): Likewise.
5133 (WORD2UTF): Likewise.
5134 (CLASS_CLASS): Likewise.
5135 (CLASS_PRIM_SIG): Likewise.
5136 (CLASS_ARRAY_CACHE): Likewise.
5137 (HASH_CHARS): Likewise.
5138 (hashClassName): Likewise.
5139 Many changes to use new field names.
5140 * java/lang/Class.h (Class): Renamed fields to track compiler.
5141
5142 1998-10-27 Tom Tromey <tromey@cygnus.com>
5143
5144 * java/lang/natClass.cc: Use #pragma implementation.
5145 (getComponentType): Moved into header.
5146 (getModifiers): Likewise.
5147 (getName): Likewise.
5148 (getSuperclass): Likewise.
5149 (isArray): Likewise.
5150 (isPrimitive): Likewise.
5151 * include/jvm.h (_Jv_FindClass): Declare.
5152 * java/lang/natFirstThread.cc (run): Updated for new Class.h.
5153 * java/lang/natSystem.cc (arraycopy): Updated for new Class.h.
5154 * include/javaprims.h: Use _Jv_Method, not JvMethod.
5155 * java/lang/Class.h: Rewrote from scratch.
5156 * prims.cc: Many changes to work with new Class.h.
5157 * include/java-field.h (CLASS_FIELDS): Removed.
5158 (CLASS_SFIELDS): Likewise.
5159 (CLASS_IFIELDS): Likewise.
5160 (CLASS_NFIELDS): Likewise.
5161 (CLASS_NIFIELDS): Likewise.
5162 (CLASS_NSFIELDS): Likewise.
5163 (CLASS_FSIZE): Likewise.
5164 (JvGetFirstInstanceField): Rewrote.
5165 (JvNumInstanceFields): Likewise.
5166
5167 * java/lang/Object.h: Added copyright comment.
5168
5169 Wed Oct 28 00:32:23 1998 Per Bothner <bothner@cygnus.com>
5170
5171 * java/text: New package directory.
5172 * java/text/FieldPosition.java: New class.
5173 * java/text/ParsePosition.java: New class.
5174 * java/text/ParseException.java: New Exception class.
5175 * java/text/Format.java: New class.
5176 * java/text/NumberFormat.java: New (empty placeholder) class.
5177 * java/text/DateFormatSymbols.java: New class (no Locales support).
5178 * java/text/DateFormat.java: New Format class (incomplete).
5179 * java/text/SimpleDateFormat.java: New DateFormat class.
5180
5181 * include/javaprims.h (java::test): Added new package and classes.
5182 * java/util/Calendar.java (clone): New method.
5183 * java/util/Date.java (toString): Added non-native implementation.
5184 (parse): Made public instead of synchronized.
5185 * java/util/natDate.cc (toString): Removed.
5186 * java/util/natGregorianCalendar.cc (computeFields):
5187 Use gmtime (or gmtime_r) if no zone offset (the default, for now!).
5188
5189 1998-10-27 Tom Tromey <tromey@cygnus.com>
5190
5191 * boehm.cc (_Jv_MarkObj): Correctly mark a class' interfaces.
5192
5193 * prims.cc (lookupArray): Added explanatory comment.
5194 * boehm.cc (_Jv_MarkObj): Correctly scan methods and fields of
5195 class. Mark the class of each object.
5196 (_Jv_MarkArray): Mark the object's class.
5197
5198 * configure: Rebuilt.
5199 * configure.in: Create java-gc.h.
5200 * include/boehm-gc.h: New file.
5201 * include/no-gc.h: New file.
5202 * java/lang/Class.h (Class): Declare JV_MARKOBJ_DECL as friend, if
5203 defined.
5204 * java/lang/Object.h: Include java-gc.h.
5205 (Object): Declare JV_MARKOBJ_DECL and JV_MARKARRAY_DECL as
5206 friends, if defined.
5207 * boehm.cc (_Jv_MarkObj): Renamed from mark_obj; changed
5208 signature.
5209 (_Jv_MarkArray): Renamed from mark_array; changed signature.
5210
5211 1998-10-26 Tom Tromey <tromey@cygnus.com>
5212
5213 * java/lang/natCharacter.cc (isSpaceChar): Look for line and
5214 paragraph separators, not numbers.
5215
5216 * java/io/Writer.java (write): Removed write(char) to avoid
5217 ambiguity.
5218 * java/util/Properties.java: Rewrote from scratch.
5219 * include/javaprims.h (java::io): Added PrintWriter,
5220 BufferedWriter, PushbackReader.
5221
5222 Mon Oct 26 13:13:28 1998 Anthony Green <green@cygnus.com>
5223
5224 * java/lang/System.java: exit() is a static method.
5225
5226 1998-10-26 Tom Tromey <tromey@cygnus.com>
5227
5228 * java/lang/natString.cc (_Jv_NewStringUTF): Use
5229 _Jv_strLengthUtf8.
5230 (_Jv_NewStringUtf8Const): Likewise.
5231 * include/jvm.h (_Jv_strLengthUtf8): Declare.
5232 * prims.cc (_Jv_strLengthUtf8): Renamed from strLengthUtf8.
5233
5234 * java/lang/Object.h (Object): Add mark_array as friend function.
5235 * prims.cc (_Jv_NewPrimArray): Use _Jv_AllocObj, not
5236 _Jv_AllocBytes, to ensure that header is marked.
5237 * boehm.cc (mark_obj): Push sync_info field for all objects, not
5238 just Objects.
5239 (mark_array): Push sync_info field for array.
5240
5241 1998-10-24 Tom Tromey <tromey@cygnus.com>
5242
5243 * java/lang/String.java (String): Updated for StringBuffer
5244 change.
5245 * java/util/BitSet.java: Renamed field (data->bits) to conform to
5246 serialization spec.
5247 * java/lang/StringBuffer.java: Renamed fields to conform to
5248 serialization spec: buffer->value, next->count, copy->shared.
5249
5250 Wed Oct 21 18:24:57 1998 Per Bothner <bothner@cygnus.com>
5251
5252 * java/util/TimeZone.java: New class.
5253 * java/util/SimpleTimeZone.java: New class.
5254 * java/util/Locale.java: New file.
5255 * java/util/Calendar.java: Make almost complete.
5256 * java/util/GregorianCalendar.java
5257 * java/util/natGregorianCalendar.cc: New file.
5258 * java/util/Date.java: Re-written from scratch.
5259 * java/util/natDate.cc (setTime): Removed - no longer native.
5260 * include/javaprims.h (java::util): Add new classes.
5261 * Makefile.am (nat_files): Add java/util/natGregorianCalendar.o.
5262 (nat_headers); Add TimeZone.h, Calendar.h, GregorianCalendar.h.
5263
5264 Sat Oct 24 22:58:25 1998 Warren Levy <warrenl@cygnus.com>
5265
5266 * java/io/natFileDescriptorPosix.cc (read): Zero extend jbyte b before
5267 returning it as a jint.
5268
5269 1998-10-23 Tom Tromey <tromey@cygnus.com>
5270
5271 * prims.cc (arg_vec, main_group, main_thread): New globals.
5272 (JvRunMain): Use them.
5273
5274 Fri Oct 23 17:10:12 1998 Warren Levy <warrenl@cygnus.com>
5275
5276 * java/io/DataInputStream.java: Rewritten.
5277
5278 * java/io/DataOutputStream.java (writeUTF): OR secondary and
5279 tertiary bytes with 0x80 per spec.
5280
5281 1998-10-23 Tom Tromey <tromey@cygnus.com>
5282
5283 * java/lang/String.java (init): Changed name of `copy' argument.
5284 * java/lang/natString.cc (init): Inverted sense of `copy'
5285 argument.
5286
5287 * java/lang/Object.h (Object): Declare mark_obj as a friend.
5288 * java/lang/Class.h (Class): Declare mark_obj as a friend.
5289 * boehm.cc (ObjectClass): New define.
5290 (ClassClass): Likewise.
5291 (mark_obj): Special-case Object and Class.
5292
5293 * prims.cc (_Jv_NewPrimArray): Pass correct args to memset.
5294
5295 * java/util/BitSet.java: Rewrote from scratch.
5296
5297 * prims.cc (lookupArray): Removed useless cast.
5298
5299 * java/lang/natObject.cc: Use `#pragma implementation'.
5300
5301 * java/lang/String.java (init): Added `copy' argument.
5302 (String): Look in StringBuffer to find char array.
5303 * java/lang/natString.cc (init): Added `copy' argument.
5304 * java/lang/StringBuffer.java: Rewrote from scratch.
5305
5306 * java/lang/Compiler.java: Rewrote from scratch.
5307 * java/lang/Throwable.java: Don't use NativeLang.
5308 * include/javaprims.h (java::lang): Don't mention NativeLang.
5309 * java/lang/Process.java: Rewrote from scratch.
5310 * java/lang/SecurityManager.java (classLoaderDepth): Commented
5311 out.
5312 (currentClassLoader): Likewise.
5313 (currentLoadedClass): Likewise.
5314 * java/lang/natClass.cc (getClassLoader): Commented out.
5315 * java/lang/Class.java (getClassLoader): Commented out.
5316 * java/lang/Compiler.java: Removed.
5317 * java/lang/NativeLang.java: Removed.
5318
5319 * java/lang/natFirstThread.cc (run): Use _Jv_makeUtf8Const.
5320 * include/jvm.h (StringClass): Declare _Jv_makeUtf8Const.
5321 * prims.cc (_Jv_makeUtf8Const): Renamed from makeUtf8Const.
5322 (_Jv_hashUtf8String): Now static.
5323 * include/java-field.h (getNameUtf8Const): Use `_Jv_Utf8Const' as
5324 name of return type.
5325
5326 * java/lang/Class.h (Class): Declare checkMemberAccess.
5327 * Makefile.in: Rebuilt.
5328 * Makefile.am (nat_headers): Added Member.h.
5329 * java/lang/natClass.cc: Include Member.h.
5330 (getDeclaredClasses): Call checkMemberAccess.
5331 * java/lang/Class.java (checkMemberAccess): Call
5332 SecurityManager.checkMemberAccess.
5333
5334 Fri Oct 23 08:01:54 1998 Anthony Green <green@cygnus.com>
5335
5336 * java/lang/SecurityManager.java: Rewritten.
5337
5338 Thu Oct 22 17:16:10 1998 Anthony Green <green@cygnus.com>
5339
5340 * java/applet/Applet.java, java/applet/AppletContext.java,
5341 java/applet/AppletStub.java, java/applet/AudioClip.java,
5342 java/awt/AWTError.java, java/awt/AWTException.java,
5343 java/awt/BorderLayout.java, java/awt/Button.java,
5344 java/awt/Canvas.java, java/awt/CardLayout.java,
5345 java/awt/Checkbox.java, java/awt/CheckboxGroup.java,
5346 java/awt/CheckboxMenuItem.java, java/awt/Choice.java,
5347 java/awt/Color.java, java/awt/Component.java,
5348 java/awt/Container.java, java/awt/Dialog.java,
5349 java/awt/Dimension.java, java/awt/Event.java,
5350 java/awt/FileDialog.java, java/awt/FlowLayout.java,
5351 java/awt/Font.java, java/awt/FontMetrics.java,
5352 java/awt/Frame.java, java/awt/Graphics.java,
5353 java/awt/GridBagConstraints.java, java/awt/GridBagLayout.java,
5354 java/awt/GridLayout.java, java/awt/Image.java,
5355 java/awt/Insets.java, java/awt/Label.java,
5356 java/awt/LayoutManager.java, java/awt/List.java,
5357 java/awt/MediaTracker.java, java/awt/Menu.java,
5358 java/awt/MenuBar.java, java/awt/MenuComponent.java,
5359 java/awt/MenuContainer.java, java/awt/MenuItem.java,
5360 java/awt/Panel.java, java/awt/Point.java, java/awt/Polygon.java,
5361 java/awt/Rectangle.java, java/awt/Scrollbar.java,
5362 java/awt/TextArea.java, java/awt/TextComponent.java,
5363 java/awt/TextField.java, java/awt/Toolkit.java,
5364 java/awt/Window.java, java/awt/image/ColorModel.java,
5365 java/awt/image/CropImageFilter.java,
5366 java/awt/image/DirectColorModel.java,
5367 java/awt/image/FilteredImageSource.java,
5368 java/awt/image/ImageConsumer.java,
5369 java/awt/image/ImageFilter.java,
5370 java/awt/image/ImageObserver.java,
5371 java/awt/image/ImageProducer.java,
5372 java/awt/image/IndexColorModel.java,
5373 java/awt/image/MemoryImageSource.java,
5374 java/awt/image/PixelGrabber.java,
5375 java/awt/image/RGBImageFilter.java, java/awt/peer/ButtonPeer.java,
5376 java/awt/peer/CanvasPeer.java,
5377 java/awt/peer/CheckboxMenuItemPeer.java,
5378 java/awt/peer/CheckboxPeer.java, java/awt/peer/ChoicePeer.java,
5379 java/awt/peer/ComponentPeer.java,
5380 java/awt/peer/ContainerPeer.java, java/awt/peer/DialogPeer.java,
5381 java/awt/peer/FileDialogPeer.java, java/awt/peer/FramePeer.java,
5382 java/awt/peer/LabelPeer.java, java/awt/peer/ListPeer.java,
5383 java/awt/peer/MenuBarPeer.java,
5384 java/awt/peer/MenuComponentPeer.java,
5385 java/awt/peer/MenuItemPeer.java, java/awt/peer/MenuPeer.java,
5386 java/awt/peer/PanelPeer.java, java/awt/peer/ScrollbarPeer.java,
5387 java/awt/peer/TextAreaPeer.java,
5388 java/awt/peer/TextComponentPeer.java,
5389 java/awt/peer/TextFieldPeer.java, java/awt/peer/WindowPeer.java,
5390 java/net/ContentHandler.java, java/net/ContentHandlerFactory.java,
5391 java/net/DatagramPacket.java, java/net/DatagramSocket.java,
5392 java/net/DefaultSocketImpl.java, java/net/InetAddress.java,
5393 java/net/MalformedURLException.java, java/net/NativeNet.java,
5394 java/net/ProtocolException.java, java/net/ServerSocket.java,
5395 java/net/Socket.java, java/net/SocketException.java,
5396 java/net/SocketImpl.java, java/net/SocketImplFactory.java,
5397 java/net/URL.java, java/net/URLConnection.java,
5398 java/net/URLEncoder.java, java/net/URLStreamHandler.java,
5399 java/net/URLStreamHandlerFactory.java,
5400 java/net/UnknownHostException.java,
5401 java/net/UnknownServiceException.java: Removed.
5402
5403 1998-10-22 Tom Tromey <tromey@cygnus.com>
5404
5405 * prims.cc (_Jv_AllocObject): Register finalizer if class'
5406 finalizer is not Object.finalize.
5407 (internalAddClass): Don't set `final' member of class.
5408 * java/lang/Object.h: Updated _JvObjectPrefix comment to mention
5409 other places that know about finalize() location.
5410 * java/lang/Class.h (Class): Removed `final' field.
5411
5412 * aclocal.m4, configure: Rebuilt.
5413 * acinclude.m4 (LIB_AC_PROG_CXX): Unconditionally use
5414 AC_CHECK_PROGS; otherwise the CXX cache variable might not be
5415 set.
5416 * configure.in (AC_OUTPUT): Pass CXX to config.status.
5417 * Makefile.in: Rebuilt.
5418 * Makefile.am (AM_MAKEFLAGS): Added CXX, CXXFLAGS.
5419
5420 1998-10-21 Tom Tromey <tromey@cygnus.com>
5421
5422 * java/lang/Object.java (finalize): Move to be first method in
5423 class.
5424
5425 * configure: Rebuilt.
5426 * configure.in (GCINCS): Include contents of boehm-cflags file.
5427
5428 Tue Oct 20 13:11:04 1998 Alexandre Petit-Bianco <apbianco@cygnus.com>
5429
5430 * java/lang/ArrayIndexOutOfBoundsException.java
5431 (ArrayIndexOutOfBoundsException): Fixed string literal.
5432 * java/lang/StringIndexOutOfBoundsException.java
5433 (StringIndexOutOfBoundsException): Fixed string literal.
5434
5435 1998-10-20 Andrew Haley <aph@viagra.cygnus.co.uk>
5436
5437 * natFileDescriptorEcos.cc added.
5438 * natFileDescriptor.cc renamed natFileDescriptorPosix.cc.
5439
5440 1998-10-20 Andrew Haley <aph@viagra.cygnus.co.uk>
5441
5442 * acconfig.h: test for __int32_t and __uint32_t added.
5443 * include/config.h.in: test for __int32_t and __uint32_t added.
5444 * java/lang/fdlibm.h: test for __int32_t and __uint32_t added.
5445 * java/lang/mprec.h: test for __int32_t and __uint32_t added.
5446 * configure.in: test for __int32_t and __uint32_t added.
5447 * configure: test for __int32_t and __uint32_t added.
5448
5449 * natFileDescriptor.cc renamed natFileDescriptorPosix.cc.
5450
5451 * configure.in: Test for --enable ecos and link
5452 natFileDescriptor.cc to natFileDescriptorEcos.cc or
5453 natFileDescriptorPosix.cc
5454
5455 * java/lang/dtoa.c: #include <stdio.h> moved inside #ifdef DEBUG.
5456
5457 Mon Oct 19 18:13:58 1998 Warren Levy <warrenl@cygnus.com>
5458
5459 * java/io/ByteArrayInputStream.java (skip): Ensure that arg passed
5460 in isn't negative.
5461
5462 * java/io/CharArrayReader.java (close): Synchronize on lock
5463 object per Reader contract.
5464 (read): Synchronize on lock obj. Verify that reader wasn't closed.
5465 (reset): Synchronize on lock obj. Verify that reader wasn't closed.
5466 (skip): Synchronize on lock obj. Verify that reader wasn't closed.
5467 Ensure that arg passed in isn't negative.
5468
5469 * java/io/FilterReader.java (FilterReader): Use the lock obj when
5470 constructing the superclass.
5471
5472 * java/io/PushbackReader.java (close): Synchronize on lock
5473 object per Reader contract.
5474 (read): Synchronize on lock obj. Verify that reader wasn't closed.
5475 (ready): Synchronize on lock obj. Throw IOException if reader
5476 wasn't closed.
5477 (reset): Synchronize on lock obj. Verify that reader wasn't closed.
5478 (skip): Synchronize on lock obj. Verify that reader wasn't closed.
5479 Ensure that arg passed in isn't negative.
5480 (unread): Synchronize on lock obj. Verify that reader wasn't closed.
5481
5482 * java/io/StringReader.java: Created.
5483
5484 Sun Oct 18 02:19:11 1998 Warren Levy <warrenl@cygnus.com>
5485
5486 * java/io/CharArrayReader.java (mark): Removed synchronized modifier
5487 to match JCL.
5488 (read): Removed synchronized modifier to match JCL.
5489 (reset): Removed synchronized modifier to match JCL.
5490 (skip): Removed synchronized modifier to match JCL.
5491
5492 Sun Oct 18 02:01:54 1998 Warren Levy <warrenl@cygnus.com>
5493
5494 * java/io/PushbackReader.java (PushbackReader): Made
5495 constructors public.
5496
5497 1998-10-17 Tom Tromey <tromey@cygnus.com>
5498
5499 * java/io/PushbackInputStream.java (PushbackInputStream): Made
5500 constructors public.
5501
5502 1998-10-16 Anthony Green <green@cygnus.com>
5503
5504 * aclocal.m4, configure: Rebuilt.
5505 * acinclude.m4 (LIBJAVA_CONFIGURE): Changed for new
5506 configure.host.
5507 * configure.host: Rewrote.
5508 * Makefile.in: Rebuilt.
5509 * Makefile.am (AM_CXXFLAGS): Added LIBJAVA_CXXFLAGS.
5510 (AM_CFLAGS): New macro.
5511 ($(c_files)): Use COMPILE macro.
5512 (EXTRA_libjava_a_SOURCES): Added dummy file to work around
5513 automake problem(s).
5514
5515 Fri Oct 16 16:36:28 1998 Warren Levy <warrenl@cygnus.com>
5516
5517 * java/io/ByteArrayInputStream.java (mark): Removed temp. comment.
5518
5519 * java/io/CharArrayReader.java: Created.
5520
5521 Fri Oct 16 15:17:01 1998 Warren Levy <warrenl@cygnus.com>
5522
5523 * java/io/PushbackInputStream.java (PushbackInputStream): Changed
5524 size check to allow 0 per JCL.
5525
5526 * java/io/PushbackReader.java: Created.
5527
5528 1998-10-16 Tom Tromey <tromey@cygnus.com>
5529
5530 * java/io/natFileDescriptor.cc: Conditionalize <unistd.h>,
5531 <sys/time.h> includes.
5532 * java/io/natFile.cc: Conditionalize <unistd.h> include.
5533 * include/no-threads.h: Conditionalize <unistd.h> include on
5534 HAVE_UNISTD_H.
5535
5536 Fri Oct 16 14:39:51 1998 Andrew Haley <aph@madras.cygnus.co.uk>
5537
5538 * include/no-threads.h: Don't include <unistd.h> unless HAVE_SLEEP
5539 is defined.
5540
5541 Thu Oct 15 19:27:54 1998 Warren Levy <warrenl@cygnus.com>
5542
5543 * java/io/FilterReader.java: Created.
5544
5545 Thu Oct 15 17:49:43 1998 Warren Levy <warrenl@cygnus.com>
5546
5547 * java/io/PushbackInputStream.java: Rewritten.
5548
5549 * java/io/BufferedInputStream.java (BufferedInputStream): Check
5550 that size passed to constructor is legal.
5551 (read): Check that args passed in are legal.
5552 (skip): Rewritten to get rid of the temporary buffer.
5553 (refill): Added marklimit check to grow the buffer.
5554
5555 * java/io/ByteArrayInputStream.java (read): Optimized invalid args
5556 check.
5557 (bytesAvail): Removed.
5558 (read): Changed bytesAvail to Math.min.
5559 (skip): Changed bytesAvail to Math.min.
5560
5561 * java/io/InputStream.java (read): Got rid of extraneous exceptions
5562 from the throws clause.
5563 (skip): Rewritten to use a temporary buffer.
5564
5565 Thu Oct 15 19:42:55 1998 Andrew Haley <aph@madras.cygnus.co.uk>
5566
5567 * prims.cc: (JvConvertArgv): Check added for argc < 0; possible on
5568 some target OSes
5569
5570 * java/lang/dtoa.c: (print): Made #ifdef DEBUG only.
5571
5572 * java/lang/strtod.c: (_strtod_r): Don't use HUGE_VAL: it's faster
5573 to write the double one word at a time.
5574
5575 Tue Oct 13 14:41:47 1998 Warren Levy <warrenl@cygnus.com>
5576
5577 * java/io/BufferedInputStream.java: Rewritten.
5578
5579 1998-10-12 Tom Tromey <tromey@cygnus.com>
5580
5581 * jni.cc: Include config.h and stddef.h.
5582
5583 * java/lang/Class.h (_dispatchTable): Removed again.
5584 Removed all ACC_* defines again.
5585
5586 Fri Oct 9 17:08:34 1998 Per Bothner <bothner@cygnus.com>
5587
5588 * Makefile.am (nat_files): Add netField.o.
5589 (libjava_a_SOURCES): Add jni.cc.
5590 (java/lang/reflect/Field.h): New rule.
5591 * Makefile.in: Re-generated.
5592 * include/javaprims.h: Add some extra class and typedefs.
5593 * include/jni.h: New file.
5594 * jni.cc: New file.
5595
5596 * include/java-field.h: New file.
5597 * include/jvm.h: #include <java-field.h>.
5598 * boehm.cc: #include <java-field.h>.
5599 * java/lang/Class.h (JvField, inline numbers): Moved to java-field.h.
5600 * java/lang/reflect/Member.java: New class.
5601 * java/lang/reflect/Field.java: New class. (Very incomplete.)
5602 * java/lang/reflect/natField.cc: New file. (Very incomplete.)
5603
5604 Sun Oct 11 00:34:44 1998 Anthony Green <green@cygnus.com>
5605
5606 * Makefile.in, aclocal.m4, configure, test/Makefile.in,
5607 testsuite/Makefile.in: Rebuilt.
5608 * Makefile.am, acinclude.m4, configure.in: Add multilib support.
5609 * configure.host: Created.
5610
5611 1998-10-10 Tom Tromey <tromey@cygnus.com>
5612
5613 * java/lang/natObject.cc (sync_init): Always allocate a new
5614 sync_info.
5615
5616 1998-10-09 Tom Tromey <tromey@cygnus.com>
5617
5618 * java/io/ByteArrayInputStream.java (mark): Renamed from
5619 `mark_FIXME'.
5620
5621 * java/io/FileOutputStream.java (finalize): Removed.
5622 * java/io/FileDescriptor.java (finalize): New method.
5623
5624 Thu Oct 8 17:59:43 1998 Warren Levy <warrenl@cygnus.com>
5625
5626 * ByteArrayInputStream.java: Corrected status comment.
5627
5628 Thu Oct 8 17:22:49 1998 Warren Levy <warrenl@cygnus.com>
5629
5630 * ByteArrayInputStream.java, FilterInputStream.java: Rewritten.
5631
5632 1998-10-08 Tom Tromey <tromey@cygnus.com>
5633
5634 * prims.cc (lookupArray): Use static array to initialize list of
5635 interfaces.
5636
5637 Thu Oct 8 12:45:03 1998 Anthony Green <green@cygnus.com>
5638
5639 * prims.cc (lookupArray): Initialize the msize for new
5640 array classes.
5641
5642 Wed Oct 7 12:13:59 1998 Anthony Green <green@cygnus.com>
5643
5644 * configure: Rebuilt.
5645 * configure.in: Check for fsync and sleep.
5646 * acconfig.h (HAVE_SLEEP, HAVE_FSYNC): Added.
5647
5648 * include/no-threads.h (_Jv_CondWait): Wrap sleep() use with
5649 HAVE_SLEEP. Include config.h.
5650
5651 * java/io/natFileDescriptor.cc (NO_FSYNC_MESSAGE): Added.
5652 * java/io/natFileDescriptor.cc (sync): Wrap fsync() use
5653 with HAVE_FSYNC.
5654
5655 1998-10-08 Tom Tromey <tromey@cygnus.com>
5656
5657 * java/io/natFile.cc: Don't include SecurityManager.h.
5658 (performList): Renamed.
5659 (performMkdir): Likewise.
5660 (performRenameTo): Likewise.
5661 (performDelete): Likewise.
5662 Include <stdlib.h>.
5663 * java/io/File.java (performDelete): Renamed from natDelete.
5664 (list): Now written in Java.
5665 (performList): New method.
5666 (performMkdir): New method.
5667 (mkdir): Now written in Java.
5668 (performRenameTo): New method.
5669 (renameTo): Now written in Java.
5670
5671 1998-10-06 Tom Tromey <tromey@cygnus.com>
5672
5673 * Makefile.in: Rebuilt.
5674 * Makefile.am (ETAGS_ARGS): New macro.
5675 (TAGS_DEPENDENCIES): Likewise.
5676
5677 Tue Oct 6 22:04:44 PDT 1998 Anthony Green <green@cygnus.com>
5678
5679 * Makefile.in: Rebuilt.
5680 * Makefile.am: Use -classpath option with javac.
5681
5682 Tue Oct 6 18:51:31 1998 Tom Tromey <tromey@cygnus.com>
5683
5684 * java/io/FileOutputStream.java (finalize): Call
5685 super.finalize().
5686
5687 Tue Oct 6 16:02:45 1998 Anthony Green <green@cygnus.com>
5688
5689 * java/lang/mprec.h: Remove unused _mprec_log10 which conflicts
5690 with newlib's libm.
5691 * java/lang/mprec.c: Ditto.
5692
5693 * java/lang/mprec.h: Include math.h for HUGE_VAL when
5694 cross-compiling.
5695
5696 Tue Oct 6 14:27:00 1998 Warren Levy <warrenl@cygnus.com>
5697
5698 * java/io/InputStream.java (skip): Make local var i a long.
5699
5700 Mon Oct 5 09:44:24 1998 Tom Tromey <tromey@cygnus.com>
5701
5702 * java/lang/natObject.cc (clone): Use memcpy, not memmove.
5703 * prims.cc (lookupArray): Use memcpy, not memmove.
5704 * include/config.h.in: Rebuilt.
5705 * acconfig.h (HAVE_MEMCPY): Added.
5706 * configure: Rebuilt.
5707 * configure.in: Check for memcpy again.
5708
5709 * java/io/RandomAccessFile.java (RandomAccessFile): Use
5710 String.compareTo, not ==.
5711
5712 * java/lang/Class.h (Class): Use _Jv_DispatchTable.
5713 (_PRIMITIVE_DTABLE): Use _Jv_DispatchTable.
5714 * java/lang/natObject.cc (struct _dispatchTable): Removed.
5715 * include/jvm.h (struct _Jv_DispatchTable): New structure.
5716 * prims.cc (lookupArray): Removed dead code. Copy Object's dtable
5717 into new array's dtable.
5718 (_Jv_AllocObject): Use _Jv_DispatchTable.
5719 (_Jv_NewPrimArray): Likewise.
5720 (_Jv_NewObjectArray): Likewise.
5721
5722 Fri Oct 2 18:57:14 1998 Alexandre Petit-Bianco <apbianco@cygnus.com>
5723
5724 * prims.cc (_Jv_ThrowBadArrayIndex): Construct a string with the
5725 offending index value.
5726 (_Jv_NewPrimArray): Throw NegativeArraySizeException when
5727 appropriate.
5728 * include/jvm.h (_Jv_ThrowBadArrayIndex): Added declaration.
5729 * java/lang/Throwable.java: (Throwable): fixed argument to this().
5730
5731 Fri Oct 2 15:58:23 1998 Warren Levy <warrenl@cygnus.com>
5732
5733 * java/io/DataInput.java, java/io/InputStream.java: Rewritten.
5734
5735 * java/io/OutputStream.java (write): Use off and len parameters to
5736 output partial byte array.
5737
5738 * java/io/BufferedReader.java, java/io/FileReader.java,
5739 java/io/InputStreamReader.java, java/io/LineNumberReader.java,
5740 java/io/OutputStreamWriter.java, java/io/PrintWriter.java,
5741 java/io/Reader.java, java/io/UnsupportedEncodingException.java,
5742 java/io/Writer.java: Added COPYRIGHT-TBD comment.
5743
5744 * include/javaprims.h (java::lang): Added
5745 ExceptionInInitializerError, IllegalStateException,
5746 NoSuchFieldException, and UnsupportedOperationException.
5747
5748 Fri Oct 2 01:05:38 1998 Tom Tromey <tromey@cygnus.com>
5749
5750 * java/lang/natObject.cc (CloneableClass): Is a Class, not a
5751 Class*.
5752
5753 * include/java-array.h (__JArray): Added clone method.
5754 * prims.cc (CloneableClass): New define.
5755 (lookupArray): Initialize array class to indicate that it
5756 implements Cloneable.
5757
5758 * java/lang/Class.h: Removed all ACC_* defines.
5759 * prims.cc: Include Modifier.h.
5760 (_Jv_LookupInterfaceMethod): Use methods in
5761 java.lang.reflect.Modifier, not ACC_ defines.
5762
5763 * java/lang/Class.h (Class): Declare getClasses,
5764 getDeclaredClasses, getDeclaringClass, getModifiers,
5765 * java/lang/Class.java: Rewrote from scratch.
5766
5767 * include/javaprims.h (java::lang): Added reflect and
5768 reflect::Modifier.
5769 * Makefile.in: Rebuilt.
5770 * Makefile.am (nat_headers): Added Modifier.h.
5771
5772 * prims.cc (_Jv_IsInstanceOf): Return false if class is
5773 primitive.
5774
5775 Fri Oct 2 06:49:00 1998 Anthony Green <green@cygnus.com>
5776
5777 * java/lang/natString.cc (_Jv_StringFindSlot): Use JvAssert
5778 instead of test and abort.
5779
5780 * java/lang/natString.cc (_Jv_NewStringUtf8Const): Add cast to
5781 remove compiler warning.
5782
5783 Fri Oct 2 12:33:44 1998 Andrew Haley <aph@korai.cygnus.co.uk>
5784
5785 * java/lang/natDouble.cc: zero terminate string.
5786 * strtod.c: Set errno if no digits are found in fraction.
5787
5788 Thu Oct 1 11:48:28 1998 Tom Tromey <tromey@cygnus.com>
5789
5790 * java/lang/reflect/Modifier.java: New file.
5791
5792 * java/lang/VirtualMachineError.java: Rewrote from scratch.
5793 * java/lang/VerifyError.java: Rewrote from scratch.
5794 * java/lang/UnsatisfiedLinkError.java: Rewrote from scratch.
5795 * java/lang/UnknownError.java: Rewrote from scratch.
5796 * java/lang/StackOverflowError.java: Rewrote from scratch.
5797 * java/lang/OutOfMemoryError.java: Rewrote from scratch.
5798 * java/lang/InternalError.java: Rewrote from scratch.
5799 * java/lang/IllegalAccessError.java: Rewrote from scratch.
5800 * java/lang/ExceptionInInitializerError.java: New file.
5801 * java/lang/Error.java: Rewrote from scratch.
5802 * java/lang/ClassFormatError.java: Rewrote from scratch.
5803 * java/lang/ClassCircularityError.java: Rewrote from scratch.
5804 * java/lang/AbstractMethodError.java: Rewrote from scratch.
5805 * java/lang/NoClassDefFoundError.java: Rewrote from scratch.
5806 * java/lang/NoSuchFieldError.java: Rewrote from scratch.
5807 * java/lang/LinkageError.java: Rewrote from scratch.
5808 * java/lang/IncompatibleClassChangeError.java: Rewrote from
5809 scratch.
5810 * java/lang/NoSuchMethodError.java: Rewrote from scratch.
5811
5812 * java/lang/natObject.cc (_Jv_FinalizeObject): New function.
5813 * java/lang/Object.h (Object): Declare _Jv_FinalizeObject as a
5814 friend.
5815 * include/cni.h (JvAllocObject): Moved from prims.cc.
5816 Include Class.h.
5817 * prims.cc (JvAllocObject): Moved to cni.h.
5818 (_Jv_AllocObject): Use _Jv_FinalizeObject.
5819 (finalize_name): Removed.
5820
5821 Wed Sep 30 12:09:34 1998 Tom Tromey <tromey@cygnus.com>
5822
5823 * java/lang/Class.h (Class): Added size() method.
5824 * prims.cc (_Jv_MonitorEnter): Removed.
5825 (_Jv_MonitorExit): Removed.
5826 * java/lang/Object.h (JvSyncInfo): Removed.
5827 * Makefile.in: Rebuilt.
5828 * Makefile.am (nat_headers): Added Cloneable.h,
5829 CloneNotSupportedException.h.
5830 * java/lang/Object.h: Rewrote.
5831 * java/lang/natObject.cc: Rewrote from scratch.
5832 * java/lang/Object.java: Rewrote from scratch.
5833
5834 * java/io/natFile.cc: Conditionally include <dirent.h>.
5835 (list): If no <dirent.h>, always return NULL.
5836 * configure: Rebuilt.
5837 * configure.in: Check for dirent.h.
5838
5839 * prims.cc (lookupArray): Don't use sprintf.
5840
5841 * java/util/Hashtable.java (containsKey): Use `abs' to compute
5842 initial index.
5843 (get): Likewise.
5844 (put): Likewise.
5845 (rehash): Likewise.
5846 (remove): Likewise.
5847
5848 * java/util/Hashtable.java (hsize): Renamed from size to avoid
5849 name conflict with method.
5850
5851 * include/javaprims.h (java::util): Added HashtableEntry.
5852
5853 Tue Sep 29 16:48:01 1998 Warren Levy <warrenl@cygnus.com>
5854
5855 * java/util/Hashtable.java: Rewritten.
5856
5857 Tue Sep 29 00:28:42 1998 Tom Tromey <tromey@cygnus.com>
5858
5859 * java/io/natFileDescriptor.cc (write): Correctly test `write'
5860 return value.
5861 (write): Likewise.
5862
5863 * java/lang/natThread.cc (join): Fixed assertion to refer to `nt',
5864 not `curr_nt'.
5865
5866 * posix-threads.cc (_Jv_CondWait): Now returns int.
5867 * include/javaprims.h (java::lang): Added
5868 IllegalMonitorStateException.
5869 * Makefile.in: Rebuilt.
5870 * Makefile.am (nat_headers): Added IllegalMonitorStateException.h.
5871 * include/no-threads.h (_Jv_CondDestroy): Removed.
5872 (_Jv_MutexDestroy): Removed.
5873 (_Jv_CondWait): Now returns int.
5874 (_Jv_CondNotify): Likewise. Added mutex argument.
5875 (_Jv_CondNotifyAll): Likewise.
5876 (_Jv_MutexLock): Always succeed.
5877 (_Jv_MutexUnlock): Likewise.
5878 * include/posix-threads.h (_Jv_HaveCondDestroy): Define.
5879 (_Jv_HaveMutexDestroy): Define.
5880 (_Jv_CondNotify): Now returns int. Added mutex argument.
5881 (_Jv_CondNotifyAll): Likewise.
5882 * include/quick-threads.h (_Jv_CondDestroy): Removed.
5883 (_Jv_MutexDestroy): Removed.
5884 (_Jv_CondWait): Now returns int.
5885 (_Jv_CondNotify): Likewise. Added mutex argument.
5886 (_Jv_CondNotifyAll): Likewise.
5887 * java/lang/natObject.cc (finalize_sync_info): New function.
5888 (init_mutex): Initialize `init' and register finalizer if
5889 required.
5890 (CHECK): New macro.
5891 (init_mutex): Use it.
5892 (notify): Use it.
5893 (notifyAll): Use it.
5894 (wait): Use it.
5895 (notify): Throw IllegalMonitorStateException on failure.
5896 (notifyAll): Likewise.
5897 (wait): Likewise. Also, throw InterruptedException if
5898 appropriate.
5899 Include cni.h, Thread.h, IllegalMonitorStateException.h,
5900 InterruptedException.h, IllegalArgumentException.h.
5901 * java/lang/Object.h (struct JvSyncInfo): Added `init' member.
5902
5903 * java/lang/natString.cc: Renamed all `JvPriv' functions.
5904 * java/lang/natRuntime.cc: Renamed all `JvPriv' functions.
5905 * java/lang/Object.h: Renamed all `JvPriv' functions (and types).
5906 * java/lang/natObject.cc: Renamed all `JvPriv' functions.
5907 * java/lang/natThread.cc: Renamed all `JvPriv' functions.
5908 * quick-threads.cc: Renamed all `JvPriv' functions.
5909 * prims.cc: Renamed all `JvPriv' functions.
5910 * posix-threads.cc: Renamed all `JvPriv' functions.
5911 * nogc.cc: Renamed all `JvPriv' functions.
5912 * no-threads.cc: Renamed all `JvPriv' functions.
5913 * boehm.cc: Renamed all `JvPriv' functions.
5914 * include/quick-threads.h: Renamed all `JvPriv' functions.
5915 * include/posix-threads.h: Renamed all `JvPriv' functions.
5916 * include/no-threads.h: Renamed all `JvPriv' functions.
5917 * include/jvm.h: Renamed all `JvPrivXXX' functions to `_Jv_XXX'.
5918
5919 * include/no-threads.h (JvPrivCondWait): Wrote minimal
5920 implementation.
5921 (JvPrivCondNotify): Do nothing.
5922 (JvPrivCondNotifyAll): Do nothing.
5923
5924 * prims.cc (processClass): Handle case where state is
5925 DOING_CONSTINIT.
5926
5927 * java/lang/natFirstThread.cc: Include <stdlib.h>
5928
5929 * configure: Rebuilt.
5930 * configure.in: Fixed sense of --enable-libjava-debug.
5931
5932 * java/lang/natThread.cc (join): Declare `t' outside the loop so
5933 it can be used afterward by the assertion.
5934
5935 * configure: Rebuilt.
5936 * configure.in: When cross-compiling, assume alloca.
5937
5938 * java/lang/natDouble.cc: Updated alloca magic to avoid use of
5939 __builtin_alloca (autoconf docs are wrong here).
5940
5941 * java/io/natFileDescriptor.cc (close): Set fd to -1 before
5942 closing.
5943 (available): Use `FD_ZERO' (typo fix).
5944
5945 Tue Sep 29 17:43:30 1998 Andrew Haley <aph@tikka.cygnus.co.uk>
5946
5947 * java/lang/mprec.h, java/lang/mprec.c, java/lang/dtoa.c,
5948 java/lang/natDouble.cc, java/lang/strtod.c: struct _Bigint renamed
5949 struct _Jv_Bigint.
5950 * java/lang/mprec.h, java/lang/mprec.c, java/lang/dtoa.c,
5951 java/lang/natDouble.cc, java/lang/strtod.c: struct _reent renamed
5952 struct _Jv_reent.
5953
5954 * java/lang/natDouble.cc: layout changed to match GNU coding standard.
5955
5956 Tue Sep 29 07:57:13 1998 Anthony Green <green@cygnus.com>
5957
5958 * java/lang/natDouble.cc: Declare alloca safely.
5959
5960 * configure, include/config.h.in: Rebuilt.
5961 * configure.in: Add alloca check.
5962
5963 Tue Sep 29 00:28:42 1998 Tom Tromey <tromey@cygnus.com>
5964
5965 * java/lang/natThread.cc (finish_): Hold mutex for interrupt
5966 condition while calling notify.
5967 (join): Remove `curr_nt' from `nt's join list, not vice versa.
5968 (interrupt): Hold mutex for interrupt condition while calling
5969 notify.
5970
5971 * java/lang/natString.cc (init): Allocate and try to read `count'
5972 characters, not `count - offset' characters.
5973
5974 * java/io/ByteArrayInputStream.java (ByteArrayInputStream):
5975 Correctly compute `count'.
5976
5977 * java/lang/Boolean.java (getBoolean): Return false if property
5978 not found.
5979
5980 * java/lang/System.java (setProperties): Set prop_init.
5981
5982 Mon Sep 28 12:39:25 1998 Tom Tromey <tromey@cygnus.com>
5983
5984 * java/io/PrintStream.java (println): Use line.separator, not
5985 file.separator.
5986 * java/lang/System.java (out, err): Make both autoflush streams.
5987 * java/io/ByteArrayOutputStream.java (write): Increment `count'.
5988
5989 * include/config.h.in: Rebuilt.
5990 * acconfig.h (HAVE_MEMCPY): Removed.
5991 * configure: Rebuilt.
5992 * configure.in: Never define HAVE_MEMCPY.
5993
5994 * java/lang/natString.cc: Don't include OutOfMemoryError.h or
5995 Class.h.
5996 (_Jv_AllocString): Use JvAllocObject again.
5997 * java/lang/Class.h (thread): New field.
5998 (_Jv_AllocString): No longer a friend.
5999 * prims.cc (processClass): Removed dead code. Changed to more
6000 closely follow the Java Language Specification.
6001 (processClass): Return early if already at the right state.
6002
6003 * prims.cc (JvNewStringUTF): Removed.
6004 * include/cni.h (JvNewStringUTF): New function.
6005 (_Jv_NewStringUTF): Declare as `extern "C"'.
6006 * java/lang/natString.cc (_Jv_NewStringUTF): New function.
6007
6008 * java/lang/natDouble.cc: Added copyright info and header
6009 comment. Include <stdlib.h>.
6010 (doubleValueOf): Use alloca, not malloc. Allocate 3 times as many
6011 bytes as are chars in string.
6012
6013 Sat Sep 26 00:19:27 1998 Tom Tromey <tromey@cygnus.com>
6014
6015 * java/util/Hashtable.java (hkeys): Member renamed from to avoid
6016 clash with method.
6017 (hsize): Likewise.
6018
6019 * java/lang/System.java (init_properties): Now native.
6020 * java/lang/natSystem.cc (init_properties): New method.
6021 Include java/util/Properties.h.
6022
6023 * Makefile.in: Rebuilt.
6024 * Makefile.am (nat_headers): Added ByteArrayOutputStream.h,
6025 OutputStreamWriter.h, ByteArrayInputStream.h,
6026 InputStreamReader.h, Writer.h, InputStream.h, OutputStream.h,
6027 Reader.h, Vector.h, SecurityManager.h, FilenameFilter.h,
6028 SyncFailedException.h, EOFException.h, FileNotFoundException.h,
6029 Properties.h, Hashtable.h, Dictionary.h.
6030 (CFLAGS): Removed.
6031
6032 * include/javaprims.h (java::io): Added Reader, Writer,
6033 InputStreamReader, OutputStreamWriter,
6034 UnsupportedEncodingException, ByteArrayInputStream,
6035 ByteArrayOutputStream, EOFException, SyncFailedException,
6036 PushbackInputStream.
6037 (java::lang): Added Cloneable.
6038 (java::util): Added NoSuchElementException, VectorEnumeration,
6039 Dictionary, HashtableEnumeration, PropertiesEnumeration.
6040
6041 * java/io/PipedReader.java: New file.
6042
6043 Fri Sep 25 00:11:25 1998 Tom Tromey <tromey@cygnus.com>
6044
6045 * java/lang/natCharacter.cc (getNumericValue): Use `digit' to pick
6046 up A-Z.
6047
6048 * java/io/io-defs.h: Removed.
6049
6050 * java/io/FileInputStream.java (skip): Use FileDescriptor.seek.
6051 (FileInputStream): Use new constructor. Can throw IOException.
6052
6053 * java/lang/System.java (getProperty): Don't throw
6054 NullPointerException.
6055
6056 * java/io/RandomAccessFile.java: Rewrote from scratch.
6057
6058 * java/io/natFileDescriptor.cc: Include EOFException.h.
6059 (seek): New method.
6060 (length): New method.
6061 (getFilePointer): New method.
6062 (read): New method.
6063 (available): New method.
6064 * java/io/FileDescriptor.java (SET, CUR): New constants.
6065 (seek, length, getFilePointer, read, available): New decls.
6066
6067 * java/io/PipedWriter.java: New file.
6068 * java/io/StringWriter.java: New file.
6069 * java/io/CharArrayWriter.java: New file.
6070 * java/io/CharConversionException.java: New file.
6071 * java/io/BufferedWriter.java: New file.
6072 * java/io/FilterWriter.java: New file.
6073 * java/io/FileWriter.java: New file.
6074
6075 * java/lang/natString.cc: Include ByteArrayOutputStream.h,
6076 OutputStreamWriter.h, NullPointerException.h,
6077 ByteArrayInputStream.h, InputStreamReader.h.
6078 (getBytes): New method.
6079 (init): Throw NullPointerException.
6080 (init): New function.
6081 * java/lang/String.java (getBytes): Added missing decl.
6082 (getBytes): New method.
6083 (String): Added byte[]-based constructors.
6084 (copyValueOf): Wrote.
6085 (init): Declare variant which takes byte array and encoding.
6086 Import java.io.UnsupportedEncodingException.
6087
6088 * java/io/File.java: Rewrote from scratch.
6089 * java/io/natFileDescriptor.cc: Rewrote from scratch.
6090 * java/io/FileDescriptor.java: Rewrote from scratch.
6091 * java/io/FilenameFilter.java: Rewrote from scratch.
6092
6093 Thu Sep 24 13:30:16 1998 Tom Tromey <tromey@cygnus.com>
6094
6095 * java/io/SyncFailedException.java: New file.
6096 * java/io/UTFDataFormatException.java: Rewrote from scratch.
6097 * java/io/InterruptedIOException.java: Rewrote from scratch.
6098 * java/io/FileNotFoundException.java: Rewrote from scratch.
6099 * java/io/EOFException.java: Rewrote from scratch.
6100 * java/io/IOException.java: Rewrote from scratch.
6101 * java/io/PrintStream.java: Rewrote from scratch.
6102 * java/io/DataOutputStream.java: Rewrote from scratch.
6103 * java/io/BufferedOutputStream.java: Rewrote from scratch.
6104 * java/io/FilterOutputStream.java: Rewrote from scratch.
6105 * java/io/ByteArrayOutputStream.java: Rewrote from scratch.
6106 * java/io/PipedOutputStream.java: Rewrote from scratch.
6107 * java/io/FileOutputStream.java: Rewrote from scratch.
6108 * java/io/OutputStream.java: Rewrote from scratch.
6109 * java/io/DataOutput.java: Rewrote from scratch.
6110
6111 Mon Sep 28 22:59:54 1998 Per Bothner <bothner@cygnus.com>
6112
6113 * prims.cc (_Jv_CheckCast): Add missing ! operator.
6114
6115 Mon Sep 28 15:50:06 1998 Anthony Green <green@cygnus.com>
6116
6117 * configure.in: Add --enable-libjava-debug
6118
6119 * Makefile.am (nat_headers): Add java/lang/Float.h and
6120 java/lang/Double.h
6121
6122 * acconfig.h: Add DEBUG and HAVE_MEMCPY.
6123
6124 * Makefile.in, configure, include/config.h.in: Rebuilt.
6125
6126 Mon Sep 28 17:05:58 1998 Andrew Haley <aph@korai.cygnus.co.uk>
6127
6128 * java/lang/Float.java: Rewritten
6129 * java/lang/Double.java: Rewritten
6130 * java/lang/natFloat.cc: toString() added.
6131 * java/lang/natDouble.cc: toString() added.
6132 * java/lang/natDouble.cc: doubleValueOf() added.
6133 * java/lang/dtoa.c, java/lang/mprec.c, java/lang/mprec.h,
6134 java/lang/strtod.c: added.
6135 * ieeefp.h: __sparc added.
6136 * Makefile.am: java/lang/Float.h and java/lang/Double.h added.
6137
6138 Thu Sep 24 13:30:16 1998 Tom Tromey <tromey@cygnus.com>
6139
6140 * include/javaprims.h (java::lang): Added
6141 CloneNotSupportedException.
6142
6143 * java/lang/Object.java (clone): No longer native. Implemented.
6144 * java/lang/natObject.cc (clone): Removed.
6145
6146 Wed Sep 23 12:03:38 1998 Tom Tromey <tromey@cygnus.com>
6147
6148 * prims.cc: Don't make definitions `extern "C"'.
6149 (_Jv_RegisterClass): Renamed from registerClass.
6150 * include/jvm.h (_Jv_ThrowBadArrayIndex): Declare.
6151 (_Jv_NewArray): Likewise.
6152 (_Jv_NewMultiArray): Likewise.
6153 (_Jv_CheckCast): Likewise.
6154 (_Jv_LookupInterfaceMethod): Likewise.
6155 (_Jv_CheckArrayStore): Likewise.
6156 (_Jv_RegisterClass): Likewise.
6157
6158 * acconfig.h (HAVE_FMOD, HAVE_MEMCPY): Removed.
6159 * configure: Rebuilt.
6160 * configure.in: Don't check for fmod; it is provided by the fdlibm
6161 code.
6162 * prims.cc (fmod): Removed.
6163
6164 * java/lang/natString.cc (charAt): Use _Jv_uint.
6165 * java/lang/Class.h (class JvField): Use _Jv_ushort.
6166 * prims.cc (HASH_CHARS): Use _Jv_ushort.
6167 (equalUtf8Consts): Likewise.
6168 (internalAddClass): Use _Jv_uint.
6169 (processClass): Likewise.
6170 * include/javaprims.h (_Jv_ushort): Renamed from uint16.
6171 (_Jv_uint): Renamed from uint32.
6172 (struct _Jv_Utf8Const): Changed members to use new type names.
6173
6174 * configure: Rebuilt.
6175 * configure.in: Don't check for memcpy. Require memmove and a way
6176 to get the time.
6177 * java/lang/natSystem.cc (arraycopy): Removed dead code, and
6178 #error.
6179 (currentTimeMillis): Don't use #error.
6180
6181 Tue Sep 22 18:00:16 1998 Andrew Haley <aph@korai.cygnus.co.uk>
6182
6183 * java/lang/Math.java: static member random renamed to random_ to
6184 avoid conflict with member function of the same name.
6185 * include/javaprims.h: java.util.Random added.
6186
6187 Tue Sep 22 13:53:14 1998 Tom Tromey <tromey@cygnus.com>
6188
6189 * include/java-chartables.h: Regenerated.
6190 * chartables.pl: End COMPACT_CHARACTER #if after fast tables
6191 printed.
6192
6193 Tue Sep 22 17:17:52 1998 Andrew Haley <aph@tikka.cygnus.co.uk>
6194
6195 * java/lang/Math.java: Rewritten.
6196 * java/lang/natMath.cc: New file.
6197 * Files added from fdlibm:
6198 java/lang/e_acos.c, java/lang/k_sin.c, java/lang/sf_floor.c,
6199 java/lang/e_asin.c, java/lang/k_tan.c, java/lang/sf_rint.c,
6200 java/lang/e_atan2.c, java/lang/s_atan.c, java/lang/w_acos.c,
6201 java/lang/e_exp.c, java/lang/s_ceil.c, java/lang/w_asin.c,
6202 java/lang/e_fmod.c, java/lang/s_copysign.c, java/lang/w_atan2.c,
6203 java/lang/e_log.c, java/lang/s_cos.c, java/lang/w_exp.c,
6204 java/lang/e_pow.c, java/lang/s_fabs.c, java/lang/w_fmod.c,
6205 java/lang/e_rem_pio2.c, java/lang/s_floor.c, java/lang/w_log.c,
6206 java/lang/e_remainder.c, java/lang/s_rint.c, java/lang/w_pow.c,
6207 java/lang/e_scalb.c, java/lang/s_scalbn.c, java/lang/w_remainder.c,
6208 java/lang/e_sqrt.c, java/lang/s_sin.c, java/lang/w_sqrt.c,
6209 java/lang/ef_fmod.c, java/lang/s_tan.c, java/lang/wf_fmod.c,
6210 java/lang/k_cos.c, java/lang/sf_ceil.c,
6211 java/lang/k_rem_pio2.c, java/lang/sf_fabs.c,
6212 java/lang/ieeefp.h, java/lang/fdlibm.h
6213 * Makefile.am: rules added for compiling C files from fdlibm.
6214
6215 Mon Sep 21 15:40:58 1998 Tom Tromey <tromey@cygnus.com>
6216
6217 * chartables.pl: Minor documentation fixes.
6218
6219 * configure: Rebuilt.
6220 * configure.in: Fixed --help output for --enable-fast-character.
6221
6222 Thu Sep 17 11:03:27 1998 Tom Tromey <tromey@cygnus.com>
6223
6224 * configure: Rebuilt.
6225 * configure.in: Recognize --enable-fast-character.
6226 * acconfig.h (COMPACT_CHARACTER): New define.
6227 * include/config.h.in: Rebuilt.
6228 * include/java-chartables.h: New file.
6229 * Makefile.in: Rebuilt.
6230 * Makefile.am (nat_files): Added natCharacter.o.
6231 * java/lang/natCharacter.cc: New file.
6232 * chartables.pl (set_attribute): New function.
6233 (@attributes, @second_attributes): New globals.
6234 ($ROMAN_START, $ROMAN_END): Likewise.
6235 (process_char): Call set_attribute when required.
6236 (print_char): Just print hex value.
6237 (print_block): Generate C++ syntax.
6238 (print_numerics): Likewise.
6239 (print_single_map): Likewise.
6240 (print_all_block): Likewise.
6241 (print_case_table): Likewise.
6242 (print_fast_tables): New function.
6243 Generate C++ code suitable for a header file.
6244 * java/lang/Character.java (table_search): Removed.
6245 (digit_value): Now native.
6246 (getNumericValue): Likewise.
6247 (getType): Likewise.
6248 Removed all automatically-generated tables.
6249 (Tamil_Digit_One): Removed.
6250 (isSpaceChar): Now native.
6251 (isTitleCase): Likewise.
6252 (isLowerCase): Likewise.
6253 (isUpperCase): Likewise.
6254 (toLowerCase): Likewise.
6255 (toTitleCase): Likewise.
6256 (toUpperCase): Likewise.
6257 (isDefined): Fixed sense of test.
6258
6259 Wed Sep 16 12:00:19 1998 Tom Tromey <tromey@cygnus.com>
6260
6261 * java/lang/natString.cc (equalsIgnoreCase): Removed obsolete
6262 FIXME comment.
6263 (regionMatches): Likewise.
6264
6265 Tue Sep 15 14:35:12 1998 Tom Tromey <tromey@cygnus.com>
6266
6267 * prims.cc (_Jv_AllocObject): Call _Jv_InitClass on the class.
6268
6269 * java/lang/Class.h (Object): For now, declare _Jv_AllocString as
6270 a friend.
6271 * java/lang/natString.cc (_Jv_AllocString): For now, don't call
6272 _Jv_AllocObject.
6273
6274 * java/lang/natString.cc (toUpperCase): Declare `ch' as a jchar,
6275 not a char.
6276
6277 * java/lang/natClass.cc (isAssignableFrom): Handle arrays.
6278
6279 Fri Sep 11 14:01:08 1998 Tom Tromey <tromey@cygnus.com>
6280
6281 * prims.cc (instanceof_class): Removed.
6282 (instanceof_array): Likewise.
6283 (instanceof): Likewise.
6284 (_Jv_IsInstanceOf): Use Class::isAssignableFrom.
6285 (_Jv_CheckCast): Likewise.
6286 * java/lang/natClass.cc (isAssignableFrom): New method.
6287 * java/lang/Class.java (isAssignableFrom): Now native.
6288
6289 * include/cni.h (JvThrow): Use `extern inline'.
6290 (JvAllocObject): Likewise.
6291 (JvInitClass): Likewise.
6292
6293 * java/lang/natSystem.cc (arraycopy): Only check class of source
6294 object if not null.
6295
6296 * prims.cc (_Jv_CheckArrayStore): Wrote.
6297 (_Jv_MonitorEnter): Prefer `JvThrow'.
6298 Include ArrayStoreException.h.
6299 (_Jv_CheckCast): Indentation cleanup.
6300
6301 Thu Sep 10 18:59:29 1998 Tom Tromey <tromey@cygnus.com>
6302
6303 * chartables.pl: New file.
6304 * java/lang/Character.java: Rewrote from scratch.
6305
6306 Fri Sep 18 18:15:58 1998 Warren Levy <warrenl@cygnus.com>
6307
6308 * java/lang/ArithmeticException.java,
6309 java/lang/ArrayIndexOutOfBoundsException.java,
6310 java/lang/ArrayStoreException.java,
6311 java/lang/ClassCastException.java,
6312 java/lang/ClassNotFoundException.java,
6313 java/lang/CloneNotSupportedException.java,
6314 java/lang/Exception.java, java/lang/IllegalAccessException.java,
6315 java/lang/IllegalArgumentException.java,
6316 java/lang/IllegalMonitorStateException.java,
6317 java/lang/IllegalThreadStateException.java,
6318 java/lang/IndexOutOfBoundsException.java,
6319 java/lang/InstantiationException.java,
6320 java/lang/InterruptedException.java,
6321 java/lang/NegativeArraySizeException.java,
6322 java/lang/NoSuchMethodException.java,
6323 java/lang/NullPointerException.java,
6324 java/lang/NumberFormatException.java,
6325 java/lang/RuntimeException.java, java/lang/SecurityException.java,
6326 java/lang/StringIndexOutOfBoundsException.java: Rewritten.
6327
6328 * java/lang/IllegalStateException.java,
6329 java/lang/NoSuchFieldException.java,
6330 java/lang/UnsupportedOperationException.java: Created.
6331
6332 Fri Sep 18 15:01:42 1998 Warren Levy <warrenl@cygnus.com>
6333
6334 * java/lang/Integer.java, java/lang/Long.java: Rewritten.
6335 * java/lang/Byte.java, java/lang/Short.java (decode): Uncommented.
6336
6337 Fri Sep 11 16:49:19 1998 Per Bothner <bothner@cygnus.com>
6338
6339 * prims.cc (JvRunMain): No longer need to call _Jv_InitClass.
6340
6341 Thu Sep 10 12:23:55 1998 Warren Levy <warrenl@cygnus.com>
6342
6343 * Makefile.am (nat_headers): Added StringIndexOutOfBoundsException.h.
6344
6345 * Makefile.in: Rebuilt.
6346
6347 * include/javaprims.h (java::lang): Added
6348 StringIndexOutOfBoundsException.
6349
6350 * java/lang/String.java: Added header comment and FIXME comment for
6351 missing constructors/methods.
6352 (endsWith): Adjusted offset into string to look at just the last chars.
6353 Commented out undocumented method.
6354
6355 * java/lang/natString.cc: Added includes for
6356 ArrayIndexOutOfBoundsException.h & StringIndexOutOfBoundsException.h.
6357 (String::init): Throw StringIndexOutOfBoundsException.
6358 (String::charAt): Throw StringIndexOutOfBoundsException.
6359 (String::substring): Throw StringIndexOutOfBoundsException.
6360 (String::getChars): Throw ArrayIndexOutOfBoundsException.
6361 (String::getBytes): Throw ArrayIndexOutOfBoundsException.
6362 (String::compareTo): Return difference/offset between chars/strings.
6363
6364 Tue Sep 8 13:22:33 1998 Warren Levy <warrenl@cygnus.com>
6365
6366 * java/lang/Boolean.java (TYPE): Added comment.
6367
6368 * java/lang/Byte.java (decode): Added - commented out until dependent
6369 code for Integer is written.
6370 (compareTo): JDK 1.2 methods written.
6371 (hashCode): Added comment to note that values have been verified.
6372
6373 * java/lang/Short.java (decode): Added - commented out until dependent
6374 code for Integer is written.
6375 (compareTo): JDK 1.2 methods written.
6376 (hashCode): Added comment to note that values have been verified.
6377
6378 * java/lang/Comparable.java: Created - JDK 1.2 interface.
6379
6380 Fri Sep 4 10:36:35 1998 Tom Tromey <tromey@cygnus.com>
6381
6382 * include/javaprims.h (java::lang): Added VirtualMachineError,
6383 OutOfMemoryError.
6384 * Makefile.in: Rebuilt.
6385 * Makefile.am (nat_headers): Added OutOfMemoryError.h,
6386 VirtualMachineError.h.
6387 * prims.cc (_Jv_NewPrimArray): Throw OutOfMemoryError.
6388 (lookupArray): Likewise.
6389 (makeUtf8Const): Likewise.
6390 (_Jv_AllocObject): Likewise.
6391 (_Jv_NewObjectArray): Likewise.
6392 Include OutOfMemoryError.h.
6393
6394 * java/io/natFileDescriptor.cc (newstr): Removed. Changed callers
6395 to use JvNewStringLatin1.
6396
6397 * java/io/io-defs.h: Include java/lang/IOException.h.
6398 * Makefile.in: Rebuilt.
6399 * Makefile.am (nat_headers): Added
6400 ArrayIndexOutOfBoundsException.h,
6401 ClassFormatError.h,ClassNotFoundException.h,
6402 ClassCircularityError.h, ClassCastException.h,
6403 IncompatibleClassChangeError.h, AbstractMethodError.h,
6404 IllegalAccessError.h, LinkageError.h, Error.h,
6405 NegativeArraySizeException.h, IOException.h.
6406 * include/cni.h (SignalError): Removed declaration.
6407 * java/util/natDate.cc (setTime): Use JvFail, not sorry.
6408 * java/lang/natObject.cc (clone): Use JvFail, not sorry.
6409 * java/lang/natClass.cc (getInterfaces): Use JvFail, not sorry.
6410 (newInstance): Likewise.
6411 (forName): Likewise.
6412 * java/io/natFileDescriptor.cc (open_read_write): Use JvFail, not
6413 sorry.
6414 (read): Use JvThrow, not SignalError.
6415 (read): Likewise.
6416 (write): Likewise.
6417 (skip): Likewise.
6418 (close): Likewise.
6419 (open_read): Likewise.
6420 (open_write): Likewise.
6421 (ftell): Likewise.
6422 (fseek): Likewise.
6423 (newstr): New function.
6424 * java/io/natFile.cc (isDirectoryUnchecked): Use JvFail, not
6425 sorry.
6426 (lastModifiedUnchecked): Likewise.
6427 (lengthUnchecked): Likewise.
6428 * include/javaprims.h (sorry): Removed declaration.
6429 (java::lang): Added ArrayIndexOutOfBoundsException, LinkageError,
6430 ClassFormatError, ClassNotFoundException, ClassCircularityError,
6431 ClassCastException, IncompatibleClassChangeError,
6432 AbstractMethodError, IllegalAccessError, NegativeArraySizeException.
6433 * prims.cc (instanceof_array): Use JvFail, not sorry.
6434 (sorry): Removed.
6435 Include ArrayIndexOutOfBoundsException.h,
6436 ClassFormatError.h,ClassNotFoundException.h,
6437 ClassCircularityError.h, ClassCastException.h,
6438 IncompatibleClassChangeError.h, AbstractMethodError.h,
6439 IllegalAccessError.h, NegativeArraySizeException.h.
6440 (_Jv_ThrowBadArrayIndex): Implemented.
6441 (JvNewStringUTF): Use JvFail, not sorry.
6442 (_Jv_FindClass): Likewise.
6443 (_Jv_NewArray): Likewise.
6444 (throwException): Removed.
6445 (getClass): Use JvThrow.
6446 (processClass): Likewise.
6447 (_Jv_NewObjectArray): Likewise.
6448 (_Jv_NewMultiArray): Likewise.
6449 (_Jv_CheckCast): Likewise.
6450 (_Jv_LookupInterfaceMethod): Likewise.
6451 (SignalError): Removed.
6452 (getClass): Use _Jv_NewStringUtf8Const to create String.
6453
6454 * java/lang/natSystem.cc (arraycopy): Throw
6455 ArrayIndexOutOfBoundsException, not IndexOutOfBoundsException.
6456
6457 * Makefile.in: Rebuilt.
6458 * Makefile.am (GCJH): Renamed. Now use `gcjh'. Changed all
6459 users.
6460 * include/java-array.h: Mention gcjh, not gjavah.
6461
6462 * java/io/natFile.cc (existsUnchecked): Use JvGetStringUTFRegion.
6463 (canReadUnchecked): Likewise.
6464 (canWriteUnchecked): Likewise.
6465 (isFileUnchecked): Likewise.
6466 * java/io/natFileDescriptor.cc: Don't include cni.h.
6467
6468 * java/lang/Thread.java (run__): Declare.
6469 * java/lang/natThread.cc (run__): New method, to avoid compiler
6470 warning.
6471 (start): Use run__, not run_.
6472
6473 * java/io/io-defs.h: Include cni.h and jvm.h.
6474
6475 Thu Sep 3 18:20:08 1998 Per Bothner <bothner@cygnus.com>
6476
6477 Re-implement java.lang.String, using "COMPACT_STRINGS" representation.
6478 * prims.cc (JvAllocString, JvNewString, JvNewStringlatin1): Moved
6479 to natString.cc (with suitable renaming, inlines etc).
6480 (javaString2CString): Removed. Subsumed by _Jv_GetStringUTFRegion.
6481 * java/lang/Class.h: Renamed Utf8Const to _Jv_Utf8Const.
6482 * java/lang/String.h: Removed - now generated using gjavah.
6483 * java/lang/String.java: Re-written from scratch. Many native methods.
6484 * java/lang/natDouble.cc, java/util/natDate.cc: #include <cni.h>.
6485 * java/lang/natString.cc: Many functions re-written for "compact
6486 strings" representation, or native java.lang.String methods added.
6487 (Utf8Const2JavaString): Renamed to _Jv_NewStringUtf8Const.
6488 (_Jv_GetStringUTFLength, _Jv_GetStringUTFRegion): New methods.
6489 * java/lang/natClass.cc (getName): Use new _Jv_NewStringUtf8Const.
6490 * java/io/natFileDescriptor.cc: Use new JvGetStringUTFRegion.
6491 * include/cni.h: Add inline method.
6492 * include/java-array.h (jobjectArrayjchar): gjavah bug work-around.
6493 * include/javaprims.h: Moved some stuff frm String.h.
6494 * include/jvm.h (UTF8_GET, Utf8Const, StringClass): Moved here.
6495 * Makefile.am (nat_header): Added Character.h and String.h.
6496 (String.h): Add new rule.
6497
6498 Thu Sep 3 10:28:16 1998 Tom Tromey <tromey@cygnus.com>
6499
6500 * no-threads.cc: Include config.h, cni.h, jvm.h. Don't include
6501 java-assert.h.
6502 * posix-threads.cc: Include cni.h, jvm.h.
6503 * quick-threads.cc: Include cni.h, jvm.h.
6504 * nogc.cc: Include cni.h, not javaprims.h.
6505 * java/lang/natFirstThread.cc: Include cni.h, jvm.h.
6506 * java/lang/natThread.cc: Rearranged #include ordering. Don't
6507 include java-assert.h.
6508 * java/lang/natSystem.cc: Include cni.h. Don't include
6509 java-assert.h.
6510 * java/lang/natRuntime.cc: Include cni.h. Don't include
6511 java-assert.h.
6512 * prims.cc: Rearranged #include ordering. Don't include
6513 java-array.h or java-assert.h.
6514 * boehm.cc: Include config.h, cni.h.
6515 * exception.cc: Include config.h, cni.h.
6516 * include/jvm.h: Include java-assert.h.
6517 * include/cni.h: Include java/lang/Object.h. Don't include
6518 java-threads.h or java-array.h.
6519
6520 Thu Sep 3 16:03:08 1998 Warren Levy <warrenl@cygnus.com>
6521
6522 * java/lang/Boolean.java: Rewritten.
6523
6524 Thu Sep 3 10:28:16 1998 Tom Tromey <tromey@cygnus.com>
6525
6526 * java/lang/natFirstThread.cc (main_func): New typedef.
6527 (run): Use main_func, not JvPrivThreadStartFunc.
6528 * include/no-threads.h (JvPrivThreadStartFunc): Use correct
6529 argument type.
6530 * include/posix-threads.h (JvPrivThreadStartFunc): Use correct
6531 argument type.
6532 * include/quick-threads.h (JvPrivThreadStartFunc): Use correct
6533 argument type.
6534
6535 Can't throw Java exceptions with C++ `throw':
6536 * quick-threads.cc (qthrow): Use _Jv_Throw, not throw.
6537 * java/lang/natThread.cc (join): Use _Jv_Throw, not throw.
6538 (setPriority): Likewise.
6539 (sleep): Likewise.
6540 (start): Likewise.
6541 (stop): Likewise.
6542 * java/lang/natSystem.cc (arraycopy): Use _Jv_Throw, not throw.
6543 * prims.cc (_Jv_MonitorEnter): Use _Jv_Throw, not throw.
6544
6545 Can't catch Java exceptions from C++:
6546 * java/lang/natThread.cc (finish_): New method.
6547 (run_): Removed.
6548 * java/lang/Thread.java (run_): Rewrote in Java.
6549 (finish_): New native method.
6550
6551 Wed Sep 2 17:30:39 1998 Warren Levy <warrenl@cygnus.com>
6552
6553 * java/lang/Cloneable.java, java/lang/Number.java: Rewritten.
6554
6555 * include/javaprims.h (java::io): Added Serializable.
6556
6557 Wed Sep 2 15:22:00 1998 Warren Levy <warrenl@cygnus.com>
6558
6559 * java/util/EmptyStackException.java,
6560 java/util/NoSuchElementException.java: Rewritten.
6561
6562 * java/util/ConcurrentModificationException.java,
6563 java/util/MissingResourceException.java,
6564 java/util/TooManyListenersException.java: Created.
6565
6566 Wed Sep 2 13:36:57 1998 Tom Tromey <tromey@cygnus.com>
6567
6568 * include/cni.h (JvThrow): New function.
6569 * include/javaprims.h (_Jv_Throw): Declare.
6570
6571 Wed Sep 2 14:07:48 1998 Warren Levy <warrenl@cygnus.com>
6572
6573 * java/util/Observable.java: Rewritten.
6574
6575 Wed Sep 2 13:36:57 1998 Tom Tromey <tromey@cygnus.com>
6576
6577 * prims.cc (_Jv_MonitorExit): Assert that object is non-null.
6578 (_Jv_MonitorEnter): Throw NullPointerException if object is null.
6579 Include NullPointerException.h.
6580
6581 Tue Sep 1 12:07:35 1998 Tom Tromey <tromey@cygnus.com>
6582
6583 * java/lang/natSystem.cc (arraycopy): Removed overlapping-copy
6584 assignability checks. Don't bother using memcpy.
6585
6586 * quick-threads.cc (JvPrivThreadStart): Don't call coop_start.
6587 (started): Removed.
6588 * include/quick-threads.h (JvPrivThreadWait): New function.
6589 * include/no-threads.h (JvPrivThreadWait): New function.
6590 * include/posix-threads.h (JvPrivThreadWait): New function.
6591 * prims.cc (JvRunMain): Call JvPrivThreadWait.
6592
6593 * java/lang/natSystem.cc (arraycopy): Do nothing if count is 0.
6594
6595 * java/lang/natSystem.cc (arraycopy): Multiply both src and dst
6596 offsets by size of type that is being copied.
6597
6598 * java/lang/natThread.cc (start): Don't pass `object' argument to
6599 JvPrivThreadStart.
6600 * no-threads.cc (JvPrivThreadStart): Removed `object' argument.
6601 * posix-threads.cc (JvPrivThreadStart): Removed `object'
6602 argument.
6603 * quick-threads.cc (JvPrivThreadStart): Removed `object' argument;
6604 always pass thread as object.
6605 * include/quick-threads.h, include/posix-threads.h,
6606 include/no-threads.h (JvPrivThreadStart): Removed `object'
6607 argument.
6608
6609 Mon Aug 31 19:11:53 1998 Warren Levy <warrenl@cygnus.com>
6610
6611 * java/util/Dictionary.java: Rewritten.
6612
6613 Mon Aug 31 14:35:55 1998 Tom Tromey <tromey@cygnus.com>
6614
6615 * include/quick-threads.h (JvPrivThreadInitData): Use 0, not NULL.
6616 (JvPrivThreadDestroy): Likewise.
6617
6618 Mon Aug 31 12:56:01 1998 Warren Levy <warrenl@cygnus.com>
6619
6620 * java/lang/natRuntime.cc (exit): Changed final call to ::exit.
6621
6622 Thu Aug 27 12:24:40 1998 Tom Tromey <tromey@cygnus.com>
6623
6624 * java/lang/natSystem.cc: Rewrote from scratch.
6625 * java/lang/System.java: Rewrote from scratch.
6626 * java/lang/Class.h (Class): Declare isAssignableFrom.
6627 * include/javaprims.h (java::lang): Added ArrayStoreException,
6628 IndexOutOfBoundsException.
6629 * Makefile.in: Rebuilt.
6630 * Makefile.am (nat_headers): Added ArrayStoreException.h,
6631 IndexOutOfBoundsException.h.
6632 * java/lang/natObject.cc (hashCode): Use _Jv_HashCode.
6633 * include/jvm.h (_Jv_HashCode): New function.
6634
6635 * java/lang/natThread.cc (suspend): Call checkAccess.
6636 (resume): Likewise.
6637 * java/lang/Thread.java (setDaemon): Call checkAccess.
6638
6639 Thu Aug 27 12:24:40 1998 Tom Tromey <tromey@cygnus.com>
6640
6641 * java/lang/Runtime.java: Rewrote from scratch.
6642 * java/lang/natRuntime.cc: Rewrote from scratch.
6643
6644 * nogc.cc (JvPrivGCTotalMemory): New function.
6645 (JvPrivGCFreeMemory): Likewise.
6646 (total): New global.
6647 (JvPrivAllocObj): Increment total.
6648 (JvPrivAllocArray): Likewise.
6649 (JvPrivAllocBytes): Likewise.
6650 * include/jvm.h: Declare JvPrivGCTotalMemory, JvPrivGCFreeMemory.
6651 * boehm.cc (JvPrivGCTotalMemory): New function.
6652 (sum_blocks): Likewise.
6653 (JvPrivGCFreeMemory): Likewise.
6654
6655 Wed Aug 26 12:30:32 1998 Tom Tromey <tromey@cygnus.com>
6656
6657 * include/javaprims.h (java::lang): Added FirstThread.
6658 * java/lang/natFirstThread.cc: New file.
6659 * java/lang/FirstThread.java: New file.
6660 * prims.cc (main_signature): Removed.
6661 (main_name): Removed.
6662 #include FirstThread.h.
6663 * Makefile.in: Rebuilt.
6664 * Makefile.am (TFRIEND): Removed.
6665 (java/lang/Thread.h): Likewise.
6666 (FTFRIEND): New macro.
6667 (java/lang/FirstThread.h): New target.
6668 (nat_files): Added natFirstThread.o.
6669 (nat_headers): Added FirstThread.h.
6670 * include/jvm.h (_Jv_StartFirstThread): Don't declare.
6671 * java/lang/natThread.cc (_Jv_StartFirstThread): Removed.
6672
6673 * java/lang/Thread.java (setName): Throw IllegalArgumentException
6674 if name is null.
6675 (Thread): Likewise.
6676
6677 * java/lang/natThread.cc (start): Synchronize the thread.
6678 (stop): Synchronize the thread.
6679
6680 * java/lang/ThreadDeath.java: Rewrote from scratch.
6681
6682 * Makefile.in: Rebuilt.
6683 * Makefile.am (TGFRIEND): New macro.
6684 (java/lang/ThreadGroup.h): New target.
6685 ($(nat_files) prims.o boehm.o nogc.o): Native files depend on the
6686 native headers.
6687 ($(javao_files) $(nat_files) prims.o boehm.o nogc.o): Removed.
6688
6689 * nogc.cc: Include config.h.
6690
6691 * java/lang/ThreadGroup.java: Rewrote from scratch.
6692
6693 Tue Aug 25 00:12:54 1998 Tom Tromey <tromey@cygnus.com>
6694
6695 * java/lang/Thread.java (checkAccess): Only call in to security
6696 manager if it exists.
6697 (Thread): Don't check access when creating the first thread. Add
6698 this thread to the appropriate ThreadGroup.
6699
6700 * java/lang/natThread.cc (run_): Call uncaughtException method on
6701 the ThreadGroup.
6702
6703 * java/lang/Runnable.java: Rewrote from scratch.
6704 * java/lang/Thread.java: Updated copyright comment to correct
6705 form.
6706
6707 Wed Aug 26 15:16:18 1998 Warren Levy <warrenl@cygnus.com>
6708
6709 * java/util/Random.java: Rewritten.
6710
6711 Wed Aug 26 14:25:39 1998 Alexandre Petit-Bianco <apbianco@cygnus.com>
6712
6713 * prims.cc (_Jv_NewMultiArray): Need one more slot to store
6714 trailing 0 in array[].
6715
6716 Wed Aug 26 12:21:06 1998 Anthony Green <green@cygnus.com>
6717
6718 * Makefile.am (AM_MAKEFLAGS): Remove RUNTEST, EXPECT,
6719 and RUNTESTFLAGS from AM_MAKEFLAGS.
6720 (SUBDIRS): Conditionally include testsuite.
6721 * Makefile.in: Rebuilt.
6722
6723 Tue Aug 25 18:14:53 1998 Anthony Green <green@cygnus.com>
6724
6725 * java/lang/Object.h: Include java-assert.h.
6726
6727 Tue Aug 25 17:33:57 1998 Anthony Green <green@cygnus.com>
6728
6729 * Makefile.am: Add testsuite directory.
6730 * configure.in: Build testsuite/Makefile.
6731 * Makefile.in, configure: Rebuilt.
6732
6733 Tue Aug 25 00:12:54 1998 Tom Tromey <tromey@cygnus.com>
6734
6735 * prims.cc (JvRunMain): Use _Jv_StartFirstThread.
6736 * include/jvm.h (_Jv_StartFirstThread): Declare.
6737
6738 * include/javaprims.h (java::lang): Added Exception,
6739 RuntimeException.
6740
6741 * Makefile.in: Rebuilt.
6742 * Makefile.am (nat_headers): Added NullPointerException.h,
6743 InterruptedException.h, IllegalArgumentException.h, Exception.h,
6744 Throwable.h, RuntimeException.h, IllegalThreadStateException.h.
6745 (java/lang/Thread.h): New target.
6746 (TFRIEND): New macro
6747
6748 * include/java-assert.h (JvFail): Use 0 and not NULL.
6749
6750 * posix-threads.cc (JvPrivThreadStart): Use getPriority() method
6751 instead of assuming we are a friend of Thread.
6752 * quick-threads.cc (JvPrivThreadStart): Use isDaemon() method
6753 instead of assuming we are a friend of Thread.
6754
6755 Mon Aug 24 15:58:36 1998 Tom Tromey <tromey@cygnus.com>
6756
6757 * java/lang/natThread.cc: Rewrote from scratch.
6758 * java/lang/Thread.java: Rewrote from scratch.
6759 * prims.cc (JvRunMain): Use new Thread constructor.
6760 * include/javaprims.h (java::lang): Added InterruptedException.
6761 * Makefile.in: Rebuilt.
6762 * Makefile.am (nat_headers): Added java/lang/Thread.h.
6763 * java/lang/Thread.h: Removed.
6764 * quick-threads.cc (JvPrivThreadStart): Added `data' argument.
6765 * no-threads.cc (JvPrivThreadStart): Added JvPrivThread_t
6766 argument.
6767 * posix-threads.cc (JvPrivThreadJoin): Removed.
6768 (JvPrivThreadInitData): Don't initialize join_mutex or join_cond.
6769 (really_start): Don't notify join_cond.
6770 (JvPrivThreadStart): Added `data' argument.
6771 * include/no-threads.h (JvPrivThreadInterrupt): Removed.
6772 (JvPrivThreadJoin): Likewise.
6773 Use JvFail instead of sorry.
6774 (JvPrivThreadSuspend): Removed.
6775 (JvPrivThreadResume): Removed.
6776 * include/quick-threads.h (JvPrivThreadInterrupt): Removed.
6777 (JvPrivThreadJoin): Likewise.
6778 (JvPrivThreadSuspend): Use JvFail.
6779 (JvPrivThreadResume): Likewise.
6780 (JvPrivThreadSuspend): Removed.
6781 (JvPrivThreadResume): Likewise.
6782 * include/posix-threads.h (JvPrivThreadInterrupt): Removed.
6783 (JvPrivThread_t): Removed join_mutex, join_cond.
6784 Use JvFail instead of sorry.
6785 (JvPrivThreadSuspend): Removed.
6786 (JvPrivThreadResume): Likewise.
6787
6788 Tue Aug 25 12:50:13 1998 Warren Levy <warrenl@cygnus.com>
6789
6790 * java/util/Observer.java: Rewritten
6791 * java/util/Enumeration.java: Rewritten
6792
6793 Tue Aug 25 11:33:54 1998 Warren Levy <warrenl@cygnus.com>
6794
6795 * java/util/StringTokenizer.java: Rewritten
6796 * java/util/Stack.java: Added COPYRIGHT-TBD comment
6797 * java/util/Vector.java: Added COPYRIGHT-TBD comment
6798 * java/io/Serializable.java: Added COPYRIGHT-TBD comment
6799
6800 Fri Aug 21 10:14:22 1998 Tom Tromey <tromey@cygnus.com>
6801
6802 * include/java-assert.h (JvFail): Call _Jv_Abort even when DEBUG
6803 not defined.
6804
6805 * no-threads.cc (JvPrivThreadStart): Use JvAssert.
6806 Include java-assert.h.
6807 * include/java-assert.h: New file.
6808 * prims.cc (_Jv_Abort): New function.
6809 Include java-assert.h, not assert.h.
6810 (_Jv_MonitorExit): Use JvAssert.
6811 (resolveConstants): Likewise.
6812 (processClass): Likewise.
6813 (JvRunMain): Assert that method is found.
6814
6815 * configure: Rebuilt.
6816 * configure.in: Check for test subdir.
6817 * Makefile.in: Rebuilt.
6818 * Makefile.am (SUBDIRS): Conditional on TESTSUBDIR.
6819
6820 * prims.cc (JvRunMain): Use NORM_PRIORITY.
6821 * java/lang/Thread.h (Thread): Added NORM_PRIORITY.
6822
6823 * prims.cc (resolveConstants): Removed unused variables.
6824 (processClass): Likewise.
6825
6826 * include/quick-threads.h (JvPrivThreadCurrent): Use
6827 coop_getspecific.
6828 * quick-threads.cc (destroy_data): New function.
6829 (JvPrivInitThreads): Create key.
6830 (JvPrivThreadKey): New global.
6831 (JvPrivThreadStart): Use coop_setspecific.
6832
6833 * include/quick-threads.h, include/posix-threads.h,
6834 include/no-threads.h, no-threads.cc, quick-threads.cc,
6835 posix-threads.cc, nogc.cc, boehm.cc: Added copyright comment.
6836
6837 Thu Aug 20 10:57:30 1998 Tom Tromey <tromey@cygnus.com>
6838
6839 * include/no-threads.h (JvPrivThreadInitData): Don't set
6840 JvPrivOnlyThread.
6841
6842 * include/quick-threads.h (JvPrivCondWait): coop function now
6843 takes microseconds.
6844 (JvPrivThreadJoin): Likewise.
6845
6846 * java/lang/Thread.h (Thread): Updated declaration of
6847 JvPrivThreadStart.
6848 * include/quick-threads.h, include/posix-threads.h: Updated
6849 declaration of JvPrivThreadStart.
6850 * include/no-threads.h (JvPrivThreadStart): Changed definition
6851 into declaration.
6852 * no-threads.cc (JvPrivThreadStart): Removed `data' argument.
6853 * quick-threads.cc (JvPrivThreadStart): Removed `data' argument.
6854 * posix-threads.cc (JvPrivThreadStart): Removed `data' argument.
6855
6856 Wed Aug 19 14:53:59 1998 Tom Tromey <tromey@cygnus.com>
6857
6858 * quick-threads.cc (qthrow): New function.
6859 (JvPrivInitThreads): New function.
6860 (started): New global.
6861 (JvPrivThreadStart): Call coop_start if required.
6862 * include/quick-threads.h (JvPrivThreadCancel): Implement.
6863 (JvPrivThreadDestroy): Likewise.
6864 (JvPrivInitThreads): Removed.
6865 * include/posix-threads.h (JvPrivThreadCancel): Added error
6866 argument.
6867 * java/lang/natThread.cc (stop_): Pass exception to
6868 JvPrivThreadCancel.
6869
6870 Tue Aug 18 12:58:22 1998 Tom Tromey <tromey@cygnus.com>
6871
6872 * include/javaprims.h (java::lang): Added
6873 IllegalArgumentException, IllegalThreadStateException, Math,
6874 NullPointerException, ThreadDeath.
6875 (java::util): Added Enumeration.
6876
6877 * Makefile.in: Rebuilt.
6878 * Makefile.am (nat_headers): Added java/lang/ThreadGroup.h.
6879
6880 * java/lang/ThreadGroup.java (ThreadGroup): No-args constructor
6881 now public.
6882 (threadsv): Renamed from threads to avoid clash in C++ header.
6883 (groupsv): Likewise.
6884 * include/no-threads.h (JvPrivThreadStart): Removed.
6885 * no-threads.cc (JvPrivThreadStart): New function.
6886 * java/lang/Thread.java (Thread): New constructor for internal use.
6887 * java/lang/Thread.h (Thread): Declare JvRunMain as friend.
6888 (Thread): Declare constructor.
6889 * prims.cc (JvRunMain): Create the initial Thread and
6890 ThreadGroup.
6891 Include <java/lang/Thread.h> and <java/lang/ThreadGroup.h>.
6892 * posix-threads.cc (JvPrivThreadStart): Added `thread' argument.
6893 Removed `daemon' argument.
6894
6895 * prims.cc (JvRunMain): Call _Jv_InitializeSyncMutex.
6896 * java/lang/Object.h (Object): Declare _Jv_InitializeSyncMutex as
6897 a friend.
6898 * java/lang/natObject.cc (_Jv_InitializeSyncMutex): New function.
6899
6900 * Makefile.in: Rebuilt.
6901 * Makefile.am (INCLUDES): Include THREADINCS.
6902
6903 * configure: Rebuilt.
6904 * configure.in: Recognize `qt' as a threads package.
6905
6906 Thu Aug 20 12:42:32 1998 Warren Levy <warrenl@cygnus.com>
6907
6908 * java/util/Stack.java (pop): Null out topmost node for robustness.
6909
6910 Thu Aug 20 12:30:30 1998 Warren Levy <warrenl@cygnus.com>
6911
6912 * java/util/Stack.java: Rewritten.
6913 * java/util/Vector.java (isEmpty): Simplified expression.
6914
6915 Wed Aug 19 18:02:19 1998 Warren Levy <warrenl@cygnus.com>
6916
6917 * prims.cc (_Jv_NewObjectArray): Renamed from JvNewObjectArray.
6918 (soft_anewarray): Removed, _Jv_NewObjectArray used instead.
6919
6920 * include/java-array.h (JvNewObjectArray): Created inline to
6921 _Jv_NewObjectArray.
6922
6923 * java/lang/Class.h (_Jv_NewObjectArray): Renamed from
6924 JvNewObjectArray.
6925
6926 Wed Aug 19 14:12:02 1998 Warren Levy <warrenl@cygnus.com>
6927
6928 * java/util/Vector.java: Rewritten.
6929 * java/io/Serializable.java: Created.
6930
6931 Fri Aug 14 10:31:54 1998 Tom Tromey <tromey@cygnus.com>
6932
6933 * java/lang/Float.java (NEGATIVE_INFINITY, POSITIVE_INFINITY):
6934 Infinity is 1/0, not 1/1.
6935
6936 * boehm.cc (JvPrivAllocArray): Use GC_generic_malloc.
6937
6938 * configure: Rebuilt.
6939 * configure.in: Removed duplicate AC_ARG_WITH.
6940
6941 Thu Aug 13 14:51:47 1998 Warren Levy <warrenl@cygnus.com>
6942
6943 * prims.cc (_Jv_ThrowBadArrayIndex): Renamed from
6944 soft_badarrayindex.
6945 (_Jv_InitClass): Renamed from soft_initialise_class.
6946 (_Jv_NewMultiArray): Renamed from soft_multianewarray.
6947 (_Jv_CheckCast): Renamed from soft_checkcast.
6948 (_Jv_LookupInterfaceMethod): Renamed from soft_lookupinterfacemethod.
6949 (_Jv_CheckArrayStore): Renamed from soft_checkarraystore.
6950 (JvRunMain): Call JvInitClass instead of soft_initialise_class.
6951 * include/cni.h (JvInitClass): New function.
6952 (_Jv_InitClass): Renamed from soft_initialise_class.
6953
6954 Wed Aug 12 10:07:04 1998 Tom Tromey <tromey@cygnus.com>
6955
6956 * configure: Rebuilt.
6957 * configure.in (CXX): Don't set.
6958 * Makefile.in: Rebuilt.
6959 * Makefile.am (AM_CXXFLAGS): New macro.
6960
6961 * Makefile.in: Rebuilt.
6962 * Makefile.am ($(javao_files) $(nat_files) prims.o boehm.o
6963 nogc.o): New target.
6964
6965 * boehm.cc (mark_obj): Update PUSH_CONTENTS call for new Boehm
6966 GC.
6967 (mark_array): Likewise.
6968
6969 Tue Aug 11 11:44:53 1998 Per Bothner <bothner@cygnus.com>
6970
6971 * java/lang/Class.h (JvMethod): Removed some unused fields.
6972 (JvField.info): Removed unused idx union variant.
6973
6974 Mon Aug 10 15:00:14 1998 Tom Tromey <tromey@cygnus.com>
6975
6976 * prims.cc (makeUtf8Const): Mask off high bits of hash value to
6977 match compiler.
6978
6979 Mon Aug 3 16:13:54 1998 Per Bothner <bothner@cygnus.com>
6980
6981 * configure.in, configure (CXX): Add -fvtable-thunks.
6982
6983 Thu Jul 30 14:34:47 1998 Per Bothner <bothner@cygnus.com>
6984
6985 * java/lang/Object.java (finalize): Move first.
6986 * java/lang/Object.h (_JvObjectPrefix): New dummy base class.
6987 (Object): Re-arrange order to match Object.java.
6988
6989 Tue Jul 28 21:42:16 1998 Per Bothner <bothner@cygnus.com>
6990
6991 * prims.cc (hashUtf8String): Fix - use new JavaSoft specification.
6992 * java/lang/natString.cc (hashChars): Likewise.
6993
6994 * prims.cc (RuntimeClass): New macro.
6995 (JvRunMain): Do soft_initialise_class of RuntimeClass before exit.
6996
6997 Mon Jul 27 22:20:10 1998 Tom Tromey <tromey@cygnus.com>
6998
6999 * Makefile.in: Rebuilt.
7000 * Makefile.am (AM_MAKEFLAGS): New macro.
7001
7002 Fri Jul 24 11:21:24 1998 Tom Tromey <tromey@cygnus.com>
7003
7004 * nogc.cc: Include <javaprims.h>.
7005
7006 * Makefile.in: Rebuilt.
7007 * Makefile.am (GJAVAH): gjavah no longer in java subdir.
7008
7009 Thu Jul 23 11:38:40 1998 Tom Tromey <tromey@cygnus.com>
7010
7011 * exception.cc (terminate): Removed.
7012 (unexpected): Removed.
7013
7014 * configure: Rebuilt.
7015 * configure.in: Handle case where target subdir is ".".
7016
7017 * configure: Rebuilt.
7018 * configure.in: Compute COMPPATH based on --with-target-subdir
7019 option. Added --with-target-subdir and --with-cross-host. Use
7020 --with-cross-host to determine when a cross compiler is in use.
7021
7022 * Makefile.in: Rebuilt.
7023 * Makefile.am (GJAVAH): Include COMPPATH.
7024 * configure: Rebuilt.
7025 * configure.in: Subst COMPPATH.
7026
7027 Mon Jul 20 16:13:43 1998 Tom Tromey <tromey@cygnus.com>
7028
7029 * prims.cc (lockMutex): Removed.
7030 (unlockMutex): Likewise.
7031 (processClass): Lock the class using a JvSynchronize object.
7032
7033 Fri Jul 17 11:27:48 1998 Tom Tromey <tromey@cygnus.com>
7034
7035 * java/lang/natString.cc (gc_calloc_fixed): Removed.
7036 (gc_free_fixed): Removed.
7037 (rehash): Use JvPrivAllocBytes, not gc_calloc_fixed; don't bother
7038 freeing old value of strhash.
7039
7040 * exception.cc (_Jv_type_matcher): Cast first argument to
7041 _Jv_IsInstanceOf.
7042
7043 Thu Jul 16 14:51:44 1998 Tom Tromey <tromey@cygnus.com>
7044
7045 * include/java-array.h (jstringArray): New type.
7046 * java/lang/natSystem.cc (setProperty): Removed.
7047 (initProperties): Directly call JvNewStringLatin1 for arguments.
7048 * java/util/natDate.cc: Include java/util/Date.h, not
7049 java-util.h.
7050 (setTime): Removed.
7051 * java/io/FileDescriptor.java (available): No longer static.
7052 * java/lang/natDouble.cc (Double): Removed class definition.
7053 * include/javaprims.h (java::lang::Number): Declare.
7054 (java::lang::NumberFormatException): Likewise.
7055 (java::io::FilenameFilter): Likewise.
7056 (java::lang::Character): Likewise.
7057 (java::lang::Error): Likewise.
7058 (java::lang::SecurityManager): Likewise.
7059 (java::util::Vector): Likewise.
7060 (java::io::FileNotFoundException): Likewise.
7061 (java::io::IOException): Likewise.
7062 (java::lang::NativeLang): Likewise.
7063 (java::lang::UnsatisfiedLinkError): Likewise.
7064 (java::util::StringTokenizer): Likewise.
7065 (java::io::InputStream, java::io::OutputStream): Likewise.
7066 (java::io::PrintStream, java::lang::SecurityException): Likewise.
7067 (java::util::Hashtable): Likewise.
7068 * Makefile.in: Rebuilt.
7069 * Makefile.am (nat_headers): Added java/lang/Double.h,
7070 java/lang/Number.h, java/lang/System.h, java/lang/Runtime.h.
7071 (MOSTLYCLEANFILES): Added nat_headers.
7072 * include/jvm.h: Moved many defines, declarations, and functions
7073 to java/lang/Class.h.
7074 (struct JvSyncInfo): Moved to java/lang/Object.h.
7075 (UTF8_GET): Moved to java/lang/String.h.
7076
7077 Wed Jul 15 09:02:31 1998 Tom Tromey <tromey@cygnus.com>
7078
7079 * java/io/io-defs.h: Don't include java-io.h.
7080 * include/java-io.h: Removed.
7081 * include/javaprims.h: Include java::io.
7082
7083 Tue Jul 14 17:04:26 1998 Tom Tromey <tromey@cygnus.com>
7084
7085 * include/java-io.h (File): Removed
7086 (FileDescriptor): Likewise.
7087
7088 * java/io/io-defs.h: Include java/io/File.h and
7089 java/io/FileDescriptor.h.
7090
7091 * Makefile.in: Rebuilt.
7092 * Makefile.am (GJAVAH): New macro.
7093 (.class.h): New rule.
7094 (SUFFIXES): Added .h.
7095 (nat_headers): New macro.
7096 ($(nat_headers)): New target.
7097 (BUILT_SOURCES): Added nat_headers.
7098
7099 * include/java-util.h: Removed.
7100
7101 Fri Jul 3 10:17:14 1998 Tom Tromey <tromey@cygnus.com>
7102
7103 * include/java-io.h: Changed to avoid java-lang.h.
7104 * java/lang/natThread.cc: Include java/lang/Thread.h, not
7105 java-lang.h.
7106 * java/lang/natSystem.cc: Include java/lang/System.h, not
7107 java-lang.h.
7108 * java/lang/natString.cc: Include java/lang/String.h, not
7109 java-lang.h.
7110 * java/lang/natRuntime.cc: Include java/lang/Runtime.h, not
7111 java-lang.h.
7112 * java/lang/natClass.cc: Include java/lang/Class.h, not
7113 java-lang.h.
7114 * java/lang/natDouble.cc: Include java/lang/Object.h, not
7115 java-lang.h.
7116 * java/lang/natObject.cc: Include java/lang/Object.h, not
7117 java-lang.h.
7118 * exception.cc: Don't include java-lang.h.
7119 * posix-threads.cc: Include java/lang/Thread.h, not java-lang.h.
7120 * no-threads.cc: Include java/lang/Thread.h, not java-lang.h.
7121 * nogc.cc: Don't include java-lang.h.
7122 * boehm.cc: Include java/lang/Class.h, not java-lang.h.
7123 * prims.cc (processClass): Don't use `init_type'; just cast to
7124 type directly.
7125 Include java/lang/Class.h and jvm.h, not java-lang.h.
7126 (JvAllocObject): Wrote single-argument version.
7127 (PrimClass): Inherit from Class.
7128 (initPrimClass): Removed.
7129 * include/java-lang.h: Removed.
7130 * include/jvm.h: Declare struct _dispatchTable.
7131 * include/cni.h: Don't declare _Jv_MonitorEnter,
7132 _Jv_MonitorExit, struct _dispatchTable.
7133 * include/javaprims.h: Moved all typedefs here, from cni.h.
7134 * java/lang/Class.h: New file.
7135 * include/java-array.h: New file.
7136 * java/lang/Object.h: New file.
7137
7138 * prims.cc (classFromSig): Now static.
7139
7140 Wed Jul 1 12:28:48 1998 Tom Tromey <tromey@cygnus.com>
7141
7142 * include/cni.h: Don't mention soft_new.
7143 * include/java-lang.h (Object): Don't mention soft_new. Mention
7144 _Jv_NewPrimArray, not newPrimArray.
7145 * prims.cc (soft_new): Removed.
7146 (_Jv_NewArray): Renamed from soft_newarray.
7147 (soft_anewarray): Use JvNewObjectArray.
7148 (newArray): Likewise.
7149 (newRefArray): Removed.
7150 (_Jv_NewPrimArray): Renamed from newPrimArray.
7151 (equalUtf8Consts): Now static.
7152 (soft_instanceof): Removed.
7153 * java/lang/natDouble.cc (doubleToString): Now static.
7154
7155 * java/lang/natDouble.cc (java_lang_Double_doubleToLongBits,
7156 java_lang_Double_longBitsToDouble, java_lang_Double_toString):
7157 Removed.
7158
7159 Tue Jun 30 10:54:57 1998 Tom Tromey <tromey@cygnus.com>
7160
7161 * include/java-lang.h: Renamed functions to _Jv_MonitorEnter and
7162 _Jv_MonitorExit.
7163 * include/cni.h: Renamed functions to _Jv_MonitorEnter and
7164 _Jv_MonitorExit.
7165 * include/no-threads.h (JvPrivMutexLock): Always return -1.
7166 (JvPrivMutexUnlock): Likewise.
7167 * prims.cc (_Jv_MonitorEnter): Renamed from soft_monitorenter.
7168 Return value now jint.
7169 (_Jv_MonitorExit): Renamed from soft_monitorexit. Return value
7170 now jint.
7171
7172 * Makefile.in: Rebuilt.
7173 * Makefile.am: Don't allow `jV' names.
7174 (maintainer-check): Depend on libjava.a.
7175 * exception.cc (_Jv_eh_free): Renamed from __jV_eh_free.
7176
7177 * Makefile.in: Rebuilt.
7178 * Makefile.am (NM): New macro.
7179 (maintainer-check): New target.
7180
7181 * include/posix-threads.h (_MIT_POSIX_THREADS): Removed.
7182
7183 * configure: Rebuilt.
7184 * configure.in: Use --enable-threads, not --enable-gc. Fix
7185 documentation for --enable-threads. Changed option to work like
7186 identical option in gcc/configure.
7187
7188 Mon Jun 29 10:44:29 1998 Tom Tromey <tromey@cygnus.com>
7189
7190 * boehm.cc (mark_array): Use JvGetArrayLength.
7191
7192 Thu Jun 25 11:56:21 1998 Per Bothner <bothner@cygnus.com>
7193
7194 * exception.cc: New file (mostly written by Andrew MacLeod),
7195 exception handling support.
7196 * Makefile.am (libjava_a_SOURCES), Makefile.in: Add exception.cc.
7197 Remove -fexceptions - it is now the default.
7198
7199 * prims.cc (JvIsInstanceOf): Renamed to _Jv_IsInstanceOf.
7200 (JvAllocObject): Renamed to _Jv_AllocObject.
7201 (soft_athrow): Removed. Replaced by _Jv_Throw in exception.cc.
7202 (loadClass): Renamed to _Jv_FindClass.
7203 * include/cni.h (JvIsInstanceOf, JvAllocObject). Make into
7204 inline methods that call _Jv_IsInstanceOf and _Jv_AllocObject.
7205 * include/java-lang.h (JvGetArrayLength): New CNI function.
7206 * include/jvm.h (_Jv_FindClass): Added declaration.
7207
7208 * java/lang/natString.cc: More implementation if COMPACT_STRINGS.
7209
7210 Wed Jun 24 16:41:30 1998 Per Bothner <bothner@cygnus.com>
7211
7212 * java/lang/natClass.cc (getName): Add implementation.
7213 * java/lang/Throwable.java (printStackTrace): Handle missing backtrace.
7214
7215 Tue Jun 23 15:56:24 1998 Tom Tromey <tromey@cygnus.com>
7216
7217 * Makefile.in: Rebuilt.
7218 * Makefile.am (.class.o): Added -fexceptions.
7219
7220 Mon Jun 15 14:54:06 1998 Tom Tromey <tromey@cygnus.com>
7221
7222 * configure: Rebuilt.
7223 * configure.in: Don't check for __nanosleep.
7224 * posix-threads.cc (nanosleep): Never define.
7225
7226 Sun Jun 14 22:37:23 1998 Tom Tromey <tromey@cygnus.com>
7227
7228 * posix-threads.cc (JvPrivCondWait): Fixed computation of
7229 timespec.
7230
7231 Thu Jun 11 10:51:44 1998 Tom Tromey <tromey@cygnus.com>
7232
7233 * java/lang/natThread.cc (enumerate): Uncommented.
7234 * java/lang/Thread.java (interrupted_): Renamed from `interrupt_'.
7235 (interrupt): Call it.
7236
7237 Wed Jun 10 15:57:16 1998 Tom Tromey <tromey@cygnus.com>
7238
7239 * configure: Rebuilt.
7240 * configure.in (GCLIBS): Use `-lgc' so gjavac can recognize it.
7241
7242 Mon Jun 8 12:04:11 1998 Tom Tromey <tromey@cygnus.com>
7243
7244 * include/no-threads.h (JvPrivThreadInterrupt): New method.
7245 * include/java-lang.h (Thread): Added `interrupted_' method.
7246 * java/lang/Thread.java (interrupted_): New method.
7247 * java/lang/natThread.cc (join): Possibly throw interrupted
7248 exception after join finishes.
7249 (interrupted_): New method.
7250 * posix-threads.cc (JvPrivThreadInitData): Initialize join_mutex,
7251 join_cond.
7252 (JvPrivThreadJoin): New function.
7253 (really_start): Notify all threads waiting for this thread.
7254 (struct starter): Added `data' member.
7255 (JvPrivThreadStart): Set it.
7256 * include/posix-threads.h (JvPrivThread_t): Added join_mutex,
7257 join_cond.
7258 (JvPrivThreadJoin): No longer inline.
7259 (JvPrivThreadInterrupt): New function.
7260
7261 * include/no-threads.h (JvPrivThreadSleep): Removed.
7262 * posix-threads.cc (JvPrivThreadSleep): Removed.
7263
7264 Fri Jun 5 13:51:25 1998 Tom Tromey <tromey@cygnus.com>
7265
7266 * configure: Rebuilt.
7267 * configure.in (THREADOBJS): Initialize to no-threads.o in
7268 no-threads case.
7269 * posix-threads.cc (key): New global.
7270 (JvPrivInitThreads): New function.
7271 (really_start): Set thread-specific data to point to object.
7272 (JvPrivThreadStart): Added `daemon' argument.
7273 (JvPrivThreadSleep): Added `data' argument.
7274 * include/posix-threads.h (JvPrivInitThreads): Removed
7275 implementation.
7276 (JvPrivThreadCurrent): New function.
7277 * include/no-threads.h (JvPrivThreadInitData): Initialize
7278 JvPrivOnlyThread. Added `thread' argument.
7279 (JvPrivThreadCurrent): New function.
7280 (JvPrivThreadStart): Added `daemon' argument.
7281 * no-threads.cc: New file.
7282 * java/lang/natThread.cc (init_data): New function.
7283 (isAlive): Removed.
7284 (start): Set `alive' member.
7285 (stop_): Clear `alive' member.
7286 (destroy): Likewise.
7287 (currentThread): Implemented.
7288 (start): Pass `daemon' argument to JvPrivThreadStart.
7289 (sleep): Rewrote.
7290 * include/java-lang.h (Thread): Added `alive', `tsync' members.
7291 (Thread): Added `init_data' method.
7292 * java/lang/Thread.java (alive, data): New instance variables.
7293 (init_data): New private method.
7294 (isAlive): No longer native.
7295
7296 Thu Jun 4 14:09:32 1998 Tom Tromey <tromey@cygnus.com>
7297
7298 * include/java-lang.h (JvRunMain): Declare.
7299 * include/jvm.h (JvPrivInitGC): Revert to C++ linkage.
7300 * prims.cc (JvRunMain): New function.
7301 (main_signature, main_name): New globals.
7302
7303 * boehm.cc (mark_array): Use `elements' function and not
7304 operator[] on jarray.
7305
7306 * posix-threads.cc: Include <config.h>. Define nanosleep if
7307 required.
7308
7309 * configure: Rebuilt.
7310 * configure.in: Check for _nanosleep.
7311
7312 * configure: Rebuilt.
7313 * configure.in: Check for pthread_mutexattr_settype.
7314
7315 * include/cni.h (class JvSynchronize): New class.
7316 * java/lang/Thread.java (sleep): Throws InterruptedException.
7317 (join): Throws InterruptedException.
7318 (resume): Not native.
7319 (resume_): New method.
7320 (start): Now synchronized.
7321 (stop_): New method.
7322 (Thread): Synchronize when accessing threadNumber.
7323 (misc): Removed.
7324 * java/lang/natThread.cc (throwException): New macro.
7325 (sleep): Throw InterruptedException.
7326 (resume_): Renamed.
7327 (stop_): Renamed.
7328 * include/java-lang.h (Runtime): Added interrupted().
7329
7330 * boehm.cc (call_finalizer): Correctly initialize jobj.
7331 * include/java-lang.h (Runtime): Added getRuntime() and exit().
7332
7333 * java/lang/natSystem.cc (currentTimeMillis): Use #elif, not
7334 `#elseif'.
7335
7336 * configure: Rebuilt.
7337 * configure.in: Added support for --disable-threads.
7338 * include/no-threads.h: New file.
7339
7340 * acconfig.h (HAVE_PTHREAD_MUTEXATTR_INIT): New macro.
7341
7342 * Makefile.in: Rebuilt.
7343 * Makefile.am (EXTRA_libjava_a_SOURCES): Added posix-threads.cc.
7344 (libjava_a_DEPENDENCIES): Added THREADOBJS.
7345 (libjava_a_LIBADD): Added THREADOBJS.
7346 * configure: Rebuilt.
7347 * configure.in: Added --with-threads option.
7348 * posix-threads.cc: New file.
7349 * include/posix-threads.h: New file.
7350 * include/java-lang.h (Object): Added static member sync_mutex,
7351 member sync_info, method init_mutex.
7352 (struct JvSyncInfo): New struct.
7353 Include "java-threads.h".
7354 * prims.cc (soft_monitorenter): Wrote.
7355 (soft_monitorexit): Likewise.
7356 * java/lang/natObject.cc (init_mutex): New method.
7357 (notify): Wrote.
7358 (notifyAll): Wrote.
7359 (wait): Wrote.
7360 (sync_mutex): Define.
7361 Include "java-threads.h".
7362
7363 Tue Jun 2 15:24:33 1998 Per Bothner <bothner@cygnus.com>
7364
7365 * include/java-lang.h (JvPrivInitGC): Make extern "C".
7366 * include/jvm.h (JvConvertArgv, JvNewObjectArray): Likewise.
7367
7368 Mon Jun 1 11:21:34 1998 Per Bothner <bothner@cygnus.com>
7369
7370 * include/cni.h (jbyte etc): Re-define using __java_byte etc.
7371 Added extern "Java" in places to tell G++ Object is a "Java" type.
7372 Other minor renaming and fixes.
7373 * include/java-io.h (FileDescriptor): Add friend class declarations.
7374 G++ no longer allows non-Java types in method parameters and results
7375 of Java classes. Converted most offending methods to friends.
7376 * java/lang/natDouble.cc (Double::toString): Rename to doubleToString.
7377 * java/lang/natSystem.cc (setProperty): Make friend.
7378 * java/lang/natString.cc, include/java-lang.h (String): Rename
7379 methods findInternSlot to __JvStringFindSlot and __JvStringGetSlot.
7380 * include/java-lang.h (JArray): Remove getData and eoprator[].
7381 Add elements friend function instead.
7382 * java/lang/natSystem.cc (arraycopy): Use elements function.
7383 * java/io/natFileDescriptor.cc (read, write): Likewise.
7384 * include/java-lang.h (Object): Remove unused make method.
7385 (System::setProperty(char*,char*)): Turn into friend function.
7386 (Class): Rename newObject by JvAllocObject.
7387 * prims.cc: Update to use JvAllocObject, and elements.
7388
7389 * java/lang/natDouble.cc: Fix double -> jdouble.
7390
7391 Wed May 20 16:50:06 1998 Per Bothner <bothner@cygnus.com>
7392
7393 * Makefile.am (INCLUDES): Add -Iinclude (to get config.h).
7394
7395 Mon May 18 13:46:02 1998 Tom Tromey <tromey@cygnus.com>
7396
7397 * java/lang/natRuntime.cc (finalize_on_exit): Define.
7398 * include/java-lang.h (Runtime): finalize_on_exit and
7399 runFinalizersOnExit now static.
7400 * java/lang/Runtime.java (runFinalizersOnExit): Now static, to
7401 match JDK 1.2b3.
7402 (finalize_on_exit): Now static.
7403
7404 * boehm.cc (mark_obj): Get class using getClass() method on
7405 object.
7406 (_dispatchTable): Removed.
7407
7408 Mon May 11 15:26:52 1998 Tom Tromey <tromey@cygnus.com>
7409
7410 * java/io/natFileDescriptor.cc (open_read): Only call open if
7411 HAVE_OPEN defined.
7412 (open_write): Likewise.
7413
7414 * Makefile.in: Rebuilt.
7415 * Makefile.am ($(nat_files)): Depend on config.h.
7416
7417 Thu May 7 16:22:00 1998 Tom Tromey <tromey@cygnus.com>
7418
7419 * prims.cc (ObjectClass): Now a macro; updated for new class name
7420 mangling scheme.
7421 (StringClass): Likewise.
7422 (ClassClass): Likewise.
7423
7424 Wed May 6 00:26:44 1998 Tom Tromey <tromey@cygnus.com>
7425
7426 * java/io/natFileDescriptor.cc (available): Do nothing unless
7427 HAVE_SELECT defined.
7428 * java/util/natDate.cc (setTime): Conditional on
7429 HAVE_GETTIMEOFDAY.
7430 (toString): Conditional on HAVE_TIME.
7431 * aclocal.m4, configure: Rebuilt.
7432 * acinclude.m4: New file.
7433 * configure.in: Don't actually call AM_EXEEXT. Call
7434 AC_CANONICAL_HOST. Use LIB_AC_PROG_CC and LIB_AC_PROG_CXX. Added
7435 --with-target-subdir option. Check for select and open
7436 functions.
7437
7438 Tue May 5 00:10:45 1998 Tom Tromey <tromey@cygnus.com>
7439
7440 * boehm.cc (JvPrivRegisterFinalizer): Changed interface.
7441 (call_finalizer): Likewise.
7442 * nogc.cc (JvPrivRegisterFinalizer): Changed interface.
7443 * prims.cc (newObject): Pass actual method pointer to
7444 JvPrivRegisterFinalizer.
7445 * include/jvm.h (JvPrivFinalizerFunc): New typedef.
7446 (JvPrivRegisterFinalizer): Changed interface.
7447
7448 * Makefile.in: Rebuilt.
7449 * Makefile.am (MOSTLYCLEANFILES): New macro.
7450 (CLEANFILES): Removed javao_files.
7451
7452 Fri May 1 22:52:24 1998 Tom Tromey <tromey@cygnus.com>
7453
7454 * nogc.cc: New file.
7455 * Makefile.in: Rebuilt.
7456 * Makefile.am (INCLUDES): Use GCINCS, not paths to boehm-gc.
7457 (EXTRA_libjava_a_SOURCES): New macro.
7458 (libjava_a_SOURCES): Removed boehm.cc.
7459 (libjava_a_DEPENDENCIES): Added GCOBJS.
7460 (libjava_a_LIBADD): Likewise.
7461 * configure: Rebuilt.
7462 * configure.in: Added code for --enable-gc=TYPE.
7463
7464 Thu Apr 30 14:54:00 1998 Tom Tromey <tromey@cygnus.com>
7465
7466 * boehm.cc (mark_array): Don't further dereference pointer from
7467 array.
7468
7469 * boehm.cc: Include <boehm-config.h>, not <private/config.h>.
7470 * Makefile.in: Rebuilt.
7471 * Makefile.am (INCLUDES): Removed -I for boehm-gc/include; added
7472 one for boehm-gc build directory.
7473
7474 Wed Apr 29 09:45:19 1998 Tom Tromey <tromey@cygnus.com>
7475
7476 * include/java-lang.h (finalize_on_exit): New instance variable in
7477 java::lang::Runtime.
7478 (runFinalizersOnExit): New method.
7479 * java/lang/Runtime.java (finalize_on_exit): New instance
7480 variable.
7481 (runAllFinalizers_): New private method.
7482 (runFinalizersOnExit): New method.
7483 * boehm.cc (JvPrivRunFinalizers): New function.
7484 (JvPrivRunAllFinalizers): Likewise.
7485 (JvPrivRunGC): Likewise.
7486 * java/lang/natRuntime.cc: Include "jvm.h".
7487 (gc): Call JvPrivRunGC.
7488 (runFinalization): Call JvPrivRunFinalizers.
7489 (runFinalizersOnExit): New method.
7490 (exit_): Call JvPrivRunAllFinalizers if required.
7491 * include/jvm.h: Declare JvPrivRunFinalizers,
7492 JvPrivRunAllFinalizers, JvPrivRunGC.
7493
7494 Tue Apr 28 15:06:50 1998 Tom Tromey <tromey@cygnus.com>
7495
7496 * boehm.cc (JvPrivRegisterFinalizer): New function.
7497 (call_finalizer): Likewise.
7498 * include/jvm.h: Declare JvPrivRegisterFinalizer.
7499 * prims.cc (finalize_name): New global.
7500 (newObject): Just call other newObject.
7501 (newObject): Register finalizer if it exists.
7502
7503 Mon Apr 27 12:47:03 1998 Tom Tromey <tromey@cygnus.com>
7504
7505 * prims.cc (gc_malloc): Removed.
7506 (makeUtf8Const): Use JvPrivAllocBytes.
7507 (lookupArray): Likewise.
7508 (newPrimArray): Likewise.
7509 (JvNewObjectArray): Use JvPrivAllocArray.
7510 (newObject): Use JvPrivAllocObj.
7511 (newObject): Likewise.
7512 Changed Method -> JvMethod everywhere.
7513 Changed Field -> JvField everywhere.
7514 * include/java-lang.h (Object): Changed type of `fields' to
7515 JvField*.
7516 (jmethodID, jfieldID): New typedefs.
7517 (Object): JvGetFirstInstanceField and JvNumInstanceFields now
7518 friends.
7519 * include/jvm.h (struct JvMethod): Renamed from Method, and moved
7520 from java-lang.h.
7521 (METHOD_NATIVECODE): Moved from java-lang.h.
7522 (class JvField): New class.
7523 (JvGetFirstInstanceField): New function.
7524 (JvFieldIsRef): Likewise.
7525 (JvGetObjectField): Likewise.
7526 (JvNumInstanceFields): Likewise.
7527
7528 Thu Apr 23 16:42:11 1998 Tom Tromey <tromey@cygnus.com>
7529
7530 * boehm.cc: New file.
7531 * Makefile.in: Rebuilt.
7532 * Makefile.am (libjava_a_SOURCES): Added boehm.cc.
7533 (INCLUDES): Added -I options to find boehm-gc files.
7534
7535 Wed Apr 29 15:11:37 1998 Tom Tromey <tromey@cygnus.com>
7536
7537 * configure: Rebuilt.
7538 * configure.in (CXX): Put -fno-rtti here and not in CXXFLAGS.
7539
7540 * Makefile.in: Rebuilt.
7541 * Makefile.am (nat_files): New macro.
7542 (libjava_a_DEPENDENCIES): Use it.
7543 (libjava_a_LIBADD): Likewise.
7544 ($(nat_files)): New static pattern rule.
7545 (class_files): Run separate find to find .class files.
7546 (javao_files): Compute based on class_files.
7547 (BUILT_SOURCES): New macro.
7548
7549 Thu Apr 23 16:42:11 1998 Tom Tromey <tromey@cygnus.com>
7550
7551 * Makefile.am (java_files): New macro.
7552 (class_files): Likewise.
7553 (javao_files): Likewise.
7554 (libjava_a_DEPENDENCIES): Include $(javao_files).
7555 (libjava_a_LIBADD): Likewise.
7556 (classes.stamp): Depend on $(java_files); only recompile changed
7557 files.
7558 (here): New macro.
7559 (CLEANFILES): Don't run find; use macros. Don't mention
7560 libjava.a.
7561 (.class.o): New target.
7562 (compiled.stamp): Removed.
7563
7564 Thu Apr 23 14:17:43 1998 Per Bothner <bothner@cygnus.com>
7565
7566 * java/io/{Reader,InputStreamReader,FileReader,BufferedReader,
7567 LineNumberReader}>java: Newly-implemented standard classes.
7568
7569 Thu Apr 23 14:02:04 1998 Tom Tromey <tromey@cygnus.com>
7570
7571 * Makefile.in: Rebuilt.
7572 * Makefile.am (compiled.stamp): Use $(CC), not $(GCC).
7573
7574 * Makefile.in: Rebuilt.
7575 * Makefile.am (hack): New macro.
7576 (libjava_a_LIBADD): Use $(hack) to work around automake oddity.
7577
7578 Wed Apr 22 16:49:57 1998 Tom Tromey <tromey@cygnus.com>
7579
7580 * include/config.h.in: New file.
7581 * include/config.h: Removed.
7582 * acconfig.h: New file.
7583 * Makefile.am (AR, ARFLAGS, JAVAC, GCC, CXX, CXXFLAGS): Removed.
7584 (lib_LIBRARIES, libjava_a_SOURCES, libjava_a_DEPENDENCIES,
7585 libjava_a_LIBADD): New macros.
7586 (INCLUDES): New macro.
7587 (prims.o): Removed.
7588 (.cc.o): Removed.
7589 (SUFFIXES): Removed.
7590 (all): Removed.
7591 (libjava.a): Removed.
7592
7593 * configure: Rebuilt.
7594 * configure.in: Call AC_PROG_CC, AC_PROG_CXX, AC_PROG_RANLIB.
7595 Look for headers and functions we require. Create
7596 include/config.h.
7597
7598 Mon Apr 20 22:25:00 1998 Per Bothner <bothner@cygnus.com>
7599
7600 * prims.cc (instance_class, instanceof, JvIsInstanceOf, JvConvertArgv,
7601 soft_instanceof, newObject, JbNewObjectArray, soft_checkcast,
7602 soft_lookupinterfacemethod): New functions.
7603 (PrimClass): Actually initialize the primitive classes.
7604 (Utf8Const2JavaString): Moved to java/lang/natString.cc.
7605
7606 * include/java-util.h: Removed java::util definition.
7607 * include/cni.h: Moved java::util here and added Properties.
7608 Added more function prototypes.
7609 * include/java-lang.h: Added mroe methods and friend declarations.
7610 * include/config.h (HAVE_GETTIMEOFDAY, HAVE_TIME): Added.
7611 * include/jvm.h (strLengthUtf8): Add declaration.
7612
7613 * java/lang/{Integer,Long,Boolean,Character,Float,Double}.java (TYPE):
7614 New static field.
7615 * java/lang/{Byte,Short,Void}.java: New classes.
7616 * java/lang/Character.java (isJavaIdentifierStart,
7617 JavaIdentifierPart): New static methods.
7618 * java/lang/Number.java (byteValue, shortValue): New methods.
7619
7620 * java/lang/String.java (intern, hashCode): Make native.
7621 * java/lang/natString.cc: New file. Handle the string pool.
7622 * Makefile.am: Build natString.o. Use CXXFLAGS.
7623
7624 * java/lang/Class.java (isArray, isPrimitive, getComponentType,
7625 isInstance, isAssignableFrom), java/lang/natClass.cc: New methods.
7626 * java/lang/Throwable.java (<init>): Don't fillInStackTrace yet.
7627 * java/lang/System.java (setProperty): New private method.
7628 (initProperties): Take argument, and make native.
7629 * java/lang/natSystem.cc: Implement (preliminary) initProperties.
7630 (currentTimeMillis): Make more robust.
7631
7632 * java/io/{Writer,PrintWriter,OutputStreamWriter}.java: New classes.
7633 * java/io/UnsupportedEncodingException.java: New exception class.
7634
7635 * java/io/DataInputStream.java: Don't use a PushbackInputStream.
7636 * java/io/FilterOutputStream.java: Add missing 'extends OutputStream'.
7637
7638 Fri Apr 10 11:52:10 1998 Per Bothner <bothner@cygnus.com>
7639
7640 * Makefile.am (CXXFLAGS, JC1FLAGS): New macro.
7641 * prims.cc: Added bunch of stuff.
7642 * include/cni.h: Added various definitions.
7643 * include/java-lang.h: Added Method, various friends, some macros.
7644
7645 * include/config.h: Added HAVA_MEMMOVE and HAVE_MEMCPY.
7646 * java/lang/System.java (arraycopy): Make native.
7647
7648 Sun Apr 5 23:58:51 1998 Per Bothner <bothner@cygnus.com>
7649
7650 * java/lang/{netObject.cc,natClass.cc,natDouble.cc,natRuntime.cc,
7651 natSystem.cc,natThread.cc}: Native (C++) methods for various classes.
7652 * java/lang/ClassLoader.java (defineClass): Now takes extra argument.
7653 * java/lang/Double.java (toString, doubleToLongBits, longBitsToDouble):
7654 Make native.
7655 * java/lang/Runtime.java: Declare methods as native instead of
7656 using NativeLang.
7657 * java/lang/SecurityManager.java (getClassContext): Just throw Error.
7658 * java/lang/System.java: Comment out some stuff, for now.
7659 * java/lang/Thread.java: Re-write. Use native methods.
7660 * java/lang/NativeLang.java: Remove most of it.
7661
7662 * java/util/natDate.cc: Native (C++) methods for Date.
7663 * java/util/{Calendar.java,GregorianCalendar.java}: New classes.
7664 * java/util/Date.java: Complete re-write.
7665
7666 * java/io/io-defs.h: New header file.
7667 * java/io/FileDescriptor.java: Add a bunch of private methods,
7668 mostly moved from NativeIO.java and natNativeIO.cc.
7669 * java/io/{natFile.cc,java/io/natFileDescriptor.cc}: New native code.
7670 * java/io/File.java: Use new code.
7671 * java/io/{FileInputStream.java.FileOutputStream.java,
7672 RandomAccessFile.java}: Use new private FileDescriptor methods.
7673 * java/io/NativeIO.java: Removed, no longer used.
7674
7675 * java/io/StreamTokenizer.java (numericChars): Make char array.
7676
7677 * include/*.h: Various header files used by the C++ native code.
7678
7679 * Makefile.am, Makefile.in, aclocal.m4, configure, configure.in:
7680 New autoconf+automake-based setup.
7681 * prims.cc: New file for Java "primitives".
7682