]> gcc.gnu.org Git - gcc.git/blob - libjava/ChangeLog
* java/awt/Color.java: Rewrote to be more memory efficient (& compile).
[gcc.git] / libjava / ChangeLog
1 2000-03-19 Warren Levy <warrenl@cygnus.com>
2
3 * java/awt/Color.java: Rewrote to be more memory efficient (& compile).
4
5 2000-03-16 Warren Levy <warrenl@cygnus.com>
6
7 * java/awt/Color.java: New file.
8 * java/awt/Graphics.java: New file.
9 * java/awt/Image.java: New file.
10 * java/awt/Paint.java: New file.
11 * java/awt/PaintContext.java: New file.
12 * java/awt/Transparency.java: New file.
13 * java/util/Collection.java: New file.
14 * java/util/Comparator.java: New file.
15 * java/util/Iterator.java: New file.
16 * java/util/List.java: New file.
17 * java/util/ListIterator.java: New file.
18 * Makefile.am: Added above new files.
19 * Makefile.in: Rebuilt.
20
21 * java/awt/Font.java (PLAIN): New field.
22 (BOLD): New field.
23 (ITALIC): New field.
24 (ROMAN_BASELINE): New field.
25 (CENTER_BASELINE): New field.
26 (HANGING_BASELINE): New field.
27 (name): New field.
28 (style): New field.
29 (size): New field.
30 (pointSize): New field.
31 (Font): Implemented constructor.
32 (isPlain): Implemented method.
33 (isBold): Implemented method.
34 (isItalic): Implemented method.
35 (getName): Implemented method.
36 (getStyle): Implemented method.
37 (getSize): Implemented method.
38 (getSize2D): Implemented method.
39 (decode): Stubbed.
40 * java/awt/Frame.java (getFont): Stubbed.
41 (postEvent): Stubbed.
42 (remove): Stubbed.
43 * java/awt/Menu.java (postEvent): Stubbed.
44 * java/awt/MenuBar.java (getFont): Stubbed.
45 (postEvent): Stubbed.
46 * java/awt/Toolkit.java (getImage): Added abstract method.
47
48 2000-03-15 Tom Tromey <tromey@cygnus.com>
49
50 * java/io/natFileDescriptorWin32.cc (winerr): Now static.
51
52 * prims.cc (win32_exception_handler): Reformatted.
53
54 * include/win32-threads.h (_Jv_HaveCondDestroy): New define.
55 (_Jv_HaveMutexDestroy): Likewise.
56
57 2000-03-15 Jon Beniston <jb7216@bristol.ac.uk>
58
59 * java/io/natFileDescriptorWin32.cc: New file.
60 * java/io/natFileWin32.cc: New file.
61 * java/net/natInetAddress.cc: Added conditional inclusion of
62 Windows / Winsock headers.
63 * java/net/natPlainDatagramSocketImpl.cc: Added conditional
64 inclusion of Windows / Winsock headers.
65 * java/net/natPlainSocketImpl.cc: Added conditional inclusion of
66 Windows / Winsock headers.
67 * include/win32-signal.h: New file.
68 * include/win32-threads.h: New file.
69 * win32-threads.cc: New file.
70 * exception.cc (win32_get_restart_frame): New function.
71 * prims.cc (win32_exception_handler): New function.
72 (main_init) Performs Winsock initialisation.
73 (main_init) Installs exeception handler.
74
75 2000-03-14 Tom Tromey <tromey@cygnus.com>
76
77 * jni.cc (mangled_name): Fixed assertion.
78 (JNI_GetCreatedJavaVMs): Don't comment out `buf_len' argument;
79 turned assert into actual failure.
80
81 2000-03-09 Warren Levy <warrenl@cygnus.com>
82
83 * java/security/Key.java(serialVersionUID): Set to 0 for now.
84 * java/security/interfaces/DSAPrivateKey.java(serialVersionUID): Ditto.
85 * java/security/interfaces/DSAPublicKey.java(serialVersionUID): Ditto.
86
87 2000-03-09 Warren Levy <warrenl@cygnus.com>
88
89 * java/security/AlgorithmParameterGeneratorSpi.java: New file.
90 * java/security/DigestException.java: New file.
91 * java/security/GeneralSecurityException.java: New file.
92 * java/security/InvalidAlgorithmParameterException.java: New file.
93 * java/security/InvalidKeyException.java: New file.
94 * java/security/InvalidParameterException.java: New file.
95 * java/security/Key.java: New file.
96 * java/security/KeyException.java: New file.
97 * java/security/KeyPair.java: New file.
98 * java/security/KeyPairGenerator.java: New file.
99 * java/security/KeyPairGeneratorSpi.java: New file.
100 * java/security/NoSuchProviderException.java: New file.
101 * java/security/PrivateKey.java: New file.
102 * java/security/Provider.java: New file.
103 * java/security/PublicKey.java: New file.
104 * java/security/SecureRandom.java: New file.
105 * java/security/Security.java: New file.
106 * java/security/Signature.java: New file.
107 * java/security/SignatureException.java: New file.
108 * java/security/interfaces/DSAKey.java: New file.
109 * java/security/interfaces/DSAParams.java: New file.
110 * java/security/interfaces/DSAPrivateKey.java: New file.
111 * java/security/interfaces/DSAPublicKey.java: New file.
112 * java/security/interfaces/RSAPrivateCrtKey.java: New file.
113 * java/security/interfaces/RSAPrivateKey.java: New file.
114 * java/security/interfaces/RSAPublicKey.java: New file.
115 * java/security/spec/AlgorithmParameterSpec.java: New file.
116 * java/security/spec/InvalidKeySpecException.java: New file.
117 * java/security/spec/InvalidParameterSpecException.java: New file.
118 * java/security/spec/KeySpec.java: New file.
119 * java/security/spec/RSAPrivateCrtKeySpec.java: New file.
120 * java/security/spec/RSAPrivateKeySpec.java: New file.
121 * java/security/spec/RSAPublicKeySpec.java: New file.
122 * Makefile.am: Added above java.security files.
123 * Makefile.in: Rebuilt.
124
125 * java/security/MessageDigest.java: Rewritten.
126 * java/security/SecureClassLoader.java: Added JDK1.2 comment.
127
128 2000-03-09 Bryce McKinlay <bryce@albatross.co.nz>
129
130 * README: Updated.
131
132 2000-03-09 Bryce McKinlay <bryce@albatross.co.nz>
133
134 * java/lang/natClassLoader.cc (_Jv_FindArrayClass): Call
135 _Jv_PrepareConstantTimeTables.
136 * java/lang/natClass.cc (_Jv_PrepareConstantTimeTables): Array
137 classes should have an IDT, so don't return if klass is an array
138 class.
139
140 2000-03-08 Tom Tromey <tromey@cygnus.com>
141
142 * java/lang/reflect/natArray.cc (newInstance): Don't allow array
143 of `void' to be created.
144
145 2000-03-08 Warren Levy <warrenl@cygnus.com>
146
147 * java/math/BigInteger.java(signum): Handle zero properly.
148
149 2000-03-07 Tom Tromey <tromey@cygnus.com>
150
151 * All files: Updated copyright information.
152 * COPYING: New file.
153 * COPYING.LIB: Removed.
154 * LIBGCJ_LICENSE: We now use GPL + special exception.
155
156 2000-03-07 Bryce McKinlay <bryce@albatross.co.nz>
157
158 * resolve.cc (_Jv_SearchMethodInClass): New function.
159 (_Jv_ResolvePoolEntry): Search superinterfaces for interface methods.
160 * java/lang/Class.h (_Jv_SearchMethodInClass): New prototype.
161
162 2000-03-07 Bryce McKinlay <bryce@albatross.co.nz>
163
164 * java/lang/Class.h (union _Jv_IDispatchTable): New declaration.
165 (struct _Jv_ifaces): New declaration.
166 JV_CLASS: New macro definition.
167 (getComponentType): Relocate below isArray() for inlining.
168 (getModifiers): Declare `inline'.
169 (getSuperclass): Ditto.
170 (isArray): Ditto.
171 (isPrimitive): Ditto.
172 (_Jv_IsAssignableFrom): New prototype.
173 (_Jv_LookupInterfaceMethodIdx): New prototype. Predeclare with "C"
174 linkage.
175 (_Jv_InitClass): Move from natClass.cc. Declare `inline'.
176 Check for JV_STATE_DONE before invoking initializeClass().
177 (_Jv_PrepareConstantTimeTables): New prototype.
178 (_Jv_GetInterfaces): Ditto.
179 (_Jv_GenerateITable): Ditto.
180 (_Jv_GetMethodString): Ditto.
181 (_Jv_AppendPartialITable): Ditto.
182 (_Jv_FindIIndex): Ditto.
183 depth, ancestors, idt: New class fields.
184
185 * java/lang/natClass.cc (isAssignableFrom): Move functionality to
186 inline function `_Jv_IsAssignableFrom'. Use that function.
187 (isInstance): Declare `inline'.
188 (initializeClass): Get lock on class before checking `state'. Unlock
189 before calling resolveClass0. Call _Jv_PrepareConstantTimeTables with
190 the lock held.
191 (_Jv_LookupInterfaceMethod): Use _Jv_GetMessageString.
192 (_Jv_IsAssignableFrom): New inline function. Test assignability using
193 class->depth and ancestor table.
194 (_Jv_IsInstanceOf): Use _Jv_IsAssignableFrom.
195 (_Jv_CheckCast): Move from prims.cc. Use JV_CLASS and
196 _Jv_IsAssignableFrom.
197 (_Jv_CheckArrayStore): Ditto.
198 (_Jv_LookupInterfaceMethodIdx): New function.
199 INITIAL_IOFFSETS_LEN, INITIAL_IFACES_LEN: New #defines.
200 (_Jv_PrepareConstantTimeTables): New function.
201 (_Jv_IndexOf): Ditto.
202 (_Jv_GetInterfaces): Ditto.
203 (_Jv_GenerateITable): Ditto.
204 (_Jv_GetMethodString): Ditto.
205 (_Jv_AppendPartialITable): Ditto.
206 iindex_mutex, iindex_mutex_initialized: New static fields.
207 (_Jv_FindIIndex): New function.
208
209 * java/lang/natClassLoader.cc (_Jv_NewClass): Set new jclass fields.
210
211 * prims.cc (_Jv_CheckCast): Moved to natClass.cc.
212 (_Jv_CheckArrayStore): Ditto.
213 (JvNewCharArray, JvNewBooleanArray, JvNewByteArray, JvNewShortArray,
214 JvNewIntArray, JvNewLongArray, JvNewFloatArray, JvNewDoubleArray):
215 Moved to gcj/array.h.
216 (_Jv_Realloc): New function.
217
218 * gcj/cni.h: Move _Jv_PrimClass definitions to gcj/array.h.
219
220 * gcj/array.h: _Jv_PrimClass definitions moved from gcj/cni.h.
221 (JvNewCharArray, JvNewBooleanArray, JvNewByteArray,
222 JvNewShortArray, JvNewIntArray, JvNewLongArray, JvNewFloatArray,
223 JvNewDoubleArray): Implementations moved from prims.cc and
224 declared `inline'.
225
226 * gcj/javaprims.h (_Jv_Realloc): Prototype.
227
228 * include/jvm.h (_Jv_LookupInterfaceMethodIdx): Prototype.
229
230 2000-03-06 Tom Tromey <tromey@cygnus.com>
231
232 * jni.cc (MARK_NONE): New define.
233 (MARK_USER): Likewise.
234 (MARK_SYSTEM): Likewise.
235 (struct _Jv_JNI_LocalFrame): Made `marker' bigger and `size'
236 smaller.
237 (_Jv_JNI_DeleteLocalRef): Use MARK_NONE in assert.
238 (_Jv_JNI_EnsureLocalCapacity): Use MARK_NONE.
239 (_Jv_JNI_PushLocalFrame): Use MARK_USER.
240 (_Jv_JNI_PopLocalFrame): New version with additional `stop'
241 argument.
242 (call): Use MARK_SYSTEM.
243 (_Jv_GetJNIEnvNewFrame): New function.
244 (_Jv_LookupJNIMethod): New function.
245 (_Jv_JNI_PopSystemFrame): New function.
246 (call): Use _Jv_JNI_PopSystemFrame and _Jv_LookupJNIMethod.
247
248 2000-03-05 Tom Tromey <tromey@cygnus.com>
249
250 Fix for PR libgcj/43:
251 * include/Makefile.in: Rebuilt.
252 * include/Makefile.am (include_HEADERS): New define.
253
254 2000-03-05 Anthony Green <green@redhat.com>
255
256 * gcj/javaprims.h ("Java"): Remove FirstThread.
257
258 * configure.host: Fix __NO_MATH_INLNES botch.
259
260 * Makefile.in: Rebuilt.
261 * Makefile.am (nat_source_files): Move natFirstThread.cc.
262 (gnu/gcj/runtime/FirstThread.h): Moved.
263 (ordinary_java_source_files): Move FirstThread.java.
264 * prims.cc: Deal with FirstThread movement.
265 (JvRunMain): Ditto.
266 (_Jv_RunMain): Ditto.
267
268 * gnu/gcj/runtime/FirstThread.java: Moved from java/lang.
269 * gnu/gcj/runtime/natFirstThread.cc: Ditto.
270
271 2000-03-05 Warren Levy <warrenl@cygnus.com>
272
273 * java/net/DatagramSocket.java(DatagramSocket(int,InetAddress)):
274 Handle null addresses.
275
276 2000-03-04 Anthony Green <green@redhat.com>
277
278 * configure.host (libgcj_flags): Define __NO_MATH_INLINES.
279 See PR gcj/151.
280
281 2000-03-04 Anthony Green <green@redhat.com>
282
283 * configure: Rebuilt.
284 * configure.in (ZLIBTESTSPEC): New macro.
285 (GCTESTSPEC): New macro.
286 (LIBGCJTESTSPEC): New macro.
287 * libgcj-test.spec.in: New file.
288
289 2000-03-02 Tom Tromey <tromey@cygnus.com>
290
291 * include/java-interp.h: Don't include MethodInvocation.h.
292 (class _Jv_InterpMethod): Don't make MethodInvocation a friend.
293 * Makefile.in: Rebuilt.
294 * Makefile.am (gnu/gcj/runtime/MethodInvocation.h): Removed.
295 (ordinary_java_source_files): Don't mention
296 MethodInvocation.java.
297 * gnu/gcj/runtime/MethodInvocation.java: Removed.
298 * interpret.cc (MethodInvocation::continue1): Removed.
299 (run): Handle exceptions here.
300 * java/lang/ClassLoader.java (defineClass1, defineClass2):
301 Removed.
302 * java/lang/natClassLoader.cc (defineClass0): Catch exceptions
303 here.
304 (defineClass2): Removed.
305
306 * java/lang/reflect/Method.java (hack_trampoline, hack_call):
307 Removed.
308 * java/lang/reflect/natMethod.cc (_Jv_CallAnyMethodA): Catch
309 exceptions here.
310 (hack_call): Removed.
311
312 * java/lang/Class.h (Class): Removed hackRunInitializers,
313 hackTrampoline.
314 * java/lang/natClass.cc (hackRunInitializers): Removed.
315 (initializeClass): Catch exceptions here.
316 Include ExceptionInInitializerError.h.
317 * java/lang/Class.java (hackTrampoline, hackRunInitializers):
318 Removed.
319
320 * java/lang/Object.h (Object): Don't mention hack12_6.
321 * java/lang/natObject.cc (_Jv_FinalizeObject): Catch exceptions
322 here.
323 * java/lang/Object.java (hack12_6): Removed.
324
325 * java/lang/natThread.cc (run_): Renamed. Catch exceptions here.
326 (start): Use run_, not run__.
327 * java/lang/Thread.java (run_): Renamed from run__; old run_
328 removed.
329
330 * jni.cc (_Jv_JNI_FindClass): Handle exceptions.
331 (_Jv_JNI_EnsureLocalCapacity): Likewise.
332 (_Jv_JNI_DefineClass): Likewise.
333 (_Jv_JNI_ThrowNew): Likewise.
334 (_Jv_JNI_AllocObject): Likewise.
335 (_Jv_JNI_GetAnyMethodID): Likewise.
336 (_Jv_JNI_CallAnyMethodV): Likewise.
337 (_Jv_JNI_CallAnyMethodA): Likewise.
338 (_Jv_JNI_CallAnyVoidMethodV): Likewise.
339 (_Jv_JNI_CallAnyVoidMethodA): Likewise.
340 (_Jv_JNI_GetAnyFieldID): Likewise.
341 (_Jv_JNI_NewString): Likewise.
342 (_Jv_JNI_NewStringUTF): Likewise.
343 (_Jv_JNI_GetStringUTFChars): Likewise.
344 (_Jv_JNI_NewObjectArray): Likewise.
345 (_Jv_JNI_NewPrimitiveArray): Likewise.
346 (_Jv_JNI_GetPrimitiveArrayRegion): Likewise.
347 (_Jv_JNI_GetStringRegion): Likewise.
348 (_Jv_JNI_GetStringUTFRegion): Likewise.
349 (_Jv_JNI_SetPrimitiveArrayRegion): Likewise.
350 (_Jv_JNI_MonitorEnter): Likewise.
351 (_Jv_JNI_MonitorExit): Likewise.
352 (_Jv_JNI_ToReflectedField): Likewise.
353 (_Jv_JNI_ToReflectedMethod): Likewise.
354 (_Jv_JNI_RegisterNatives): Likewise.
355 (_Jv_JNI_AttachCurrentThread): Likewise.
356 (_Jv_JNI_DestroyJavaVM): Likewise.
357
358 2000-02-28 Mo DeJong <mdejong@cygnus.com>
359
360 * java/util/zip/ZipOutputStream.java(closeEntry) : Fixed
361 error caused by the incorrect casting of a long to an int.
362
363 2000-02-28 Mo DeJong <mdejong@cygnus.com>
364
365 * java/util/zip/ZipOutputStream.java(write_entry) : Fixed
366 SIGSEV caused by use of the wrong instance variable.
367
368 2000-02-27 Bryce McKinlay <bryce@albatross.co.nz>
369
370 * java/io/File.java (File(String, String)): For dirPath, treat an
371 empty String the same as `null'.
372
373 2000-02-26 Anthony Green <green@cygnus.com>
374
375 * gnu/gcj/io/MimeTypes.java: Test for null.
376
377 * jni.cc (_Jv_JNI_AttachCurrentThread): Minor cleanup.
378 (JNI_GetCreatedJavaVMs): Remove compiler warning.
379
380 * java/net/URLConnection.java: Update copyright notice.
381
382 2000-02-25 Tom Tromey <tromey@cygnus.com>
383
384 * jni.cc (_Jv_JNI_RegisterNatives): Conditionalize body on
385 `INTERPRETER'.
386
387 2000-02-25 Bryce McKinlay <bryce@albatross.co.nz>
388
389 * java/net/URLConnection.java (initializeDateFormats): New
390 private method.
391 (getHeaderFieldDate): Call initializeDateFormats if required.
392 locale, dateFormat1, dateFormat2, dateFormat3: Don't initialize
393 these.
394 Fix for PR libgcj/38.
395
396 2000-02-24 Warren Levy <warrenl@cygnus.com>
397
398 * java/math/BigInteger.java(ival): Made private.
399 (words): Ditto.
400 (neg): Ditto.
401
402 2000-02-20 Anthony Green <green@cygnus.com>
403
404 * Makefile.in: Rebuilt.
405 * Makefile.am (ordinary_java_source_files): Add
406 gnu/gcj/io/DefaultMimeTypes.java and gnu/gcj/io/MimeTypes.java
407
408 * scripts/MakeDefaultMimeTypes.java: New file.
409 * scripts/mime.types: New file.
410 * scripts/classes.pl: Moved from top level.
411 * classes.pl: Moved to scripts directory.
412
413 * java/net/URLConnection.java: Implement guessContentTypeFromName.
414
415 * gnu/gcj/io/MimeTypes.java: New file.
416 * gnu/gcj/io/DefaultMimeTypes.java: New file.
417
418 2000-02-20 Tom Tromey <tromey@cygnus.com>
419
420 * boehm.cc (_Jv_AllocBytes): Clear returned memory.
421
422 2000-02-19 Bryce McKinlay <bryce@albatross.co.nz>
423
424 * java/util/zip/ZipEntry.java (setCrc): Fix overflow.
425 (setSize): ditto.
426
427 2000-02-18 Tom Tromey <tromey@cygnus.com>
428
429 * include/jvm.h (_Jv_GetJavaVM): Declare.
430 * include/java-interp.h (_Jv_GetFirstMethod): New function.
431 (_Jv_MethodBase::get_method): New method.
432 (_Jv_JNIMethod::set_function): New method.
433 * jni.cc (_Jv_JNI_UnregisterNatives): New function.
434 (_Jv_JNI_RegisterNatives): New function.
435 (_Jv_JNIFunctions): Updated for new functions.
436 (_Jv_GetJavaVM): New function.
437 (_Jv_JNI_GetJavaVM): Use it. Now static.
438 (_Jv_JNI_AttachCurrentThread): Create a new JNIEnv if this thread
439 is already a Java thread but does not have a JNIEnv yet.
440
441 * java/lang/natRuntime.cc (_load): Pass the JavaVM to the onload
442 function.
443
444 2000-02-17 Tom Tromey <tromey@cygnus.com>
445
446 * gcj/field.h (_Jv_Field::getClass): Don't use JvAssert.
447 Fixes PR gcj/152.
448
449 2000-02-16 Tom Tromey <tromey@cygnus.com>
450
451 * jni.cc (_Jv_JNI_CallStaticMethodV): Added some assertions.
452
453 * jni.cc (_Jv_JNI_NewObjectV): Corrected assertion.
454 (_Jv_JNI_NewObject): Likewise.
455 (_Jv_JNI_NewObjectA): Likewise.
456 (_Jv_JNI_CallAnyMethodV): In constructor case, pass correct value
457 as "return" type to _Jv_CallAnyMethodA.
458 (_Jv_JNI_CallAnyMethodA): Likewise.
459 (_Jv_JNI_CallAnyVoidMethodV): Likewise.
460
461 * jni.cc (_Jv_JNI_FindClass): Use ClassLoader.loadClass, not
462 findClass.
463
464 2000-02-15 Tom Tromey <tromey@cygnus.com>
465
466 * resolve.cc (ncode): Set args_raw_size. Compute jni_cif and
467 jni_arg_types.
468 (init_cif): Added `rtype_p' argument.
469 * include/java-interp.h (class _Jv_MethodBase): Added
470 args_raw_size.
471 (class _Jv_InterpMethod): Removed args_raw_size.
472 (class _Jv_JNIMethod): Added jni_cif and jni_arg_types fields.
473 * jni.cc (call): Pass JNIEnv and (for static methods only) the
474 class pointer as well as the ordinary arguments.
475
476 * jni.cc (mangled_name): Skip leading `(' in signature.
477
478 * jni.cc (add_char): Added missing `else'.
479
480 * jni.cc (_Jv_JNI_AttachCurrentThread): Return error if malloc
481 fails.
482
483 2000-02-15 Bryce McKinlay <bryce@albatross.co.nz>
484
485 * NEWS: Updated.
486
487 * java/lang/natRuntime.cc (_load): Include library path with
488 exception message.
489
490 * java/lang/natSystem.cc (init_properties): set java.lang.classpath
491 property.
492
493 * java/lang/natThread.cc (dumpStack): Removed.
494 * java/lang/Thread.java (dumpStack): Implemented.
495
496 2000-02-15 Tom Tromey <tromey@cygnus.com>
497
498 * java/lang/natRuntime.cc (_load): On Unix, prefix library name
499 with `lib' for loadLibrary. Fixes PR gcj/150.
500
501 2000-02-14 Warren Levy <warrenl@cygnus.com>
502
503 * gnu/gcj/math/MPN.java(findLowestBit): Made methods public.
504
505 * java/math/BigInteger.java(BigInteger(int,int,java.util.Random):
506 New constructor.
507 (min): Implemented.
508 (max): Implemented.
509 (modPow): Rewritten to not use the naive, slow, brute force approach.
510 (isProbablePrime): Implemented.
511 (testBit): Implemented.
512 (flipBit): Implemented.
513 (getLowestSetBit): Implemented.
514
515 2000-02-16 Anthony Green <green@redhat.com>
516
517 * configure.host: Use the same options for i386 and i486 as we do
518 for i586 and i686.
519
520 2000-02-12 Tom Tromey <tromey@cygnus.com>
521
522 * java/io/File.java (createTempFile): Use low bits from counter,
523 not high bits.
524
525 Fri Feb 11 19:48:08 2000 Anthony Green <green@cygnus.com>
526
527 * THANKS: More thanks.
528
529 2000-02-11 Tom Tromey <tromey@cygnus.com>
530
531 * interpret.cc (continue1): Use STOREA, not STOREI, to implement
532 astore instruction. From Hans Boehm.
533
534 2000-02-11 Warren Levy <warrenl@cygnus.com>
535
536 * java/math/BigInteger.java(BigInteger(String, int)): New constructor.
537 (BigInteger(String)): New constructor.
538 (not): Rewritten using version from Kawa's BitOps class.
539 (valueOf): New private methods from Kawa's BitOps class.
540 (swappedOp): ditto.
541 (bitOp): ditto.
542 (setBitOp): ditto.
543 (and): Implemented.
544 (or): Implemented.
545 (xor): Implemented.
546 (andNot): Implemented.
547 (clearBit): Implemented.
548 (setBit): Implemented.
549 (bitCount): Implemented.
550 (toByteArray): Implemented.
551
552 2000-02-11 Tom Tromey <tromey@cygnus.com>
553
554 * java/io/File.java (nextValue): Now synchronized.
555
556 2000-02-10 Tom Tromey <tromey@cygnus.com>
557
558 * java/io/natFileDescriptorPosix.cc (open): Recognize EXCL flag.
559 * java/io/FileDescriptor.java (EXCL): New static field.
560 * java/io/File.java (tmpdir): New static field.
561 (createTempFile): New method.
562 (nextValue): New method.
563 * java/lang/natSystem.cc (init_properties): Set java.io.tmpdir
564 property.
565
566 * include/jni.h (JNI_FALSE): Renamed from JNI_TRUE; oops.
567 (jboolean): Declare as an attributed int, not a bool.
568 (_Jv_func): Declare differently for C.
569
570 * gnu/gcj/jni/natNativeThread.cc: New file.
571 * gnu/gcj/jni/NativeThread.java: New file.
572 * java/lang/Thread.java (data): Now a RawData.
573 * include/jvm.h (_Jv_GetCurrentJNIEnv, _Jv_SetCurrentJNIEnv):
574 Declare.
575 * Makefile.in: Rebuilt.
576 * Makefile.am (java/lang/Thread.h): New target.
577 (ordinary_java_source_files): Added NativeThread.java.
578 (nat_source_files): Added natNativeThread.cc.
579 * java/lang/natThread.cc: Include <jni.h>
580 (struct natThread): Added `jni_env' field.
581 (_Jv_GetCurrentJNIEnv): New function.
582 (_Jv_SetCurrentJNIEnv): Likewise.
583 (initialize_native): Initialize jni_env.
584 Include RawData.h.
585 * jni.cc (ThreadGroupClass): New define.
586 (_Jv_JNI_InvokeFunctions): New structure.
587 (JNI_GetCreatedJavaVMs): New function.
588 (the_vm): New global.
589 (JNI_GetDefaultJavaVMInitArgs): New function.
590 Include NativeThread.h.
591 (NativeThreadClass): New define.
592 (_Jv_JNI_EnsureLocalCapacity): Return JNI_ERR, not -1.
593 (_Jv_JNI_DestroyJavaVM): New function.
594 (_Jv_JNI_AttachCurrentThread): New function.
595 (_Jv_JNI_DetachCurrentThread): New function.
596 (_Jv_JNI_GetEnv): New function.
597 (JNI_CreateJavaVM): New function.
598 (_Jv_JNI_GetJavaVM): New function.
599 (_Jv_JNIFunctions): Added entry for GetJavaVM.
600 * include/jni.h (JavaVMAttachArgs): New structure.
601 (JNI_EDETACHED): New define.
602 (JNI_EVERSION): Likewise.
603 (JavaVM): Define properly.
604 (struct JNIInvokeInterface): New structure.
605 (class _Jv_JavaVM): New class.
606 (JNI_OnLoad, JNI_OnUnload): Declare.
607 (JNI_GetDefaultJavaVMInitArgs, JNI_CreateJavaVM,
608 JNI_GetCreatedJavaVMs): Declare.
609 (JavaVMInitArgs): New typedef.
610 (JavaVMOption): Likewise.
611 (JNI_ERR): New define.
612 (JNI_OK): Likewise.
613
614 2000-02-10 Andrew Haley <aph@cygnus.com>
615
616 * interpret.cc: Don't include fdlibm.h.
617 Replace #if with #ifdef throughout.
618 Declare extern __ieee754_fmod.
619 (continue1): Remove op_getfield, op_getstatic, op_putfield,
620 op_putstatic insns.
621 * resolve.cc (_Jv_PrepareClass): Use imeth as method pointer.
622 Search class hierarchy for superclass vtable.
623
624 * java/lang/natClassLoader.cc (_Jv_UnregisterClass): Don't fall
625 off the end of a pointer list.
626
627 * java/lang/natThread.cc (stop): Don't abort, throw an exception
628 instead.
629 (suspend): Ditto.
630
631 2000-02-09 Tom Tromey <tromey@cygnus.com>
632
633 * java/lang/natRuntime.cc (_load): Call add_library.
634 (loadLibraryInternal): Likewise.
635
636 * gnu/gcj/convert/natIconv.cc (Input_iconv::finalize): Call
637 iconv_close when handle is not NULL. Thanks to Andrew Haley.
638 (Output_iconv::finalize): Likewise.
639
640 2000-02-08 Tom Tromey <tromey@cygnus.com>
641
642 * java/util/Properties.java (setProperty): New method.
643 (store): New method.
644
645 2000-02-07 Tom Tromey <tromey@cygnus.com>
646
647 * java/lang/Runtime.java (_load): Declare.
648 (load, loadLibrary): Wrote in terms of _load.
649 * java/lang/natRuntime.cc (load): Call JNI_OnLoad if it appears in
650 library.
651 (loadLibrary): Likewise.
652 Include <jni.h>.
653 (_load): New method.
654 (loadLibrary, load): Removed.
655
656 * jni.cc (ThrowableClass): New define.
657 (_Jv_JNI_Throw): Check argument.
658 (_Jv_JNI_ThrowNew): Likewise.
659 (wrap_value): Don't wrap object if it is NULL.
660 (_Jv_JNI_DefineClass): Use wrap_value.
661 (_Jv_JNI_FindClass): Likewise.
662 (_Jv_JNI_GetSuperclass): Likewise.
663 (_Jv_JNI_ExceptionOccurred): Likewise.
664 (_Jv_JNI_AllocObject): Likewise.
665 (_Jv_JNI_GetObjectClass): Likewise.
666 (_Jv_JNI_NewString): Likewise.
667 (_Jv_JNI_NewStringUTF): Likewise.
668 (_Jv_JNI_NewObjectArray): Likewise.
669 (_Jv_JNI_GetObjectArrayElement): Likewise.
670 (_Jv_JNI_NewPrimitiveArray): Likewise.
671 (_Jv_JNI_ToReflectedField): Likewise.
672 (_Jv_JNI_ToReflectedMethod): Likewise.
673 (_Jv_JNI_AllocObject): Check argument.
674 (_Jv_JNI_NewObjectV): Likewise.
675 (_Jv_JNI_NewObject): Likewise.
676 (_Jv_JNI_NewObjectA): Likewise.
677 (_Jv_JNI_GetObjectClass): Likewise.
678 (_Jv_JNI_GetField): Likewise.
679 (_Jv_JNI_SetField): Likewise.
680
681 * interpret.cc (PUSHL): Don't use expression statement.
682 (PUSHD): Likewise.
683 (LOADL): Likewise.
684 (STOREL): Likewise.
685
686 * jni.cc (add_char): Conditional on INTERPRETER.
687 (mangled_name): Likewise.
688 (call): Likewise.
689 * include/java-interp.h (class _Jv_MethodBase): Conditional on
690 INTERPRETER.
691 (class _Jv_JNIMethod): Likewise.
692
693 2000-02-04 Warren Levy <warrenl@cygnus.com>
694
695 * Makefile.am: Added MPN.java and BigInteger.java.
696 * Makefile.in: Rebuilt.
697 * gnu/gcj/math/MPN.java: New file. From Kawa by Per Bothner
698 <per@bothner.com>.
699 * java/math/BigInteger.java: New file. Based primarily on
700 Kawa's IntNum.java by Per Bothner <per@bothner.com>.
701
702 2000-02-04 Tom Tromey <tromey@cygnus.com>
703
704 * defineclass.cc (handleMethodsBegin): Allocate _Jv_MethodBase
705 pointers.
706 (handleMethodsEnd): Fixed error messages. Create a _Jv_JNIMethod
707 if the method is native.
708 * resolve.cc (ncode): Don't handle native methods.
709 (_Jv_JNIMethod::ncode): New method.
710 (_Jv_PrepareClass): Handle native methods.
711 * jni.cc (call): Renamed from _Jv_JNI_conversion_call.
712 Include AbstractMethodError.h.
713 (add_char): New function.
714 (mangled_name): Likewise.
715 * include/java-interp.h (class _Jv_JNIMethod): New class.
716 (class _Jv_MethodBase): New class.
717 (class _Jv_InterpMethod): Derive from _Jv_MethodBase.
718 (_Jv_InterpClass): Changed `interpreted_methods' field to type
719 `_Jv_MethodBase'.
720
721 * include/jvm.h (_Jv_FindSymbolInExecutable): Declare.
722 * java/lang/natRuntime.cc (libraries_size, libraries_count,
723 libraries): New globals.
724 (add_library): New function.
725 (_Jv_FindSymbolInExecutable): New function.
726
727 * java/lang/natClassLoader.cc (initiated_classes, loaded_classes):
728 Now static.
729
730 2000-02-04 Andrew Haley <aph@cygnus.com>
731
732 * java/lang/Throwable.java (CPlusPlusDemangler): New class.
733 (printStackTrace): Use a CPlusPlusDemangler to demangle names.
734 * java/lang/natThrowable.cc (printRawStackTrace): Rename
735 printStackTrace to printRawStackTrace.
736
737 2000-02-03 Tom Tromey <tromey@cygnus.com>
738
739 * java/util/Calendar.java (toString): New method.
740 * java/util/SimpleTimeZone.java (clone): New method.
741 (toString): New method.
742 * java/util/TimeZone.java (clone): New method.
743 * java/text/SimpleDateFormat.java (clone): New method.
744 * java/text/NumberFormat.java (clone): New method.
745 (equals): New method.
746 * java/text/Format.java (clone): New method.
747 * java/text/DateFormatSymbols.java (DateFormatSymbols): New
748 constructor.
749 (clone): New method.
750 * java/text/DateFormat.java (clone): New method.
751 * java/text/Collator.java (clone): New method.
752
753 2000-02-03 Tom Tromey <tromey@cygnus.com>
754
755 * java/io/PipedOutputStream.java (write(byte[], int, int)): New
756 method.
757
758 2000-02-01 Tom Tromey <tromey@cygnus.com>
759
760 * include/java-interp.h (_Jv_JNI_conversion_call): Declare.
761 * resolve.cc (ncode): Use _Jv_JNI_conversion_call when
762 constructing the closure if the function is native.
763 * jni.cc (_Jv_JNI_conversion_call): Now returns `void'. No longer
764 a template function, #if'd out, or static.
765 Include <java-interp.h>.
766
767 * include/jni.h (class _Jv_JNIEnv): Corrected calls using `...'.
768
769 * include/jni.h (class _Jv_JNIEnv): Added all C++ inline methods.
770
771 * jni.cc (_Jv_JNI_PopLocalFrame): Leave loop when `n == NULL'.
772 (_Jv_JNI_conversion_call): _Jv_JNI_PopLocalFrame will never leave
773 `locals == NULL'.
774 (wrap_value): New function.
775 (_Jv_JNI_CallAnyMethodV): Use it.
776 (_Jv_JNI_CallAnyMethodA): Likewise.
777 (_Jv_JNI_GetField): Use wrap_value; removed specialized version.
778 (_Jv_JNI_GetStaticField): Likewise.
779
780 * jni.cc (_Jv_JNI_GetField): Specialize for jobject.
781 (_Jv_JNI_GetStaticField): Likewise.
782
783 2000-01-31 Tom Tromey <tromey@cygnus.com>
784
785 * prims.cc (_Jv_MallocUnchecked): New function.
786 (main_init): Call _Jv_JNI_Init.
787 * include/jvm.h (_Jv_MallocUnchecked): Declare.
788 (_Jv_JNI_Init): Declare.
789 * jni.cc: Include Hashtable.h, OutOfMemoryError.h, Integer.h,
790 <string.h>.
791 (_Jv_JNI_NewGlobalRef): New function.
792 (_Jv_JNI_DeleteGlobalRef): New function.
793 (_Jv_JNI_DeleteLocalRef): New function.
794 (_Jv_JNI_conversion_call): Initialize and clear local reference
795 frame.
796 (_Jv_JNI_NewLocalRef): New function.
797 (struct _Jv_JNI_LocalFrame): New structure.
798 (_Jv_JNI_PushLocalFrame): New function.
799 (_Jv_JNI_EnsureLocalCapacity): New function.
800 (FRAME_SIZE): New define.
801 (_Jv_JNI_GetStringChars): Mark string, not characters.
802 (_Jv_JNI_ReleaseStringChars): Unmark string, not characters.
803 (_Jv_JNI_GetPrimitiveArrayElements): Mark array, not elements.
804 (_Jv_JNI_ReleasePrimitiveArrayElements): Unmark array, not
805 elements.
806 (_Jv_JNI_DefineClass): Make return value a local ref.
807 (_Jv_JNI_FindClass): Likewise.
808 (_Jv_JNI_GetSuperclass): Likewise.
809 (_Jv_JNI_ExceptionOccurred): Likewise.
810 (_Jv_JNI_AllocObject): Likewise.
811 (_Jv_JNI_GetObjectClass): Likewise.
812 (_Jv_JNI_CallAnyMethodV): Likewise.
813 (_Jv_JNI_NewString): Likewise.
814 (_Jv_JNI_NewStringUTF): Likewise.
815 (_Jv_JNI_NewObjectArray): Likewise.
816 (_Jv_JNI_GetObjectArrayElement): Likewise.
817 (_Jv_JNI_ToReflectedField): Likewise.
818 (_Jv_JNI_ToReflectedMethod): Likewise.
819 (_Jv_JNIFunctions): Updated table for new functions.
820 (_Jv_JNI_Init): New function.
821 (mark_for_gc): Wrote.
822 (unmark_for_gc): Wrote.
823 * include/jni.h (struct JNINativeInterface): Removed name from
824 PopLocalFrame parameter.
825 (class _Jv_JNIEnv): Added `locals' field.
826
827 Mon Jan 31 00:43:15 2000 Anthony Green <green@redhat.com>
828
829 * gnu/gcj/convert/natIconv.cc (read): Minor fixes.
830 (write): Ditto.
831
832 2000-01-30 Tom Tromey <tromey@cygnus.com>
833
834 * include/config.h.in: Rebuilt.
835 * acconfig.h (HAVE_ICONV): Define.
836 * configure: Rebuilt.
837 * configure.in: Check for `iconv' function.
838 * gnu/gcj/convert/BytesToUnicode.java (getDecoder): Try iconv if
839 no specific encoder exists.
840 * gnu/gcj/convert/UnicodeToBytes.java (getEncoder): Try iconv if
841 no specific encoder exists.
842 * Makefile.in: Rebuilt.
843 * Makefile.am (convert_source_files): Mention Input_iconv.java and
844 Output_iconv.java.
845 (nat_source_files): Added natIconv.cc.
846 * gnu/gcj/convert/natIconv.cc: New file.
847 * gnu/gcj/convert/Input_iconv.java: New file.
848 * gnu/gcj/convert/Output_iconv.java: New file.
849
850 2000-01-28 Tom Tromey <tromey@cygnus.com>
851
852 * Makefile.in: Rebuilt.
853 * Makefile.am (LIBFFIINCS): Added MULTIBUILDTOP.
854
855 2000-01-26 Tom Tromey <tromey@cygnus.com>
856
857 * gcj/method.h (JvNumMethods): Moved from Class.h.
858 (JvGetFirstMethod): Likewise.
859 * java/lang/Class.h (Object): Updated decl of
860 _Jv_JNI_ToReflectedField.
861 (Object): Added _Jv_JNI_ToReflectedMethod as a friend.
862 * Makefile.in: Rebuilt.
863 * Makefile.am (java/lang/reflect/Field.h): Added `jboolean'
864 argument of _Jv_JNI_ToReflectedField.
865 (java/lang/reflect/Constructor.h): Added _Jv_JNI_ToReflectedMethod
866 as a friend.
867 (java/lang/reflect/Method.h): Likewise.
868 * include/jni.h (class _Jv_JNIEnv): Added `klass' member. Use
869 __GCJ_JNI_IMPL__.
870 (jweak): New typedef.
871 (struct JNINativeInterface): Correctly declare remaining entries.
872 * jni.cc: Include Class.h, ClassLoader.h.
873 (_Jv_JNI_FindClass): New function.
874 (_Jv_JNI_DefineClass): New function.
875 (_Jv_JNI_conversion_call): New function.
876 (_Jv_JNI_FindClass): Use current class loader to find class.
877 (_Jv_JNI_ExceptionCheck): New function.
878 (_Jv_JNI_FromReflectedField): Now static.
879 (MethodClass): New define.
880 (_Jv_JNI_FromReflectedMethod): New function.
881 (_Jv_JNI_ToReflectedMethod): Likewise.
882 Include Method.h.
883 (_Jv_JNI_IsAssignableFrom): Renamed.
884 (_Jv_JNI_GetStringRegion): New function.
885 Include StringIndexOutOfBoundsException.h.
886 (_Jv_JNI_GetStringUTFRegion): New function.
887 (_Jv_JNIFunctions): Updated for new functions.
888 (_Jv_JNI_GetPrimitiveArrayCritical): New function
889 (_Jv_JNI_ReleasePrimitiveArrayCritical): Likewise.
890 (_Jv_JNI_GetStringCritical): New function.
891 (_Jv_JNI_ReleaseStringCritical): Likewise.
892 (get_throwable): Removed.
893 (GCJ_JV_JNIENV_FRIEND): Removed.
894 (__GCJ_JNI_IMPL__): Define.
895 Include method.h.
896
897 * resolve.cc (get_ffi_type_from_signature): Handle case where
898 boolean is an int.
899
900 Tue Jan 25 08:51:16 2000 Tom Tromey <tromey@ferrule.cygnus.com>
901
902 * interpret.cc (run): Don't call println.
903 Don't include PrintStream.h.
904
905 * gcj/field.h (struct _Jv_Field): Use "jshort" as type for
906 nameIndex. Use "jint" as type for boffset.
907 * java/lang/Class.h (struct _Jv_Method): Made accflags a
908 _Jv_ushort.
909 (Class): Likewise. Also changed type of method_count,
910 vtable_method_count, size_in_bytes, field_count,
911 static_field_count, interface_count.
912 * gcj/array.h (__JArray): Made `length' a const jsize, not an
913 int.
914
915 2000-01-21 Tom Tromey <tromey@cygnus.com>
916
917 * java/lang/reflect/natConstructor.cc (newInstance): Use
918 _Jv_CallAnyMethodA.
919 * include/jvm.h: Declare _Jv_CallAnyMethodA.
920 * java/lang/reflect/natMethod.cc (_Jv_CallAnyMethodA): Renamed
921 from _Jv_CallNonvirtualMethodA. Changed interface; overloaded.
922 Include <jni.h>.
923 (COPY): Removed.
924 (invoke): Use _Jv_CallAnyMethodA.
925 (VAL): Redefined.
926 * java/lang/Class.h (Class): Declare JvGetFirstStaticField,
927 JvNumStaticFields, JvNumMethods, and JvGetFirstMethod as friend
928 functions.
929 (struct _Jv_Method): Added getNextMethod method.
930 (JvNumMethods): New function.
931 (JvGetFirstMethod): Likewise.
932 * gcj/field.h (JvGetFirstStaticField): New function.
933 (JvNumStaticFields): Likewise.
934 (getNextField): Renamed from getNextInstanceField.
935 (struct _Jv_Field): New method getClass.
936 * jni.cc: Wrote many new functions.
937 * include/jni.h (JNI_TRUE): Define.
938 (JNI_FALSE): Likewise.
939 (jobject, jclass, jstring, jarray, jthrowable, jobjectArray,
940 jbyteArray, jshortArray, jintArray, jlongArray, jbooleanArray,
941 jcharArray, jfloatArray, jdoubleArray): New typedefs.
942 (jfieldID, jmethodID): Likewise.
943 (JNI_COMMIT, JNI_ABORT): New defines.
944 (JNINativeMethod): New struct.
945 (struct JNINativeInterface): Correctly declared more entries.
946 (class _Jv_JNIEnv): Added `ex' member.
947 (JNI_VERSION_1_1): New define.
948 (JNI_VERSION_1_2): Likewise.
949
950 * boehm.cc (_Jv_MarkObj): Use getNextField, not
951 getNextInstanceField.
952
953 2000-01-20 Tom Tromey <tromey@cygnus.com>
954
955 * resolve.cc (StringClass): Removed.
956 * defineclass.cc (StringClass): Removed.
957
958 2000-01-19 Bryce McKinlay <bryce@albatross.co.nz>
959
960 * NEWS: updated.
961
962 2000-01-19 Tom Tromey <tromey@cygnus.com>
963
964 * interpret.cc (PC_REGISTER_ASM): Removed.
965
966 * java/lang/natThrowable.cc: Don't use `#pragma implementation'.
967 From Bryce McKinlay.
968
969 * All files: Updated copyright to reflect Cygnus purchase.
970
971 2000-01-18 Bryce McKinlay <bryce@albatross.co.nz>
972
973 * configure: Rebuilt.
974 * configure.in: Recognize --disable-interpreter.
975
976 2000-01-18 Andrew Haley <aph@cygnus.com>
977
978 * name-finder.cc (lookup): Check for dladdr function.
979 acconfig.h (HAVE_DLADDR): Add.
980 configure.in: Check for HAVE_DLADDR
981 configure: Rebuilt.
982 include/config.h.in: Rebuilt.
983
984 2000-01-17 Andrew Haley <aph@cygnus.com>
985
986 * prims.cc (_Jv_RunMain): Set the name of this executable.
987
988 2000-01-17 Tom Tromey <tromey@cygnus.com>
989
990 * java/lang/natThrowable.cc (fillInStackTrace): Return `this' even
991 when backtrace can't be computed.
992
993 * configure: Rebuilt.
994 * configure.in: Fixed typo in AC_CONFIG_SUBDIRS call.
995
996 * java/lang/Runtime.java (loadLibraryInternal): Declare.
997 * java/lang/natClassLoader.cc (_Jv_FindClass): Removed dead copy.
998 (_Jv_FindClassInCache): Likewise.
999 (_Jv_FindClass): Don't conditionalize body on INTERPRETER.
1000 (findSystemClass): Try to load class from compiled module.
1001 Include Runtime.h.
1002 * java/lang/natRuntime.cc (load): Use UTF-8 copy of filename.
1003 (loadLibrary): Likewise.
1004 (lt_preloaded_symbols): Define.
1005 (loadLibraryInternal): New method.
1006 * include/config.h.in: Rebuilt.
1007 * acconfig.h (USE_LTDL): Added.
1008 * Makefile.am (SUBDIRS): Added $(DIRLTDL).
1009 (INCLUDES): Added $(INCLTDL).
1010 (libgcj_la_DEPENDENCIES): Added $(LIBLTDL).
1011 (libgcj_la_LIBADD): Likewise.
1012 * aclocal.m4, configure: Rebuilt.
1013 * configure.in: Added libltdl support.
1014
1015 2000-01-15 Tom Tromey <tromey@cygnus.com>
1016
1017 * prims.cc (_Jv_PrimClass): Use `JV_STATE_NOTHING', not `0'.
1018
1019 2000-01-14 Andrew Haley <aph@cygnus.com>
1020
1021 * java/lang/natThrowable.cc: New file.
1022
1023 * java/lang/Throwable.java (fillInStackTrace): Make native.
1024 (printStackTrace): Call native method to do this.
1025 (Throwable): Call fillInStackTrace.
1026 (stackTrace): New variable.
1027
1028 * include/jvm.h: Add _Jv_ThisExecutable functions.
1029
1030 * prims.cc: (_Jv_execName): New variable.
1031 (catch_segv): Call fillInStackTrace.
1032 (catch_fpe): Ditto.
1033 (_Jv_ThisExecutable): New functions.
1034 (JvRunMain): Set the name of this executable.
1035
1036 * Makefile.am: Add java/lang/natThrowable.cc.
1037 Add name-finder.cc.
1038 * Makefile.in: Rebuilt.
1039
1040 * acconfig.h: Add HAVE_PROC_SELF_EXE.
1041
1042 * configure.in: Force link with __frame_state_for in
1043 FORCELIBGCCSPEC. Add new checks for backtrace.
1044 * include/config.h.in: Rebuilt.
1045
1046 * name-finder.cc: New file.
1047 * include/name-finder.h: New file.
1048
1049 2000-01-16 Anthony Green <green@cygnus.com>
1050
1051 * java/lang/StringBuffer.java (StringBuffer): Don't special case
1052 null argument.
1053
1054 2000-01-16 Jeff Sturm <jsturm@sigma6.com>
1055
1056 * java/io/StreamTokenizer.java (nextToken): Avoid unread(TT_EOF).
1057
1058 2000-01-13 Tom Tromey <tromey@cygnus.com>
1059
1060 * java/lang/natClassLoader.cc (_Jv_FindClass): Register `loader',
1061 not system loader, as initiating loader.
1062
1063 2000-01-11 Tom Tromey <tromey@cygnus.com>
1064
1065 * java/lang/natSystem.cc (getpwuid_adaptor): New adaptor for
1066 HP/UX. From David Scott Urban.
1067
1068 2000-01-10 Jeff Sturm <jsturm@sigma6.com>
1069
1070 * java/lang/natMath.cc (pow): Cast args to `double', not
1071 `jdouble'.
1072 (atan2): Likewise.
1073 (IEEEremainder): Likewise.
1074 * java/lang/mprec.h: Don't wrap includes in `extern "C"'.
1075 * java/lang/fdlibm.h: Don't wrap includes in `extern "C"'.
1076
1077 2000-01-09 Anthony Green <green@cygnus.com>
1078
1079 * java/lang/natString.cc (init): Test for overflow condition
1080 during out of bounds check.
1081 (getChars): Throw StringIndexOutOfBoundsException, not
1082 ArrayIndexOutOfBoundsException.
1083 (getBytes): Ditto.
1084 (regionMatches): Obey case option during string comparison.
1085
1086 * configure.host (ligcj_interpreter): New variable. Enable
1087 interpreter by default on IA-32.
1088 * configure.in: Examine libgcj_interpreter.
1089 * configure: Rebuilt.
1090
1091 2000-01-07 Tom Tromey <tromey@cygnus.com>
1092
1093 * mauve-libgcj: Don't disable ClassTest.
1094
1095 * java/lang/natClass.cc (getClasses): Wrote.
1096
1097 2000-01-06 Tom Tromey <tromey@cygnus.com>
1098
1099 * java/lang/natClass.cc (_getConstructors): Correctly check
1100 whether method name is the init name.
1101 (getMethod): Look at accflags on method in `klass', not `this'.
1102
1103 2000-01-05 Tom Tromey <tromey@cygnus.com>
1104
1105 * java/lang/natClass.cc (getMethod): Compute offset relative to
1106 `klass's methods table, not `this's table.
1107
1108 * java/lang/reflect/natMethod.cc (_Jv_CallNonvirtualMethodA):
1109 In unwrapping/widening case, check whether `k' is null, not
1110 whether it is primitive. Initialize `num' from `argelts', not
1111 `paramelts'. Correct create and pass arguments to ffi_call.
1112 Don't let presence of `this' argument affect index used to look in
1113 argument arrays.
1114 (COPY): Set appropriate element in `values' vector.
1115
1116 * java/lang/natClass.cc: Include <gcj/method.h>.
1117
1118 * java/lang/Class.h (_getMethods): Correctly declare as private,
1119 not public.
1120
1121 * java/lang/Class.h (_getMethods): Declare.
1122 * java/lang/Class.java (_getMethods): Declare.
1123 * java/lang/natClass.cc (getDeclaringClass): Always return NULL.
1124 (getDeclaredClasses): Always return empty array.
1125 (_getMethods): New method.
1126 (getMethods): Wrote.
1127 (getDeclaredMethod): Return `rmethod'.
1128 (finit_name): New global.
1129 (getDeclaredMethods): Check for finit_name.
1130 (_getMethods): Likewise.
1131 (getMethod): Only return public methods.
1132
1133 * java/lang/reflect/natMethod.cc (get_ffi_type): Test size of
1134 jboolean and select correct ffi type on that basis.
1135 (_Jv_CallNonvirtualMethodA): Handle `void' return type.
1136 Constructor call always has `void' return type.
1137
1138 2000-01-04 Tom Tromey <tromey@cygnus.com>
1139
1140 * java/lang/Class.h (getSignature): Updated.
1141 * java/lang/Class.java (getSignature): Updated.
1142 * java/lang/natClass.cc (getSignature): Added `is_constructor'
1143 argument.
1144 (getConstructor): Ensure constructor is public.
1145 (_getConstructors): Check for public-ness of constructor when
1146 `declared' is false, not when it is true.
1147
1148 2000-01-04 Warren Levy <warrenl@cygnus.com>
1149
1150 * java/net/natPlainDatagramSocketImpl.cc (peek): Removed unnecesary
1151 comment.
1152 (receive): Set the sender's address in the DatagramPacket.
1153
1154 2000-01-04 Tom Tromey <tromey@cygnus.com>
1155
1156 * java/lang/reflect/natConstructor.cc (newInstance): Pass
1157 declaring class as return_type argument to
1158 _Jv_CallNonvirtualMethodA.
1159 * java/lang/reflect/natMethod.cc (_Jv_CallNonvirtualMethodA): In
1160 constructor case, create object and use it as `this' argument.
1161 * java/lang/Class.h (_getConstructors): Declare.
1162 (_getFields): Declare.
1163 * java/lang/Class.java (getConstructors): Wrote.
1164 (_getConstructors): New native method.
1165 (getDeclaredConstructors): Wrote.
1166 (_getFields): Declare new native method.
1167 * java/lang/natClass.cc (_Jv_LookupInterfaceMethod): Removed
1168 incorrect comment.
1169 (getMethod): Work correctly when class is primitive.
1170 (getDeclaredMethods): Likewise. Compute offset using `method',
1171 not `mptr'.
1172 (getDeclaredMethod): Likewise.
1173 (getConstructor): Wrote.
1174 (ConstructorClass): New define.
1175 (getDeclaredConstructor): Wrote.
1176 (_getConstructors): New method.
1177 (_getFields): New method.
1178 (getFields): Wrote.
1179
1180 * Makefile.in: Rebuilt.
1181 * Makefile.am (AM_CXXFLAGS): Added -D_GNU_SOURCE.
1182
1183 * prims.cc: Remove `#pragma implementation'.
1184 * gcj/array.h: Remove `#pragma interface'.
1185
1186 * prims.cc (_Jv_equaln): New function.
1187 * java/lang/Class.java (getSignature): Declare.
1188 * resolve.cc (_Jv_LookupDeclaredMethod): Moved to natClass.cc.
1189 * java/lang/natClass.cc (_Jv_LookupDeclaredMethod): Moved from
1190 resolve.cc.
1191 (getSignature): New method.
1192 (getDeclaredMethod): Wrote.
1193 (getMethod): Wrote.
1194 Include StringBuffer.h.
1195 * java/lang/Class.h (Class): Added _Jv_FromReflectedConstructor
1196 as a friend. Unconditionally declare _Jv_LookupDeclaredMethod as
1197 a friend.
1198 (getSignature): Declare.
1199 * include/jvm.h (_Jv_GetTypesFromSignature): Declare.
1200 (_Jv_equaln): Declare.
1201 (_Jv_CallNonvirtualMethodA): Declare.
1202 * Makefile.in: Rebuilt.
1203 * Makefile.am (nat_source_files): Added natConstructor.cc.
1204 (java/lang/reflect/Constructor.h): New target.
1205 * java/lang/reflect/natConstructor.cc: New file.
1206 * java/lang/reflect/Constructor.java (newInstance): Now native.
1207 (declaringClass): Renamed from decl_class.
1208 (offset): Renamed from index.
1209 (getType): New native method.
1210 (getModifiers): Now native.
1211 (getParameterTypes): Call getType if required.
1212 (hashCode): Include hash code from declaring class.
1213 (modifiers): Removed.
1214 (toString): Call getType if required.
1215 * gcj/method.h (_Jv_FromReflectedConstructor): New function.
1216 * java/lang/reflect/natMethod.cc (hack_call): New method.
1217 Removed `#if 0' around FFI code.
1218 Include <gnu/gcj/RawData.h>.
1219 (invoke): Use _Jv_CallNonvirtualMethodA. Throw
1220 IllegalArgumentException when argument object and class disagree.
1221 (_Jv_GetTypesFromSignature): New function.
1222 (getType): Use it.
1223 (ObjectClass): New define.
1224 (_Jv_CallNonvirtualMethodA): New function.
1225 * java/lang/reflect/Method.java (hack_trampoline): New method.
1226 (hack_call): New native method.
This page took 0.095074 seconds and 6 git commands to generate.