]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/java/ChangeLog
edc2c552361abfd2dd7847c906f99aa87651b2fc
[thirdparty/gcc.git] / gcc / java / ChangeLog
1 2015-06-25 Richard Sandiford <richard.sandiford@arm.com>
2
3 * jcf-io.c (charstar_hash): Inherit from nofree_ptr_hash rather
4 than typed_noop_remove. Remove redudant typedefs.
5
6 2015-06-17 Andrew MacLeod <amacleod@redhat.com>
7
8 * boehm.c: Do not include input.h, line-map.h or is-a.h.
9 * builtins.c: Likewise.
10 * class.c: Likewise.
11 * constants.c: Likewise.
12 * decl.c: Likewise.
13 * except.c: Likewise.
14 * expr.c: Likewise.
15 * java-gimplify.c: Likewise.
16 * jcf-dump.c: Likewise.
17 * jcf-io.c: Likewise.
18 * jcf-parse.c: Likewise.
19 * jvgenmain.c: Likewise.
20 * lang.c: Likewise.
21 * mangle.c: Likewise.
22 * mangle_name.c: Likewise.
23 * resource.c: Likewise.
24 * typeck.c: Likewise.
25 * verify-glue.c: Likewise.
26 * verify-impl.c: Likewise.
27
28 2015-06-08 Andrew MacLeod <amacleod@redhat.com>
29
30 * boehm.c : Adjust include files.
31 * builtins.c : Likewise.
32 * class.c : Likewise.
33 * constants.c : Likewise.
34 * decl.c : Likewise.
35 * except.c : Likewise.
36 * expr.c : Likewise.
37 * java-gimplify.c : Likewise.
38 * java-tree.h : Likewise.
39 * jcf-dump.c : Likewise.
40 * jcf-io.c : Likewise.
41 * jcf-parse.c : Likewise.
42 * jcf-reader.c : Likewise.
43 * jvgenmain.c : Likewise.
44 * lang.c : Likewise.
45 * mangle.c : Likewise.
46 * mangle_name.c : Likewise.
47 * resource.c : Likewise.
48 * typeck.c : Likewise.
49 * verify-glue.c : Likewise.
50 * verify-impl.c : Likewise.
51
52 2015-06-05 Aldy Hernandez <aldyh@redhat.com>
53
54 * jcf-parse.c: Include toplev.h.
55
56 2015-06-05 Aldy Hernandez <aldyh@redhat.com>
57
58 * class.c: Remove pending_static_fields.
59 (add_field): Remove use of pending_static_fields.
60 (java_write_globals): Remove.
61 * decl.c (java_mark_class_local): Remove use of
62 pending_static_fields.
63 * java-tree.h: Remove pending_static_fields and
64 java_write_globals.
65 * jcf-parse.c (java_parse_file): Call global_decl_processing.
66 * lang.c (LANG_HOOKS_WRITE_GLOBALS): Remove.
67
68 2015-06-04 Andrew MacLeod <amacleod@redhat.com>
69
70 * boehm.c: Adjust includes for restructured coretypes.h.
71 * builtins.c: Likewise.
72 * class.c: Likewise.
73 * constants.c: Likewise.
74 * decl.c: Likewise.
75 * except.c: Likewise.
76 * expr.c: Likewise.
77 * java-gimplify.c: Likewise.
78 * jcf-dump.c: Likewise.
79 * jcf-io.c: Likewise.
80 * jcf-parse.c: Likewise.
81 * jvgenmain.c: Likewise.
82 * lang.c: Likewise.
83 * mangle.c: Likewise.
84 * mangle_name.c: Likewise.
85 * resource.c: Likewise.
86 * typeck.c: Likewise.
87 * verify-glue.c: Likewise.
88 * verify-impl.c: Likewise.
89
90 2015-05-20 David Malcolm <dmalcolm@redhat.com>
91
92 * jcf-parse.c (set_source_filename): Replace write through
93 ORDINARY_MAP_FILE_NAME with direct access to "to_file".
94
95 2015-04-18 Trevor Saunders <tsaunders@mozilla.com>
96
97 * jcf-io.c: Adjust for hash_table changes.
98
99 2015-01-30 Joseph Myers <joseph@codesourcery.com>
100
101 * class.c, expr.c, jcf-parse.c, jvspec.c: All callers of
102 fatal_error changed to pass input_location as first argument.
103
104 2015-10-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
105
106 * builtins.c: Include calls.h dojump.h emit-rtl.h explow.h expmed.h
107 fixed-value.h function.h hard-reg-set.h hashtab.h insn-config.h
108 real.h statistics.h stmt.h varasm.h.
109
110 2015-01-09 Michael Collison <michael.collison@linaro.org>
111
112 * boehm.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
113 input.h, alias.h, symtab.h, options.h, fold-const.h,
114 wide-int.h, and inchash.h due to flattening of tree.h.
115 * builtins.c: Ditto.
116 * class.c: Ditto.
117 * constants.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
118 input.h, alias.h, symtab.h, options.h, fold-const.h,
119 wide-int.h, and inchash.h due to flattening of tree.h.
120 * decl.c: Ditto.
121 * except.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
122 input.h, alias.h, symtab.h, fold-const.h,
123 wide-int.h, and inchash.h due to flattening of tree.h.
124 * expr.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
125 input.h, alias.h, symtab.h, fold-const.h,
126 wide-int.h,inchash.h and real.h due to flattening of tree.h.
127 * gimplify.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
128 input.h, alias.h, symtab.h, options.h, fold-const.h,
129 wide-int.h, and inchash.h due to flattening of tree.h.
130 * jcf-dump.c: Ditto.
131 * jcf-io.c: Ditto.
132 * jcf-parse.c: Ditto.
133 * jvgenmain.c: Ditto.
134 * lang.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
135 input.h, alias.h, symtab.h, fold-const.h,
136 wide-int.h, and inchash.h due to flattening of tree.h.
137 * mangle.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
138 input.h, alias.h, symtab.h, options.h, fold-const.h,
139 wide-int.h, and inchash.h due to flattening of tree.h.
140 * mangle_name.c: Ditto.
141 * resource.c: Ditto.
142 * typeck.c: Ditto.
143 * verify-glue.c: Ditto.
144 * verify-impl.c: Ditto.
145
146 2015-01-05 Jakub Jelinek <jakub@redhat.com>
147
148 Update copyright years.
149
150 * jcf-dump.c (version): Update copyright notice dates.
151
152 2014-11-24 Richard Biener <rguenther@suse.de>
153
154 PR java/64004
155 * class.c (build_classdollar_field): Do not set TREE_READONLY.
156
157 2014-11-19 David Malcolm <dmalcolm@redhat.com>
158
159 Merger of git branch "gimple-classes-v2-option-3".
160 * ChangeLog.gimple-classes: New.
161 * java-gimplify.c (java_gimplify_block): Strengthen local "outer"
162 from gimple to gbind *.
163
164 2014-11-11 David Malcolm <dmalcolm@redhat.com>
165
166 * gcc/ChangeLog.jit: New.
167
168 2014-10-29 Richard Sandiford <richard.sandiford@arm.com>
169
170 * builtins.c, java-tree.h, typeck.c: Remove redundant enum from
171 machine_mode.
172
173 2014-10-28 Andrew MacLeod <amacleod@redhat.com>
174
175 * class.c: Adjust include files.
176 * decl.c: Ditto.
177 * jcf-parse.c: Ditto.
178 * resource.c: Ditto.
179
180 2014-10-27 Andrew MacLeod <amacleod@redhat.com>
181
182 * java-gimplify.c: Adjust include files.
183
184 2014-10-22 Alan Modra <amodra@gmail.com>
185
186 * mangle.c (finish_mangling): Cast result of obstack_base to (char *).
187 * typeck.c (build_java_argument_signature): Likewise.
188 (build_java_signature): Likewise.
189
190 2014-10-16 Andrew MacLeod <amacleod@redhat.com>
191
192 * class.c: Adjust include files.
193 * resource.c: Likewise.
194
195 2014-10-15 Evgeny Stupachenko <evstupac@gmail.com>
196
197 PR target/63536
198 * lang.c (java_print_error_function): Add check on NULL function
199 context.
200
201 2014-10-12 Trevor Saunders <tsaunders@mozilla.com>
202
203 * class.c, decl.c, except.c, expr.c, java-tree.h, lang.c: Use
204 hash_table instead of hashtab.
205
206 2014-10-07 Marek Polacek <polacek@redhat.com>
207
208 * jvgenmain.c (main): Provide declarations for JvRunMain{,Name}.
209
210 2014-07-08 Mark Wielaard <mjw@redhat.com>
211
212 * builtins.c (putVolatile_builtin): Use build_qualified_type
213 instead of build_type_variant.
214 (getVolatile_builtin): Likewise.
215 (build_classdollar_field): Likewise.
216
217 2014-06-24 Trevor Saunders <tsaunders@mozilla.com>
218
219 * jcf-io.c: Adjust.
220
221 2014-06-11 Jan Hubicka <hubicka@ucw.cz>
222
223 * java/class.c (build_utf8_ref): Update handling for section names
224 that are no longer trees.
225 (emit_register_classes_in_jcr_section): Update.
226
227 2014-06-07 Jan Hubicka <hubicka@ucw.cz>
228
229 * class.c (build_utf8_ref): Use set_decl_section_name.
230 (emit_register_classes_in_jcr_section): Likewise.
231 (emit_register_classes_in_jcr_section): Likewise.
232
233 2014-05-17 Trevor Saunders <tsaunders@mozilla.com>
234
235 * class.c (add_method_1): Adjust.
236 (java_treetreehash_new): Likewise.
237 * constants.c (set_constant_entry): Likewise.
238 (cpool_for_class): Likewise.
239 * decl.c (make_binding_level): Likewise.
240 (java_dup_lang_specific_decl): Likewise.
241 * expr.c (add_type_assertion): Likewise.
242 * java-tree.h (MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC): Likewise.
243 (lang_decl): don't use variable_size gty attribute.
244 (MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC): Adjust.
245 (lang_type): Don't use variable_size gty attribute.
246 * jcf-parse.c (java_parse_file): Adjust.
247 (process_zip_dir): Likewise.
248 * jcf.h: Remove usage of variable_size gty attribute.
249 * jcf-reader.c (jcf_parse_constant_pool): Adjust.
250 (jcf_parse_bootstrap_methods): Likewise.
251
252 2014-05-17 Trevor Saunders <tsaunders@mozilla.com>
253
254 * constants.c (set_constant_entry): Adjust.
255
256 2014-05-06 Richard Sandiford <r.sandiford@uk.ibm.com>
257
258 * boehm.c (mark_reference_fields): Don't update the mask when
259 setting pointer_after_end.
260
261 2014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
262 Mike Stump <mikestump@comcast.net>
263 Richard Sandiford <rdsandiford@googlemail.com>
264
265 * boehm.c: Include wide-int.h.
266 (mark_reference_fields): Use a wide_int mask.
267 (get_boehm_type_descriptor): Use wide-int interfaces.
268 * expr.c: Include wide-int.h.
269 (build_newarray): Remove bogus "== INTEGER_CST".
270 (expand_java_pushc): Use real_from_integer.
271 (build_field_ref): Use tree_int_cst_lt instead of INT_CST_LT_UNSIGNED.
272 * jcf-parse.c: Include wide-int.h.
273 (get_constant): Use wide-int interfaces.
274
275 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
276
277 Update copyright years
278
279 2014-01-02 Tobias Burnus <burnus@net-b.de>
280
281 * jcf-dump.c (version): Update copyright notice dates.
282 * gcj.texi: Bump @copying's copyright year.
283
284 2013-12-19 Jakub Jelinek <jakub@redhat.com>
285
286 PR other/59545
287 * class.c (hashUtf8String): Compute hash in unsigned type.
288 * javaop.h (WORD_TO_INT): Avoid signed integer overflow.
289
290 2013-11-22 Andrew MacLeod <amacleod@redhat.com>
291
292 * java-gimplify.c: Add required include files from gimple.h.
293
294 2013-11-22 David Malcolm <dmalcolm@redhat.com>
295
296 * class.c (maybe_layout_super_class): Update comment.
297 * decl.c (java_add_stmt): Remove use of input_filename macro.
298 * jcf-parse.c (set_source_filename): Remove use of
299 input_filename macro.
300 (parse_class_file): Remove use of input_line and input_filename
301 macros.
302 (java_parse_file): Remove use of input_filename macro.
303
304 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
305
306 * class.c, expr.c: Replace tree_low_cst (..., 0) with tree_to_shwi
307 throughout.
308
309 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
310
311 * class.c, expr.c: Replace host_integerp (..., 0) with
312 tree_fits_shwi_p throughout.
313
314 2013-11-14 Andrew MacLeod <amacleod@redhat.com>
315
316 * java-gimplify.c: Include only gimplify.h and gimple.h as needed.
317
318 2013-11-14 Diego Novillo <dnovillo@google.com>
319
320 * builtins.c: Include stor-layout.h.
321 Include stringpool.h.
322 * class.c: Include stringpool.h.
323 Include stor-layout.h.
324 Include varasm.h.
325 * constants.c: Include stringpool.h.
326 Include stor-layout.h.
327 * decl.c: Include stor-layout.h.
328 Include stringpool.h.
329 Include varasm.h.
330 * except.c: Include stringpool.h.
331 Include stor-layout.h.
332 * expr.c: Include stringpool.h.
333 Include stor-layout.h.
334 * jcf-parse.c: Include stringpool.h.
335 * mangle.c: Include stringpool.h.
336 * resource.c: Include stringpool.h.
337 Include stor-layout.h.
338 * typeck.c: Include stor-layout.h.
339 Include stringpool.h.
340 * verify-glue.c: Include stringpool.h.
341
342 2013-11-12 Andrew MacLeod <amacleod@redhat.com>
343
344 * java-gimplify.c: Include gimplify.h.
345
346 2013-11-07 Jeff Law <law@redhat.com>
347
348 * builtins.c (initialize_builtins): Provide __builtin_trap.
349
350 2013-10-29 David Malcolm <dmalcolm@redhat.com>
351
352 Patch autogenerated by refactor_symtab.py from
353 https://github.com/davidmalcolm/gcc-refactoring-scripts
354 revision 58bb219cc090b2f4516a9297d868c245495ee622
355
356 * decl.c (java_mark_decl_local): Update for conversion of symtab types
357 to a true class hierarchy.
358
359 2013-10-14 David Malcolm <dmalcolm@redhat.com>
360
361 * lang.c (java_handle_option): Update for introduction of
362 gcc::dump_manager.
363
364 2013-09-25 Tom Tromey <tromey@redhat.com>
365
366 * Make-lang.in (jvspec.o): Remove.
367 (CFLAGS-java/jvspec.o): New variable.
368 ($(XGCJ)$(exeext), java_OBJS): Use java/jvspec.o
369 (java/jvspec.o-warn): Rename from jvspec.o-warn.
370 (JAVA_TREE_H, java/jcf-dump.o, java/boehm.o, java/builtins.o)
371 (java/class.o, java/constants.o, java/decl.o, java/except.o)
372 (java/expr.o, java/jcf-depend.o, java/jcf-parse.o)
373 (java/jvgenmain.o, java/lang.o, java/mangle.o, java/mangle_name.o)
374 (java/resource.o java/typeck.o, java/win32-host.o)
375 (java/verify-glue.o, java/verify-impl.o, java/zextract.o)
376 (java/java-gimplify.o, java/jcf-io.o, java/jcf-path.o): Remove.
377
378 2013-09-25 Tom Tromey <tromey@redhat.com>
379
380 * Make-lang.in (jvspec.o): Don't use subshell.
381
382 2013-06-05 Jan Hubicka <jh@suse.cz>
383
384 * class.c (emit_register_classes_in_jcr_section): Use DECL_PRESERVE_P
385 instead of mark_decl_referenced.
386
387 2013-05-29 Jan Hubicka <jh@suse.cz>
388
389 * decl.c (java_mark_decl_local): Update for new symtab flags.
390
391 2013-05-22 Matthias Klose <doko@ubuntu.com>
392
393 * jvspec.c (jvgenmain_spec): Add %I to cc1 call.
394
395 2013-05-16 Jason Merrill <jason@redhat.com>
396
397 * Make-lang.in (jc1$(exeext)): Use link mutex.
398
399 2013-05-06 Jakub Jelinek <jakub@redhat.com>
400
401 PR libgcj/57074
402 * class.c (emit_symbol_table): Use array type of the
403 right size for the_syms_decl and its DECL_INITIAL, instead
404 of symbols_array_type. Set TREE_TYPE (the_syms_decl) to it.
405 (emit_assertion_table): Use array type of the right size
406 for table_decl and its DECL_INITIAL.
407
408 2013-04-15 Gerald Pfeifer <gerald@pfeifer.com>
409
410 * gcj.texi (Configure-time Options): Refer to GCC, not gcc.
411 (Resources): Adjust reference to Mauve.
412 Remove link to java.sun.com.
413 Refer to GCC, not gcc.
414
415 2013-04-09 Richard Biener <rguenther@suse.de>
416
417 * expr.c (build_java_binop): Pass a type to build_int_cst.
418
419 2013-03-22 Kai Tietz <ktietz@redhat.com>
420
421 * lang.c (put_decl_node): Don't iterate over end_params_node.
422
423 2013-01-03 Jakub Jelinek <jakub@redhat.com>
424
425 * jcf-dump.c (version): Update copyright notice dates.
426
427 2012-11-16 Diego Novillo <dnovillo@google.com>
428
429 Adjust for new vec API (http://gcc.gnu.org/wiki/cxx-conversion/cxx-vec)
430
431 * boehm.c: Use new vec API in vec.h.
432 * class.c: Likewise.
433 * constants.c: Likewise.
434 * decl.c: Likewise.
435 * expr.c: Likewise.
436 * java-tree.h: Likewise.
437 * jcf-parse.c: Likewise.
438 * resource.c: Likewise.
439 * verify-glue.c: Likewise.
440
441 2012-11-15 Jan Hubicka <jh@suse.cz>
442
443 * builtins.c (define_builtin): Accept ECF flags and
444 use set_call_expr_flags.
445 (initialize_builtins): Update.
446
447 2012-10-01 Lawrence Crowl <crowl@google.com>
448
449 * Make-lang.in (JAVA_OBJS): Add dependence on hash-table.o.
450 (JCFDUMP_OBJS): Add dependence on hash-table.o.
451 (jcf-io.o): Add dependence on hash-table.h.
452 * jcf-io.c (memoized_class_lookups): Change to use type-safe hash table.
453
454 2012-09-24 Lawrence Crowl <crowl@google.com>
455
456 * decl.c (java_init_decl_processing): Change to new double_int API.
457 * jcf-parse.c (get_constant): Likewise.
458 * boehm.c (mark_reference_fields): Likewise.
459 (get_boehm_type_descriptor): Likewise.
460
461 2012-07-30 Laurynas Biveinis <laurynas.biveinis@gmail.com>
462
463 * jcf.h (CPool): Use the "atomic" GTY option for the tags field.
464 (bootstrap_method): Likewise for the bootstrap_arguments field.
465
466 2012-07-16 Steven Bosscher <steven@gcc.gnu.org>
467
468 * java-gimplify.c: Include dumpfile.h instead of tree-dump.h
469 * Make-lang.in: Fix dependencies.
470
471 2012-07-11 Steven Bosscher <steven@gcc.gnu.org>
472
473 * java-tree.h (force_evaluation_order): Remove prototype.
474 * expr.c (force_evaluation_order): Remove unused function.
475
476 2012-07-11 Steven Bosscher <steven@gcc.gnu.org>
477
478 * decl.c: Do not include libfuncs.h.
479 * class.c: Do not include defaults.h.
480 * jvgenmain.c: Likewise.
481 * magnle.c: Likewise.
482 * Make-lang.in (decl.o): Fix dependencies.
483
484 2012-07-08 Steven Bosscher <steven@gcc.gnu.org>
485
486 * verify.h: Do not include system.h and coretypes.h here.
487 * verify-impl.c: Include them here instead.
488
489 2012-07-05 Uros Bizjak <ubizjak@gmail.com>
490
491 * jcf-io.c (read_zip_member): Initialize d_stream.
492
493 2012-05-31 Steven Bosscher <steven@gcc.gnu.org>
494
495 * resource.c: Do not include output.h.
496
497 2012-05-21 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
498
499 PR java/52815
500 * class.c (emit_register_classes_in_jcr_section): Revise placement
501 of #ifdef JCR_SECTION_NAME.
502
503 2012-04-22 Jan Hubicka <jh@suse.cz>
504
505 * class.c (build_utf8_ref): Do not mark varpool node as needed.
506
507 2012-04-20 Jan Hubicka <jh@suse.cz>
508
509 * class.c (make_local_function_alias): Do not mark symbol referenced.
510
511 2012-04-11 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
512
513 * jcf-dump.c (print_constant): Cast JPOOL_USHORT2, JPOOL_USHORT1
514 results to long to match formats.
515
516 2012-04-11 Andrew Haley <aph@redhat.com>
517
518 * jcf-reader.c (jcf_parse_bootstrap_methods): Add
519 ATTRIBUTE_UNUSED.
520
521 2012-04-11 Andrew Haley <aph@redhat.com>
522
523 * jcf.h (bootstrap_method): New.
524 (BootstrapMethods): New.
525 (JCF): Add BootstrapMethods.
526 (enum cpool_tag): Add MethodHandle, MethodType, and InvokeDynamic.
527 * jcf-reader.c (jcf_parse_bootstrap_methods): New.
528 (jcf_parse_constant_pool): Handlers for MethodHandle, MethodType,
529 and InvokeDynamic.
530 (jcf_parse_bootstrap_methods): New.
531 * javaop.def (invokedynamic): New opcode.
532 * jcf-parse.c (get_constant): An unknown constant type should not
533 be an internal error, but a fatal one. Make it so.
534 * jcf-dump.c (HANDLE_BOOTSTRAP_METHODS_ATTRIBUTE): New.
535 (HANDLE_END_BOOTSTRAP_METHODS): New.
536 (print_constant): Handlers for MethodHandle, MethodType, and
537 InvokeDynamic.
538
539 2012-04-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
540
541 * class.c (emit_register_classes_in_jcr_section): Set DECL_USER_ALIGN.
542 Clear TREE_READONLY.
543
544 2012-03-29 Steven Bosscher <steven@gcc.gnu.org>
545
546 PR java/52730
547 * class.c (emit_register_classes_in_jcr_section): New function.
548 (emit_Jv_RegisterClass_calls): New function, split out from ...
549 (emit_register_classes): ... here. Reorganize. Do not call
550 output_constant.
551
552 2012-01-23 Andreas Schwab <schwab@linux-m68k.org>
553
554 * lang.c (java_init_options_struct): Set
555 frontend_set_flag_trapping_math.
556
557 2012-01-01 Jakub Jelinek <jakub@redhat.com>
558
559 * jcf-dump.c (version): Update copyright notice dates.
560
561 2011-12-03 Matthias Klose <doko@ubuntu.com>
562
563 * expr.c (SPECIAL_WIDE): Fix typo in message.
564
565 2011-11-23 Jeffrey A Law (law@cygnus.com)
566
567 * lang.c (java_init_options_struct): Disable optimizations
568 which assume a NULL pointer dereference will cause a fault.
569
570 2011-11-07 Richard Henderson <rth@redhat.com>
571
572 * builtins.c (compareAndSwapInt_builtin): Use can_compare_and_swap_p.
573 (compareAndSwapLong_builtin): Likewise.
574 (compareAndSwapObject_builtin): Likewise.
575 (VMSupportsCS8_builtin): Likewise.
576
577 2011-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
578
579 * Make-lang.in (jvspec.o): Pass SHLIB instead of SHLIB_LINK.
580
581 2011-10-15 Tom Tromey <tromey@redhat.com>
582 Dodji Seketeli <dodji@redhat.com>
583
584 * jcf-parse.c (set_source_filename): Adjust to the new map API.
585
586 2011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
587
588 * class.c (build_static_field_ref): Delete old interface with two
589 parallel arrays to hold standard builtin declarations, and replace
590 it with a function based interface that can support creating
591 builtins on the fly in the future. Change all uses, and poison
592 the old names. Make sure 0 is not a legitimate builtin index.
593 * decl.c (java_init_decl_processing): Ditto.
594 * except.c (compareAndSwapLong_builtin): Ditto.
595 (compareAndSwapObject_builtin): Ditto.
596 (putVolatile_builtin): Ditto.
597 (define_builtin): Ditto.
598 (check_for_builtin): Ditto.
599 * expr.c (rewrite_arglist_getcaller): Ditto.
600 (expand_java_field_op): Ditto.
601
602 2011-08-24 Joseph Myers <joseph@codesourcery.com>
603
604 * Make-lang.in (CFLAGS-java/jcf-io.o, CFLAGS-java/jcf-path.o):
605 New.
606 (java/jcf-io.o, java/jcf-path.o): Remove explicit compilation
607 rules.
608
609 2011-08-18 Peter Collingbourne <peter@pcc.me.uk>
610
611 * expr.c (expand_invoke) Use the type of the method rewrite
612 target.
613
614 2011-08-10 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
615
616 * jcf-dump.c (print_constant): Cast first frexp arg.
617
618 2011-08-08 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
619
620 * Make-lang.in ($(XGCJ)$(exeext)): Add $(EXTRA_GCC_LIBS).
621
622 2011-07-19 Richard Guenther <rguenther@suse.de>
623
624 * builtins.c (static): Use fold_build_pointer_plus.
625 * class.c (make_class_data): Likewise.
626 (build_symbol_entry): Likewise.
627 * except.c (build_exception_object_ref): Likewise.
628 * expr.c (build_java_arrayaccess): Likewise.
629 (build_field_ref): Likewise.
630 (build_known_method_ref): Likewise.
631 (build_invokevirtual): Likewise.
632
633 2011-07-06 Richard Guenther <rguenther@suse.de>
634
635 * decl.c (java_init_decl_processing):
636 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
637
638 2011-06-21 Andrew MacLeod <amacleod@redhat.com>
639
640 * builtins.c: Add sync_ or SYNC__ to builtin names.
641 * expr.c: Add sync_ or SYNC__ to builtin names.
642
643 2011-06-07 Richard Guenther <rguenther@suse.de>
644
645 * decl.c (java_init_decl_processing): Call build_common_nodes,
646 build_common_nodes_2 at the beginning. Remove then duplicate
647 initializations.
648
649 2011-06-07 Richard Guenther <rguenther@suse.de>
650
651 * decl.c (java_init_decl_processing): Properly initialize
652 size_type_node.
653
654 2011-05-30 Joern Rennecke <joern.rennecke@embecosm.com>
655
656 PR middle-end/46500
657 * expr.c: Include "tm.h" .
658
659 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
660
661 * decl.c (poplevel): Don't access TREE_TYPE of BLOCKs.
662 * expr.c (build_jni_stub): Likewise.
663
664 2011-05-24 Joseph Myers <joseph@codesourcery.com>
665
666 * Make-lang.in ($(XGCJ)$(exeext)): Use libcommon-target.a instead
667 of prefix.o.
668
669 2011-05-20 Joseph Myers <joseph@codesourcery.com>
670
671 * Make-lang.in ($(XGCJ)$(exeext)): Don't explicitly use intl.o and
672 version.o.
673 (JCFDUMP_OBJS): Remove errors.o, version.o and intl.o.
674 (JVGENMAIN_OBJS): Remove errors.o and intl.o.
675 (java/jcf-dump.o, java/jvgenmain.o): Depend in $(DIAGNOSTIC_H).
676 * jcf-dump.c: Include diagnostic.h.
677 (main): Initialize diagnostics.
678 * jvgenmain.c: Include diagnostic.h.
679 (main): Initialize diagnostics.
680
681 2011-05-11 Nathan Froyd <froydnj@codesourcery.com>
682
683 * java-tree.h (TYPE_ARGUMENT_SIGNATURE): Use TYPE_MINVAL.
684
685 2011-05-07 Eric Botcazou <ebotcazou@adacore.com>
686
687 * java-tree.h (global_bindings_p): Adjust prototype.
688 * decl.c (global_bindings_p): Return bool.
689
690 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
691
692 * expr.c (expand_java_switch): Call build_case_label.
693 (expand_java_add_case): Likewise.
694
695 2011-04-29 Richard Guenther <rguenther@suse.de>
696
697 PR middle-end/48819
698 * constants.c (build_constants_constructor): Use ptr_type_node for
699 temp.
700
701 2011-04-20 Jim Meyering <meyering@redhat.com>
702
703 * jcf-parse.c (java_parse_file): Remove useless if-before-free.
704
705 2011-04-18 Jim Meyering <meyering@redhat.com>
706
707 * jcf-parse.c: Fix typo in comment.
708
709 2011-04-14 Nathan Froyd <froydnj@codesourcery.com>
710
711 * decl.c (poplevel): Use BLOCK_CHAIN and block_chainon.
712
713 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
714
715 * java-tree.h (union lang_tree_node): Check for TS_COMMON before
716 calling TREE_CHAIN.
717
718 2011-04-11 Martin Jambor <mjambor@suse.cz>
719
720 * decl.c (java_mark_decl_local): Call cgraph_get_node instead of
721 cgraph_node and handle returned NULL.
722
723 2011-03-25 Kai Tietz <ktietz@redhat.com>
724
725 * jcf-parse.c (java_read_sourcefilenames): Use filename_cmp
726 instead of strcmp.
727 (set_source_filename): Likewise.
728 * win32-host.c (jcf_open_exact_case): Likewise.
729
730 2011-03-21 Kai Tietz <ktietz@redhat.com>
731
732 PR target/12171
733 * lang.c (java_attribute_table): Adjust table.
734
735 2011-02-13 Joseph Myers <joseph@codesourcery.com>
736
737 * jvspec.c (jvgenmain_spec): Remove %{a*}.
738
739 2011-01-21 Kai Tietz <kai.tietz@onevision.com>
740
741 PR bootstrap/47215
742 * decl.c (java_init_decl_processing): Remove
743 va_list_type_node related type initializations.
744
745 2011-01-11 Kai Tietz <kai.tietz@onevision.com>
746
747 PR bootstrap/47215
748 * decl.c (java_init_decl_processing): Initialize
749 long_integer_type_node.
750
751 2011-01-07 Kai Tietz <kai.tietz@onevision.com>
752
753 PR bootstrap/47215
754 * decl.c (java_init_decl_processing): Initialize unsigned_type_node.
755
756 2011-01-07 Kai Tietz <kai.tietz@onevision.com>
757
758 * decl.c (java_init_decl_processing): Setup va_list_type_node.
759
760 2011-01-03 Jakub Jelinek <jakub@redhat.com>
761
762 * jcf-dump.c (version): Update copyright notice dates.
763
764 2010-12-15 Dave Korn <dave.korn.cygwin@gmail.com>
765
766 * decl.c (java_init_decl_processing): Initialise integer_three_node.
767 * lang.c (put_decl_node): Handle nested function decls.
768
769 2010-12-07 Joseph Myers <joseph@codesourcery.com>
770
771 * jcf-parse.c: Don't include assert.h.
772 (java_parse_file): Use gcc_assert.
773
774 2010-12-03 Joseph Myers <joseph@codesourcery.com>
775
776 * lang.opt (static-libgcj): New option.
777
778 2010-12-01 Joseph Myers <joseph@codesourcery.com>
779
780 * jcf-parse.c: Don't include toplev.h.
781 * Make-lang.in (java/jcf-parse.o): Don't depend on toplev.h.
782
783 2010-11-30 Joseph Myers <joseph@codesourcery.com>
784
785 * boehm.c: Don't include toplev.h.
786 * Make-lang.in (java/boehm.o): Don't depend on toplev.h.
787
788 2010-11-30 Joseph Myers <joseph@codesourcery.com>
789
790 * expr.c, lang.c, mangle.c, mangle_name.c, typeck.c,
791 verify-glue.c: Don't include toplev.h.
792 * Make-lang.in: Dependencies for above files changed to remove
793 toplev.h.
794
795 2010-11-29 Joseph Myers <joseph@codesourcery.com>
796
797 * boehm.c: Include "config.h" instead of <config.h>.
798 * builtins.c: Don't include <stdarg.h>.
799 * class.c: Don't include "stdio.h".
800 (O_BINARY): Don't define here.
801 * jcf-depend.c: Don't include <assert.h>.
802 (jcf_dependency_set_dep_file, jcf_dependency_init,
803 jcf_dependency_write): Use gcc_assert.
804 * jcf-io.c (O_BINARY): Don't define here.
805 * jcf-path.c: Don't include "tm.h".
806 (jcf_path_init): Use getenv instead of GET_ENVIRONMENT.
807 * resource.c: Don't include "stdio.h".
808 (O_BINARY): Don't define here.
809 * verify-impl.c: Don't include <stdio.h>.
810
811 2010-11-17 Joseph Myers <joseph@codesourcery.com>
812
813 * jcf-parse.c (java_parse_file): Take no arguments.
814 * java-tree.h (java_parse_file): Update prototype.
815
816 2010-11-09 Joern Rennecke <amylaar@spamcop.net>
817 Andrew Haley <aph@redhat.com>
818
819 PR java/46386
820 * config/pdp11/t-pdp11 (java/constants.o-warn): Remove.
821
822 2010-11-12 Joseph Myers <joseph@codesourcery.com>
823
824 * Make-lang.in (jvspec.o, java/lang.o): Use $(OPTS_H).
825 * lang.c (java_handle_option): Take location_t parameter.
826
827 2010-11-10 Joseph Myers <joseph@codesourcery.com>
828
829 * expr.c (expand_java_field_op): Use %' in diagnostic.
830 * jcf-parse.c (java_parse_file): Use %' in diagnostics.
831 * jvspec.c (lang_specific_driver): Use %' in diagnostic.
832 * lang.c (java_post_options): Use %' in diagnostics.
833
834 2010-11-06 Joern Rennecke <amylaar@spamcop.net>
835
836 PR middle-end/46314
837 * class.c: Include target.h.
838 (make_local_function_alias):
839 Use targetm.asm_out.generate_internal_label.
840 * expr.c (lookup_label, generate_name): Likewise.
841
842 2010-11-03 Joern Rennecke <joern.rennecke@embecosm.com>
843
844 PR bootstrap/44335
845 * jfc-parse.c (target.h): Include.
846 (handle_constant): Use targetm.words_big_endian and
847 targetm.float_words_big_endian.
848 (get_constant): Use targetm.float_words_big_endian.
849
850 2010-10-13 Richard Henderson <rth@redhat.com>
851
852 * lang.c (java_eh_personality): Update call to
853 build_personality_function.
854
855 2010-10-12 Joseph Myers <joseph@codesourcery.com>
856
857 * Make-lang.in (java/lang.o): Use $(OPTIONS_H) instead of
858 options.h.
859
860 2010-10-11 Nathan Froyd <froydnj@codesourcery.com>
861
862 * decl.c (java_init_decl_processing): Use build_function_type_list
863 instead of build_function_type.
864 * jcf-parse.c (java_emit_static_constructor): Likewise.
865 * builtins.c (initialize_builtins): Likewise.
866
867 2010-10-08 Joseph Myers <joseph@codesourcery.com>
868
869 * lang.c (java_init_options_struct): New. Split out from
870 java_init_options.
871 (LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
872
873 2010-10-04 Andi Kleen <ak@linux.intel.com>
874
875 * Make-lang.in (xgcj, jc1, jcf-dump, jvgenmain):
876 Add + to build rule.
877
878 2010-09-29 Joseph Myers <joseph@codesourcery.com>
879
880 * lang.opt: Don't use VarExists.
881
882 2010-09-29 Joseph Myers <joseph@codesourcery.com>
883
884 * java-tree.h (flag_filelist_file, flag_assert, flag_jni,
885 flag_force_classes_archive_check, flag_redundant, flag_newer,
886 flag_use_divide_subroutine, flag_use_atomic_builtins,
887 flag_use_boehm_gc, flag_hash_synchronization,
888 flag_check_references, flag_optimize_sci, flag_indirect_classes,
889 flag_indirect_dispatch, flag_store_check,
890 flag_reduced_reflection): Remove.
891 * jcf-dump.c (flag_newer): Remove.
892 * jcf.h (quiet_flag): Remove.
893 * parse.h (quiet_flag): Remove.
894
895 2010-09-28 Richard Henderson <rth@redhat.com>
896
897 * lang.c: Include "target.h".
898 (java_eh_personality): Use targetm.except_unwind_info.
899 * Make-lang.in (lang.o): Update deps.
900
901 2010-09-27 Andrew Haley <aph@redhat.com>
902
903 PR java/45773
904 * jvgenmain.c (main): Fix arg processing.
905
906 2010-09-22 Joseph Myers <joseph@codesourcery.com>
907
908 * jvspec.c (lang_specific_driver): Handle OPT__help instead of
909 OPT_fhelp.
910 * lang.opt (-CLASSPATH, -all-warnings, -bootclasspath, -classpath,
911 -dependencies, -encoding, -extdirs, -include-directory,
912 -include-directory=, -output-class-directory,
913 -output-class-directory=, -resource, -resource=,
914 -user-dependencies): New.
915
916 2010-09-16 Richard Guenther <rguenther@suse.de>
917
918 * jcf-parse.c (current_file_list): Remove.
919 (java_parse_file): Use build_translation_unit_decl. Adjust.
920
921 2010-09-03 Joseph Myers <joseph@codesourcery.com>
922
923 * lang.opt (d): New.
924
925 2010-09-03 H.J. Lu <hongjiu.lu@intel.com>
926
927 PR java/45504
928 * jvgenmain.c (main): Check "-D XXX=YYY".
929
930 2010-09-02 Joseph Myers <joseph@codesourcery.com>
931
932 * jvspec.c (jvgenmain_spec): Don't handle -fnew-verifier.
933
934 2010-09-02 Joseph Myers <joseph@codesourcery.com>
935
936 * lang.opt (CLASSPATH, bootclasspath, classpath, encoding,
937 fCLASSPATH=): Mark as Java options and as aliases.
938 * jvspec.c (jvgenmain_spec): Don't handle -fCLASSPATH*.
939 (lang_specific_driver): Don't handle options marked as aliases.
940 * lang.c (java_handle_option): Don't handle OPT_fCLASSPATH_.
941
942 2010-08-22 Joseph Myers <joseph@codesourcery.com>
943
944 * Make-lang.in (jvspec.o): Update dependencies.
945 * jvspec.c: Include opts.h.
946 (PARAM_ARG): Remove.
947 (find_spec_file): Do not add leading -specs=.
948 (lang_specific_driver): Use cl_decoded_option structures.
949 * lang.opt (C, CLASSPATH, D, bootclasspath, classpath, encoding,
950 extdirs, fmain=, s-bc-abi): New options.
951
952 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
953
954 * class.c: Use FOR_EACH_VEC_ELT.
955 * expr.c: Likewise.
956 * jcf-parse.c: Likewise.
957 * resource.c: Likewise.
958
959 2010-08-16 Joseph Myers <joseph@codesourcery.com>
960
961 * lang.opt (MD_, MMD_, version): Mark RejectDriver.
962
963 2010-08-05 David Daney <ddaney@caviumnetworks.com>
964
965 * class.c (build_utf8_ref): Fix code formatting from previous commit.
966
967 2010-08-05 David Daney <ddaney@caviumnetworks.com>
968
969 * class.c (build_utf8_ref): Make decl DECL_USER_ALIGN.
970
971 2010-07-27 Joseph Myers <joseph@codesourcery.com>
972
973 * lang.c (java_handle_option): Update prototype and return value
974 type.
975
976 2010-07-27 Joseph Myers <joseph@codesourcery.com>
977
978 * lang.c (java_option_lang_mask): New.
979 (java_init_options): Update prototype.
980 (LANG_HOOKS_OPTION_LANG_MASK): Define.
981
982 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
983
984 * java-tree.h: Carefully replace TREE_CHAIN with DECL_CHAIN.
985 * boehm.c: Likewise.
986 * class.c: Likewise.
987 * decl.c: Likewise.
988 * expr.c: Likewise.
989 * jcf-parse.c: Likewise.
990 * typeck.c: Likewise.
991 * verify-glue.c: Likewise.
992
993 2010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
994
995 * boehm.c: Include diagnostic-core.h in every file that includes
996 toplev.h.
997 * class.c: Likewise.
998 * constants.c: Likewise.
999 * decl.c: Likewise.
1000 * except.c: Likewise.
1001 * expr.c: Likewise.
1002 * jcf-parse.c: Likewise.
1003 * mangle.c: Likewise.
1004 * mangle_name.c: Likewise.
1005 * resource.c: Likewise.
1006 * typeck.c: Likewise.
1007 * verify-glue.c: Likewise.
1008
1009 2010-07-05 Nathan Froyd <froydnj@codesourcery.com>
1010
1011 PR bootstrap/44825
1012 * class.c (make_class_data): Cast result of VEC_length calls to int.
1013
1014 2010-07-05 Nathan Froyd <froydnj@codesourcery.com>
1015
1016 * constants.c (build_constants_constructor): Use build_constructor
1017 instead of build_constructor_from_list.
1018 * class.c (make_method_value): Likewise.
1019 (get_dispatch_table): Likewise.
1020 (make_class_data): Likewise.
1021 (emit_indirect_register_classes): Likewise.
1022 (emit_symbol_table): Likewise.
1023 (add_assertion_table_entry): Likewise.
1024 (emit_assertion_table): Likewise.
1025 (make_field_value): Use build_constructor_single instead of
1026 build_constructor_from_list.
1027
1028 2010-06-28 Nathan Froyd <froydnj@codesourcery.com>
1029
1030 * java-tree.h (struct lang_type) [catch_classes]: Change type to a
1031 VEC.
1032 * except.c (prepare_eh_table_type): Call CONSTRUCTOR_APPEND_ELT
1033 instead of tree_cons.
1034 * class.c (make_class): Add dummy entry to TYPE_CATCH_CLASSES.
1035 (emit_catch_table): Adjust for new type of TYPE_CATCH_CLASSES.
1036
1037 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
1038
1039 * lang.c: Do not include except.h
1040 * except.c: Likewise.
1041 (doing_eh): New, moved from except.c (in gcc/) but removed the
1042 do_warning flag.
1043 (maybe_start_try): Update doing_eh call.
1044 * Make-lang.in: Update dependencies.
1045
1046 2010-06-23 Anatoly Sokolov <aesok@post.ru>
1047
1048 * decl.c (java_init_decl_processing): Use double_int_to_tree instead
1049 of build_int_cst_wide.
1050 * boehm.c (set_bit): Remove.
1051 (mark_reference_fields): Use double_int type for 'mask' argument.
1052 Use double_int_setbit instead of set_bit.
1053 (get_boehm_type_descriptor): Use double_int_setbit instead of
1054 set_bit. Use double_int_to_tree instead of build_int_cst_wide.
1055
1056 2010-06-10 Gerald Pfeifer <gerald@pfeifer.com>
1057
1058 * gcj.texi: Move to GFDL version 1.3. Fix copyright years.
1059
1060 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
1061
1062 * jcf-reader.c (jcf_parse_constant_pool): Use typed GC allocation.
1063
1064 * jcf-parse.c (java_parse_file): Likewise.
1065 (process_zip_dir): Likewise.
1066
1067 * java-tree.h (MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC): Likewise.
1068 (MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC): Likewise.
1069
1070 * expr.c (add_type_assertion): Likewise.
1071
1072 * decl.c (make_binding_level): Likewise.
1073 (java_dup_lang_specific_decl): Likewise.
1074
1075 * constants.c (set_constant_entry): Likewise.
1076 (cpool_for_class): Likewise.
1077
1078 * class.c (add_method_1): Likewise.
1079 (java_treetreehash_new): Likewise.
1080
1081 * java-tree.h (struct lang_type): Add variable_size GTY option.
1082 (struct lang_decl): Likewise.
1083
1084 * jch.h (struct cpool_entry): Likewise.
1085
1086 * java-tree.h (java_treetreehash_create): Remove parameter ggc.
1087
1088 * except.c (prepare_eh_table_type): Update
1089 java_treetreehash_create call.
1090
1091 * class.c (add_method_1): Update java_treetreehash_create call.
1092 (java_treetreehash_create): Remove parameter gc. Use
1093 htab_create_ggc.
1094
1095 2010-06-04 Joseph Myers <joseph@codesourcery.com>
1096
1097 * jvspec.c (lang_specific_driver): Use GCC-specific formats in
1098 diagnostics.
1099
1100 2010-05-30 Steven Bosscher <steven@gcc.gnu.org>
1101
1102 * except.c: Include tm.h.
1103
1104 2010-05-28 Joseph Myers <joseph@codesourcery.com>
1105
1106 * jvspec.c (lang_specific_driver): Use fatal_error instead of
1107 fatal. Use warning instead of error for warnings.
1108
1109 2010-05-28 Nathan Froyd <froydnj@codesourcery.com>
1110
1111 * expr.c (get_symbol_table_index): Add spaces in expression.
1112
1113 2010-05-28 Nathan Froyd <froydnj@codesourcery.com>
1114
1115 * java-tree.h (method_entry): Declare. Declare VECs containing it.
1116 (struct lang_type): Change type of otable_methods, atable_methods, and
1117 itable_methods to VECs. Fix comment for atable_methods.
1118 (emit_symbol_table): Take a VEC instead of a tree.
1119 (get_symbol_table_index): Take a VEC * instead of a tree *.
1120 * class.c (add_table_and_syms): Take a VEC instead of a tree.
1121 (emit_symbol_table): Update for changed parameter type.
1122 * expr.c (get_symbol_table_index): Likewise.
1123
1124 2010-05-27 Steven Bosscher <steven@gcc.gnu.org>
1125
1126 * buildings.c: Pretend to be a backend file by undefining
1127 IN_GCC_FRONTEND (still need rtl.h here).
1128
1129 2010-05-26 Nathan Froyd <froydnj@codesourcery.com>
1130
1131 * java-tree.h (struct lang_decl_func): Change type of throws_list
1132 field to a VEC.
1133 * jcf-parse.c (HANDLE_EXCEPTIONS_ATTRIBUTE): Adjust for changed type
1134 of DECL_FUNCTION_THROWS.
1135 * class.c (make_method_value): Likewise.
1136
1137 2010-05-26 Nathan Froyd <froydnj@codesourcery.com>
1138
1139 * class.c (utf8_decl_list): Delete.
1140 (build_utf8_ref): Remove references to it.
1141 * java-tree.h (all_class_list): Delete.
1142 (predef_filenames): Delete.
1143 (enum java_tree_index) [JTI ALL_CLASS_LIST,JTI_PREDEF_FILENAMES]:
1144 Delete.
1145 * jcf-parse.c (parse_roots): Decrease size to 2.
1146 (current_file_list): Convert to a VEC.
1147 (all_class_list): Declare.
1148 (jcf_parse): Adjust for new type of all_class_list.
1149 (java_layout_seen_class_methods): Likewise.
1150 (predefined_filenames): Declare.
1151 (add_predefined_file): Use it.
1152 (predefined_filename_p): Likewise.
1153 (java_parse_file): Adjust for new type of current_file_list.
1154
1155 2010-05-25 Jakub Jelinek <jakub@redhat.com>
1156
1157 * lang.c (java_classify_record): Return RECORD_IS_INTERFACE
1158 for interfaces.
1159
1160 PR debug/43260
1161 * java-tree.h (pending_static_fields): New extern declaration.
1162 (java_write_globals): New prototype.
1163 * lang.c (LANG_HOOKS_WRITE_GLOBALS): Define.
1164 * decl.c (java_mark_class_local): When clearing DECL_EXTERNAL
1165 of a static field push it into pending_static_fields vector.
1166 * class.c (pending_static_fields): New variable.
1167 (add_field): If static field is not DECL_EXTERNAL, push it into
1168 pending_static_fields vector.
1169 (java_write_globals): New function.
1170
1171 2010-05-24 Nathan Froyd <froydnj@codesourcery.com>
1172
1173 * expr.c (quick_stack): Change type to a VEC. Update comment.
1174 (tree_list_free_list): Delete.
1175 (flush_quick_stack): Update for quick_stack type change.
1176 (push_value): Likewise.
1177 (pop_value): Likewise.
1178
1179 2010-05-23 Steven Bosscher <steven@gcc.gnu.org>
1180
1181 * java-gimplify.c: Do not include tm.h, toplev.h.
1182 * typeck.c: Do not include tm.h.
1183 * mangle_name.c: Do not include tm.h.
1184 * jcf-dump.c: Do not include tm.h, ggc.h.
1185 * class.c: Do not include rtl.h, tm_p.h, target.h, except.h, cgraph.h.
1186 * decl.c: Do not include tm.h, rtl.h, function.h, expr.h, except.h,
1187 and timevar.h.
1188 * jcf-parse.c: Do not include tm.h and tm_p.h.
1189 * resource.c: Do not include tm.h, rtl.h, flags.h, obstack.h,
1190 target.h, and expr.h.
1191 * except.c: Do not include tm.h, rtl.h, function.h.
1192 * builtins.c: Do not include convert.h. Explain why RTL headers
1193 have to be included here.
1194 * verify-glue.c: Do not include tm.h.
1195 * jcf-depend.c: Do not include tm.h.
1196 * jcf-reader.c: Include ggc.h.
1197 * jcf-io.c: Do not include tm.h, toplev.h.
1198 * expr.c: Do not include tm.h, rtl.h, expr.h, except.h, tm_p.h,
1199 gimple.h.
1200 * lang.c: Do not include rtl.h, expr.h.
1201 * Make-lang.in: Update dependencies.
1202
1203 2010-05-23 Steven Bosscher <steven@gcc.gnu.org>
1204
1205 * jcf-parse.c: Include bitmap.h.
1206 * Make-lang.in: Update dependencies.
1207
1208 2010-05-20 Jakub Jelinek <jakub@redhat.com>
1209
1210 PR debug/43521
1211 * decl.c (start_java_method): Set DECL_ARTIFICIAL on the 'this'
1212 PARM_DECL.
1213
1214 2010-05-19 Anatoly Sokolov <aesok@post.ru>
1215
1216 * jcf-parse.c (get_constant): Use double_int_to_tree instead of
1217 build_int_cst_wide_type.
1218
1219 2010-05-18 Nathan Froyd <froydnj@codesourcery.com>
1220
1221 * expr.c (pop_arguments): Fix use of undeclared variable.
1222
1223 2010-05-18 Nathan Froyd <froydnj@codesourcery.com>
1224
1225 * expr.c (expand_java_multianewarray): Use build_call_vec instead of
1226 build_call_list.
1227 (pop_arguments): Return a VEC instead of a tree. Take a method type
1228 rather than a list of argument types.
1229 (rewrite_rule): Change signature. of rewrite_arglist member.
1230 (rewrite_arglist_getcaller): Update signature.
1231 (rewrite_arglist_getclass): Likewise.
1232 (maybe_rewrite_invocation): Update for rewrite_arglist change.
1233 (build_known_method_ref): Take a VEC instead of a tree.
1234 (invoke_build_dtable): Likewise.
1235 (expand_invoke): Update calls to pop_arguments. Use build_call_vec
1236 instead of build_call_list.
1237 (build_jni_stub): Use build_call_vec instead of build_call_list.
1238 * java-tree.h (maybe_rewrite_invocation): Update declaration.
1239 (build_known_method_ref): Likewise.
1240 (invoke_build_dtable): Likewise.
1241
1242 2010-05-14 Nathan Froyd <froydnj@codesourcery.com>
1243
1244 PR 44103
1245 * java-tree.h (START_RECORD_CONSTRUCTOR): Change first argument to a
1246 vector. Move call to build_constructor...
1247 (FINISH_RECORD_CONSTRUCTOR): ...here. Add necessary arguments. Clear
1248 TREE_CONSTANT on the constructor.
1249 (PUSH_SUPER_VALUE): Change first argument to a vector.
1250 (PUSH_FIELD_VALUE): Likewise.
1251 * resource.c (compile_resource_data): Update calls to above macros.
1252 * constants.c (build_constants_constructor): Likewise.
1253 * class.c (build_utf8_ref): Likewise.
1254 (make_field_value): Likewise.
1255 (make_method_value): Likewise.
1256 (add_table_and_syms): New function.
1257 (make_class_data): Call it. Update calls to above macros.
1258 (build_symbol_table_entry): New function.
1259 (build_symbol_entry): Call it. Update calls to above macros.
1260 (emit_symbol_table): Likewise.
1261 (make_catch_class_record): Update calls to above macros.
1262 (build_assertion_table_entry): New function.
1263 (add_assertion_table_entry): Call it.
1264 (emit_assertion_table): Likewise.
1265
1266 2010-05-06 Manuel López-Ibáñez <manu@gcc.gnu.org>
1267
1268 PR 40989
1269 * lang.c (java_handle_option): Add argument kind.
1270
1271 2010-04-18 Eric Botcazou <ebotcazou@adacore.com>
1272
1273 * decl.c (java_init_decl_processing): Remove argument in call to
1274 initialize_sizetypes
1275
1276 2010-04-07 Jakub Jelinek <jakub@redhat.com>
1277
1278 * exception.cc (_Jv_Throw): Avoid set but not used warning.
1279 * include/java-assert.h (JvAssertMessage, JvAssert): Use argument in
1280 sizeof to avoid set but not used warnings.
1281
1282 2010-01-20 Joern Rennecke <amylaar@spamcop.net>
1283
1284 * lang.c (java_post_options): Constify variable "dot".
1285
1286 * jcf-parse.c (set_source_filename): Constify variable "dot".
1287 (load_class): Constify variable "separator".
1288 Use get_identifier_with_length.
1289
1290 * jvspec.c (lang_specific_driver): Constify two variables named "p".
1291
1292 2010-01-09 Jakub Jelinek <jakub@redhat.com>
1293
1294 * jcf-dump.c (version): Update copyright notice dates.
1295
1296 2009-11-28 Jakub Jelinek <jakub@redhat.com>
1297
1298 * jvspec.c (lang_specific_driver): Remove unused
1299 saw_verbose_flag variable.
1300 * jcf-dump.c (main): Remove unused general_purpose_bits
1301 variable.
1302 * builtins.c (initialize_builtins): Remove unused float_ftype_float
1303 variable.
1304 * expr.c (java_stack_pop): Remove unused val variable.
1305 (build_jni_stub): Remove unused res_type variable.
1306 * verify-impl.c (check_field_constant): Remove unused len variable.
1307
1308 2009-10-20 Joel Dice <dicej@mailsnare.net>
1309
1310 PR java/28474
1311 * mangle_name.c (append_unicode_mangled_name): Fix mangling
1312 of names with multiple underscores and "U".
1313 (unicode_mangling_length): Likewise.
1314
1315 2009-10-03 Simon Baldwin <simonb@google.com>
1316
1317 * config-lang.in (lang_dirs): Remove zlib.
1318
1319 2009-09-28 Richard Henderson <rth@redhat.com>
1320
1321 * builtins.c (initialize_builtins): Update call to
1322 build_common_builtin_nodes.
1323 * lang.c (LANG_HOOKS_EH_USE_CXA_END_CLEANUP): New.
1324
1325 2009-09-14 Richard Henderson <rth@redhat.com>
1326
1327 * builtins.c (initialize_builtins): Update call to
1328 build_common_builtin_nodes.
1329 * decl.c (java_init_decl_processing): Don't call
1330 default_init_unwind_resume_libfunc.
1331 * except.c: Include tree-iterator.h.
1332 (build_exception_object_var): New.
1333 (build_exception_object_ref): Use it.
1334 (expand_end_java_handler): Initialize it from __builtin_eh_pointer.
1335 Attach all CATCH_EXPRs to a single TRY_CATCH_EXPR.
1336 * java-tree.h (DECL_FUNCTION_EXC_OBJ): New.
1337
1338 2009-09-13 Richard Guenther <rguenther@suse.de>
1339 Rafael Avila de Espindola <espindola@google.com>
1340
1341 * decl.c (do_nothing): Remove.
1342 (java_init_decl_processing): Do not set lang_eh_runtime_type.
1343 * Make-lang.in (lang.o): Add $(EXCEPT_H) dependency.
1344 * lang.c (java_eh_personality): New.
1345 (java_eh_personality_decl): Likewise.
1346 (LANG_HOOKS_EH_PERSONALITY): Define.
1347
1348 2009-09-03 Diego Novillo <dnovillo@google.com>
1349
1350 * lang.c (lang_hooks): Remove const qualifier.
1351
1352 2009-09-01 Jakub Jelinek <jakub@redhat.com>
1353
1354 * boehm.c (mark_reference_fields): Compute % in HOST_WIDE_INT
1355 type.
1356
1357 2009-09-01 Richard Guenther <rguenther@suse.de>
1358
1359 * lang.c (LANG_HOOKS_MARK_ADDRESSABLE): Remove.
1360 * java-tree.h (java_mark_addressable): Likewise.
1361 * typeck.c (java_mark_addressable): Likewise.
1362
1363 2009-08-17 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1364
1365 * Make-lang.in (java.install-pdf): Install gcj.pdf in
1366 $(pdfdir)/gcc, alongside the other manuals.
1367
1368 2009-08-12 Andrew Haley <aph@redhat.com>
1369
1370 * builtins.c (compareAndSwapInt_builtin): Use
1371 flag_use_atomic_builtins.
1372 (compareAndSwapLong_builtin): Likewise.
1373 (compareAndSwapObject_builtin): Likewise.
1374 * jvspec.c: Add flag_use_atomic_builtins.
1375 * gcj.texi: Likewise.
1376 * java-tree.h: Likewise.
1377 * lang.opt: Likewise.
1378
1379 2009-08-11 Dodji Seketeli <dodji@redhat.com>
1380
1381 PR debug/40990
1382 * lang.c (put_decl_node): Outputs different level of information
1383 depending on the verbosity level.
1384
1385 2009-07-31 Andrew Haley <aph@redhat.com>
1386
1387 PR java/40867
1388 * decl.c (java_replace_references): Set EXPR_LOCATION on all
1389 generated expressions.
1390 (binding_level.loc): new field.
1391 (clear_binding_level): Initialize loc.
1392 (set_input_location): New function.
1393 (pushlevel): Set new binding_level.loc.
1394 (poplevel): Set EXPR_LOCATION on the new BIND_EXPR_BODY.
1395 (start_java_method): Set DECL_SOURCE_LOCATION of this new method.
1396 (java_add_stmt): Set the EXPR_LOCATION on all subtrees of new_stmt.
1397
1398 2009-07-17 Richard Guenther <rguenther@suse.de>
1399
1400 PR c/40401
1401 * java-gimplify.c (java_genericize): Do not gimplify here.
1402 But replace all local references.
1403 (java_gimplify_expr): Do not replace local references here.
1404 (java_gimplify_modify_expr): Likewise.
1405 * jcf-parse.c (java_parse_file): Do not finalize the CU or
1406 optimize the cgraph here.
1407 * decl.c (java_replace_reference): Make static.
1408 (java_replace_references): New function.
1409 (end_java_method): Clear base_decl_map.
1410 * java-tree.h (java_replace_references): Declare.
1411 (java_replace_reference): Remove.
1412
1413 2009-07-14 Taras Glek <tglek@mozilla.com>
1414 Rafael Espindola <espindola@google.com>
1415
1416 * Make-lang.in (java.install-plugin): New target for
1417 installing plugin headers.
1418
1419 2009-07-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
1420
1421 * class.c: Replace %J by an explicit location. Update all calls.
1422
1423 2009-07-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
1424
1425 * jcf-parse.c: Replace %H by an explicit location. Update all calls.
1426
1427 2009-06-29 Andrew Haley <aph@redhat.com>
1428
1429 PR java/40590
1430 * java-tree.h (cxx_keyword_p): New declaration.
1431 * mangle_name.c (utf8_cmp): Move here from mangle.c.
1432 (cxx_keywords): Likewise.
1433 (cxx_keyword_p): Likewise.
1434 (MANGLE_CXX_KEYWORDS): New macro.
1435 (append_gpp_mangled_name): Use MANGLE_CXX_KEYWORDS.
1436 (append_gpp_mangled_name): Likewise.
1437 * mangle.c: Move code to mangle_name.c.
1438 (mangle_member_name): Don't call cxx_keyword_p.
1439
1440 2009-06-12 Aldy Hernandez <aldyh@redhat.com>
1441
1442 * java-gimplify.c (java_gimplify_block): New argument to
1443 build_empty_stmt.
1444 * expr.c (force_evaluation_order): Same.
1445 * typeck.c: Add location to build_decl or PUSH_FIELD calls.
1446 * class.c: Same.
1447 * decl.c: Same.
1448 * jcf-parse.c: Same.
1449 * constants.c: Same.
1450 * resource.c: Same.
1451 * except.c: Same.
1452 * builtins.c: Same.
1453 * expr.c: Same.
1454 * java-tree.h (PUSH_FIELD): Add location field.
1455
1456 2009-06-09 Ian Lance Taylor <iant@google.com>
1457
1458 * verify.h: Remove extern "C".
1459
1460 2009-06-07 Ian Lance Taylor <iant@google.com>
1461
1462 * jcf-parse.c (handle_constant): Change local variable 'kind' to
1463 unsigned int.
1464
1465 2009-06-01 Ian Lance Taylor <iant@google.com>
1466
1467 * jcf-io.c (find_class): Use CONST_CAST.
1468
1469 2009-05-27 Ian Lance Taylor <iant@google.com>
1470
1471 * Make-lang.in ($(XGCJ)$(exeext)): Change $(COMPILER) to
1472 $(LINKER).
1473 (jc1$(exeext), jcf-dump$(exeext), jvgenmain$(exeext)): Likewise.
1474
1475 2009-05-26 Ian Lance Taylor <iant@google.com>
1476
1477 * Make-lang.in (jvspec.o): Use $(COMPILER).
1478 ($(XGCJ)$(exeext), jc1$(exeext), jcf-dump$(exeext)): Likewise.
1479 (jvgenmain$(exeext), java/jcf-io.o, java/jcf-path.o): Likewise.
1480
1481 2009-05-12 Alexandre Oliva <aoliva@redhat.com>
1482
1483 * Make-lang.in (GCJ): Renamed to...
1484 (XGCJ): ... this.
1485
1486 2009-04-27 Ian Lance Taylor <iant@google.com>
1487
1488 * builtins.c (java_builtins): Add casts to enum type.
1489 * verify-impl.c (check_class_constant): Add cast to enum type.
1490 (check_constant, check_wide_constant): Likewise.
1491
1492 2009-04-27 Richard Guenther <rguenther@suse.de>
1493
1494 PR java/38374
1495 * constants.c (build_constants_constructor): Retain the old
1496 pointer type as valid TYPE_POINTER_TO after patching the
1497 type of the constant pool decl.
1498
1499 2009-04-24 Ian Lance Taylor <iant@google.com>
1500
1501 * jcf-parse.c (handle_constant): Add cast to enum type.
1502
1503 2009-04-21 Taras Glek <tglek@mozilla.com>
1504
1505 * builtins.c: Update GTY annotations to new syntax
1506 * decl.c: Likewise
1507 * java-tree.h: Likewise
1508 * jcf.h: Likewise
1509 * lang.c: Likewise
1510
1511 2009-04-21 Joseph Myers <joseph@codesourcery.com>
1512
1513 * ChangeLog, ChangeLog.ptr, ChangeLog.tree-ssa: Add copyright and
1514 license notices.
1515
1516 2009-04-18 Ian Lance Taylor <iant@google.com>
1517
1518 * verify-impl.c (verify_instructions_0): Add cast to enum type.
1519
1520 2009-04-09 Paolo Bonzini <bonzini@gnu.org>
1521
1522 * builtins.c (compareAndSwapLong_builtin,
1523 compareAndSwapInt_builtin, compareAndSwapObject_builtin,
1524 VMSupportsCS8_builtin): Do not look at sync_compare_and_swap_cc.
1525
1526 2009-03-31 Richard Guenther <rguenther@suse.de>
1527
1528 * java-gimplify.c (java_gimplify_expr): Do not manually gimplify
1529 the first operand of binary and comaprison expressions.
1530
1531 2009-03-30 Joseph Myers <joseph@codesourcery.com>
1532
1533 PR rtl-optimization/323
1534 * lang.c (java_post_options): Set flag_excess_precision_cmdline.
1535 Give an error for -fexcess-precision=standard for processors where
1536 the option is significant.
1537
1538 2009-03-18 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1539
1540 * lang.opt: Unify help text for -Wdeprecated.
1541
1542 2009-02-03 Jakub Jelinek <jakub@redhat.com>
1543
1544 * jcf-dump.c (version): Update copyright notice dates.
1545
1546 2009-01-16 Richard Guenther <rguenther@suse.de>
1547
1548 PR tree-optimization/38835
1549 PR middle-end/36227
1550 * builtins.c (build_addr_sum): Use POINTER_PLUS_EXPR.
1551
1552 2008-12-05 Sebastian Pop <sebastian.pop@amd.com>
1553
1554 PR bootstrap/38262
1555 * Make-lang.in (jc1): Add BACKENDLIBS, remove GMPLIBS.
1556
1557 2008-11-04 Andrew Haley <aph@redhat.com>
1558
1559 PR java/37068
1560 * jcf-parse.c (java_emit_static_constructor): Don't call
1561 cgraph_build_static_cdtor. Rewrite.
1562
1563 2008-10-24 Jakub Jelinek <jakub@redhat.com>
1564
1565 * Make-lang.in (check-java-subtargets): New target.
1566
1567 2008-10-16 David Edelsohn <edelsohn@gnu.org>
1568
1569 PR target/35483
1570 * Make-lang.in (class.o): Depend on $(TM_P_H).
1571 (expr.o): Same.
1572 * class.c: Include tm_p.h.
1573 * expr.c: Include tm_p.h.
1574
1575 2008-10-14 Andrew Haley <aph@redhat.com>
1576
1577 * constants.c (build_constant_data_ref): Make sure we only build
1578 one copy of the decl for the constant pool.
1579
1580 2008-09-22 Andrew Haley <aph@redhat.com>
1581
1582 * expr.c (rules): Add new rule for
1583 gnu.java.lang.VMCPStringBuilder.toString.
1584 (rewrite_rule.new_classname): New field.
1585 (maybe_rewrite_invocation): Use new_classname field instead of
1586 DECL_CONTEXT (*method_p).
1587 Allow rewrite_arglist to be NULL.
1588
1589 2008-09-17 Andrew Pinski <andrew_pinski@playstation.sony.com>
1590
1591 * lang.c (LANG_HOOKS_GET_CALLEE_FNDECL): Don't define.
1592 (java_get_callee_fndecl): Kill.
1593
1594 2008-09-17 Jan Hubicka <jh@suse.cz>
1595
1596 PR c++/18071
1597 * class.c (add_method_1): Do not initialize DECL_INLINE.
1598 (make_local_function_alias): Likewise.
1599 * expr.c (rewrite_arglist_getcaller): Set DECL_UNINLINABLE.
1600 * lang.c (java_decl_ok_for_sibcall): Use DECL_UNINLINABLE.
1601
1602 2008-09-09 Richard Guenther <rguenther@suse.de>
1603
1604 * decl.c (build_result_decl): Remove no longer applicable
1605 promotion.
1606
1607 2008-09-05 David Daney <ddaney@avtrex.com>
1608
1609 * gcj.texi (-freduced-reflection): Clarify option's restrictions.
1610
1611 2008-08-21 David Daney <ddaney@avtrex.com>
1612
1613 * class.c (make_class_data): Don't add field_index when
1614 flag_reduced_reflection set.
1615
1616 2008-08-12 Ulrich Weigand <uweigand@de.ibm.com>
1617
1618 * typeck.c (convert): Do not check for TARGET_FLOAT_FORMAT.
1619
1620 2008-08-08 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
1621
1622 PR 28875
1623 * lang.c (java_handle_option): Replace set_Wunused with
1624 warn_unused.
1625
1626 2008-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1627
1628 * gcj.texi: Update copyright years. Do not list GPL as
1629 Invariant Section.
1630
1631 2008-07-29 Jakub Jelinek <jakub@redhat.com>
1632
1633 * class.c (build_utf8_ref): Set DECL_SIZE and DECL_SIZE_UNIT
1634 from ctype's sizes.
1635
1636 * class.c (build_utf8_ref): Pad initializer string to utf8const_type's
1637 alignment.
1638
1639 2008-07-29 Jan Hubicka <jh@suse.cz>
1640
1641 * lang.c (java_post_options): Remove handling of flag_no_inline.
1642
1643 2008-07-28 Richard Guenther <rguenther@suse.de>
1644
1645 Merge from gimple-tuples-branch.
1646
1647 2008-07-18 Richard Guenther <rguenther@suse.de>
1648
1649 * expr.c: Include tree-iterator.h.
1650 * Make-lang.in (expr.o): Add tree-iterator.h dependency.
1651
1652 2008-07-18 Aldy Hernandez <aldyh@redhat.com>
1653
1654 * java-gimplify.c: Include gimple.h instead of tree-gimple.h.
1655 * expr.c: Same.
1656
1657 2008-07-14 Aldy Hernandez <aldyh@redhat.com>
1658
1659 * java-gimplify.c (java_gimplify_expr): Same.
1660 (java_gimplify_modify_expr): Same.
1661 * java-tree.h: Rename GENERIC_NEXT to TREE_CHAIN.
1662
1663 2008-05-02 Diego Novillo <dnovillo@google.com>
1664
1665 * expr.c (build_java_throw_out_of_bounds_exception): Fix
1666 mixed declarations and code.
1667
1668 2008-05-02 Doug Kwan <dougkwan@google.com>
1669
1670 * expr.c (build_java_throw_out_of_bounds_exception ): Wrap call to
1671 _Jv_ThrowBadArrayIndex with a COMPOUND_EXPR to return 0.
1672
1673 2008-02-19 Diego Novillo <dnovillo@google.com>
1674
1675 http://gcc.gnu.org/ml/gcc-patches/2008-02/msg00804.html
1676
1677 * java-gimplify.c (java_gimplify_self_mod_expr): Change
1678 gimple_seq arguments to gimple_seq *. Update all users.
1679
1680 2007-11-26 Aldy Hernandez <aldyh@redhat.com>
1681
1682 * java-gimplify.c (java_gimplify_expr): Make pre_p and post_p
1683 sequences.
1684 (java_gimplify_self_mod_expr): Same.
1685 * java-tree.h (java_gimplify_expr): Make pre_p and post_p
1686 sequences.
1687
1688 2008-07-24 Jan Hubicka <jh@suse.cz>
1689
1690 * java/decl.c: Include cgraph.h
1691 (end_java_method): Remove non-unit-at-a-time code.
1692 (java_mark_decl_local): Likewise; sanity check that we don't touch
1693 finalized nodes.
1694
1695 2008-07-15 Jan Hubicka <jh@suse.cz>
1696
1697 * lang.c (java_init_options): Enable unit-at-a-time by default.
1698
1699 2008-07-14 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1700
1701 * Make-lang.in (jvspec.o): Fix dependencies.
1702
1703 2008-07-06 Tom Tromey <tromey@redhat.com>
1704
1705 * Make-lang.in (java/parse.o-warn): Remove.
1706 (java/jcf-io.o-warn): Remove.
1707
1708 2008-07-05 Tom Tromey <tromey@redhat.com>
1709
1710 * jcf-io.c: Don't include fnmatch.h. Don't use JCF_USE_SCANDIR.
1711 (compare_path): Remove.
1712 (java_or_class_file): Likewise.
1713 (memoized_dirlist_entry): Likewise.
1714 (memoized_dirlist_hash): Likewise.
1715 (memoized_dirlist_lookup_eq): Likewise.
1716 (memoized_dirlists): Likewise.
1717 (caching_stat): Likewise.
1718 (find_class): Use stat.
1719 * jcf.h (JCF_USE_SCANDIR): Remove.
1720
1721 2008-06-30 Joshua Sumali <jsumali@redhat.com>
1722
1723 * Make-lang.in (JAVA_MANFILES): Add doc/aot-compile.1 and
1724 doc/rebuild-gcj-db.1
1725 (java.uninstall): Likewise.
1726 (java.maintainer-clean): Likewise.
1727 (aot-compile.pod): New rule.
1728 (rebuild-gcj-db.pod): New rule.
1729 (java.install-man): Install doc/aot-compile.1 and doc/rebuild-gcj-db.1
1730 * gcj.texi: Add new sections for aot-compile and rebuild-gcj-db.
1731
1732 2008-06-29 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1733
1734 * Make-lang.in (java/jcf-io.o-warn): New.
1735
1736 2008-06-24 Tom Tromey <tromey@redhat.com>
1737
1738 * jcf-path.c (jcf_path_init): Don't name variable 'try'.
1739 * expr.c (add_type_assertion): Rename argument.
1740 (build_java_arrayaccess): Don't name variable 'throw'.
1741 (ARRAY_NEW_MULTI): Don't name variable 'class'.
1742 * jcf-io.c (find_class): Don't name variable 'class'.
1743 * mangle.c (compression_table_add): Don't name variable 'new'.
1744 * constants.c (cpool_for_class): Rename argument.
1745 (alloc_constant_fieldref): Likewise.
1746 * jcf-parse.c (handle_innerclass_attribute): Don't name variable
1747 'class'.
1748 (read_class): Likewise.
1749 (parse_zip_file_entries): Likewise.
1750 (process_zip_dir): Likewise.
1751 * decl.c (java_mark_class_local): Rename argument.
1752 * class.c (GEN_TABLE): Use type_name, not typename.
1753 (gen_indirect_dispatch_tables): Likewise.
1754 (add_field): Rename argument.
1755 (is_compiled_class): Likewise.
1756 (safe_layout_class): Likewise.
1757 (emit_assertion_table): Likewise.
1758 * typeck.c (has_method): Rename argument.
1759
1760 2008-06-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1761
1762 * class.c (ident_subst, mangled_classname, unmangle_classname,
1763 gen_indirect_dispatch_tables, add_method_1,
1764 build_fieldref_cache_entry, make_local_function_alias,
1765 layout_class, java_treetreehash_find, java_treetreehash_new,
1766 split_qualified_name): Fix for -Wc++-compat.
1767 * constants.c (set_constant_entry, cpool_for_class): Likewise.
1768 * decl.c (make_binding_level, java_dup_lang_specific_decl,
1769 start_java_method): Likewise.
1770 * except.c (prepare_eh_table_type): Likewise.
1771 * expr.c (type_assertion_hash, note_instructions): Likewise.
1772 * java-tree.h (MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC,
1773 MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC): Likewise.
1774 * jcf-io.c (jcf_filbuf_from_stdio, opendir_in_zip, find_class):
1775 Likewise.
1776 * jcf-parse.c (reverse, java_read_sourcefilenames,
1777 annotation_grow, rewrite_reflection_indexes, java_parse_file,
1778 process_zip_dir): Likewise.
1779 * jcf-path.c (add_entry, add_path, jcf_path_init,
1780 jcf_path_extdirs_arg): Likewise.
1781 * jcf-reader.c (jcf_parse_constant_pool): Likewise.
1782 * jvgenmain.c (do_mangle_classname): Likewise.
1783 * lang.c (put_decl_string): Likewise.
1784 * verify-impl.c (make_state_copy, make_state, add_new_state):
1785 Likewise.
1786
1787 2008-06-15 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1788
1789 * gcj.texi: Expand TABs, remove whitespace from blank lines.
1790
1791 2008-06-14 Tom Tromey <tromey@redhat.com>
1792
1793 PR java/36247:
1794 * class.c (build_class_ref): Initialize this_classdollar when
1795 needed.
1796
1797 2008-05-23 Andrew Haley <aph@redhat.com>
1798
1799 * jcf-parse.c (give_name_to_class): Call find_sourcefile to find full
1800 pathname of source file.
1801
1802 2008-05-12 Aaron W. LaFramboise <aaronavay62@aaronwl.com>
1803
1804 * jcf-dump.c (print_constant): Use
1805 HOST_LONG_LONG_FORMAT.
1806
1807 2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com>
1808
1809 * decl.c (java_init_decl_processing): Change DECL_IS_PURE to
1810 DECL_PURE_P.
1811
1812 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
1813
1814 * class.c (build_utf8_ref): Don't set TREE_INVARIANT.
1815 (build_classdollar_field): Don't set TREE_INVARIANT.
1816 (get_dispatch_table): Don't set TREE_INVARIANT.
1817 (make_class_data): Don't set TREE_INVARIANT.
1818 (build_symbol_entry): Don't set TREE_INVARIANT.
1819 (emit_symbol_table): Don't set TREE_INVARIANT.
1820 * constants.c (build_constant_data_ref): Don't set TREE_INVARIANT.
1821 (build_ref_from_constant_pool): Don't set TREE_INVARIANT.
1822 * resource.c (compile_resource_data): Don't set TREE_INVARIANT.
1823 * expr.c (cache_cpool_data_ref): Don't set TREE_INVARIANT.
1824
1825 2008-04-03 Tom Tromey <tromey@redhat.com>
1826
1827 * Make-lang.in (java_OBJS): New variable.
1828
1829 2008-04-03 Paolo Bonzini <bonzini@gnu.org>
1830
1831 * java-tree.h (insert_block): Kill.
1832 * decl.c (insert_block): Kill.
1833
1834 2008-04-01 Joseph Myers <joseph@codesourcery.com>
1835
1836 * gcj.texi: Include gpl_v3.texi instead of gpl.texi
1837 * Make-lang.in (TEXI_JAVA_FILES): Include gpl_v3.texi instead of
1838 gpl.texi.
1839
1840 2008-03-27 Tom Tromey <tromey@redhat.com>
1841
1842 * Make-lang.in: Revert automatic dependency patch.
1843
1844 2008-03-25 Tom Tromey <tromey@redhat.com>
1845
1846 * Make-lang.in: Removed most explicit .o targets.
1847 (java/jvspec.o): Reduce to variable setting. Moved to java/.
1848 ($(GCJ)$(exeext)): Update.
1849 (JAVA_OBJS): New variable.
1850 (JCFDUMP_OBJS): Reformat.
1851 (java_OBJS): New variable.
1852 (java/jvspec.o-warn): Update.
1853 (java/parse.o-warn): Remove.
1854 (JAVA_TREE_H): Remove.
1855 (java/jcf-io.o): Reduce to variable setting.
1856 (ALL_CPPFLAGS): Likewise.
1857
1858 2008-03-12 Paolo Bonzini <bonzini@gnu.org>
1859
1860 * mangle.c (java_mangle_decl): Remove dead check.
1861
1862 2008-03-11 Paolo Bonzini <bonzini@gnu.org>
1863
1864 * jcf-parse.c (java_parse_file): Assert binding levels are
1865 left in order.
1866 * lang.c (LANG_HOOKS_CLEAR_BINDING_STACK, java_clear_binding_stack):
1867 Delete.
1868
1869 2008-03-02 Jakub Jelinek <jakub@redhat.com>
1870
1871 * jcf-dump.c (version): Update copyright notice dates.
1872
1873 2008-02-29 Tom Tromey <tromey@redhat.com>
1874
1875 * expr.c (expand_byte_code): Set DECL_FUNCTION_LAST_LINE on
1876 method.
1877 * java-tree.h (struct lang_decl_func): Remove obsolete comment.
1878
1879 2008-02-26 Tom Tromey <tromey@redhat.com>
1880
1881 * lang.c (java_post_options): Remove conditional.
1882 * expr.c (expand_byte_code): Remove old location code.
1883 * jcf-parse.c (set_source_filename): Remove old location code.
1884 (give_name_to_class): Likewise.
1885 (jcf_parse): Likewise.
1886 (duplicate_class_warning): Likewise.
1887 (parse_class_file): Likewise.
1888 (java_parse_file): Likewise.
1889 * decl.c (finish_method): Remove old location code.
1890 * class.c (push_class): Remove old location code.
1891
1892 2008-02-06 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1893
1894 PR other/35107
1895 * Make-lang.in (jc1): Add $(GMPLIBS).
1896
1897 2008-01-23 David Daney <ddaney@avtrex.com>
1898
1899 * class.c (hide) Rename to...
1900 (java_hide_decl) ... this throughout, and make public.
1901 * resource.c (Jr_count): Remove.
1902 (compile_resource_data): Call java_mangle_resource_name to generate
1903 decl name. Make resource decl public and hidden.
1904 * mangle.c (java_mangle_resource_name): New function.
1905 * java-tree.h (java_hide_decl, java_mangle_resource_name): Declare
1906 functions.
1907
1908 2008-01-04 Andrew Haley <aph@redhat.com>
1909
1910 PR java/17779
1911 * jcf-parse.c (parse_zip_file_entries): Move decl to compile on
1912 C90.
1913
1914 2008-01-03 Andrew Haley <aph@redhat.com>
1915
1916 PR java/17779
1917 * jcf-parse.c (parse_zip_file_entries): Unset TYPE_ALIAS_SET if
1918 we're about to re-layout the type.
1919
1920 2007-12-20 Alexandre Oliva <aoliva@redhat.com>
1921
1922 * lang.c (java_classify_record): Don't return
1923 RECORD_IS_INTERFACE for now.
1924
1925 2007-12-18 Andrew Haley <aph@redhat.com>
1926
1927 PR java/27643
1928 * jcf-parse.c (java_parse_file): Remove call to
1929 java_mark_class_local.
1930 (parse_class_file): Reinstate call to java_mark_class_local here.
1931 * decl.c (java_mark_cni_decl_local): If the ASSEMBLER_NAME is
1932 already set, call java_mangle_decl() and make_decl_rtl() to
1933 rewrite its name as a hidden alias.
1934
1935 2007-12-15 Alexandre Oliva <aoliva@redhat.com>
1936
1937 PR debug/7081
1938 * lang.c (java_classify_record): New.
1939 (LANG_HOOKS_CLASSIFY_RECORD): Override.
1940
1941 2007-11-26 Andreas Krebbel <krebbel1@de.ibm.com>
1942
1943 PR 34081/C++
1944 * decl.c (finish_method): Pass 'false' for the new
1945 allocate_struct_function parameter.
1946
1947 2007-11-26 Alexandre Oliva <aoliva@redhat.com>
1948
1949 * expr.c (build_jni_stub): Use the computed jni func type for
1950 variable meth.
1951
1952 2007-11-26 Alexandre Oliva <aoliva@redhat.com>
1953
1954 * class.c (JAVA_TREEHASHHASH_H): Use TYPE_UID.
1955
1956 2007-11-26 Alexandre Oliva <aoliva@redhat.com>
1957
1958 * expr.c (type_assertion_hash): Hash type uids rather than
1959 tree pointers.
1960
1961 2007-11-17 David Daney <ddaney@avtrex.com>
1962 Andrew Haley <aph@redhat.com>
1963
1964 * constants.c (build_constants_constructor): Use POINTER_SIZE
1965 insead of BITS_PER_WORD in big-endian work around.
1966
1967 2007-11-07 Tom Tromey <tromey@redhat.com>
1968
1969 PR java/34019:
1970 * gcj.texi (Input Options): Add missing noun.
1971
1972 2007-11-02 Tom Tromey <tromey@redhat.com>
1973
1974 PR java/33765:
1975 * jcf-parse.c (java_parse_file): Ignore ZIPEMPTYMAGIC files.
1976 * zipfile.h (ZIPEMPTYMAGIC): New define.
1977
1978 2007-11-01 Tom Tromey <tromey@redhat.com>
1979
1980 * Make-lang.in (java/jcf-dump.o): Depend on zipfile.h.
1981 (java/jcf-parse.o): Depend on jcf-reader.c, zipfile.h, and jcf.h.
1982 (java/jcf-io.o): Depend on zipfile.h.
1983
1984 2007-10-17 Richard Guenther <rguenther@suse.de>
1985
1986 * Make-lang.in (java/builtins.o): Add $(OPTABS_H) and $(EXPR_H)
1987 dependencies.
1988
1989 2007-10-03 Andrew Haley <aph@redhat.com>
1990
1991 PR java/33639
1992 * class.c (mangled_classname): Detect and replace illegal
1993 characters in assembly language symbols.
1994 (gen_indirect_dispatch_tables): Call mangled_classname() on
1995 the type.
1996
1997 2007-09-27 Jakub Jelinek <jakub@redhat.com>
1998
1999 * lang.c (java_print_error_function): Add third argument.
2000
2001 2007-09-15 Tom Tromey <tromey@redhat.com>
2002
2003 * java-tree.h (struct lang_decl_func) <function_decl_body>:
2004 Remove.
2005 <init_final>: Likewise.
2006 * lang.c (java_dump_tree): Update.
2007 * java-tree.h (DECL_FUNCTION_BODY): Remove.
2008
2009 2007-09-11 Jan Hubicka <jh@suse.cz>
2010
2011 * decl.c (java_expand_body): Kill.
2012 (LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): Kill.
2013
2014 2007-09-06 Tom Tromey <tromey@redhat.com>
2015
2016 * jcf-parse.c (parse_class_file): Re-enter the current file.
2017
2018 2007-09-07 Roman Zippel <zippel@linux-m68k.org>
2019
2020 * boehm.c (mark_reference_fields): Move misaligned pointer check
2021 after JREFERENCE_TYPE_P test
2022
2023 2007-09-06 Roman Zippel <zippel@linux-m68k.org>
2024
2025 * boehm.c (mark_reference_fields): Don't use bitmap as gc_descr
2026 if pointer is misaligned.
2027
2028 2007-09-06 Tom Tromey <tromey@redhat.com>
2029
2030 * lang.c (java_post_options): Update.
2031 * jcf-parse.c (set_source_filename): Update.
2032 (give_name_to_class): Update.
2033 (jcf_parse): Update.
2034 (duplicate_class_warning): Update.
2035 (parse_class_file): Update.
2036 (java_parse_file): Update.
2037 * expr.c (expand_byte_code): Update.
2038
2039 2007-09-05 Sandra Loosemore <sandra@codesourcery.com>
2040
2041 * decl.c (finish_method): Use set_cfun.
2042
2043 2007-09-04 Andrew Haley <aph@redhat.com>
2044
2045 * decl.c (java_init_decl_processing): Call "__cxa_end_cleanup"
2046 when using the ARM EABI.
2047
2048 2007-09-03 Daniel Jacobowitz <dan@codesourcery.com>
2049
2050 * Make-lang.in (jvspec.o): Remove SHLIB_MULTILIB.
2051
2052 2007-09-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2053
2054 * jcf-parse.c (read_class, java_parse_file): Supply a TYPE for
2055 CONST_CAST.
2056 * jcf.h (JCF_FINISH): Likewise.
2057
2058 2007-08-28 Tom Tromey <tromey@redhat.com>
2059
2060 * Make-lang.in (java.tags): Don't tag '*.y' files.
2061
2062 2007-08-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2063
2064 * lang.c (java_decl_ok_for_sibcall): Likewise.
2065
2066 2007-08-21 Paul Brook <paul@codesourcery.com>
2067 Nathan Sidwell <nathan@codesourcery.com>
2068 Mark Mitchell <mark@codesourcery.com>
2069 Joseph Myers <joseph@codesourcery.com>
2070
2071 * jcf-dump.c (version): Use pkgversion_string. Update copyright
2072 date.
2073
2074 2007-08-20 Richard Guenther <rguenther@suse.de>
2075
2076 * lang.c (java_tree_inlining_walk_subtrees): Remove.
2077 (LANG_HOOKS_TREE_INLINING_WALK_SUBTREES): Remove.
2078
2079 2007-08-17 Tom Tromey <tromey@redhat.com>
2080
2081 * typeck.c (find_method_in_interfaces): Update.
2082 * jcf-parse.c (load_class): Update.
2083 * java-gimplify.c (java_gimplify_component_ref): Removed.
2084 (java_gimplify_modify_expr): Update. Removed pre_p and post_p
2085 arguments.
2086 (java_gimplify_expr): Update.
2087 * decl.c (java_init_decl_processing): Update.
2088 * class.c (set_constant_value): Update.
2089 (make_class_data): Update.
2090 (finish_class): Update.
2091 (build_static_field_ref): Update.
2092 (is_compiled_class): Update.
2093 (maybe_layout_super_class): Update.
2094 (layout_class): Update.
2095 (layout_class_method): Update.
2096 * java-tree.h (CAN_COMPLETE_NORMALLY): Removed.
2097 (lang_decl_var) <am, final_iud, cif>: Removed fields.
2098 (lang_decl_func) <init_calls_this>: Removed field.
2099 (lang_type) <dot_class, verify_method>: Removed fields.
2100 (FIELD_NESTED_ACCESS): Removed.
2101 (FIELD_NESTED_ACCESS_P): Removed.
2102 (DECL_FIELD_FINAL_IUD): Removed.
2103 (DECL_LOCAL_FINAL_IUD): Removed
2104 (LOCAL_FINAL_P): Removed.
2105 (FINAL_VARIABLE_P): Removed.
2106 (CLASS_FINAL_VARIABLE_P): Removed.
2107 (DECL_BIT_INDEX): Removed.
2108 (DECL_INIT_CALLS_THIS): Removed.
2109 (FIELD_LOCAL_ALIAS): Removed.
2110 (FIELD_LOCAL_ALIAS_USED): Removed.
2111 (FIELD_THISN): Removed.
2112 (DECL_FUNCTION_INIT_TEST_CLASS): Removed.
2113 (LOCAL_CLASS_INITIALIZATION_FLAG): Removed.
2114 (LOCAL_CLASS_INITIALIZATION_FLAG_P): Removed.
2115 (TYPE_DOT_CLASS): Removed.
2116 (TYPE_VERIFY_METHOD): Removed.
2117 (ID_CLASSDOLLAR_P): Removed.
2118 (enum java_tree_index) <JTI_CLASSDOLLAR_IDENTIFIER_NODE>:
2119 Removed.
2120 (classdollar_identifier_node): Removed.
2121 (TYPE_UNKNOWN): Removed.
2122 (CLASS_FROM_SOURCE_P): Removed.
2123 * expr.c (build_jni_stub): Update.
2124 (force_evaluation_order): Update.
2125 (build_java_empty_stmt): Update.
2126 (build_class_init): Update.
2127 (java_stack_swap): Update.
2128 (build_jni_stub): Update.
2129
2130 2007-08-17 Tom Tromey <tromey@redhat.com>
2131
2132 * java-tree.h (LABEL_TYPE_STATE): Removed.
2133 (load_type_state): Removed.
2134 (LABEL_PC): Removed.
2135 (LABEL_VERIFIED): Removed.
2136 (type_states): Declare.
2137 * expr.c (type_states): New global.
2138 (load_type_state): Now static. Use type_states. Changed
2139 argument.
2140 (lookup_label): Don't set LABEL_PC.
2141 (expand_byte_code): Don't use LABEL_VERIFIED.
2142 (note_instructions): Initialize type_states.
2143 * verify-glue.c (vfy_note_stack_depth): Rewrote.
2144 (vfy_note_stack_type): Use type_states.
2145 (vfy_note_local_type): Likewise.
2146
2147 2007-08-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2148
2149 * jcf-parse.c (read_class, java_parse_file): Use CONST_CAST.
2150 * jcf.h (JCF_FINISH): Likewise.
2151
2152 2007-07-31 Nick Clifton <nickc@redhat.com>
2153
2154 * java-gimplify.c: Change copyright header to refer to version 3
2155 of the GNU General Public License and to point readers at the
2156 COPYING3 file and the FSF's license web page.
2157 * typeck.c, lang-specs.h, mangle_name.c, jcf-dump.c, class.c,
2158 decl.c, config-lang.in, jcf-parse.c, constants.c, Make-lang.in,
2159 resource.c, except.c, builtins.c, jvspec.c, java-tree.def,
2160 javaop.def, jcf-path.c, verify-glue.c, jcf-depend.c, lang.opt,
2161 jcf-reader.c, mangle.c, zextract.c, jcf-io.c, jcf.h, zipfile.h,
2162 verify.h, java-except.h, win32-host.c, expr.c, jvgenmain.c,
2163 parse.h, lang.c, java-tree.h, javaop.h, boehm.c: Likewise.
2164
2165 2007-07-30 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2166
2167 * jcf-io.c (find_class): Fix -Wcast-qual warnings.
2168
2169 2007-07-29 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2170
2171 * lang.c (java_get_callee_fndecl): Constify.
2172
2173 2007-07-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2174
2175 * mangle.c (set_type_package_list): Constify.
2176 * verify-glue.c (vfy_make_string): Delete.
2177 * verify.h (vfy_make_string): Likewise.
2178
2179 2007-07-26 Tom Tromey <tromey@redhat.com>
2180
2181 * java-tree.h (push_labeled_block, pop_labeled_block): Remove.
2182 (LABELED_BLOCK_LABEL, LABELED_BLOCK_BODY,
2183 EXIT_BLOCK_LABELED_BLOCK): Likewise.
2184 * lang.c (java_tree_inlining_walk_subtrees): Update.
2185 (java_dump_tree): Likewise.
2186 * java-tree.def (LABELED_BLOCK_EXPR, EXIT_BLOCK_EXPR, TRY_EXPR):
2187 Remove.
2188 * decl.c (push_labeled_block, pop_labeled_block): Remove.
2189 * java-gimplify.c (java_gimplify_labeled_block_expr,
2190 java_gimplify_exit_block_expr, java_gimplify_try_expr): Remove.
2191 (java_gimplify_expr): Update.
2192
2193 2007-07-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2194
2195 * class.c (java_treetreehash_hash, java_treetreehash_compare):
2196 Constify.
2197 * expr.c (type_assertion_eq): Likewise.
2198 * jcf-io.c (compare_path): Likewise.
2199 * jcf-parse.c (cmpstringp): Likewise.
2200 * verify-impl.c (get_one_type, compute_argument_types,
2201 compute_return_type): Likewise.
2202
2203 2007-07-16 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
2204
2205 PR target/32462
2206 PR libgcj/32465
2207 * class.c (hide): Wrap in HAVE_GAS_HIDDEN.
2208
2209 2007-07-12 Richard Guenther <rguenther@suse.de>
2210
2211 * expr.c (expand_java_return): RETURN_EXPR has void type.
2212 (build_jni_stub): Likewise. Use a comparison against zero
2213 for null-pointer test in COND_EXPR.
2214 (build_field_ref): Build POINTER_PLUS_EXPR with correct
2215 type. Convert result instead.
2216 (build_invokevirtual): Likewise.
2217
2218 2007-07-09 Geoffrey Keating <geoffk@apple.com>
2219
2220 PR 32617
2221 * lang.c (java_init): Remove setting of force_align_functions_log.
2222 * class.c (add_method_1): Set DECL_ALIGN of non-static method
2223 to cope with ptrmemfunc_vbit_in_pfn.
2224
2225 2007-07-03 David Daney <ddaney@avtrex.com>
2226
2227 * java/Make-lang.in (doc/gcj.info): Add $(gcc_docdir) to
2228 include path.
2229 (doc/gcj.dvi): Same.
2230 (doc/gcj.pdf): Same.
2231 (java/index.html): Same.
2232
2233 2007-06-15 Andrew Pinski <andrew_pinski@playstation.sony.com>
2234
2235 * class.c (make_class_data): Build the index in sizetype.
2236 Use POINTER_PLUS_EXPR instead of PLUS_EXPR when
2237 adding to a pointer type.
2238 (build_symbol_entry): Likewise.
2239 * expr.c (build_java_arrayaccess): Likewise.
2240 (build_field_ref): Likewise.
2241 (build_known_method_ref): Likewise.
2242 (build_invokevirtual): Likewise.
2243 * except.c (build_exception_object_ref): Do a
2244 NEGATIVE and then a POINTER_PLUS_EXPR instead
2245 of a MINUS_EXPR.
2246
2247 2007-06-11 Rafael Ávila de Espíndola <espindola@google.com>
2248
2249 * typeck.c (java_signed_type): Remove.
2250 * lang.c (LANG_HOOKS_SIGNED_TYPE): Remove.
2251 * java-tree.h (java_signed_type): Remove.
2252
2253 2007-05-18 Geoffrey Keating <geoffk@apple.com>
2254
2255 * jcf-dump.c (HANDLE_MAGIC): Use 'unsigned long' for %lx.
2256 (print_constant): Likewise.
2257
2258 2007-05-14 Rafael Ávila de Espíndola <espindola@google.com>
2259
2260 * expr.c (build_java_binop): Use unsigned_type_for instead of
2261 java_unsigned_type.
2262 * java-tree.h (java_unsigned_type): Remove.
2263 * lang.c (LANG_HOOKS_UNSIGNED_TYPE): Remove.
2264 * typeck.c (java_unsigned_type): Remove.
2265
2266 2007-04-21 Andrew Pinski <andrew_pinski@playstation.sony.com>
2267
2268 * java-tree.h (lang_tree_node): Use GENERIC_NEXT
2269 instead of checking GIMPLE_STMT_P in chain_next.
2270
2271 2007-04-06 Colin Walters <walters@redhat.com>
2272
2273 https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=161701
2274 * jcf-io.c (open_class): Copy 'filename'.
2275
2276 2007-04-03 Andrew Haley <aph@redhat.com>
2277
2278 * jvgenmain.c (main): Change main to use class$, not class$$.
2279 (do_mangle_classname): Likewise.
2280 * class.c (hide): New function.
2281 (add_field): Hide everything that shouldn't be visible outside a
2282 DSO.
2283 (build_static_class_ref): Likewise.
2284 (build_classdollar_field): Likewise.
2285 (make_class_data): Likewise.
2286 (layout_class_method): Likewise.
2287 * expr.c (special_method_p): New function.
2288
2289 * class.c (push_class): Don't bogusly guess the source filename.
2290 * jcf-parse.c (give_name_to_class): Don't set input_location from
2291 DECL_ARTIFICIAL decls.
2292
2293 2007-03-30 Rafael Ávila de Espíndola <espindola@google.com>
2294
2295 * typeck.c (java_signed_or_unsigned_type): Removed.
2296 (java_signed_type): use get_signed_or_unsigned_type instead of
2297 java_signed_or_unsigned_type.
2298 (java_unsigned_type): Ditto.
2299 * lang.c (LANG_HOOKS_SIGNED_OR_UNSIGNED_TYPE): Removed.
2300 * java-tree.h (java_signed_or_unsigned_type): Removed.
2301
2302 2007-03-26 Tom Tromey <tromey@redhat.com>
2303
2304 * Make-lang.in (JAVA_MANFILES): Removed grmiregistry.1.
2305 (java.maintainer-clean): Likewise.
2306 (java.install-man): Likewise.
2307 (.INTERMEDIATE): Removed grmiregistry.pod.
2308 (grmiregistry.pod): Removed.
2309 * gcj.texi (Invoking gcjh): Removed.
2310 (Invoking gjnih): Likewise.
2311 (Invoking grmiregistry): Likewise.
2312 (direntry): Updated.
2313 (Top): Likewise.
2314 (which-gcj): Removed.
2315
2316 2007-03-01 Brooks Moses <brooks.moses@codesourcery.com>
2317
2318 * Make-lang.in: Add install-pdf target as copied from
2319 automake v1.10 rules.
2320
2321 2007-02-27 Brooks Moses <brooks.moses@codesourcery.com>
2322
2323 * gcj.texi: Standardize title page.
2324
2325 2007-02-18 Kazu Hirata <kazu@codesourcery.com>
2326
2327 * class.c: Fix a comment typo.
2328
2329 2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
2330 Brooks Moses <brooks.moses@codesourcery.com>
2331 Lee Millward <lee.millward@codesourcery.com>
2332
2333 * java-tree.h (BUILD_MONITOR_ENTER): Use build_call_nary instead
2334 of build3.
2335 (BUILD_MONITOR_EXIT): Likewise.
2336
2337 * java-gimplify.c (java_gimplify_component_ref): Use build_call_expr.
2338 (java_gimplify_modify_expr): Likewise.
2339
2340 * class.c (cache_this_class_ref): Use build_call_expr.
2341 (build_static_field_ref): Likewise.
2342 (emit_indirect_register_classes): Likewise.
2343 (emit_register_classes): Likewise.
2344
2345 * resource.c (write_resource_constructor): Use build_call_expr.
2346
2347 * builtins.c (builtin_creator_function): Change interpretation of
2348 the second parameter to be the whole CALL_EXPR instead of the arglist.
2349 (max_builtin): Tweak parameter list. Use new CALL_EXPR accessors.
2350 (min_builtin): Likewise.
2351 (abs_builtin): Likewise.
2352 (java_build_function_call_expr): Likewise.
2353 (convert_real): Likewise.
2354 (UNMARSHAL3): Likewise.
2355 (UNMARSHAL4): Likewise.
2356 (UNMARSHAL5): Likewise.
2357 (build_arglist_for_builtin): Delete. Fix callers to use
2358 build_call_expr instead.
2359 (putObject_builtin): Tweak parameter list. Use new CALL_EXPR
2360 accessors.
2361 (compareAndSwapInt_builtin): Likewise.
2362 (compareAndSwapLong_builtin): Likewise.
2363 (compareAndSwapObject_builtin): Likewise.
2364 (putVolatile_builtin): Likewise.
2365 (getVolatile_builtin): Likewise.
2366 (VMSupportsCS8_builtin): Likewise.
2367 (check_for_builtin): Pass entire CALL_EXPR to builtin expander
2368 instead of arglist.
2369
2370 * expr.c (build_java_athrow): Use build_call_nary instead of build3.
2371 (build_java_throw_out_of_bounds_exception): Likewise.
2372 (java_check_reference): Likewise.
2373 (build_java_arraystore_check): Likewise.
2374 (build_newarray): Likewise.
2375 (build_anewarray): Likewise.
2376 (expand_java_multinewarray): Use build_call_list instead of build3.
2377 (build_java_monitor): Use build_call_nary instead of build3.
2378 (java_create_object): Likewise.
2379 (expand_java_NEW): Likewise.
2380 (build_instanceof): Likewise.
2381 (expand_java_CHECKCAST): Likewise.
2382 (build_java_soft_divmod): Likewise.
2383 (build_java_binop): Likewise.
2384 (build_field_ref): Likewise.
2385 (build_class_init): Likewise.
2386 (rewrite_arglist_getcaller): Use build_call_expr.
2387 (build_invokeinterface): Use build_call_nary instead of build3.
2388 (expand_invoke): Use build_call_list instead of build3.
2389 (build_jni_stub): Use build_call_nary, build_call_list, or
2390 build_call_expr instead of build3.
2391 (expand_java_field_op): Use build_call_expr instead of build3.
2392 (force_evaluation_order): Use new CALL_EXPR accessors.
2393
2394 * lang.c (java_get_callee_fndecl): Use new CALL_EXPR accessors.
2395
2396 2007-02-15 David Daney <ddaney@avtrex.com>
2397
2398 * Make-lang.in (JAVA_MANFILES): Add doc/gc-analyze.1.
2399 (java.maintainer-clean):Add gc-analyze.1.
2400 (.INTERMEDIATE): Add gc-analyze.pod.
2401 (gc-analyze.pod): New rule.
2402 (java.install-man): Install gc-analyze.1
2403 * gcj.texi: Add new section for the gc-analyze program.
2404
2405 2007-02-07 Andrew Haley <aph@redhat.com>
2406
2407 * class.c (uncache_this_class_ref): New.
2408 * expr.c (build_jni_stub): Initialize the class.
2409 (expand_byte_code): Call uncache_this_class_ref after generating
2410 code.
2411
2412 2007-02-06 Tom Tromey <tromey@redhat.com>
2413
2414 PR java/30714:
2415 * jvspec.c (lang_specific_driver): Check for the '-' in '-I'.
2416
2417 2007-02-03 Kazu Hirata <kazu@codesourcery.com>
2418
2419 * java-tree.h, javaop.def, jcf-parse.c: Fix comment typos.
2420
2421 2007-02-02 Andrew Haley <aph@redhat.com>
2422
2423 * expr.c (expand_byte_code): Call cache_this_class_ref() and
2424 cache_cpool_data_ref().
2425 Set TYPE_CPOOL_DATA_REF.
2426 (cache_cpool_data_ref): New function.
2427 * constants.c (build_ref_from_constant_pool): Remove special-case
2428 code for flag_indirect_classes.
2429 (build_constant_data_ref): Move special-case code for
2430 flag_indirect_classes here from build_ref_from_constant_pool.
2431 * decl.c (finish_method): Move class initialization from here to
2432 cache_this_class_ref.
2433 * class.c (cache_this_class_ref): New function.
2434 (build_class_ref): Use this_classdollar for the ouput class.
2435
2436 2007-02-02 David Daney <ddaney@avtrex.com>
2437
2438 * class.c (is_compiled_class): Move check to avoid reloading
2439 current class.
2440 (layout_class_method): Don't calculate DECL_EXTERNAL if it is
2441 already set.
2442
2443 2007-02-01 Andrew Haley <aph@redhat.com>
2444
2445 PR java/30641
2446 * jcf-parse.c (jcf_parse): Clear the field_offsets bitmap.
2447
2448 2007-01-31 Kazu Hirata <kazu@codesourcery.com>
2449
2450 * class.c, jcf-parse.c: Fix comment typos.
2451
2452 2007-01-30 Tom Tromey <tromey@redhat.com>
2453
2454 * gcj.texi (Strings): Fix documentation for JvNewString.
2455
2456 2007-01-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
2457
2458 * gcj.texi (Invoking gcjh, Invoking gjnih, Arrays): Fix some
2459 typos.
2460
2461 2007-01-30 Ben Elliston <bje@au.ibm.com>
2462
2463 * jvspec.c (lang_specific_driver): Remove unused classpath_args.
2464
2465 2007-01-29 Tom Tromey <tromey@redhat.com>
2466
2467 PR java/30607:
2468 * jvspec.c (lang_specific_driver): Handle separate -I argument.
2469 * lang.opt (-I): Add 'Separate'.
2470
2471 2007-01-29 Andrew Haley <aph@redhat.com>
2472
2473 * class.c (add_method_1): Mark fndecl as external unless we are
2474 compiling it into this object file.
2475
2476 2007-01-24 Andrew Haley <aph@redhat.com>
2477
2478 * jcf-parse.c (HANDLE_SYNTHETIC_ATTRIBUTE): current_class is a
2479 type node, not a decl, so use TYPE_SYNTHETIC not CLASS_SYNTHETIC.
2480
2481 2007-01-22 Andrew Haley <aph@redhat.com>
2482
2483 * builtins.c (VMSupportsCS8_builtin): New function.
2484
2485 2007-01-23 Andrew Pinski <pinskia@gmail.com>
2486
2487 PR java/30454
2488 * jcf-io.c (opendir_in_zip): Close the file
2489 and free zipf before returning after an error.
2490
2491 2007-01-16 Tom Tromey <tromey@redhat.com>
2492
2493 * java-tree.def: Added copyright header.
2494
2495 2007-01-15 Tom Tromey <tromey@redhat.com>
2496
2497 * lang.c (dump_compound_expr) <EXPR_WITH_FILE_LOCATION>: Removed
2498 case.
2499 * java-gimplify.c (java_gimplify_expr) <EXPR_WITH_FILE_LOCATION>:
2500 Removed case.
2501 * java-tree.h (EXPR_WFL_EMIT_LINE_NOTE): Removed.
2502 (EXPR_WFL_NODE): Likewise.
2503 (EXPR_WFL_LINECOL): Likewise.
2504 (EXPR_WFL_FILENAME): Likewise.
2505 (EXPR_WFL_LINENO): Likewise.
2506 (build_expr_wfl, expr_add_location): Don't declare.
2507 (build_unknown_wfl): Removed.
2508 (EXPR_WFL_FILENAME_NODE): Removed.
2509 (EXPR_WFL_COLNO): Removed.
2510 (EXPR_WFL_SET_LINECOL): Removed.
2511 (DECL_FUNCTION_WFL): Removed.
2512 (DECL_FIELD_FINAL_WFL): Removed.
2513 (struct lang_decl_func) <wfl>: Removed field.
2514 <called_constructor>: Likewise.
2515 <inner_access>: Likewise.
2516 (struct lang_decl_var) <wfl>: Removed field.
2517 (DECL_CONSTRUCTOR_CALLS): Removed.
2518 (DECL_FUNCTION_ACCESS_DECL): Likewise.
2519 (DECL_FUNCTION_INNER_ACCESS): Likewise.
2520 (DECL_SPECIFIC_COUNT): Likewise.
2521 * java-tree.def (EXPR_WITH_FILE_LOCATION): Removed.
2522 * expr.c (build_expr_wfl): Removed.
2523 (expr_add_location): Likewise.
2524
2525 2007-01-12 Tom Tromey <tromey@redhat.com>
2526
2527 * jcf-dump.c (main): Updated call to find_class.
2528 * lang.c (java_init): Removed dead code.
2529 * jcf-parse.c (read_class): Don't use java_source field. Removed
2530 dead code.
2531 (parse_zip_file_entries): Don't use java_source field.
2532 (process_zip_dir): Likewise.
2533 (jcf_parse): Removed dead code.
2534 (java_parse_file): Likewise.
2535 (read_class): Updated call to find_class.
2536 * jcf-io.c (find_class): Don't use java_source field. Removed
2537 'source_ok' argument, .java logic.
2538 * jcf.h (JCF) <java_source>: Removed field.
2539 (JCF_ZERO): Updated. (find_class): Updated.
2540 * decl.c: Removed dead code.
2541 * class.c: Removed dead code.
2542
2543 2007-01-11 Tom Tromey <tromey@redhat.com>
2544
2545 * typeck.c (convert): Don't use flag_emit_class_files.
2546 * lang.c (java_post_options): Don't use flag_emit_class_files.
2547 (java_handle_option): Don't use flag_extraneous_semicolon or
2548 flag_redundant.
2549 * jcf-parse.c (HANDLE_CONSTANTVALUE): Don't use
2550 flag_emit_class_files.
2551 (load_class): Likewise.
2552 * java-tree.h (flag_emit_class_files): Don't declare.
2553 (STATIC_CLASS_INIT_OPT_P): Don't use flag_emit_class_files.
2554 (flag_extraneous_semicolon): Don't declare.
2555 (flag_not_overriding): Likewise.
2556 (flag_static_local_jdk1_1): Likewise.
2557 (flag_redundant): Likewise.
2558 * expr.c (build_newarray): Don't use flag_emit_class_files.
2559 * class.c (DEFAULT_ENABLE_ASSERT): Don't use
2560 flag_emit_class_files.
2561 (build_class_ref): Likewise.
2562 * builtins.c (check_for_builtin): Don't use
2563 flag_emit_class_files.
2564
2565 2007-01-10 Tom Tromey <tromey@redhat.com>
2566
2567 * lang.c (java_can_use_bit_fields_p): Removed.
2568 (LANG_HOOKS_CAN_USE_BIT_FIELDS_P): Removed.
2569
2570 2007-01-09 Andrew Haley <aph@redhat.com>
2571
2572 * expr.c (build_java_arrayaccess): Rewrite to generate array
2573 access in canonical form.
2574 (expand_java_arraystore): Use build_fold_addr_expr() on address of
2575 array access.
2576
2577 2007-01-03 Andrew Haley <aph@redhat.com>
2578
2579 PR java/28754
2580 * expr.c (expand_java_field_op): If we're initializing a field's
2581 declaring interface we should not also initialize the class
2582 context in which it was referenced.
2583
2584 2007-01-02 Tom Tromey <tromey@redhat.com>
2585
2586 * java-tree.h (compiling_from_source, current_encoding,
2587 JTI_FINIT_IDENTIFIER_NODE, JTI_INSTINIT_IDENTIFIER_NODE,
2588 JTI_LENGTH_IDENTIFIER_NODE, JTI_SUPER_IDENTIFIER_NODE,
2589 JTI_CONTINUE_IDENTIFIER_NODE, JTI_ACCESS0_IDENTIFIER_NODE,
2590 JTI_WFL_OPERATOR): Removed
2591 (finit_identifier_node, instinit_identifier_node,
2592 length_identifier_node, super_identifier_node,
2593 continue_identifier_node, access0_identifier_node, wfl_operator):
2594 Removed.
2595 (cyclic_inheritance_report,
2596 DECL_FUNCTION_STATIC_METHOD_INVOCATION_COMPOUND,
2597 DECL_FUNCTION_NAP, DECL_FUNCTION_SYNTHETIC_CTOR,
2598 DECL_FIXED_CONSTRUCTOR_P): Removed.
2599 (struct lang_decl_func) <smic, nap, synthetic_ctor, fixed_ctor>:
2600 Removed.
2601 (TYPE_FINIT_STMT_LIST, TYPE_CLINIT_STMT_LIST, TYPE_II_STMT_LIST,
2602 TYPE_IMPORT_LIST, TYPE_IMPORT_DEMAND_LIST): Removed.
2603 (struct lang_type) <finit_stmt_list, clinit_stmt_list, ii_block,
2604 import_list, import_demand_list>: Removed.
2605 (java_layout_seen_class_methods, init_jcf_parse, init_src_parse,
2606 cxx_keyword_p): Removed.
2607 (DECL_FINIT_P, DECL_INSTINIT_P, ID_FINIT_P, ID_INSTINIT_P,
2608 TYPE_UNUSED, TYPE_UNDERFLOW, TYPE_UNEXPECTED,
2609 CLASS_ACCESS0_GENERATED_P, CLASS_HAS_FINIT_P,
2610 IS_A_SINGLE_IMPORT_CLASSFILE_NAME_P, IS_A_CLASSFILE_NAME,
2611 IS_AN_IMPORT_ON_DEMAND_P, COMPOUND_ASSIGN_P, SWITCH_HAS_DEFAULT,
2612 PRIMARY_P, MODIFY_EXPR_FROM_INITIALIZATION_P,
2613 CLASS_METHOD_CHECKED_P, FOR_LOOP_P, ANONYMOUS_CLASS_P,
2614 LOCAL_CLASS_P, ARG_FINAL_P, SUPPRESS_UNREACHABLE_ERROR,
2615 RESOLVE_PACKAGE_NAME_P, RESOLVE_TYPE_NAME_P, IS_BREAK_STMT_P,
2616 IS_CRAFTED_STRING_BUFFER_P, IS_INIT_CHECKED, CALL_USING_SUPER,
2617 NESTED_FIELD_ACCESS_IDENTIFIER_P, TOPLEVEL_CLASS_DECL_P,
2618 PURE_INNER_CLASS_TYPE_P, TOPLEVEL_CLASS_TYPE_P,
2619 CALL_CONSTRUCTOR_P, CALL_EXPLICIT_CONSTRUCTOR_P,
2620 CALL_THIS_CONSTRUCTOR_P, CALL_SUPER_CONSTRUCTOR_P,
2621 FINALLY_EXPR_LABEL, FINALLY_EXPR_BLOCK, BLOCK_IS_IMPLICIT,
2622 BLOCK_EMPTY_P, IS_UNCHECKED_EXCEPTION_P, java_error_count,
2623 java_parse_abort_on_error, extract_field_decl): Removed.
2624 (finput): Declare.
2625 * lang.c: (compiling_from_source, current_encoding): Removed.
2626 (java_handle_option): Ignore -fencoding.
2627 * parse.h: Don't include lex.h.
2628 (java_error_count, int_fits_type_p, stabilize_reference, RULE,
2629 RECOVERED, DRECOVERED, RECOVER, DRECOVER, YYERROR_NOW,
2630 YYNOT_TWICE, CLASS_MODIFIERS, FIELD_MODIFIERS, METHOD_MODIFIERS,
2631 INTERFACE_MODIFIERS, INTERFACE_INNER_MODIFIERS,
2632 INTERFACE_METHOD_MODIFIERS, INTERFACE_FIELD_MODIFIERS,
2633 MODIFIER_WFL, THIS_MODIFIER_ONLY, parse_error_context,
2634 ABSTRACT_CHECK, JCONSTRUCTOR_CHECK, exit_java_complete_class,
2635 CLASS_OR_INTERFACE, GET_REAL_TYPE, GET_TYPE_NAME,
2636 OBSOLETE_MODIFIER_WARNING, OBSOLETE_MODIFIER_WARNING2,
2637 BUILD_PTR_FROM_NAME, INCOMPLETE_TYPE_P,
2638 JAVA_MAYBE_GENERATE_DEBUG_INFO, JBSC_TYPE_P, JSTRING_P,
2639 JNULLP_TYPE_P, JDECL_P, TYPE_INTERFACE_P, TYPE_CLASS_P,
2640 IDENTIFIER_INNER_CLASS_OUTER_FIELD_ACCESS,
2641 MANGLE_OUTER_LOCAL_VARIABLE_NAME,
2642 MANGLE_ALIAS_INITIALIZER_PARAMETER_NAME_ID,
2643 MANGLE_ALIAS_INITIALIZER_PARAMETER_NAME_STRING,
2644 SKIP_THIS_AND_ARTIFICIAL_PARMS, MARK_FINAL_PARMS,
2645 UNMARK_FINAL_PARMS, CRAFTED_PARAM_LIST_FIXUP,
2646 AIPL_FUNCTION_CREATION, AIPL_FUNCTION_DECLARATION,
2647 AIPL_FUNCTION_CTOR_INVOCATION, AIPL_FUNCTION_FINIT_INVOCATION,
2648 ERROR_CANT_CONVERT_TO_BOOLEAN, ERROR_CANT_CONVERT_TO_NUMERIC,
2649 ERROR_CAST_NEEDED_TO_INTEGRAL, ERROR_VARIABLE_NOT_INITIALIZED,
2650 LOOP_EXPR_BODY_MAIN_BLOCK, LOOP_EXPR_BODY_UPDATE_BLOCK,
2651 LOOP_EXPR_BODY_CONDITION_EXPR, LOOP_EXPR_BODY_LABELED_BODY,
2652 LOOP_EXPR_BODY_BODY_EXPR, PUSH_LABELED_BLOCK, POP_LABELED_BLOCK,
2653 PUSH_LOOP, POP_LOOP, PUSH_EXCEPTIONS, POP_EXCEPTIONS,
2654 IN_TRY_BLOCK_P, EXCEPTIONS_P, ANONYMOUS_ARRAY_BASE_TYPE,
2655 ANONYMOUS_ARRAY_DIMS_SIG, ANONYMOUS_ARRAY_INITIALIZER,
2656 INVOKE_STATIC, INVOKE_NONVIRTUAL, INVOKE_SUPER, INVOKE_INTERFACE,
2657 INVOKE_VIRTUAL, jdep_code, struct _jdep, JDEP_DECL, JDEP_DECL_WFL,
2658 JDEP_KIND, JDEP_WFL, JDEP_MISC, JDEP_ENCLOSING, JDEP_CLASS,
2659 JDEP_APPLY_PATCH, JDEP_GET_PATCH, JDEP_CHAIN, JDEP_TO_RESOLVE,
2660 JDEP_RESOLVED_DECL, JDEP_RESOLVED, JDEP_RESOLVED_P, struct
2661 jdeplist_s, jdeplists, CLASSD_FIRST, CLASSD_LAST, CLASSD_CHAIN,
2662 JDEP_INSERT, SET_TYPE_FOR_RESOLUTION, WFL_STRIP_BRACKET,
2663 STRING_STRIP_BRACKETS, PROMOTE_RECORD_IF_COMPLETE,
2664 BLOCK_CHAIN_DECL, GET_CURRENT_BLOCK, EXPR_WFL_GET_LINECOL,
2665 EXPR_WFL_QUALIFICATION, QUAL_WFL, QUAL_RESOLUTION, QUAL_DECL_TYPE,
2666 GET_SKIP_TYPE, COMPLETE_CHECK_OP, COMPLETE_CHECK_OP_0,
2667 COMPLETE_CHECK_OP_1, COMPLETE_CHECK_OP_2, BUILD_APPEND,
2668 BUILD_STRING_BUFFER, BUILD_THROW, SET_WFL_OPERATOR,
2669 PATCH_METHOD_RETURN_ERROR, CHECK_METHODS, CLEAR_DEPRECATED,
2670 CHECK_DEPRECATED_NO_RESET, CHECK_DEPRECATED, REGISTER_IMPORT,
2671 CURRENT_OSB, struct parser_ctxt, GET_CPC_LIST, CPC_INNER_P,
2672 GET_CPC, GET_CPC_UN, GET_CPC_UN_MODE, GET_CPC_DECL_NODE,
2673 GET_ENCLOSING_CPC, GET_NEXT_ENCLOSING_CPC,
2674 GET_ENCLOSING_CPC_CONTEXT, INNER_ENCLOSING_SCOPE_CHECK, PUSH_CPC,
2675 PUSH_ERROR, POP_CPC, DEBUG_CPC, CPC_INITIALIZER_LIST,
2676 CPC_STATIC_INITIALIZER_LIST, CPC_INSTANCE_INITIALIZER_LIST,
2677 CPC_INITIALIZER_STMT, CPC_STATIC_INITIALIZER_STMT,
2678 CPC_INSTANCE_INITIALIZER_STMT, SET_CPC_INITIALIZER_STMT,
2679 SET_CPC_STATIC_INITIALIZER_STMT,
2680 SET_CPC_INSTANCE_INITIALIZER_STMT, JAVA_NOT_RADIX10_FLAG,
2681 java_complete_class, java_check_circular_reference,
2682 java_fix_constructors, java_layout_classes, java_reorder_fields,
2683 java_method_add_stmt, java_get_line_col, reset_report,
2684 java_init_lex, yyparse, java_parse, yyerror, java_expand_classes,
2685 java_finish_classes, ctxp, ctxp_for_generation,
2686 ctxp_for_generation_last): Removed.
2687 * expr.c (force_evaluation_order): Don't mention NEW_CLASS_EXPR.
2688 * mangle.c (utf8_cmp): New function.
2689 (cxx_keywords): New global.
2690 (cxx_keyword_p): New function.
2691 * jvspec.c (JAVA_START_CHAR): Removed obsolete comment.
2692 * java-tree.def (UNARY_PLUS_EXPR, NEW_ARRAY_EXPR,
2693 NEW_ANONYMOUS_ARRAY_EXPR, NEW_CLASS_EXPR, THIS_EXPR,
2694 CASE_EXPR, DEFAULT_EXPR, JAVA_CATCH_EXPR, SYNCHRONIZED_EXPR,
2695 THROW_EXPR, CONDITIONAL_EXPR, INSTANCEOF_EXPR, NEW_ARRAY_INIT,
2696 CLASS_LITERAL, JAVA_EXC_OBJ_EXPR): Removed.
2697 * Make-lang.in (java.srcextra): Do nothing.
2698 (parse.c, keyword.h, gt-java-parse.h): Removed targets.
2699 (JAVA_OBJS): Don't mention deleted files.
2700 (java.mostlyclean): Likewise.
2701 (java.clean): Likewise.
2702 (JAVA_LEX_C): Removed.
2703 (buffer.o, check-init.o, parse.o): Remove unused targets.
2704 (typeck.o): Updated.
2705 * jcf-parse.c (read_class): Comment out unused code.
2706 (java_layout_seen_class_methods): New function.
2707 (parse_source_file_1, parse_source_file_2, parse_source_file_3):
2708 Removed.
2709 (java_parse_file): Comment out unused code. Don't use 'ctxp'.
2710 (init_jcf_parse): Removed.
2711 * config-lang.in (gtfiles): Remove deleted files.
2712 * decl.c (java_init_decl_processing): Don't initialize
2713 finit_identifier_node, instinit_identifier_node,
2714 length_identifier_node, super_identifier_node,
2715 continue_identifier_node, access0_identifier_node. Don't call
2716 init_jcf_parse.
2717 * class.c (cyclic_inheritance_report): New global.
2718 (add_method_1): Don't use
2719 DECL_FUNCTION_STATIC_METHOD_INVOCATION_COMPOUND.
2720 (maybe_layout_super_class): Comment out code.
2721 (safe_layout_class): New function.
2722 * java-gimplify.c (java_gimplify_expr): Removed CASE_EXPR,
2723 DEFAULT_EXPR, NEW_ARRAY_INIT, JAVA_CATCH_EXPR, JAVA_EXC_OBJ_EXPR,
2724 UNARY_PLUS_EXPR, NEW_ARRAY_EXPR, NEW_ANONYMOUS_ARRAY_EXPR,
2725 NEW_CLASS_EXPR, SYNCHRONIZED_EXPR, CONDITIONAL_EXPR,
2726 INSTANCEOF_EXPR, CLASS_LITERAL, THIS_EXPR.
2727 (java_gimplify_case_expr): Removed.
2728 (java_gimplify_default_expr): Likewise.
2729 (java_gimplify_new_array_init): Likewise.
2730 * parse.y: Removed.
2731 * keyword.gperf, keyword.h: Removed.
2732 * chartables.h: Removed.
2733 * check-init.c: Removed.
2734 * buffer.c, buffer.h: Removed.
2735 * convert.h: Removed.
2736 * gen-table.pl: Removed.
2737 * lex.c, lex.h: Removed.
2738
2739 2007-01-02 Andrew Haley <aph@redhat.com>
2740
2741 * expr.c (expand_java_arraystore): Make sure we perform a bounds
2742 check at runtime before we perform a type check.
2743
2744 2006-12-19 Andrew Haley <aph@redhat.com>
2745
2746 * decl.c: Bump minor BC ABI version.
2747
2748 2006-12-13 Gary Benson <gbenson@redhat.com>
2749
2750 * jcf-depend.c (jcf_dependency_add_file): Mark filename unused.
2751
2752 2006-12-12 Tom Tromey <tromey@redhat.com>
2753
2754 * lang-specs.h: Pass -M options to jc1.
2755 * jcf-depend.c (jcf_dependency_add_file): Don't emit
2756 dependencies.
2757
2758 2006-12-07 Mohan Embar <gnustuff@thisiscool.com>
2759
2760 * jcf-path.c (jcf_path_compute): Use platform PATH_SEPARATOR.
2761
2762 2006-12-06 Mohan Embar <gnustuff@thisiscool.com>
2763
2764 * lang-specs.h: Pass '%U'-based options as separate arguments.
2765
2766 2006-12-05 Tom Tromey <tromey@redhat.com>
2767
2768 PR java/29495:
2769 * jcf-parse.c (HANDLE_SYNTHETIC_ATTRIBUTE): Mark fields and
2770 classes as well.
2771 * class.c (add_field): Handle ACC_SYNTHETIC.
2772 (add_method_1): Likewise. Handle bridge and varargs.
2773 (get_access_flags_from_decl): Handle synthetic, bridge, varargs,
2774 annotation.
2775 (set_class_decl_access_flags): Handle synthetic and annotation.
2776 * java-tree.h (METHOD_BRIDGE): New macro.
2777 (METHOD_VARARGS): Likewise.
2778 (TYPE_SYNTHETIC): Likewise.
2779 (TYPE_ANNOTATION): Likewise.
2780 (lang_type): New fields 'synthetic' and 'annotation'.
2781 (lang_decl_func): New fields 'varargs' and 'bridge'.
2782
2783 2006-12-04 Andrew Haley <aph@redhat.com>
2784
2785 * jcf-parse.c (rewrite_reflection_indexes): Don't do anything if
2786 there's no map.
2787
2788 2006-11-29 Gary Benson <gbenson@redhat.com>
2789
2790 * expr.c (rewrite_arglist_getcaller): Reorder.
2791
2792 2006-11-29 Andrew Haley <aph@redhat.com>
2793
2794 * expr.c (rewrite_arglist_getcaller): Remove DECL_INLINE.
2795 * lang.c (java_decl_ok_for_sibcall): Check for DECL_INLINE.
2796
2797 2006-11-23 Andrew Haley <aph@redhat.com>
2798
2799 * expr.c (rewrite_arglist_getcaller): New.
2800 (rewrite_arglist_getclass): Fix indentation.
2801 (rules): Add gnu.classpath.VMStackWalker.getCallingClass() and
2802 gnu.classpath.VMStackWalker.getCallingClassLoader().
2803 * builtins.c (initialize_builtins): Remove duplicate def'n of
2804 __sync_synchronize.
2805 Add __builtin_return_address.
2806
2807 2006-11-22 Andrew Haley <aph@redhat.com>
2808
2809 * jcf-reader.c (get_attribute): Mark attr_type unused.
2810
2811 * builtins.c (compareAndSwapObject_builtin): Fix declaration.
2812
2813 2007-01-08 Richard Guenther <rguenther@suse.de>
2814
2815 * lex.c (do_java_lex): Use build_int_cst_wide_type.
2816 * jcf-parse.c (get_constant): Likewise.
2817
2818 2006-11-12 Jan Hubicka <jh@suse.cz>
2819
2820 * resource.c (compile_resource_data): Update for new varpool names.
2821 * java/class.c (build_utf8_ref): Likewise.
2822
2823 2006-11-12 David Daney <ddaney@avtrex.com>
2824
2825 PR java/29805
2826 * typeck.c (build_java_array_type): Increase buffer sizes.
2827
2828 2006-11-11 Richard Guenther <rguenther@suse.de>
2829
2830 * check-init.c (check_init): Remove handling of FIX_CEIL_EXPR,
2831 FIX_FLOOR_EXPR and FIX_ROUND_EXPR.
2832
2833 2006-11-06 Andrew Haley <aph@redhat.com>
2834
2835 * java-tree.h (CONSTANT_LazyFlag): New.
2836 * constants.c (build_constants_constructor): Mask CONSTANT_LazyFlag.
2837 * jcf-parse.c (handle_innerclass_attribute): Write attribute to
2838 reflection_data.
2839 (handle_constant): Return 0 for dummy cpool entries.
2840 Handle constants of kind Class.
2841 Handle constants of kind NameAndType.
2842 (handle_enclosingmethod_attribute): New.
2843 (handle_signature_attribute): New.
2844 (HANDLE_ENCLOSINGMETHOD_ATTRIBUTE): New.
2845 (HANDLE_SIGNATURE_ATTRIBUTE): New.
2846 (handle_constant): Use unmangle_classname()rather than calling
2847 identifier_subst() directly.
2848
2849 2006-11-02 Andrew Haley <aph@redhat.com>
2850
2851 * java-tree.h (FIELD_ENUM): New.
2852 (lang_decl_var.field_enum): New.
2853 (lang_type.enum_class): New.
2854 (CLASS_ENUM): New.
2855 * class.c (set_class_decl_access_flags): Handle enum types.
2856 (add_field): Handle enum fields.
2857 (get_access_flags_from_decl): Likewise.
2858
2859 * class.c (make_class_data): Put reflection_data into rodata.
2860
2861 2006-11-01 Andrew Haley <aph@redhat.com>
2862
2863 * jcf-parse.c (field_offsets, bit_obstack): New variables.
2864 (jcf_parse): Write end marker to annotation_data.
2865 (java_parse_file): Create field_offsets bitmap. Destroy it.
2866 (annotation_grow, annotation_rewrite_byte)
2867 (annotation_rewrite_short, annotation_rewrite_int)
2868 (annotation_read_short, annotation_write_byte)
2869 (annotation_write_short, annotation_write_int)
2870 (handle_long_constant, handle_constant, handle_element_value)
2871 (handle_annotation, handle_annotations)
2872 (handle_annotation_attribute, rewrite_reflection_indexes)
2873 (handle_member_annotations, handle_parameter_annotations)
2874 (handle_default_annotation): New functions.
2875 (HANDLE_RUNTIMEVISIBLEANNOTATIONS_ATTRIBUTE)
2876 (HANDLE_RUNTIMEINVISIBLEANNOTATIONS_ATTRIBUTE)
2877 (HANDLE_RUNTIMEVISIBLEPARAMETERANNOTATIONS_ATTRIBUTE)
2878 (HANDLE_RUNTIMEINVISIBLEPARAMETERANNOTATIONS_ATTRIBUTE)
2879 (HANDLE_ANNOTATIONDEFAULT_ATTRIBUTE): New definitions.
2880 * java-tree.h (enum jv_attr_type, enum jv_attr_kind): New.
2881 (TYPE_REFLECTION_DATA): New.
2882 (TYPE_REFLECTION_DATASIZE): New.
2883 * jcf.h (enum cpool_tag): Convert a bunch of #define constants to
2884 an enum.
2885 * jcf-reader.c (get_attribute): Pass field/method index and
2886 attribute type to get_attribute().
2887 * constants.c (find_class_or_string_constant): Make nonstatic.
2888 (cpool_for_class): Likewise.
2889 (build_constants_constructor): Separate string and scalar types.
2890 * class.c (make_class_data): Generate field_indexes permutation.
2891 Pass it to rewrite_reflection_indexes().
2892 (make_class_data): Generate constructor for reflection_data field.
2893
2894 2006-10-20 Tom Tromey <tromey@redhat.com>
2895
2896 * gcj.texi (Top): Don't mention jv-scan.
2897 (Invoking gcj): Likewise.
2898 (Invoking gcjh): Likewise.
2899 (Invoking gjnih): Likewise.
2900 (Invoking gij): Likewise.
2901 (Invoking gcj-dbtool): Likewise.
2902 (Invoking jv-scan): Removed.
2903 * parse-scan.y: Removed.
2904 * jv-scan.c: Removed.
2905 * config-lang.in (stagestuff): Don't mention jv-scan.
2906 * Make-lang.in (java): Removed jv-scan.
2907 (JAVA_TARGET_INDEPENDENT_BIN_TOOLS): Likewise.
2908 (JVSCAN_OBJS): Removed.
2909 (jv-scan$(exeext)): Likewise.
2910 (JAVA_MANFILES): Removed jv-scan.1.
2911 (java.uninstall): Don't mention jv-scan.
2912 (java.mostlyclean): Likewise.
2913 (java.maintainer-clean): Likewise.
2914 (.INTERMEDIATE): Likewise.
2915 (java/jv-scan.o): Removed.
2916 (jv-scan.pod): Likewise.
2917 (java.srcextra): Don't mention parse-scan.c.
2918 (java.mostlyclean): Likewise.
2919 (java/parse-scan.c): Removed.
2920 (java/parse-scan.o-warn): Removed.
2921 (java/parse-scan.o): Removed.
2922
2923 2006-10-20 Tom Tromey <tromey@redhat.com>
2924
2925 * lang.c (java_handle_option): Don't use
2926 jcf_write_base_directory.
2927 * jcf.h (jcf_write_base_directory): Removed.
2928 * parse.y (java_expand_classes): Don't call write_classfile.
2929 * config-lang.in (gtfiles): Removed jcf-write.c.
2930 * Make-lang.in (JAVA_OBJS): Removed jcf-write.o.
2931 (java/jcf-write.o): Removed.
2932 * jcf-parse.c (parse_class_file): Don't call write_classfile.
2933 * java-tree.h (write_classfile): Removed declaration.
2934 * jcf-write.c: Removed.
2935
2936 2006-10-20 Tom Tromey <tromey@redhat.com>
2937
2938 * Make-lang.in (java): Removed gjnih, gcjh.
2939 (JAVA_TARGET_INDEPENDENT_BIN_TOOLS): Likewise.
2940 (GCJH_OBJS): Removed.
2941 (GJNIH_OBJS): Likewise.
2942 (gjnih$(exeext)): Likewise.
2943 (gcjh$(exeext)): Likewise.
2944 (JAVA_MANFILES): Removed gcjh.1, gjnih.1.
2945 (java.install-common): Don't special case gcjh.
2946 (java.uninstall): Don't mention gcjh, gjnih.
2947 (java.mostlyclean): Likewise.
2948 (java.maintainer-clean): Likewise.
2949 (.INTERMEDIATE): Likewise.
2950 (gcjh.pod): Removed.
2951 (gjnih.pod): Likewise.
2952 (GCJH_TARGET_INSTALL_NAME): Removed.
2953 (java/gjavah-jni.o): Removed.
2954 (java/gjavah.o): Likewise.
2955 * config-lang.in (stagestuff): Removed gjnih, gcjh.
2956 * gjavah.c: Removed.
2957
2958 2006-10-17 Tom Tromey <tromey@redhat.com>
2959
2960 * jcf-dump.c (print_element_value): Expect a utf8 constant in the
2961 "string" case.
2962
2963 2006-10-17 Tom Tromey <tromey@redhat.com>
2964
2965 * jvgenmain.c (main): Handle -findirect-dispatch.
2966 * jvspec.c (jvgenmain_spec): Pass -findirect-dispatch to
2967 jvgenmain.
2968
2969 2006-10-06 Andrew Haley <aph@redhat.com>
2970
2971 * builtins.c (compareAndSwapInt_builtin): Check that we really do
2972 have a compare_and_swap builtin.
2973 (compareAndSwapLong_builtin): Likewise.
2974 (compareAndSwapObject_builtin): Likewise.
2975
2976 2006-10-04 Andrew Haley <aph@redhat.com>
2977
2978 * builtins.c (java_builtins): Add compareAndSwapInt,
2979 compareAndSwapLong, compareAndSwapObject, putOrderedInt,
2980 putOrderedLong, putOrderedObject, putIntVolatile, putLongVolatile,
2981 putObjectVolatile, getObjectVolatile, getIntVolatile,
2982 getLongVolatile, getLong.
2983 (UNMARSHAL3): New macro.
2984 (UNMARSHAL4): Likewise.
2985 (UNMARSHAL5): Likewise.
2986 (build_arglist_for_builtin): New function.
2987 (build_addr_sum, build_check_this): New functions.
2988 (putObject_builtin. compareAndSwapInt_builtin,
2989 compareAndSwapLong_builtin, compareAndSwapObject_builtin,
2990 putVolatile_builtin, getVolatile_builtin): New builtins.
2991
2992 2006-06-08 Andrew Haley <aph@redhat.com>
2993
2994 * expr.c (build_field_ref): Pass NULL_TREE as SPECIAL arg to
2995 get_symbol_table_index().
2996 (maybe_rewrite_invocation): Set SPECIAL if we need to access a
2997 private method.
2998 (build_known_method_ref): New arg: special. Pass it to
2999 get_symbol_table_index.
3000 (get_symbol_table_index): Put SPECIAL in the TREE_PURPOSE field of
3001 the method list.
3002 (build_invokevirtual): New arg: special. Pass it to
3003 get_symbol_table_index.
3004 (expand_invoke): New variable: special.
3005 Pass it to maybe_rewrite_invocation().
3006 Pass it to build_known_method_ref().
3007 * class.c (build_symbol_entry): Add new arg: special. Use it to
3008 build the symbol table conbstructor.
3009 (emit_symbol_table): Extract SPECIAL from the method list and pass
3010 it to build_symbol_entry().
3011 * parse.y (patch_invoke): Call maybe_rewrite_invocation() and set
3012 special accordingly.
3013
3014 2006-09-08 Andrew Haley <aph@redhat.com>
3015
3016 * class.c (layout_class_method): Use build_java_signature, not
3017 build_java_argument_signature. Use lookup_java_method, not
3018 lookup_argument_method.
3019
3020 2006-08-16 Jakub Jelinek <jakub@redhat.com>
3021 Bryce McKinlay <bryce@mckinlay.net.nz>
3022
3023 * jvspec.c (lang_specific_driver): Add -s-bc-abi when needed.
3024
3025 2006-07-18 Tom Tromey <tromey@redhat.com>
3026
3027 * lang.opt: Added missing -W options.
3028
3029 2006-07-12 Tom Tromey <tromey@redhat.com>
3030
3031 PR java/28329:
3032 * lang-specs.h: Pass '%U'-based options as separate arguments.
3033 Use -faux-classpath.
3034 * lang.c (java_handle_option): Handle OPT_faux_classpath.
3035 * lang.opt (faux-classpath): New option.
3036
3037 2006-07-07 Tom Tromey <tromey@redhat.com>
3038
3039 * class.c (make_class_data): Set value for reflection_data field.
3040 * decl.c (java_init_decl_processing): Add reflection_data field.
3041
3042 2006-07-07 Tom Tromey <tromey@redhat.com>
3043
3044 * jcf-dump.c (HANDLE_ENCLOSINGMETHOD_ATTRIBUTE): Declare locals
3045 earlier.
3046 (HANDLE_SIGNATURE_ATTRIBUTE): Likewise.
3047
3048 2006-07-07 Andrew Haley <aph@redhat.com>
3049
3050 * jcf-parse.c (set_source_filename): Don't check for
3051 CLASS_FROM_CURRENTLY_COMPILED_P.
3052 Remove // comments.
3053
3054 2006-07-07 Andrew Haley <aph@redhat.com>
3055
3056 * java-tree.h (java_read_sourcefilenames): Declare.
3057 * lang.c (java_handle_option): Call java_read_sourcefilenames().
3058 * lang.opt (fsource-filename): New opt.
3059 * lang-specs.h: Add -fsource-filename.
3060 * jcf-parse.c (num_files, filenames): New variables.
3061 (reverse, cmpstringp, java_read_sourcefilenames,
3062 find_sourcefile): New.
3063 (set_source_filename): Call find_sourcefile to find the real name
3064 of a source file.
3065
3066 2006-06-27 Tom Tromey <tromey@redhat.com>
3067
3068 * jcf-reader.c (get_attribute): Handle EnclosingMethod,
3069 Signature, LocalVariableTypeTable, annotation attributes.
3070 * jcf-dump.c (HANDLE_ENCLOSINGMETHOD_ATTRIBUTE): New macro.
3071 (HANDLE_SIGNATURE_ATTRIBUTE): Likewise.
3072 (HANDLE_START_FIELD): Mention 'descriptor', not 'signature'.
3073 (HANDLE_METHOD): Likewise.
3074 (HANDLE_LOCALVARIABLETYPETABLE_ATTRIBUTE): New macro.
3075 (print_annotation): New function.
3076 (print_element_value): Likewise.
3077 (indent): Likewise.
3078 (HANDLE_RUNTIMEVISIBLEANNOTATIONS_ATTRIBUTE): New macro.
3079 (HANDLE_RUNTIMEINVISIBLEANNOTATIONS_ATTRIBUTE): Likewise.
3080 (print_parameter_annotations): New function.
3081 (HANDLE_RUNTIMEVISIBLEPARAMETERANNOTATIONS_ATTRIBUTE): New macro.
3082 (HANDLE_RUNTIMEINVISIBLEPARAMETERANNOTATIONS_ATTRIBUTE):
3083 Likewise.
3084 (HANDLE_ANNOTATIONDEFAULT_ATTRIBUTE): Likewise.
3085 (print_annotations): New function.
3086
3087 2006-06-23 Tom Tromey <tromey@redhat.com>
3088
3089 * lang-specs.h: Default -fsource and -ftarget to 1.5. If
3090 emitting class files, always use 1.5.
3091 * gcj.texi (Input Options): Document -fsource.
3092 (Code Generation): Document -ftarget.
3093
3094 2006-06-21 Tom Tromey <tromey@redhat.com>
3095
3096 PR java/28089:
3097 * expr.c (expand_java_field_op): Initialize field's declaring
3098 class.
3099
3100 2006-06-20 Tom Tromey <tromey@redhat.com>
3101
3102 * expr.c (push_value): Always flush quick stack.
3103
3104 2006-06-19 Tom Tromey <tromey@redhat.com>
3105
3106 * expr.c (push_value): Also flush quick stack if value is a
3107 component_ref.
3108
3109 2006-06-19 Tom Tromey <tromey@redhat.com>
3110
3111 * expr.c (push_value): Flush quick stack if value has side
3112 effects.
3113
3114 2006-06-13 Tom Tromey <tromey@redhat.com>
3115
3116 * class.c (is_compiled_class): Explicitly check for current
3117 class.
3118
3119 2006-06-09 Tom Tromey <tromey@redhat.com>
3120
3121 * gjavah.c (decompile_method): Don't decompile a static field
3122 accessor method.
3123
3124 2006-06-06 Tom Tromey <tromey@redhat.com>
3125
3126 * lang-specs.h <jc1>: Add .jar file to command line if
3127 -fsaw-java-file. Also, remove -ffilelist-file in this case.
3128
3129 2006-06-05 Tom Tromey <tromey@redhat.com>
3130
3131 * jcf-dump.c (print_access_flags): Handle varargs, bridge,
3132 synthetic, enum, annotation.
3133 * jcf.h (ACC_BRIDGE): New macro.
3134 (ACC_VARARGS): Likewise.
3135 (ACC_SYNTHETIC): Likewise.
3136 (ACC_ENUM): Likewise.
3137 (ACC_ANNOTATION): Likewise.
3138
3139 2006-06-04 Tom Tromey <tromey@redhat.com>
3140
3141 * lang.opt (-fsaw-java-file, -fsource, -ftarget): New options.
3142 * jvspec.c (jvgenmain_spec): Remove -fsaw-java-file, -fsource,
3143 and -ftarget.
3144 (lang_specific_driver): Removed dead code. Add -fsaw-java-file
3145 when needed. Handle classpath-setting.
3146 * Make-lang.in ($(GCJ)$(exeext)): Link in jcf-path.o.
3147 * lang-specs.h: Rewrote.
3148
3149 2006-06-04 Tom Tromey <tromey@redhat.com>
3150
3151 * jcf-io.c (find_class): Set source_ok to 0.
3152 * jcf-parse.c (jcf_parse): Disable gnu.gcj.gcj-compiled warning.
3153 (parse_class_file): Don't call java_mark_class_local.
3154 (java_parse_file): Skip .java files. Call java_mark_class_local
3155 before lowering any code.
3156 (parse_zip_file_entries): Don't call duplicate_class_warning
3157 here.
3158 (process_zip_dir): ... call it here.
3159 * class.c (add_field): Don't mark field external if it is being
3160 compiled into this object.
3161 (make_class_data): Handle situation where class_dtable_decl is
3162 created before Class is compiled.
3163 (is_compiled_class): Don't assume files in zip are compiled into
3164 this object.
3165 (layout_class_method): Don't mark method external if it is being
3166 compiled into this object.
3167
3168 2006-06-04 Tom Tromey <tromey@redhat.com>
3169
3170 * jcf-path.c (jcf_path_compute): New function.
3171 * jcf.h (jcf_path_compute): Declare.
3172
3173 2006-10-23 Rafael Ávila de Espíndola <rafael.espindola@gmail.com>
3174
3175 * decl.c: Include langhooks.h.
3176 (builtin_function): Remove.
3177 (java_init_decl_processing): Replace calls to builtin_function
3178 with add_builtin_function.
3179 * Make-lang.in (jc1$(exeext)): Depend on and link with attribs.o.
3180 (java/decl.o): Depend on langhooks.h.
3181 * java-tree.h (builtin_function): Remove.
3182
3183 2006-10-10 Brooks Moses <bmoses@stanford.edu>
3184
3185 * Make-lang.in: Added "java.pdf", "gcj.pdf" target support.
3186
3187 2006-09-12 Tom Tromey <tromey@redhat.com>
3188
3189 * expr.c (push_value): Always flush quick stack.
3190
3191 2006-09-12 Tom Tromey <tromey@redhat.com>
3192
3193 PR java/29013:
3194 * jcf-write.c (generate_bytecode_insns) <CALL_EXPR>: Always note
3195 the push of the called method's return result.
3196
3197 2006-09-12 Tom Tromey <tromey@redhat.com>
3198
3199 * jvspec.c (lang_specific_driver): Read spec file even if
3200 -fsyntax-only.
3201
3202 2006-09-12 Tom Tromey <tromey@redhat.com>
3203
3204 PR java/28754:
3205 * expr.c (expand_java_field_op): Initialize field's declaring
3206 interface if necessary.
3207
3208 2006-09-12 Tom Tromey <tromey@redhat.com>
3209
3210 PR java/28892:
3211 * expr.c (expand_java_field_op): No error for assignments not in
3212 class initializer or constructor.
3213
3214 2006-08-22 Andrew Haley <aph@redhat.com>
3215
3216 * decl.c (java_add_stmt): Give the statement list a type.
3217
3218 2006-08-16 Jakub Jelinek <jakub@redhat.com>
3219 Bryce McKinlay <bryce@mckinlay.net.nz>
3220
3221 * jvspec.c (lang_specific_driver): Add -s-bc-abi when needed.
3222
3223 2006-08-10 Simon Martin <simartin@users.sourceforge.net>
3224
3225 PR java/8923
3226 * parse.y (build_incdec): Emit an error instead of an ICE if '++'
3227 or '--' is used with a constant operand.
3228 (java_complete_lhs): When processing a '++' or '--' expression,
3229 don't call java_complete_tree but java_complete_lhs, so that a
3230 static final variable operand is never replaced by its value. This
3231 avoids an ICE later on.
3232 (patch_unaryop): Fixed typo in comment.
3233
3234 2006-07-28 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
3235
3236 * Make-lang.in: Use $(HEADER_H) instead of header.h in dependencies.
3237
3238 2006-07-12 Bryce McKinlay <mckinlay@redhat.com>
3239
3240 * builtins.c (check_for_builtin): If a builtin could result in a
3241 direct call being generated, don't use it if flag_indirect_dispatch
3242 is set.
3243
3244 2006-07-12 Bryce McKinlay <mckinlay@redhat.com>
3245
3246 * gcj.texi (Invocation): Corrections for Invocation API example.
3247
3248 2006-07-04 Andrew Haley <aph@redhat.com>
3249
3250 * class.c (build_fieldref_cache_entry): Set DECL_IGNORED_P on the
3251 entry.
3252
3253 2006-06-21 Andrew Haley <aph@redhat.com>
3254
3255 * java-tree.h (update_aliases): Remove
3256 * expr.c (expand_iinc): Remove call to update_aliases().
3257 (STORE_INTERNAL): Likewise.
3258 * decl.c (update_aliases, initialize_local_variable)
3259 (maybe_pushlevels): Set DECL_VALUE_EXPR for debugging decls.
3260
3261 2006-06-19 Andrew Haley <aph@redhat.com>
3262
3263 PR java/1305
3264 PR java/27908
3265 * expr.c (java_modify_addr_for_volatile): New function.
3266 (expand_java_field_op): Handle volatile fields.
3267 * java-gimplify.c (java_gimplify_component_ref): Call
3268 java_modify_addr_for_volatile to give the field_ref the correct
3269 volatile type.
3270 (java_gimplify_modify_expr): Likewise.
3271 * java-tree.h (java_modify_addr_for_volatile): New decl.
3272
3273 2006-06-17 Karl Berry <karl@gnu.org>
3274
3275 * gcj.texi (@dircategory): Use "Software development" instead
3276 of "Programming", following the Free Software Directory.
3277
3278 2006-06-16 Andrew Haley <aph@redhat.com>
3279
3280 * class.c (make_class_data): When using flag_indirect_classes,
3281 don't initialize the vtable of Class instances.
3282
3283 2006-06-09 Andrew Haley <aph@redhat.com>
3284
3285 PR java/1305
3286 PR java/27908
3287 * builtins.c (initialize_builtins): Add __sync_synchronize().
3288 * class.c (add_field): Mark volatile fields.
3289 * java-gimplify.c (java_gimplify_expr): Call new functions to
3290 handle self-modifying exprs and COMPONENT_REFs.
3291 (java_gimplify_component_ref): New.
3292 (java_gimplify_modify_expr): Add handling for volatiles.
3293
3294 2006-06-08 Tom Tromey <tromey@redhat.com>
3295
3296 * gcj.texi (libgcj Runtime Properties): Document
3297 gnu.gcj.user.realname.
3298
3299 2006-06-08 Andrew Haley <aph@redhat.com>
3300
3301 * expr.c (build_field_ref): Pass NULL_TREE as SPECIAL arg to
3302 get_symbol_table_index().
3303 (maybe_rewrite_invocation): Set SPECIAL if we need to access a
3304 private method.
3305 (build_known_method_ref): New arg: special. Pass it to
3306 get_symbol_table_index.
3307 (get_symbol_table_index): Put SPECIAL in the TREE_PURPOSE field of
3308 the method list.
3309 (build_invokevirtual): New arg: special. Pass it to
3310 get_symbol_table_index.
3311 (expand_invoke): New variable: special.
3312 Pass it to maybe_rewrite_invocation().
3313 Pass it to build_known_method_ref().
3314 * class.c (build_symbol_entry): Add new arg: special. Use it to
3315 build the symbol table conbstructor.
3316 (emit_symbol_table): Extract SPECIAL from the method list and pass
3317 it to build_symbol_entry().
3318 * parse.y (patch_invoke): Call maybe_rewrite_invocation() and set
3319 special accordingly.
3320
3321 2006-06-06 David Daney <ddaney@avtrex.com>
3322
3323 * gcj.texi (libgcj Runtime Properties): Document
3324 gnu.gcj.runtime.NameFinder.show_raw and
3325 gnu.gcj.runtime.NameFinder.remove_unknown.
3326
3327 2006-06-06 Tom Tromey <tromey@redhat.com>
3328
3329 * jcf-dump.c (print_access_flags): Handle varargs, bridge,
3330 synthetic, enum, annotation.
3331 * jcf.h (ACC_BRIDGE): New macro.
3332 (ACC_VARARGS): Likewise.
3333 (ACC_SYNTHETIC): Likewise.
3334 (ACC_ENUM): Likewise.
3335 (ACC_ANNOTATION): Likewise.
3336
3337 2006-06-06 Mike Stump <mrs@apple.com>
3338
3339 * Make-lang.in: Rename to htmldir to build_htmldir to avoid
3340 installing during build.
3341
3342 2006-05-31 Thomas Fitzsimmons <fitzsim@redhat.com>
3343
3344 * gcj.texi (Extensions): Document the new gcj-dbtool-based
3345 classname-to-library resolution mechanism.
3346 Declare the old gnu.gcj.runtime.VMClassLoader.library_control
3347 mechanism deprecated.
3348 (libgcj Runtime Properties): Document
3349 gnu.gcj.runtime.VMClassLoader.library_control's new default.
3350
3351 2006-05-29 Jakub Jelinek <jakub@redhat.com>
3352
3353 * javaop.h (int16, int32, int64): Define to exactly 16 (resp. 32, 64)
3354 bit wide type.
3355 (jword): Define to uint64 on 64-bit arches.
3356 * jcf-dump.c (print_constant): Cast JPOOL_UINT to long.
3357
3358 2006-05-28 Kazu Hirata <kazu@codesourcery.com>
3359
3360 * class.c, except.c, expr.c, java-gimplify.c: Fix comment
3361 typos.
3362
3363 2006-05-26 Tom Tromey <tromey@redhat.com>
3364
3365 * expr.c (java_push_constant_from_pool): Handle 'ldc class'.
3366 * verify-glue.c (vfy_class_type): New function.
3367 * verify-impl.c (check_constant): Allow 'ldc class'.
3368 * verify.h (vfy_class_type): Declare.
3369
3370 2006-05-25 Andrew Haley <aph@redhat.com>
3371
3372 PR java/27756
3373 * decl.c (maybe_pushlevels): When variable ranges are non-nested
3374 update all lifetimes, not just the first one.
3375
3376 2006-05-24 Tom Tromey <tromey@redhat.com>
3377
3378 * java-tree.h: Fixed flag documentation.
3379
3380 2006-05-24 Tom Tromey <tromey@redhat.com>
3381
3382 PR libgcj/27729:
3383 * jcf.h (ACC_INVISIBLE): Changed value.
3384
3385 2006-05-24 Andrew Haley <aph@redhat.com>
3386
3387 PR java/27754
3388 * decl.c (java_add_stmt): Use a STATEMENT_LIST rather than a
3389 COMPOUND_EXPR.
3390
3391 2006-05-16 H.J. Lu <hongjiu.lu@intel.com>
3392
3393 * lang.opt (femit-class-file): Remove VarExists.
3394
3395 2006-05-16 Tom Tromey <tromey@redhat.com>
3396
3397 * verify-impl.c (verify_instructions_0) <op_return>: Special case
3398 for Object.<init>.
3399
3400 2006-05-16 H.J. Lu <hongjiu.lu@intel.com>
3401
3402 PR driver/26885
3403 * Make-lang.in ($(GCJ)$(exeext)): Replace gcc.o with
3404 $(GCC_OBJS).
3405
3406 2006-05-14 H.J. Lu <hongjiu.lu@intel.com>
3407
3408 * Make-lang.in (java/decl.o): Add dependency on $(TARGET_H).
3409 (java/expr.o): Replace target.h with $(TARGET_H).
3410 (java/parse.o): Likewise.
3411
3412 2006-05-10 Andrew Haley <aph@redhat.com>
3413
3414 * class.c (emit_indirect_register_classes): Fix comment.
3415
3416 2006-05-04 Tom Tromey <tromey@redhat.com>
3417
3418 * java-tree.h (uses_jv_markobj_p): Declare.
3419 * class.c (uses_jv_markobj_p): Removed.
3420 * boehm.c (PROCEDURE_OBJECT_DESCRIPTOR): New define.
3421 (get_boehm_type_descriptor): Use it.
3422 (uses_jv_markobj_p): Moved from class.c. Return bool.
3423
3424 2006-05-04 Tom Tromey <tromey@redhat.com>
3425
3426 * java-tree.def (THIS_EXPR): Now a tcc_expression.
3427
3428 2006-05-04 Andrew Haley <aph@redhat.com>
3429
3430 * class.c (make_field_value): Always build_address_of fdecl if
3431 there is an initializer.
3432
3433 2006-05-03 Andrew Haley <aph@redhat.com>
3434
3435 PR libgcj/27352
3436 * expr.c (maybe_rewrite_invocation): New function.
3437 (rewrite_arglist_getclass): Likewise.
3438 (rules): New.
3439 (expand_invoke): Call maybe_rewrite_invocation.
3440 * parse.y (patch_invoke): Likewise.
3441 * java-tree.h: (maybe_rewrite_invocation): New function.
3442
3443 2006-04-21 Andrew Haley <aph@redhat.com>
3444
3445 * lang.c (java_init): Handle flag_indirect_classes.
3446 * jvgenmain.c: Use "class$$" instead of "class$".
3447 * mangle.c (java_mangle_decl): Accept RECORD_TYPEs sw well as
3448 DECLs.
3449 (mangle_class_field): Special case "class$$" as well as "class$".
3450 * constants.c (build_ref_from_constant_pool): If
3451 flag_indirect_classes, generate a ref into the heap.
3452 * decl.c (constants_field_decl_node,
3453 constants_data_field_decl_node): New.
3454 * class.c (build_static_class_ref): New.
3455 (build_classdollar_field): Factor out from build_class_ref().
3456 (make_field_value): Handle static fields in heap.
3457 (make_class_data): Make sure we get a static ref to class.
3458 Make class initializer const if flag_indirect_classes.
3459 (register_class): Build a class_ref for initialization if
3460 flag_indirect_classes.
3461 (emit_indirect_register_classes): New.
3462
3463 2006-04-08 Kazu Hirata <kazu@codesourcery.com>
3464
3465 * expr.c, gjavah.c: Fix comment typos.
3466
3467 2006-04-03 Andrew Haley <aph@redhat.com>
3468
3469 PR java/26858
3470 * expr.c (build_field_ref): Don't check the field offset if
3471 flag_syntax_only.
3472
3473 2006-03-30 Andrew Haley <aph@redhat.com>
3474
3475 PR java/26858
3476 * lang.c (java_attribute_table): New.
3477 (LANG_HOOKS_ATTRIBUTE_TABLE): Define.
3478 * expr.c (build_field_ref): Add a null pointer check for all
3479 fields of offset > 4k. Don't do so for accesses via the this
3480 pointer, which we know can never be null.
3481 * class.c (build_java_method_type): Mark arg 1 of all nonstatic
3482 methods nonnull.
3483
3484 2006-03-30 Carlos O'Donell <carlos@codesourcery.com>
3485
3486 * Make-lang.in: Rename docdir to gcc_docdir.
3487
3488 2006-03-30 Tom Tromey <tromey@redhat.com>
3489
3490 PR java/26042:
3491 * parse.y (java_reorder_fields): Reset superclass field's size as
3492 well.
3493
3494 2006-03-28 Tom Tromey <tromey@redhat.com>
3495
3496 PR java/26390:
3497 * parse.y (find_most_specific_methods_list): Added 'class'
3498 argument.
3499 (lookup_method_invoke): Updated.
3500
3501 2006-03-15 Tom Tromey <tromey@redhat.com>
3502
3503 * jcf-write.c (generate_bytecode_insns): Use qualifying type for
3504 non-static method calls.
3505
3506 2006-03-15 David Daney <ddaney@avtrex.com>
3507
3508 * java-tree.h : Moved comment for TYPE_DOT_CLASS adjacent to its
3509 declaration.
3510
3511 2006-03-15 David Daney <ddaney@avtrex.com>
3512
3513 * lang.opt (-freduced-reflection): New option.
3514 * lang.c (java_post_options): Generate an error if
3515 -freduced-reflection used with -fjni or -findirect-dispatch.
3516 * java-tree.h (flag_reduced_reflection): Declare new variable.
3517 * boehm.c (get_boehm_type_descriptor): Indicate all pointers
3518 if bitmap overflows and flag_reduced_reflection set.
3519 * class.c (uses_jv_markobj_p): New function.
3520 (make_class_data): Moved generation of vtable to before
3521 reflection data, generate less reflection data if
3522 flag_reduced_reflection set.
3523 * gcj.texi: Document -freduced-reflection.
3524
3525 2006-03-15 Tom Tromey <tromey@redhat.com>
3526
3527 PR java/26638:
3528 * class.c (get_interface_method_index): Don't put <clinit> into
3529 interface table.
3530
3531 2006-03-15 Tom Tromey <tromey@redhat.com>
3532
3533 * parse.y (analyze_clinit_body): Ignore empty statements.
3534
3535 2006-03-08 David Daney <ddaney@avtrex.com>
3536
3537 * gcj.texi: Document -static-libgcj option.
3538
3539 2006-02-20 Andrew Haley <aph@redhat.com>
3540
3541 * jcf-parse.c (parse_class_file): Set input_location from
3542 current_class.
3543
3544 2006-02-15 Andrew Haley <aph@redhat.com>
3545
3546 * class.c (GEN_TABLE): Don't pushdecl *_SYMS_DECL here.
3547 (make_class_data): pushdecl_top_level TYPE_OTABLE_SYMS_DECL,
3548 TYPE_ATABLE_SYMS_DECL, TYPE_ITABLE_SYMS_DECL here.
3549
3550 2006-02-09 Andrew Haley <aph@redhat.com>
3551
3552 PR java/26192
3553 * expr.c (expand_invoke): Allow methods in arrays to be resolved
3554 in their superclass.
3555
3556 * typeck.c (build_java_array_type): Generate TYPE_STUB_DECLs for
3557 array types.
3558
3559 2006-02-08 Tom Tromey <tromey@redhat.com>
3560
3561 PR java/22578:
3562 * check-init.c (check_init): Handle VIEW_CONVERT_EXPR.
3563 * builtins.c (convert_real): New function.
3564 (java_builtins): Handle Float.intBitsToFloat,
3565 Float.floatToRawIntBits, Double.longBitsToDouble,
3566 Double.doubleToRawLongBits.
3567
3568 2006-02-07 Andrew Haley <aph@redhat.com>
3569
3570 * expr.c (expand_invoke): (BC mode.) If we find a method in a
3571 class other than the one in which we expected to find it, ignore
3572 the result.
3573
3574 PR java/25535
3575 * constants.c (build_constants_constructor): move initializer into
3576 first halfword on a 64-bit big-endian machine.
3577
3578 2006-02-04 Tom Tromey <tromey@redhat.com>
3579
3580 PR java/25676:
3581 * builtins.c (max_builtin): Skip floating point 'max'.
3582 (min_builtin): Skip floating point 'min'.
3583 (check_for_builtin): Never return NULL_TREE.
3584
3585 2006-02-04 Tom Tromey <tromey@redhat.com>
3586
3587 PR java/26097:
3588 * expr.c (push_type): Avoid side effect in gcc_assert.
3589
3590 2006-02-04 Roger Sayle <roger@eyesopen.com>
3591
3592 * decl.c (java_init_decl_processing): Create char_type_node as a
3593 regular INTEGER_TYPE node.
3594 (push_promoted_type): Preserve TYPE_STRING_FLAG on types.
3595 * typeck.c (convert): No longer check for CHAR_TYPEs but instead
3596 test for char_type_node and promoted_char_type_node as special
3597 instances of INTEGER_TYPE tree codes.
3598 (promote_type,build_java_signature): Likewise.
3599 * jcf-write.c (adjust_typed_op): Likewise.
3600 * mangle.c (mangle_type): Likewise.
3601 * parse.y (do_unary_numeric_promotion): No longer handle CHAR_TYPE.
3602 * parse.h (JINTEGRAL_TYPE_P): Likewise.
3603
3604 2006-02-04 Andreas Tobler <a.tobler@schweiz.ch>
3605
3606 * expr.c (java_stack_swap): Revert gcc_assert patch.
3607
3608 2006-02-03 Ben Elliston <bje@au.ibm.com>
3609
3610 * java-gimplify.c: Use gcc_assert and gcc_unreachable throughout.
3611 * typeck.c: Likewise.
3612 * verify-impl.c: Likewise.
3613 * class.c: Likewise.
3614 * decl.c: Likewise.
3615 * jcf-parse.c: Likewise.
3616 * constants.c: Likewise.
3617 * check-init.c: Likewise.
3618 * jcf-write.c: Likewise.
3619 * verify-glue.c: Likewise.
3620 * mangle.c: Likewise.
3621 * expr.c: Likewise.
3622 * lang.c: Likewise.
3623 * boehm.c: Likewise.
3624
3625 2006-02-01 Jan Hubicka <jh@suse.cz>
3626
3627 * decl.c (end_java_method): Kill hack disabling unit-at-a-time.
3628 * lang.c (java_init_options): Set no_unit_at_a_time_default.
3629
3630 2006-01-30 Andrew Haley <aph@redhat.com>
3631
3632 PR java/21428
3633 * parse.y: (source_start_java_method): Mark DECL_ARTIFICIAL("this").
3634
3635 2006-01-21 Joseph S. Myers <joseph@codesourcery.com>
3636
3637 * jv-scan.c (version), jcf-dump.c (version), gjavah.c (version):
3638 Update copyright notice dates.
3639
3640 2006-01-16 Rafael Ávila de Espíndola <rafael.espindola@gmail.com>
3641
3642 * jvspec.c (lang_specific_spec_functions): Remove.
3643
3644 2006-01-06 Tom Tromey <tromey@redhat.com>
3645
3646 * gcj.texi (Arrays): Added more documentation for
3647 JvNewObjectArray.
3648 (Primitive types): Correct information about primitive classes.
3649 (Reference types): New node.
3650 (Index): New node.
3651
3652 2005-12-16 Alexandre Oliva <aoliva@redhat.com>
3653
3654 * jcf-parse.c (set_source_filename): Set the decl source location
3655 even when returning early.
3656
3657 2005-12-15 Tom Tromey <tromey@redhat.com>
3658 Andrew Haley <aph@redhat.com>
3659
3660 PR java/25429
3661 * parse.y (resolve_expression_name): Don't generate accessor
3662 methods for constant fields.
3663
3664 2005-12-13 Andrew Haley <aph@redhat.com>
3665
3666 PR java/25366
3667 PR java/25368
3668 * class.c (maybe_layout_super_class): Update current_class before
3669 calling do_resolve_class.
3670
3671 2005-12-12 H.J. Lu <hongjiu.lu@intel.com>
3672
3673 PR java/25330
3674 * jcf-write.c (write_classfile): Use PID in temporary class
3675 file. Save/restore errno when reporting error.
3676
3677 2005-12-10 Terry Laurenzo <tlaurenzo@gmail.com>
3678
3679 PR java/9861
3680 * mangle.c (mangle_method_decl): Mangle Java methods by prepending 'J'
3681 to bare_function_type and including the return type
3682 * builtins.c (initialize_builtins) : Change builtin mangled name
3683 constants to conform to new mangling scheme
3684
3685 2005-12-08 Andrew Haley <aph@redhat.com>
3686
3687 PR libgcj/25265
3688 * java-tree.h (enum java_tree_index): Add JTI_SOFT_NOSUCHFIELD_NODE.
3689 (soft_abstractmethod_node): New.
3690 * expr.c (build_field_ref): Add in-line check for missing field.
3691 * decl.c (java_init_decl_processing): Add soft_nosuchfield_node.
3692
3693 2005-12-07 Rafael Ávila de Espíndola <rafael.espindola@gmail.com>
3694
3695 * Make-lang.in (java.all.build, java.install-normal): Remove.
3696
3697 2005-12-07 Rafael Ávila de Espíndola <rafael.espindola@gmail.com>
3698
3699 * Make-lang.in: Remove all dependencies on s-gtype, except for
3700 gt-java-parse.h.
3701
3702 2005-12-07 Richard Sandiford <richard@codesourcery.com>
3703
3704 * class.c (build_utf8_ref, emit_register_classes): Use
3705 switch_to_section and get_section.
3706
3707 2005-12-06 Tom Tromey <tromey@redhat.com>
3708
3709 PR java/25283:
3710 * parse.y (patch_new_array_init): Revert previous patch.
3711 (lookup_method_invoke): Use size-less array type when creating an
3712 anonymous constructor.
3713
3714 2005-12-05 Tom Tromey <tromey@redhat.com>
3715
3716 * parse.y (patch_new_array_init): Don't set length on array.
3717
3718 2005-12-02 Richard Guenther <rguenther@suse.de>
3719
3720 * java-gimplify.c (java_gimplify_labeled_block_expr): Use
3721 buildN instead of build.
3722 * class.c (finish_class): Likewise.
3723 * expr.c (java_create_object): Likewise.
3724
3725 2005-11-28 Tom Tromey <tromey@redhat.com>
3726
3727 PR java/18278:
3728 * expr.c (build_jni_stub): Unwrap the return value.
3729 * java-tree.h (soft_unwrapjni_node): New define.
3730 (enum java_tree_index): Added JTI_SOFT_UNWRAPJNI_NODE.
3731 * decl.c (java_init_decl_processing): Initialize
3732 soft_unwrapjni_node.
3733
3734 2005-11-24 Bryce McKinlay <mckinlay@redhat.com>
3735
3736 * gcj.texi (gij options): Add -Xss documentation.
3737
3738 2005-11-08 Wil Mahan <wmahan@gmail.com>
3739
3740 PR java/23617
3741 * zextract.c (read_zip_archive): Fix out of memory error when
3742 reading jar files with zip-style comments.
3743
3744 2005-11-07 Terry Laurenzo <tlaurenzo@gmail.com>
3745
3746 * gjavah.c (HANDLE_CODE_ATTRIBUTE): Only define for ELF Object
3747 formats.
3748 * gjavah.c (decompile_method): Add ATTRIBUTE_UNUSED
3749
3750 2005-10-12 Nathan Sidwell <nathan@codesourcery.com>
3751 Wil Mahan <wmahan@gmail.com>
3752
3753 PR java/23620
3754 * class.c (make_class): Create empty binfo here.
3755 (set_super_info): Only create binfo if we have superclasses.
3756
3757 2005-10-03 Ranjit Mathew <rmathew@gcc.gnu.org>
3758
3759 PR java/24127
3760 * parse.y (method_header): Make the result of the rule a NULL_TREE
3761 when a parsing error occurs.
3762
3763 2005-09-29 Tom Tromey <tromey@redhat.com>
3764
3765 PR java/24120:
3766 * jcf-io.c (memoized_dirlist_hash): New function.
3767 (caching_stat): Use it.
3768
3769 2005-09-21 Ranjit Mathew <rmathew@gcc.gnu.org>
3770
3771 PR java/21418
3772 * class.c (inherits_from_p): Try to lay out super class
3773 if it is not already laid out.
3774 (maybe_layout_super_class): Handle the case where SUPER_CLASS
3775 is a NULL_TREE.
3776
3777 2005-09-18 James A. Morrison <phython@gcc.gnu.org>
3778
3779 * builtins.c (max_builtin, min_builtin, abs_builtin,
3780 java_build_function_call_expr): Use fold_buildN.
3781 * class.c (layout_class_method): Likewise.
3782 * expr.c (java_truthvalue_conversion, build_java_jsr,
3783 build_java_arrayaccess, expand_java_arrayload, expand_iinc,
3784 build_java_binop, build_field_ref, expand_compare,
3785 build_known_method_ref, build_invokevirtual,
3786 process_jvm_instruction): Likewise.
3787 * parse.y (patch_binop, patch_exit_expr): Likewise.
3788 * typeck.c (convert_ieee_real_to_integer): Likewise.
3789 (convert): Don't call fold after convert_ieee_real_to_integer.
3790
3791 2005-09-14 Bryce McKinlay <mckinlay@redhat.com>
3792
3793 PR java/23891
3794 * parse.y (maybe_create_class_interface_decl): Set TYPE_PACKAGE for
3795 the newly created type. Set import lists here, not in create_class.
3796 (jdep_resolve_class): Set current_class.
3797 (do_resolve_class): Use current_class's TYPE_PACKAGE to determine
3798 the current package context, not ctxp->package.
3799 (cicp_cache): Removed.
3800 (class_in_current_package): Simplify implementation using TYPE_PACKAGE.
3801 * jcf-parse.c (give_name_to_class): Set TYPE_PACKAGE.
3802 * java-tree.h (TYPE_PACKAGE): New macro.
3803 (struct lang_type): New member 'package'.
3804
3805 2005-09-09 Andrew Haley <aph@redhat.com>
3806
3807 PR libgcj/23182
3808 * expr.c (pop_type_0): If the expected type is object or ptr
3809 (i.e. void*), return the type of the object we just popped from
3810 the stack.
3811
3812 2005-09-06 Andrew Pinski <pinskia@physics.uc.edu>
3813
3814 * java-gimplify.c (java_gimplify_block): NULL out the old BLOCK's
3815 BLOCK_EXPR_BODY before returning the new BIND_EXPR.
3816
3817 2005-09-06 Kazu Hirata <kazu@codesourcery.com>
3818
3819 * check-init.c, decl.c, expr.c, gcj.texi, java-tree.h,
3820 jcf-parse.c, jcf.h, parse.h, parse.y, typeck.c: Fix comment
3821 typos. Follow spelling conventions.
3822
3823 2005-09-05 Ranjit Mathew <rmathew@hotmail.com>
3824
3825 PR java/23431
3826 * typeck.c (lookup_do): Look up interfaces for the original class,
3827 not the base class.
3828 * parse.y (java_check_regular_methods): Fix diagnostic message for
3829 more restrictive overriding of a method from an interface.
3830
3831 2005-08-16 Tom Tromey <tromey@redhat.com>
3832
3833 * class.c (make_class_data): Always emit JV_STATE_PRELOADING for
3834 class' initial state.
3835
3836 2005-08-16 Ranjit Mathew <rmathew@hotmail.com>
3837
3838 PR java/22113
3839 * lex.c (do_java_lex): Define MAX_TOKEN_LEN. Avoid overflowing
3840 `literal_token' for large numeric input tokens.
3841
3842 2005-08-16 Ranjit Mathew <rmathew@hotmail.com>
3843
3844 PR java/19870
3845 * parse.y (nested_field_access_p): Rename to nested_member_access_p
3846 and expand to handle method accesses across nested classes.
3847 (build_outer_method_access_method): Rename to
3848 build_nested_method_access_method. Minor adjustments to comments.
3849 (resolve_expression_name): Use the newly-renamed
3850 nested_member_access_p method.
3851 (resolve_qualified_expression_name): Likewise.
3852 (patch_method_invocation): Also consider static methods for access
3853 method generation. Minor adjustments to comments.
3854 (maybe_use_access_method): Use the more general
3855 nested_memeber_access_p to determine access across nested class
3856 boundaries. Allow THIS_ARG to be NULL (for static methods).
3857
3858 2005-08-15 Tom Tromey <tromey@redhat.com>
3859
3860 PR java/23300.
3861 * expr.c (build_field_ref): Don't generate otable reference when
3862 DECL_FIELD_OFFSET is 0.
3863 * class.c (maybe_layout_super_class): Pass outer class to
3864 do_resolve_class.
3865
3866 2005-08-15 Tom Tromey <tromey@redhat.com>
3867
3868 * java-tree.h (LABEL_IN_SUBR): Removed.
3869 (LABEL_IN_SUBR): Likewise.
3870 (LABEL_IS_SUBR_START): Likewise.
3871 (LABEL_SUBR_START): Likewise.
3872 (LABEL_SUBR_CONTEXT): Likewise.
3873 (LABEL_CHANGED): Likewise.
3874 (LABEL_RETURN_LABEL): Likewise.
3875 (LABEL_RETURN_TYPE_STATE): Likewise.
3876 (LABEL_RETURN_LABELS): Likewise.
3877 (RETURN_MAP_ADJUSTED): Likewise.
3878 (LABEL_PENDING_CHAIN): Likewise.
3879
3880 2005-08-15 Tom Tromey <tromey@redhat.com>
3881
3882 * Make-lang.in (JAVA_OBJS): Removed verify.o
3883 (java/verify.o): Removed.
3884 * verify.c: Removed.
3885 * lang.c (flag_new_verifier): Removed.
3886 (java_post_options): Updated.
3887 * java-tree.h (flag_new_verifier): Removed.
3888 (verify_jvm_instructions): Removed.
3889 * expr.c (pop_type_0): Assume flag_new_verifier is true.
3890 (build_java_check_indexed_type): Likewise.
3891 (expand_java_arraystore): Likewise.
3892 (expand_java_arrayload): Likewise.
3893 (pop_arguments): Likewise.
3894 (expand_byte_code): Likewise.
3895 (process_jvm_instruction): Likewise.
3896
3897 2005-08-10 Andrew Haley <aph@redhat.com>
3898
3899 * java-gimplify.c (java_gimplify_modify_expr): Fix any pointer
3900 type mismatches to make legal GIMPLE.
3901
3902 2005-08-10 Robin Green <greenrd@greenrd.org>
3903
3904 PR java/23230:
3905 * parse.y (maybe_use_access_method): Generalize check from
3906 java.lang.Object to any superclass of current_class
3907
3908 2005-08-08 Nathan Sidwell <nathan@codesourcery.com>
3909
3910 * class.c (build_class_ref): Wrap the primary class type in a
3911 NOP_EXPR.
3912 * parse.y (java_complete_lhs) <COMPONENT_REF case>: Extract the
3913 primary class type from the NOP_EXPR in which it was placed.
3914
3915 2005-07-28 Diego Novillo <dnovillo@redhat.com>
3916
3917 * expr.c (expand_load_internal): Fix missing parens in
3918 predicate.
3919
3920 2005-07-28 Andrew Haley <aph@redhat.com>
3921
3922 * expr.c (expand_load_internal): Convert to destination type.
3923
3924 2005-07-22 Manfred Hollstein <mh@suse.com>
3925
3926 * verify-impl.c (check_class_constant): Fix uninitialised warnings.
3927 (check_constant): Likewise.
3928 (check_wide_constant): Likewise.
3929
3930 2005-07-20 Giovanni Bajo <giovannibajo@libero.it>
3931
3932 Make CONSTRUCTOR use VEC to store initializers.
3933 * check-init.c (check_init): Update to cope with VEC in
3934 CONSTRUCTOR_ELTS.
3935 * class.c (make_field_value, make_method_value, get_dispatch_table,
3936 make_class_data, emit_symbol_table, emit_catch_table,
3937 emit_assertion_table): Use build_constructor_from_list instead of
3938 build_constructor.
3939 * constants.c (build_constants_constructor): Likewise.
3940 * java-gimplify.c (java_gimplify_new_array_init): Update to cope with
3941 VEC in CONSTRUCTOR_ELTS.
3942 * java-tree.h (START_RECORD_CONSTRUCTOR, PUSH_SUPER_VALUE,
3943 PUSH_FIELD_VALUE, FINISH_RECORD_CONSTRUCTOR): Create a VEC instead
3944 of a TREE_LIST.
3945 * jcf-write.c (generate_bytecode_insns): Update to cope with VEC in
3946 CONSTRUCTOR_ELTS.
3947 * parse.y (build_new_array_init): Use build_constructor_from_list
3948 instead of build_constructor.
3949 (patch_new_array_init): Update to cope with VEC in
3950 CONSTRUCTOR_ELTS.
3951 (array_constructor_check_entry): Likewise.
3952
3953 2005-07-12 Tom Tromey <tromey@redhat.com>
3954
3955 * jvspec.c (lang_specific_driver): Put filelist_filename first on
3956 command line.
3957
3958 2005-07-12 Tom Tromey <tromey@redhat.com>
3959
3960 PR java/19674:
3961 * parse-scan.y (interface_member_declaration): Added
3962 empty_statement.
3963
3964 2005-07-08 Daniel Berlin <dberlin@dberlin.org>
3965
3966 * java-tree.h (LABEL_RETURN_LABELS): Use decl_non_common.
3967 (LABEL_PENDING_CHAIN): Ditto.
3968 (LABEL_PC): Ditto.
3969 (DECL_BIT_INDEX): Ditto.
3970
3971 2005-07-07 Bryce McKinlay <mckinlay@redhat.com>
3972
3973 PR java/18119
3974 * parse.y (inner_class_accessible): New function. Logic moved from
3975 check_inner_class_access.
3976 (check_inner_class_access): Use inner_class_accessible.
3977 (resolve_inner_class): Simplify arguments. Create circularity hash
3978 here. Keep looking for classes if we found one that was inaccessible.
3979 Return the inaccessible class only if there is no other match.
3980 (do_resolve_class): Update for new resolve_inner_class arguments.
3981 Don't create circularity_hash here.
3982
3983 2005-07-07 Bryce McKinlay <mckinlay@redhat.com>
3984
3985 PR java/21045
3986 * parse.y (add_exception_to_throws): New function.
3987 (purge_unchecked_exceptions): Removed.
3988 (get_constructor_super): Renamed from verify_constructor_super. Now
3989 returns the super constructor after verification.
3990 (java_complete_expand_method): Don't use purge_unchecked_exceptions
3991 or save/restore the exception list.
3992 (check_thrown_exceptions): Add uncaught exceptions in anonymous
3993 class initializers and constructors to the throws clause of the method.
3994
3995 2005-07-05 Bryce McKinlay <mckinlay@redhat.com>
3996
3997 PR java/19674
3998 * parse.y (interface_member_declaration): Allow empty statements in
3999 interface declarations.
4000
4001 2005-07-05 Paolo Bonzini <bonzini@gnu.org>
4002
4003 * Makefile.in (parse.o): Adjust dependencies.
4004 * parse.y: Include tree-dump.h.
4005
4006 2005-07-02 Joseph S. Myers <joseph@codesourcery.com>
4007
4008 * class.c, decl.c, expr.c: Use '+' flag instead of %J. Use 'q'
4009 flag for quoting.
4010
4011 2005-07-01 Andrew Pinski <pinskia@physics.uc.edu>
4012
4013 * parse.y (issue_warning_error_from_context): Call
4014 pp_output_formatted_text to be able to get the buffer.
4015
4016 2005-06-30 Andrew Pinski <pinskia@physics.uc.edu>
4017
4018 * parse.y (issue_warning_error_from_context): Update for the
4019 renaming of pp_format_text to pp_format.
4020
4021 2005-06-28 Paul Brook <paul@codesourcery.com>
4022
4023 * decl.c (java_init_decl_processing): Call
4024 default_init_unwind_resume_libfunc.
4025
4026 2005-06-27 Tom Tromey <tromey@redhat.com>
4027
4028 PR java/21540, PR java/13788:
4029 * parse.y (java_complete_lhs) <CASE_EXPR>: Use
4030 fold_constant_for_init.
4031 (patch_binop): Added 'folding' argument. Updated all callers.
4032 (patch_unaryop) <NOP_EXPR>: New case.
4033 (fold_constant_for_init) <NOP_EXPR>: Likewise.
4034 (fold_constant_for_init) <COND_EXPR>: Fix sense of test.
4035
4036 2005-06-25 Jan Hubicka <jh@suse.cz>
4037
4038 * builtins.c (define_builtin): Accept new flags parameter.
4039 (initialize_builtins): Mark the builtins const and nothrow accordingly.
4040
4041 2005-06-25 Kelley Cook <kcook@gcc.gnu.org>
4042
4043 * all files: Update FSF address in copyright headers.
4044
4045 2005-06-24 Tom Tromey <tromey@redhat.com>
4046
4047 * verify-impl.c (verify_instructions_0): Correctly handle
4048 situation where PC falls off end.
4049
4050 2005-06-23 Bryce McKinlay <mckinlay@redhat.com>
4051
4052 PR java/20697
4053 * parse.y (find_most_specific_methods_list): Remove special case for
4054 inner classes.
4055
4056 2005-06-15 Tom Tromey <tromey@redhat.com>
4057
4058 PR libgcj/21906:
4059 * class.c (make_method_value): Use soft_abstractmethod_node for
4060 abstract method.
4061 * java-tree.h (soft_abstractmethod_node): New define.
4062 (JTI_SOFT_ABSTRACTMETHOD_NODE): New enum constant.
4063 * decl.c (java_init_decl_processing): Initialize
4064 soft_abstractmethod_node.
4065
4066 2005-06-13 Geoffrey Keating <geoffk@apple.com>
4067
4068 * Make-lang.in (rule for installing gcj.1): Depends on installdirs.
4069
4070 2005-06-13 Per Bothner <per@bothner.com>
4071
4072 * expr.c (int highest_label_pc_this_method,
4073 start_label_pc_this_method): New globals.
4074 (lookup_label): Add start_label_pc_this_method to pc for label, and
4075 update highest_label_pc_this_method. This prevents conflicts between
4076 labels from different methods.
4077 * java-tree.h: Declare new globals.
4078 * jcf-parse.c (parse_class_file): If needed bump
4079 start_label_pc_this_method and reset highest_label_pc_this_method.
4080
4081 2005-06-13 Tom Tromey <tromey@redhat.com>
4082
4083 PR java/21844:
4084 * parse.y (nested_field_access_p): Handle case where outer field
4085 is inherited by enclosing class.
4086
4087 2005-06-12 Per Bothner <per@bothner.com>
4088
4089 * class.c (inherits_from_p): Do load_class if needed.
4090
4091 2005-06-09 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4092
4093 * gjavah.c (error): Add ATTRIBUTE_PRINTF_1.
4094 * java-tree.h (parse_error_context): Move...
4095 * parse.h (parse_error_context): ... here, add ATTRIBUTE_GCC_DIAG.
4096 * parse.y (parse_warning_context): Add ATTRIBUTE_GCC_DIAG.
4097 * verify-impl.c (debug_print): Add ATTRIBUTE_PRINTF_1.
4098
4099 2005-06-08 Roger Sayle <roger@eyesopen.com>
4100
4101 * typeck.c (convert): Only clear TREE_OVERFLOW on INTEGER_CST nodes.
4102
4103 2005-06-06 Jakub Jelinek <jakub@redhat.com>
4104
4105 * jv-scan.c (fatal_error, warning, warning0): Use gmsgid instead of
4106 msgid for argument name.
4107 * gjavah.c (error): Likewise.
4108 * java-tree.h (parse_error_context): Likewise.
4109 * parse.y (parse_error_context, parse_warning_context,
4110 issue_warning_error_from_context): Likewise.
4111
4112 2005-06-01 Tom Tromey <tromey@redhat.com>
4113
4114 PR java/21722:
4115 * class.c (build_static_field_ref): Don't fold constant fields if
4116 current class is from a .class file and we're using indirect
4117 dispatch.
4118
4119 2005-05-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4120
4121 * java/verify-glue.c: Don't include errors.h and include toplev.h.
4122 * java/Make-lang.in: Updates dependencies.
4123
4124 2005-05-26 Ranjit Mathew <rmathew@hotmail.com>
4125
4126 PR java/19870.
4127 * java-tree.h (OUTER_FIELD_ACCESS_IDENTIFIER_P): Rename to
4128 NESTED_FIELD_ACCESS_IDENTIFIER_P.
4129 (FIELD_INNER_ACCESS): Rename to FIELD_NESTED_ACCESS.
4130 (FIELD_INNER_ACCESS_P): Rename to FIELD_NESTED_ACCESS_P.
4131 * jcf-write.c (generate_classfile): Use
4132 NESTED_FIELD_ACCESS_IDENTIFIER_P instead of
4133 OUTER_FIELD_ACCESS_IDENTIFIER_P.
4134 * parse.y (build_outer_field_access): Rename to
4135 build_nested_field_access. Support static fields and outer-to-inner
4136 class accesses.
4137 (outer_field_access_p): Rename to nested_field_access_p. Support
4138 static fields and generalise to outer-to-inner class and sibling
4139 inner class accesses.
4140 (outer_field_expanded_access_p): Rename to
4141 nested_field_expanded_access_p and support static fields.
4142 (outer_field_access_fix): Rename to nested_field_access_fix and
4143 support static fields.
4144 (build_outer_field_access_expr): Rename to
4145 build_nested_field_access_expr and support static fields.
4146 (build_outer_field_access_methods): Rename to
4147 build_nested_field_access_methods and support static fields. For
4148 static fields, generate accessors without class instance parameters.
4149 (build_outer_field_access_method): Rename to
4150 build_nested_field_access_method and support static fields.
4151 (build_outer_method_access_method): Use
4152 NESTED_FIELD_ACCESS_IDENTIFIER_P instead of
4153 OUTER_FIELD_ACCESS_IDENTIFIER_P.
4154 (resolve_expression_name): Consider static field accesses across
4155 nested classes.
4156 (resolve_qualified_expression_name): Likewise.
4157 (java_complete_lhs): Use nested_field_access_fix instead of
4158 outer_field_access_fix.
4159 (patch_unary_op): Rename outer_field_flag to nested_field_flag.
4160 Use nested_field_expanded_access_p instead of
4161 outer_field_expanded_access_p. Use nested_field_access_fix instead
4162 of outer_field_access_fix.
4163 (check_thrown_exceptions): Use NESTED_FIELD_ACCESS_IDENTIFIER_P
4164 instead of OUTER_FIELD_ACCESS_IDENTIFIER_P.
4165
4166 2005-05-26 Bryce McKinlay <mckinlay@redhat.com>
4167
4168 * decl.c (GCJ_BINARYCOMPAT_ADDITION,
4169 GCJ_BOOTSTRAP_LOADER_ADDITION): Removed.
4170 (FLAG_BINARYCOMPAT_ABI, FLAG_BOOTSTRAP_LOADER,
4171 MINOR_BINARYCOMPAT_ABI_VERSION): New.
4172 (GCJ_CURRENT_BC_ABI_VERSION): Use new method to calculate version ID.
4173 (parse_version): Calculate version ID using new method. Use bit-flags
4174 for flag_indirect_dispatch and flag_bootstrap_classes.
4175
4176 2005-05-25 Richard Henderson <rth@redhat.com>
4177
4178 PR libgcj/21692
4179 * Make-lang.in (java/mangle.o): Depend on LANGHOOKS_DEF_H.
4180 * class.c (build_class_ref): Set DECL_CLASS_FIELD_P and
4181 DECL_CONTEXT; avoid pushdecl_top_level.
4182 (build_dtable_decl): Set DECL_VTABLE_P and DECL_CONTEXT.
4183 (layout_class): Don't SET_DECL_ASSEMBLER_NAME.
4184 (layout_class_method): Likewise.
4185 * decl.c (java_mark_cni_decl_local): New.
4186 (java_mark_class_local): Use it.
4187 * java-tree.h (DECL_LOCAL_CNI_METHOD_P): New.
4188 (DECL_CLASS_FIELD_P, DECL_VTABLE_P): New.
4189 (struct lang_decl_func): Add local_cni;
4190 (struct lang_decl_var): Add class_field, vtable.
4191 (java_mangle_decl): Declare.
4192 * lang.c (LANG_HOOKS_SET_DECL_ASSEMBLER_NAME): New.
4193 * mangle.c: Remove dup obstack.h; include langhooks-def.h.
4194 (mangle_obstack_1): New.
4195 (java_mangle_decl): Remove obstack argument. Call mangle_class_field,
4196 mangle_vtable, and mangle_local_cni_method_decl. Fall back to
4197 lhd_set_decl_assembler_name for things that don't need mangling.
4198 (mangle_class_field): Rename from java_mangle_class_field, make
4199 static, don't call init_mangling or finish_mangling.
4200 (mangle_vtable): Similarly.
4201 (mangle_local_cni_method_decl): New.
4202 (init_mangling): Remove obstack argument. Use &mangle_obstack_1,
4203 gcc_assert, and MANGLE_RAW_STRING.
4204 (finish_mangling): Use gcc_assert, remove if 0 debugging code.
4205
4206 2005-05-25 DJ Delorie <dj@redhat.com>
4207
4208 * class.c (set_constant_value): Move warning control from if() to
4209 warning(OPT_*).
4210
4211 2005-05-24 Richard Henderson <rth@redhat.com>
4212
4213 * builtins.c (define_builtin): Don't call make_decl_rtl.
4214 * constants.c (build_constant_data_ref): Likewise.
4215 * class.c (build_utf8_ref): Likewise.
4216 (build_fieldref_cache_entry, build_static_field_ref): Likewise.
4217 (get_dispatch_table, layout_class_method): Likewise.
4218 (build_class_ref): Likewise. Don't set DECL_SIZE or DECL_SIZE_UNIT
4219 by hand.
4220 (make_local_function_alias): Don't SET_DECL_ASSEMBLER_NAME.
4221 (make_method_value): Use METHOD_ABSTRACT instead of DECL_RTL_SET_P
4222 to determine if we need a non-zero address.
4223 * decl.c (builtin_function): Don't call make_decl_rtl.
4224 (give_name_to_locals): Don't SET_DECL_ASSEMBLER_NAME.
4225 * expr.c (build_known_method_ref): Don't call make_decl_rtl.
4226 * resource.c (compile_resource_data): Likewise.
4227 * parse.y (resolve_field_access): Re-word comment to avoid
4228 building DECL_RTL.
4229
4230 2005-05-24 Richard Henderson <rth@redhat.com>
4231
4232 * class.c (registered_class): Take it out of class_roots; turn into
4233 a vec of trees.
4234 (register_class): Make static. Don't duplicate decl node. Use
4235 VEC_safe_push.
4236 (emit_register_classes): Use VEC_iterate. Use output_constant
4237 instead of assemble_integer. Don't call mark_decl_referenced
4238 directly.
4239 * java-tree.h (register_class): Remove decl.
4240
4241 2005-05-19 Paolo Bonzini <bonzini@gnu.org>
4242
4243 PR java/17845
4244
4245 * parse.y (register_package, package_list): Remove.
4246 (package_declaration): Do not call register_package.
4247 (do_resolve_class): Do not use package_list.
4248
4249 2005-05-15 Gerald Pfeifer <gerald@pfeifer.com>
4250
4251 * jcf-write.c (generate_bytecode_insns) <SAVE_EXPR>: Remove
4252 unused variable.
4253
4254 2005-05-15 Tom Tromey <tromey@redhat.com>
4255
4256 PR java/21519:
4257 * jcf-write.c (generate_bytecode_insns) <SAVE_EXPR>: Don't call
4258 NOTE_PUSH.
4259
4260 2005-05-12 Aaron Luchko <aluchko@redhat.com>
4261
4262 * gcj.texi: Add '-verify', '-noverify', and '-verifyremote'.
4263
4264 2005-05-11 Tom Tromey <tromey@redhat.com>
4265
4266 * gcj.texi (Code Generation): Document -fbootstrap-classes.
4267 * decl.c (GCJ_BOOTSTRAP_LOADER_ADDITION): New macro.
4268 (parse_version): Use it.
4269 * lang.opt (-fbootstrap-classes): New option.
4270
4271 2005-05-10 Paolo Bonzini <bonzini@gnu.org>
4272
4273 PR java/21436
4274 * class.c (maybe_layout_super_class): Look for imports in this_class.
4275 * parse.h (ctxp_for_generation_last): New.
4276 (do_resolve_class): Add a parameter.
4277 * parse.y (ctxp_for_generation_last): New.
4278 (java_pop_parser_context): Add at end of list.
4279 (find_in_imports, find_in_imports_on_demand): Look in ctxp
4280 if the TYPE_IMPORT_LIST or respectively the TYPE_IMPORT_DEMAND_LIST of
4281 the given type are NULL.
4282 (do_resolve_class): Look into the imports of the new second parameter.
4283 Adjust recursive calls.
4284 (resolve_class, resolve_inner_class, find_as_inner_class): Adjust
4285 calls to do_resolve_class.
4286 (create_class): Set the TYPE_IMPORT_LIST and TYPE_IMPORT_DEMAND_LIST.
4287 (java_complete_class): Do not do that here.
4288
4289 2005-05-03 Thomas Fitzsimmons <fitzsim@redhat.com>
4290
4291 PR java/20309
4292 * Make-lang.in (java): Add gjnih.
4293 (JAVA_TARGET_INDEPENDENT_BIN_TOOLS): Likewise.
4294 (GJNIH_OBJS): New variable.
4295 (gjnih$(exeext)): New target.
4296 (JAVA_MANFILES): Add gjnih.1.
4297 (java.uninstall): Add gjnih.1.
4298 (java.mostlyclean): Add gjnih.
4299 (java.maintainer-clean): Add gjnih.1.
4300 (java/gjavah-jni.o): New target.
4301 (.INTERMEDIATE): Add gjnih.pod.
4302 (gjnih.pod): New target.
4303 * config-lang.in (stagestuff): Add gjnih.
4304 * gcj.texi (Top): Add gjnih node.
4305 (Invoking gcjh): Add descriptions of -force, -old, -trace, -J and
4306 -bootclasspath options.
4307 (Invoking gjnih): New node.
4308 * gjavah.c Initialize flag_jni to 1 if JNI_DEFAULT is defined.
4309 (TOOLNAME): New macro.
4310 (error): Replace hard-coded gcjh with TOOLNAME.
4311 (process_file): Likewise.
4312 (usage): Likewise.
4313 (version): Likewise.
4314 (help): Likewise. Add help output for -force, -old, -trace and -J
4315 options.
4316 (OPT_FORCE, OPT_OLD, OPT_TRACE): New macros.
4317 (options): Add force, old, trace and J fields.
4318 (main): Handle -force, -old, -trace and -J options.
4319
4320 2005-05-03 Tom Tromey <tromey@redhat.com>
4321
4322 PR java/21245:
4323 * gjavah.c (main): Unlink output file on error.
4324
4325 2005-05-03 Kazu Hirata <kazu@cs.umass.edu>
4326
4327 * constants.c, jvgenmain.c, lang.opt, resource.c: Update
4328 copyright.
4329
4330 2005-04-29 Tom Tromey <tromey@redhat.com>
4331
4332 * expr.c (build_jni_stub): Updated for change to build_block.
4333
4334 2005-04-29 Andrew Pinski <pinskia@gcc.gnu.org>
4335
4336 * expr.c (force_evaluation_order): Declare 'saved' earlier.
4337
4338 2005-04-28 Andrew Haley <aph@redhat.com>
4339
4340 PR java/19285
4341 * java-tree.h (soft_resolvepoolentry_node): New.
4342 (alloc_constant_fieldref): Declare.
4343 * expr.c (expand_java_field_op): Don't call class_init for
4344 accesses to static fields with indirect dispatch.
4345 * builtins.c (initialize_builtins): Add "__builtin_expect".
4346 * decl.c (soft_resolvepoolentry_node): New variable.
4347 (java_init_decl_processing): Create a decl for
4348 "_Jv_ResolvePoolEntry".
4349 * class.c (build_fieldref_cache_entry): New function.
4350 (build_static_field_ref): Rewrite for indirect dispatch.
4351 * constants.c (find_name_and_type_constant_tree): New function.
4352 (alloc_constant_fieldref): Likewise.
4353 (build_constants_constructor): Handle CONSTANT_Fieldref and
4354 CONSTANT_NameAndType.
4355
4356 PR java/21115
4357 * expr.c (force_evaluation_order): Convert outgoing args smaller
4358 than integer.
4359
4360 2005-04-27 Bryce McKinlay <mckinlay@redhat.com>
4361
4362 * gcj.texi (libgcj Runtime Properties): Remove obsolete
4363 gnu.gcj.runtime.NameFinder.* system properties. Update documentation
4364 for gnu.gcj.runtime.NameFinder.use_addr2line and gnu.gcj.progname.
4365
4366 2005-04-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4367
4368 * gjavah.c, jcf-dump.c, jv-scan.c, jvgenmain.c: Replace calls
4369 to `unlock_stream' with `unlock_std_streams'.
4370
4371 2005-04-25 Jakub Jelinek <jakub@redhat.com>
4372
4373 * Make-lang.in (java/decl.o, java/resource.o): Depend on $(EXPR_H)
4374 instead of just expr.h.
4375
4376 2005-04-24 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4377
4378 * gjavah.c (main): Unlock the stdio streams.
4379 * jcf-dump.c (main): Likewise.
4380 * jv-scan.c (main): Likewise.
4381 * jvgenmain.c (main): Likewise.
4382
4383 2005-04-23 DJ Delorie <dj@redhat.com>
4384
4385 * class.c, decl.c, expr.c, jcf-io.c, jcf-parse.c, jv-scan.c,
4386 parse.y: Adjust warning() callers.
4387
4388 2005-04-21 Bryce McKinlay <mckinlay@redhat.com>
4389
4390 * gcj.texi (Object fields): Change "Integer" to "Int" in example
4391 contructor.
4392
4393 2005-04-20 Bryce McKinlay <mckinlay@redhat.com>
4394
4395 * gcj.texi: Fix typos and bogus example.
4396
4397 2005-04-19 Kazu Hirata <kazu@cs.umass.edu>
4398
4399 * except.c: Fix a comment typo.
4400
4401 2005-04-19 Julian Brown <julian@codesourcery.com>
4402
4403 * decl.c (finish_method): Revert patch from 2005-04-13 for breaking
4404 indirect dispatch with PIC.
4405
4406 2005-04-18 Andrew Haley <aph@redhat.com>
4407
4408 * java-except.h (struct eh_range.handler): Remove unused field.
4409 (handle_nested_ranges): Remove function declaration.
4410 (sanity_check_exception_range): Add function declaration.
4411 * verify.c (verify_jvm_instructions): Remove call to
4412 handle_nested_ranges.
4413 * verify-glue.c (verify_jvm_instructions_new): Call
4414 sanity_check_exception_range.
4415 * except.c (link_handler, eh_range_freelist, link_handler,
4416 handle_nested_ranges): Remove.
4417 (add_handler): Rewrite.
4418 (sanity_check_exception_range): New function.
4419 (print_ranges): New function.
4420
4421 2005-04-13 Julian Brown <julian@codesourcery.com>
4422
4423 * decl.c (finish_method): Give methods once-only linkage.
4424
4425 2005-04-11 Richard Sandiford <rsandifo@redhat.com>
4426
4427 * lang.opt: Refer to the GCC internals documentation instead of c.opt.
4428
4429 2005-04-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4430
4431 * java-tree.h: Don't use PARAMS().
4432
4433 2005-04-07 Per Bothner <per@bothner.com>
4434
4435 * class.c (push_class): By default, suppress debug output.
4436 (finish_class): Enable debug output for classes we're emitting.
4437
4438 2005-04-07 Andrew Haley <aph@redhat.com>
4439
4440 * gcj.texi: Correct gcj-dbtool instructions.
4441
4442 2005-04-04 Kazu Hirata <kazu@cs.umass.edu>
4443
4444 * gcj.texi: Fix a typo.
4445 * lang.c: Fix a comment typo.
4446
4447 2005-04-01 Thomas Fitzsimmons <fitzsim@redhat.com>
4448
4449 * gcj.texi (Invoking gij): Add descriptions of new -X options.
4450 Mention recognized-and-ignored compatibility options.
4451 (Memory allocation): Add descriptions of JvMalloc, JvRealloc and
4452 JvFree.
4453 (About CNI): Add Memory allocation section.
4454
4455 2005-04-01 Tom Tromey <tromey@redhat.com>
4456
4457 * decl.c (java_init_decl_processing): Fix types of
4458 _Jv_MonitorEnter, _Jv_MonitorExit, _Jv_AllocObject,
4459 _Jv_AllocObjectNoFinalizer, _Jv_Throw, _Jv_NewPrimArray,
4460 _Jv_JNI_PopSystemFrame, _Jv_divI, _Jv_remI, _Jv_divJ, _Jv_remJ.
4461
4462 2005-03-31 Jan Hubicka <jh@suse.cz>
4463
4464 * Make-lang.in (class.o, decl.o): Depend on cgraph.h.
4465 * class.c: Include cgraph.h
4466 (make_local_functoin_alias): Mark aslias as needed.
4467 * resource.c: Include cgraph.h
4468 (compile_resource_data): Go via cgraph interface.
4469
4470 2005-03-30 Ian Lance Taylor <ian@airs.com>
4471
4472 * parse.y (maybe_yank_clinit): Don't crash if bbody is NULL.
4473
4474 2005-03-30 Tom Tromey <tromey@redhat.com>
4475
4476 * jcf-dump.c (HANDLE_INNERCLASSES_ATTRIBUTE): Handle cases where
4477 inner_class_info_index==0 or outer_class_info_index==0.
4478
4479 2005-03-29 Tom Tromey <tromey@redhat.com>
4480
4481 * gcj.texi (libgcj Runtime Properties): Document
4482 gnu.gcj.runtime.endorsed.dirs.
4483
4484 2005-03-24 Anthony Green <green@redhat.com>
4485
4486 * gcj.texi (Invoking gcj-dbtool): Document new LIBDIR option to
4487 'gcj-dbtool -p'.
4488
4489 2005-03-23 Tom Tromey <tromey@redhat.com>
4490
4491 * decl.c (GCJ_CURRENT_BC_ABI_VERSION): New define.
4492 (parse_version): Use it.
4493
4494 2005-03-23 Joseph S. Myers <joseph@codesourcery.com>
4495
4496 * lang.c (LANG_HOOKS_TRUTHVALUE_CONVERSION): Remove.
4497
4498 2005-03-18 Andrew Haley <aph@redhat.com>
4499
4500 PR java/20522
4501 * decl.c (update_aliases): Don't update variables that are about
4502 to die.
4503 (maybe_poplevels): Add comment.
4504
4505 2005-03-17 Bryce McKinlay <mckinlay@redhat.com>
4506
4507 PR java/20502
4508 * jcf-parse.c (duplicate_class_warning): New function.
4509 (java_parse_file): Call duplicate_class_warning if
4510 CLASS_FROM_CURRENTLY_COMPILED_P is already set.
4511 (parse_zip_file_entries): Likewise. Also set
4512 CLASS_FROM_CURRENTLY_COMPILED_P.
4513
4514 2005-03-16 Andrew Haley <aph@redhat.com>
4515
4516 * expr.c (expand_java_arrayload): Don't generate a
4517 NullPointerException based on the type of the node.
4518 (build_java_array_length_access): Likewise.
4519
4520 2005-03-15 Zack Weinberg <zack@codesourcery.com>
4521
4522 * Make-lang.in (TEXI_JAVA_FILES): Add gcc-vers.texi.
4523
4524 2005-03-11 Tom Tromey <tromey@redhat.com>
4525
4526 * gcj.texi (Invoking gcj-dbtool): Document 'gcj-dbtool -p'.
4527 (libgcj Runtime Properties): Document the default .db.
4528
4529 2005-03-10 Ranjit Mathew <rmathew@hotmail.com>
4530
4531 PR java/20312
4532 * parse.y (checks_throws_clauses): Check exceptions list even when
4533 the base class does not come from a source file being compiled.
4534 (java_complete_lhs): Remove unused variable 'wfl'.
4535
4536 2005-03-09 Ranjit Mathew <rmathew@hotmail.com>
4537
4538 PR java/20338
4539 * decl.c (finish_method): Emit _Jv_InitClass for private static
4540 methods inside inner classes as well.
4541
4542 2005-03-08 Julian Brown <julian@codesourcery.com>
4543 * Revert patch from 2005-03-08 for causing bootstrap failure on
4544 ppc-darwin.
4545
4546 2005-03-08 Julian Brown <julian@codesourcery.com>
4547
4548 * decl.c (finish_method): Give methods once-only linkage.
4549
4550 2005-03-07 Ranjit Mathew <rmathew@hotmail.com>
4551
4552 * lang.c (flag_new_verifier): Enable by default, regardless of ABI.
4553
4554 2005-03-07 Bryce McKinlay <mckinlay@redhat.com>
4555
4556 * verify-glue.c (vfy_is_assignable_from): Perform static check using
4557 can_widen_reference_to if the C++ ABI is in use.
4558 (vfy_get_interface_count, vfy_get_interface): Remove unused functions.
4559 * verify-impl.c (debug_print, make_utf8_const, init_type, copy_type,
4560 type_isresolved, init_state, set_pc, state_get_pc,
4561 _Jv_BytecodeVerifier): Clean up unused and disabled functions.
4562 (verify_fail): Report the current PC from the verifier context.
4563 (free_state): Remove #if 0 block to enable this function.
4564 (free_verifier_context): Call free_state on state_list iterator
4565 values before freeing them.
4566 * expr.c (pop_type_0): Pop correct type for error message when stack
4567 contains a multi-word type.
4568
4569 2005-03-07 Ranjit Mathew <rmathew@hotmail.com>
4570
4571 * expr.c (build_java_array_length_access): Remove !flag_new_verifier
4572 for known NULL array length access.
4573
4574 2005-03-07 Tom Tromey <tromey@redhat.com>
4575
4576 * gcj.texi (Invoking gcj-dbtool): Document '-f'.
4577
4578 2005-03-06 Kazu Hirata <kazu@cs.umass.edu>
4579
4580 * jcf-dump.c, jcf-io.c, jcf-reader.c, lang.c, parse.h,
4581 typeck.c: Update copyright.
4582
4583 2005-03-06 Ranjit Mathew <rmathew@hotmail.com>
4584
4585 Remove xref code.
4586 * xref.c, xref.h: Remove file.
4587 * Make-lang.in (java/xref.o): Remove.
4588 * java-tree.h (flag_emit_xref, do_not_fold): Remove declaration.
4589 * lang.c (flag_emit_xref): Remove definition.
4590 * parse.h (DECL_END_SOURCE_LINE, DECL_INHERITED_SOURCE_LINE): Remove.
4591 * typeck.c (convert): Remove use of do_not_fold.
4592 * parse.y (do_not_fold): Remove definition.
4593 (parser grammar): Remove xref code.
4594 (maybe_create_class_interface_decl, create_class): Likewise.
4595 (register_fields, method_header, finish_method_declaration): Likewise.
4596 (declare_local_variables, source_end_java_method): Likewise.
4597 (java_complete_expand_classes): Do not set do_not_fold.
4598 (java_complete_expand_method): Remove xref code.
4599 (java_expand_classes, resolve_field_access, patch_invoke): Likewise.
4600 (java_complete_tree, java_complete_lhs, patch_assignment): Likewise.
4601 (patch_binop, build_string_concatenation, patch_array_ref): Likewise.
4602 (patch_synchronized_statement, patch_throw_statement): Likewise.
4603 (maybe_build_class_init_for_field): Likewise.
4604
4605 2005-03-05 Kazu Hirata <kazu@cs.umass.edu>
4606
4607 * expr.c (build_expr_wfl, expr_add_location): Use TYPE_P
4608 instead of IS_NON_TYPE_CODE_CLASS.
4609
4610 2005-03-04 Andrew Haley <aph@redhat.com>
4611
4612 PR java/18362
4613 * class.c (set_method_index): Don't set method_index if it is
4614 NULL_TREE.
4615 (layout_class_method): Don't complain about "non-static method foo
4616 overrides static method" in the case of indirect dispatch.
4617
4618 2005-03-02 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4619
4620 * jcf-io.c (caching_stat): Use __extension__ to avoid pedantic
4621 warning.
4622 * Make-lang.in: Don't elide warnings in jcf-io.c.
4623
4624 2005-03-01 Per Bothner <per@bothner.com>
4625
4626 PR java/8608
4627 * check-init.c (wfl): Remove static.
4628 (final_assign_error, check_init): Replace calls to parse_error_context
4629 by plain error.
4630 (check_init): Save, set, and restore input_location for each exp.
4631
4632 2005-03-01 Per Bothner <per@bothner.com>
4633
4634 * jcf-reader.c (get_attribute): Handle SourceDebugExtension (JSR 45)
4635 if HANDLE_SOURCEDEBUGEXTENSION_ATTRIBUTE is defined.
4636 * jcf-dump.c (HANDLE_SOURCEDEBUGEXTENSION_ATTRIBUTE): Print contents.
4637
4638 2005-03-01 Per Bothner <per@bothner.com>
4639
4640 * java-tree.h (IDENTIFIER_HANDLECLASS_VALUE): Remove ancient macro.
4641
4642 2005-02-23 Thomas Fitzsimmons <fitzsim@redhat.com>
4643
4644 PR libgcj/16923
4645 * gcj.texi (Invocation): Add descriptions of JvVMInitArgs and
4646 JvVMOption.
4647
4648 2005-02-22 Tom Tromey <tromey@redhat.com>
4649
4650 PR java/20056:
4651 * verify-impl.c (EITHER): New define.
4652 (types_compatible): Handle it.
4653 (check_field_constant): Use it.
4654
4655 2005-02-18 Tom Tromey <tromey@redhat.com>
4656
4657 PR java/20056:
4658 * verify-impl.c (types_equal): Fixed test.
4659
4660 PR java/20056:
4661 * verify-glue.c (vfy_class_has_field): New function.
4662 * verify.h (vfy_class_has_field): Declare.
4663 * verify-impl.c (check_field_constant): Added 'putfield'
4664 argument.
4665 (verify_instructions_0): Updated.
4666 (types_equal): New function.
4667
4668 2005-02-14 Tom Tromey <tromey@redhat.com>
4669
4670 PR java/19921:
4671 * jcf-write.c (generate_bytecode_insns) <CALL_EXPR>: Note the
4672 stack effect of multianewarray.
4673
4674 2005-02-14 Andrew Haley <aph@redhat.com>
4675
4676 PR java/19907
4677 * expr.c (expand_byte_code): Call promote_arguments().
4678 (promote_arguments): New function.
4679 * decl.c (check_local_unnamed_variable): Remove special case for
4680 new verifier.
4681 (find_local_variable): Promote all boolean types to int
4682 when searching for local variable decls.
4683
4684 2005-02-12 Kazu Hirata <kazu@cs.umass.edu>
4685
4686 * builtins.c, java-except.h, jcf-parse.c, jv-scan.c, lex.c,
4687 parse-scan.y: Update copyright.
4688
4689 2005-02-11 Per Bothner <per@bothner.com>
4690
4691 PR java/15543
4692 * parse-scan.y (input_location): Remove variable.
4693 (main_input_filename): New - replaces input_filename, which isn't
4694 settable if USE_MAPPED_LOCATION.
4695 * lex.c (java_init_lex): Wrap some more places in #ifndef JC1-LITE,
4696 so we don't reference input_location or wfl_operator in that case.
4697 * jv-scan.c (expand_location): Remove - no longer used.
4698 (main): Set main_input_filename rather than input_filename.
4699
4700 2005-02-09 Richard Henderson <rth@redhat.com>
4701
4702 * builtins.c (initialize_builtins): Call build_common_builtin_nodes.
4703 * decl.c (java_init_decl_processing): Initialize const_ptr_type_node.
4704
4705 2005-02-08 Marcin Dalecki <martin@dalecki.de>
4706
4707 * expr.c (add_type_assertion): Use the proper enumeration type,
4708 since this is what htab_find_slot() is expecting.
4709
4710 2005-02-06 Joseph S. Myers <joseph@codesourcery.com>
4711
4712 * gcj.texi: Update copyright dates.
4713
4714 2005-02-02 Tom Tromey <tromey@redhat.com>
4715
4716 * gcj.texi (libgcj Runtime Properties): Default library_control
4717 to 'cache'.
4718
4719 2005-02-02 Ranjit Mathew <rmathew@hotmail.com>
4720
4721 PR java/15543
4722 * parse-scan.y (formal_parameter): Use $2 (type) instead of $$
4723 (modifiers) when square brackets are present in a declaration for
4724 a final paramter.
4725 * jv-scan.c (main): Set input_filename and input_line.
4726
4727 2005-02-01 Tom Tromey <tromey@redhat.com>
4728
4729 PR java/19742:
4730 * gjavah.c (get_field_name): Don't override name for JNI header.
4731
4732 2005-02-01 Roger Sayle <roger@eyesopen.com>
4733
4734 * jcf-write.c (generate_bytecode_insns): Implement RSHIFT_EXPR
4735 of unsigned types using iushr and lushr JVM bytecodes.
4736
4737 2005-02-01 Ranjit Mathew <rmathew@hotmail.com>
4738
4739 PR java/19738
4740 * gjavah.c (jni_print_float): Do not emit floating-point
4741 initialiser for a static final field.
4742 (jni_print_double): Likewise.
4743
4744 2005-02-01 Mark Mitchell <mark@codesourcery.com>
4745
4746 Revert:
4747 2005-01-31 Mark Mitchell <mark@codesourcery.com>
4748 * gjavah.c (print_field_info): Mark static data members of
4749 floating-point type with "__extension__".
4750
4751 2005-01-31 Mark Mitchell <mark@codesourcery.com>
4752
4753 * gjavah.c (print_field_info): Mark static data members of
4754 floating-point type with "__extension__".
4755
4756 2005-02-01 Ranjit Mathew <rmathew@hotmail.com>
4757
4758 PR java/9157
4759 * parse.y (build_string_concatenation): Remove redundant if.
4760 (patch_conditional_expr): Attempt to patch_string() the condition
4761 of a ?: as well, in addition to its other operands.
4762
4763 2005-01-25 Tom Tromey <tromey@redhat.com>
4764
4765 * Make-lang.in (java/java-tree-inline.o): Removed.
4766
4767 2005-01-25 Ranjit Mathew <rmathew@hotmail.com>
4768
4769 PR java/19070
4770 * parse.y (patch_binop): Allow comparisons against NULL only
4771 if the other operand is of a reference type.
4772
4773 2005-01-24 Tom Tromey <tromey@redhat.com>
4774
4775 * java-tree.h (gcj_abi_version): Declare.
4776 * class.c (make_class_data): Push gcj_abi_version into "next"
4777 field. Renamed field.
4778 * decl.c (gcj_abi_version): New global.
4779 (parse_version): New function.
4780 (java_init_decl_processing): Call it. Renamed 'next' field.
4781 Include version.h.
4782 (GCJ_BINARYCOMPAT_ADDITION): New define.
4783
4784 2005-01-24 Roger Sayle <roger@eyesopen.com>
4785
4786 PR java/19295
4787 * jcf-write.c (generate_bytecode_insns): Conversions between
4788 integer types of the same precision shouldn't generate widening
4789 or narrowing conversion bytecodes.
4790
4791 2005-01-22 Kazu Hirata <kazu@cs.umass.edu>
4792
4793 * java-except.h, java-tree.h: Remove unused prototypes.
4794
4795 2005-01-20 Andrew Pinski <pinskia@gcc.gnu.org>
4796
4797 PR java/18091:
4798 * jcf-write.c (perform_relocations): Don't call memcpy if source
4799 and destination are the same.
4800
4801 2005-01-17 Tom Tromey <tromey@redhat.com>
4802
4803 * verify-impl.c (get_short): Sign extend.
4804 (get_int): Likewise.
4805
4806 2005-01-12 Ranjit Mathew <rmathew@hotmail.com>
4807
4808 * expr.c (build_jni_stub): Replace mistaken use of TYPE_SIZE_UNIT
4809 with TYPE_SIZE.
4810
4811 2005-01-10 Ranjit Mathew <rmathew@hotmail.com>
4812
4813 * verify.c: Revert to the version before the BC-ABI merge.
4814
4815 2005-01-10 Ranjit Mathew <rmathew@hotmail.com>
4816
4817 PR java/19277
4818 * check-init.c (check_init): Take care of references that do not
4819 have an explicit final variable declaration (e.g. array length
4820 access) for pre/post in/de-crement operators.
4821
4822 2005-01-08 Mark Wielaard <mark@klomp.org>
4823
4824 * parse.y (process_imports): Allocate (and free) original_name only
4825 when not already defined.
4826 * jcf-parse.c (read_class): Free results of find_class() and
4827 lrealpath().
4828 (java_parse_file): Keep pointer to head of file_list and free when
4829 done. Free result of lrealpath().
4830
4831 2005-01-05 Tom Tromey <tromey@redhat.com>
4832
4833 * gcj.texi (Standard Properties): java.ext.dirs is now used.
4834
4835 2004-12-20 Andrew Haley <aph@redhat.com>
4836
4837 * typeck.c: Use fold_convert for ints and booleans.
4838
4839 2004-12-17 Andrew Haley <aph@redhat.com>
4840
4841 PR java/18931
4842 * typeck.c (convert): Use a CONVERT_EXPR when converting to
4843 BOOLEAN_TYPE or CHAR_TYPE.
4844 (convert_to_boolean, convert_to_char) : Remove.
4845 * convert.h (convert_to_boolean, convert_to_char) : Remove.
4846 * expr.c (expand_load_internal): Do type conversion if type is not
4847 as required.
4848
4849 2004-12-13 Danny Smith <dannysmith@users.sourceforge.net>
4850
4851 PR target/18459
4852 * class.c (emit_register_classes): Use TARGET_USE_JCR_SECTION.
4853 Update comment.
4854
4855 2004-12-07 Andrew Haley <aph@redhat.com>
4856
4857 PR java/18811:
4858 * jcf-parse.c (load_class): Remove sanity test for missing inner
4859 class file.
4860
4861 2004-12-06 Tom Tromey <tromey@redhat.com>
4862
4863 * Make-lang.in (JAVA_MANFILES): Added gcj-dbtool.
4864 (java.uninstall): Likewise.
4865 (java.maintainer-clean): Likewise.
4866 (.INTERMEDIATE): Likewise.
4867 (java.install-man): Likewise.
4868 (gcj-dbtool.pod): New target.
4869 * gcj.texi (Code Generation): Document -findirect-dispatch.
4870 (libgcj Runtime Properties): Document
4871 gnu.gcj.precompiled.db.path.
4872 (Top): Link to "Invoking gcj-dbtool".
4873
4874 2004-12-06 Tom Tromey <tromey@redhat.com>
4875
4876 PR java/14853:
4877 * java-tree.h (extract_field_decl): Declare.
4878 * parse.y (extract_field_decl): Renamed from
4879 strip_out_static_field_access_decl. No longer static.
4880 * check-init.c (get_variable_decl): Unwrap COMPOUND_EXPRs.
4881
4882 2004-12-03 Tom Tromey <tromey@redhat.com>
4883
4884 * lang.c (flag_new_verifier): Define.
4885 (java_post_options): Set flag_new_verifier if indirect dispatch
4886 is being used.
4887 * lang.opt (fnew-verifier): Removed.
4888
4889 2004-12-03 Tom Tromey <tromey@redhat.com>
4890
4891 PR bootstrap/14614:
4892 * Make-lang.in (java.install-common): Only install transformed
4893 gcjh if gcj-cross exists.
4894
4895 2004-12-03 Andrew Haley <aph@redhat.com>
4896
4897 PR java/18812
4898 * except.c (link_handler): Patch 'outer' field of siblings of the
4899 range we're demoting.
4900
4901 2004-12-03 Andrew Haley <aph@redhat.com>
4902
4903 PR java/18697
4904 * class.c (layout_class_method): Don't fail to override a method
4905 simply because it has DECL_ARTIFICIAL set.
4906
4907 2004-12-02 Tom Tromey <tromey@redhat.com>
4908
4909 PR java/16675:
4910 * parse.y (craft_constructor): Special case null_pointer_node.
4911
4912 2004-12-02 Tom Tromey <tromey@redhat.com>
4913
4914 PR java/18741:
4915 * java-gimplify.c (java_gimplify_expr): Don't call
4916 SET_EXPR_LOCATION unless wrapped tree is an expression.
4917
4918 2004-11-27 Per Bothner <per@bothner.com>
4919
4920 * jcf-parse.c (set_source_filename): Improvement to Andrew's fix:
4921 Fix fencepost error in 'i', which got executed one too many times.
4922 Also, fold memcpy into explicit loop, as originally intended.
4923 Also, free temporary 'buf' which otherwise leaks.
4924
4925 2004-11-27 Per Bothner <per@bothner.com>
4926
4927 * expr.c (build_expr_wfl): Only declare last_file and last_filenode
4928 local static variables if not USE_MAPPED_LOCATION.
4929
4930 2004-11-27 Kazu Hirata <kazu@cs.umass.edu>
4931
4932 * class.c, decl.c, expr.c: Fix comment typos.
4933
4934 2004-11-26 Andrew Pinski <pinskia@physics.uc.edu>
4935
4936 PR java/18305
4937 * decl.c (end_java_method): Call
4938 attach_init_test_initialization_flags on all the init_decls.
4939 * parse.y (attach_init_test_initialization_flags): Move to ...
4940 * expr.c (attach_init_test_initialization_flags): here and
4941 support BIND_EXPR also.
4942 * java-tree.h (attach_init_test_initialization_flags): Prototype.
4943 * jcf-parse.c (parse_class_file): Don't disable class init
4944 optimization.
4945
4946 2004-11-25 Joseph S. Myers <joseph@codesourcery.com>
4947
4948 * gjavah.c, jcf-dump.c, jv-scan.c, jvspec.c: Avoid ` as left quote
4949 in diagnostics.
4950
4951 2004-11-24 Richard Henderson <rth@redhat.com>
4952
4953 * verify-glue.c (vfy_init_name, vfy_clinit_name, vfy_object_type,
4954 vfy_string_type, vfy_throwable_type): Use ANSI declaration form.
4955
4956 2004-11-24 Tom Tromey <tromey@redhat.com>
4957
4958 * verify.c (defer_merging): Don't use C++-style comment.
4959 * verify.h (java_opcode): Added java_opcode_end.
4960 * class.c (build_class_ref): Remove C++ comment and old FIXME.
4961
4962 * verify-impl.c (vfy_push_type): Removed bogus "return".
4963 (initialize_stack): Use vfy_alloc and vfy_free.
4964 (verify_instructions_0): Likewise.
4965
4966 * Merged gcj-abi-2-dev-branch to trunk.
4967
4968 2004-11-24 Andrew Haley <aph@redhat.com>
4969
4970 * jcf-parse.c (parse_class_file): Set file_start_location.
4971
4972 2004-11-10 Tom Tromey <tromey@redhat.com>
4973
4974 * class.c (make_field_value): Don't call build_static_field_ref.
4975 (build_static_field_ref): Don't emit direct references when using
4976 indirect dispatch.
4977
4978 * gcj.texi (Invoking gij): Document -verbose. Put -verbose and
4979 -verbose:class into man page synopsis.
4980
4981 2004-11-09 Tom Tromey <tromey@redhat.com>
4982
4983 * expr.c (build_java_arraystore_check): Still generate check if
4984 element type is itself an array.
4985
4986 2004-11-08 Tom Tromey <tromey@redhat.com>
4987
4988 * java-tree.h (soft_check_assignment_node): Removed.
4989 (enum java_tree_index): Removed JTI_SOFT_CHECK_ASSIGNMENT_NODE.
4990 * decl.c (java_init_decl_processing): Don't initialize
4991 soft_check_assignment_node.
4992
4993 2004-11-05 Tom Tromey <tromey@redhat.com>
4994
4995 * class.c (layout_class_methods): Don't add Miranda methods when
4996 using indirect dispatch.
4997
4998 2004-11-05 Bryce McKinlay <mckinlay@redhat.com>
4999
5000 * class.c (make_class_data): Call emit_assertion_table to set the
5001 'assertion_table' field.
5002 (build_signature_for_libgcj): Move here from expr.c.
5003 (add_assertion_table_entry): New function. Callback for assertion
5004 hashtable traversal.
5005 (emit_assertion_table): New. Take class argument, and generate
5006 assertion table DECL based on the TYPE_ASSERTIONS hashtable.
5007 * decl.c (init_decl_processing): Define assertion_entry_type record.
5008 Push 'assertion_table' class field instead of 'verify'.
5009 * expr.c (type_assertion_eq): Compare 'assertion_code' field.
5010 (type_assertion_hash): Include 'assertion_code' in hash.
5011 (add_type_assertion): Rewritten. Take class and assertion_code
5012 arguments. Add assertions to the TYPE_ASSERTIONS hashtable.
5013 (can_widen_reference_to): Use new add_type_assertion() arguments.
5014 * java-tree.h (java_tree_index): Add JTI_ASSERTION_ENTRY_TYPE,
5015 JTI_ASSERTION_TABLE_TYPE. Remove JTI_VERIFY_IDENTIFIER_NODE.
5016 (verify_identifier_node): Removed.
5017 (assertion_entry_type, assertion_table_type): New.
5018 (ASSERTION_TYPES_COMPATIBLE, ASSERTION_IS_INSTANTIABLE): New. Type
5019 assertion code definitions.
5020 (struct type_assertion): Add assertion_code. Rename 'source_type' and
5021 'target_type' to 'op1' and 'op2'.
5022 (add_type_assertion): Declare.
5023 (lang_printable_name_wls): Remove unused definition.
5024 * verify-glue.c: (vfy_is_assignable_from): New. Call add_type_assertion
5025 to emit runtime assertion.
5026 (vfy_note_stack_type): Clean up non-C90 declarations.
5027 (vfy_note_local_type): Likewise.
5028 * verify.h (vfy_is_assignable_from): Declare.
5029 * verify-impl.c (is_assignable_from_slow): Remove unused function.
5030 (ref_compatible): Rename arguments. Call vfy_is_assignable_from()
5031 instead of is_assignable_from_slow().
5032 (types_compatible): Reinstate ref_compatible() call.
5033
5034 2004-11-04 Tom Tromey <tromey@redhat.com>
5035
5036 * class.c (build_static_field_ref): Reverted previous patch.
5037
5038 * class.c (build_static_field_ref): Don't emit direct references
5039 when using indirect dispatch.
5040
5041 2004-11-03 Tom Tromey <tromey@redhat.com>
5042
5043 * expr.c (expand_java_arrayload): Set lhs_type_node.
5044 (expand_java_arraystore): Set rhs_type_node.
5045
5046 2004-11-02 Tom Tromey <tromey@redhat.com>
5047
5048 * jcf-parse.c (compute_class_name): Use filename length from zip
5049 directory, not strlen.
5050
5051 * expr.c (expand_invoke): Mark new interface methods as abstract.
5052
5053 2004-11-01 Tom Tromey <tromey@redhat.com>
5054
5055 * verify-impl.c (push_jump): Removed check for uninitialized
5056 objects.
5057 (push_exception_jump): Likewise.
5058 (handle_ret_insn): Likewise.
5059 (handle_jsr_insn): Likewise.
5060 (state_check_no_uninitialized_objects): Removed.
5061
5062 * decl.c (check_local_unnamed_variable): Recognize
5063 promoted-to-int parameters when using the new verifier.
5064 * expr.c (expand_java_arraystore): Explicitly request array type
5065 when using new verifier.
5066 (expand_java_arrayload): Likewise.
5067 (invoke_build_dtable): Don't pass object_type_node as
5068 expression argument to build_java_indirect_ref.
5069 (build_java_check_indexed_type): Do nothing.
5070 (build_java_arraystore_check): Handle case where array doesn't
5071 have array type.
5072 (build_java_array_length_access): Likewise.
5073 (expand_invoke): Handle case where interface overrides a method
5074 from Object.
5075 (pop_type_0): Always succeed for reference types.
5076 (process_jvm_instruction): Don't pop a value in a dead
5077 exception handler.
5078 (pop_arguments): Convert arguments to correct types.
5079
5080 2004-10-29 Andrew Haley <aph@redhat.com>
5081
5082 * jcf-parse.c (give_name_to_class): Remove line that was
5083 incorrectly merged.
5084
5085 2004-10-29 Andrew Haley <aph@redhat.com>
5086
5087 * jcf-parse.c (set_source_filename): Add code to build new sfname.
5088
5089 2004-10-20 Andrew Haley <aph@redhat.com>
5090
5091 * decl.c (end_java_method): Don't expand if flag_syntax_only.
5092
5093 2004-10-26 Tom Tromey <tromey@redhat.com>
5094
5095 * verify.h (vfy_notify_verified): Removed.
5096 * verify-glue.c (vfy_notify_verified): Removed.
5097
5098 2004-10-26 Tom Tromey <tromey@redhat.com>
5099
5100 * verify-impl.c (debug_print_state): Declare `i' before code.
5101 (merge_types): Modify `t' when it is null_type.
5102
5103 2004-10-26 Tom Tromey <tromey@redhat.com>
5104
5105 * verify-impl.c (type_print): Renamed from print. Now static and
5106 takes an argument.
5107 (debug_print_state): Use type_print.
5108
5109 2004-10-25 Tom Tromey <tromey@redhat.com>
5110
5111 * expr.c (build_invokeinterface): Compute correct offset for
5112 index into interface methods.
5113
5114 2004-10-20 Tom Tromey <tromey@redhat.com>
5115
5116 * java-tree.h (verify_jvm_instructions_new): Declare.
5117
5118 * jvspec.c (jvgenmain_spec): Remove -fnew-verifier from cc1
5119 command line.
5120
5121 * verify-impl.c (verify_instructions): Correctly handle wide
5122 types on the stack.
5123 * verify-glue.c (vfy_get_class_name): Use DECL_NAME.
5124 (vfy_get_component_type): Strip pointer types.
5125 (vfy_find_class): Use get_type_from_signature. Strip pointer
5126 types.
5127 Include java-except.h.
5128
5129 2004-10-20 Bryce McKinlay <mckinlay@redhat.com>
5130
5131 * verify-impl.c (type_array_elementpop_raw, vfy_pop_type_t,
5132 vfy_push_type_t, set_variable, add_new_state, merge_into,
5133 handle_jsr_insn, branch_prepass, check_class_constant,
5134 check_wide_constant, get_one_type, compute_static_types,
5135 verify_instructions_0): Clean up C99 declarations after statements.
5136
5137 2004-10-20 Tom Tromey <tromey@redhat.com>
5138
5139 * verify-impl.c (merge_refs): Compare reference against iterator,
5140 not ref2.
5141
5142 * verify-glue.c (vfy_tag): Mask off resolved flag.
5143
5144 2004-10-19 Tom Tromey <tromey@redhat.com>
5145
5146 * verify-impl.c (verify_instructions): Call vfy_note_local_type.
5147 (init_state_with_stack): Initialize `this_type' in state.
5148 (verify_method): Use debug_print.
5149 * verify-glue.c (vfy_is_primitive): Removed debugging print.
5150 (vfy_note_stack_depth): Reverted last patch.
5151 (vfy_note_stack_type): Note pointer to Object, not Object.
5152 (vfy_note_local_type): Likewise.
5153
5154 * verify.h (vfy_note_instruction_seen): Declare.
5155 * verify-glue.c (verify_jvm_instructions_new): Set
5156 BCODE_EXCEPTION_TARGET on target instruction.
5157 (vfy_note_instruction_seen): New function.
5158 * verify-impl.c (FLAG_INSN_SEEN): New define.
5159 (verify_instructions_0): Set flag on instruction. Save state for
5160 PC=0 later.
5161 (verify_instructions): Call vfy_note_instruction_seen.
5162
5163 * verify-glue.c (vfy_note_stack_depth): Fix off-by-one error.
5164 (verify_jvm_instructions_new): Call method_init_exceptions,
5165 add_handler, and handle_nested_ranges.
5166 * verify-impl.c (verify_method): Return 1 on success.
5167 (verify_instructions_0): Save the state at PC=0.
5168
5169 * verify-impl.c (init_type_from_class): Set is_resolved and
5170 ref_next on new ref_intersection.
5171 (init_type_from_string): Likewise.
5172
5173 2004-10-15 Bryce McKinlay <mckinlay@redhat.com>
5174
5175 * expr.c (expand_bytecode): Use verify_jvm_instructions_new
5176 if flag_new_verifier is set.
5177 * java-tree.h (flag_new_verifier): Declare.
5178 * lang.opt (fnew-verifier): New option.
5179 * verify-impl.c: Work around namespace pollution by undef'ing
5180 'current_class'.
5181 (struct verifier_context): Make 'bytecode' const.
5182 (verify_fail_pc): Pass -1 PC argument to vfy_fail.
5183 (types_compatible): For the BC-ABI, always consider reference types
5184 compatible.
5185 (check_class_constant): Use vfr->current_class.
5186 (check_constant): Likewise.
5187 (check_wide_constant): Likewise.
5188 (check_field_constant): Check for 'L' at start of type name.
5189 (get_one_type): Return pointer instead of type. Set type result in
5190 caller via passed type pointer.
5191 (compute_argument_types): Update to use new get_one_type arguments.
5192 (compute_return_type): Likewise.
5193 (make_verifier_context): New. Allocate and initialize 'vfr'.
5194 (free_verifier_context): New. Free 'vfr' and its contents.
5195 (verify_method): Remove ATTRIBUTE_UNUSED. Call make_verifier_context
5196 and free_verifier_context.
5197
5198 2004-10-15 Tom Tromey <tromey@redhat.com>
5199
5200 * verify-glue.c (vfy_note_local_type): Mark argument as unused.
5201 * verify.h (vfy_fail): Fixed formatting.
5202
5203 * verify-impl.c (vfr): Fixed comment formatting.
5204 (collapse_type): New function.
5205 (verify_instructions): Notify compiler about type map.
5206 * verify.h (vfy_note_stack_depth): Updated.
5207 (vfy_note_stack_type): Likewise.
5208 (vfy_note_local_type): Likewise.
5209 (vfy_unsuitable_type, vfy_return_address_type, vfy_null_type):
5210 Declare.
5211 * verify-glue.c (vfy_note_stack_depth): Correctly size type
5212 state. Added `method' argument.
5213 (vfy_note_stack_type): Renamed from vfy_note_type. Added `method'
5214 argument.
5215 (vfy_note_local_type): New function.
5216 (vfy_unsuitable_type): Likewise.
5217 (vfy_return_address_type): Likewise.
5218 (vfy_null_type): Likewise.
5219
5220 * verify.h (VFY_IN_GCC): Removed.
5221 (VFY_WANT_TYPEMAP): Removed.
5222 * verify-impl.c (verify_instructions_0): Removed useless "\".
5223 (struct state) <next>: Uncomment.
5224
5225 2004-10-13 Bryce McKinlay <mckinlay@redhat.com>
5226
5227 * verify-impl.c: Formatting fixes. Reformat C++-style comments to
5228 C-style.
5229
5230 2004-10-06 Bryce McKinlay <mckinlay@redhat.com>
5231
5232 * Make-lang.in (verify.o): Re-enabled this target.
5233 * verify-glue.c (vfy_get_interface_count): Add ATTRIBUTE_UNUSED.
5234 (vfy_get_interface): Likewise.
5235 (verify_jvm_instructions_new): Renamed from verify_jvm_instructions.
5236 * verify.h (verify_jvm_instructions_new): Declare.
5237 * verify-impl.c (free_state): Temporarily comment out unused
5238 function.
5239
5240 2004-10-06 Tom Tromey <tromey@redhat.com>
5241
5242 * java-tree.h (JV_STATE_READ): New enum value.
5243
5244 2004-10-06 Bryce McKinlay <mckinlay@redhat.com>
5245
5246 * verify.h: New file.
5247
5248 2004-10-05 Bryce McKinlay <mckinlay@redhat.com>
5249
5250 * verify-impl.c, verify-glue.c, verify.h: New files.
5251 * Make-lang.in: Add rules for verify-impl.o and verify-glue.o.
5252
5253 2004-09-24 Andrew Haley <aph@redhat.com>
5254
5255 * decl.c (check_local_unnamed_variable): Always use the PARM_DECL
5256 for a slot if it's of pointer type.
5257
5258 2004-09-14 Tom Tromey <tromey@redhat.com>
5259
5260 * class.c (make_class_data): Correctly initialize "state" field.
5261 Initialize "engine" field.
5262 * decl.c (java_init_decl_processing): Add "engine" field.
5263
5264 2004-09-10 Andrew Haley <aph@redhat.com>
5265
5266 PR java/12760
5267 * expr.c (build_invokeinterface): Use fast method for interface
5268 dispatch.
5269 * java-tree.h (enum java_tree_index): Add JTI_ITABLE_TYPE,
5270 JTI_ITABLE_PTR_TYPE.
5271 (struct lang_type): Add itable_methods, itable_decl, itable_syms_decl.
5272 (emit_symbol_table): Add new arg, element_size.
5273 * decl.c (java_init_decl_processing): Initialize Class.itable.
5274 * class.c (GEN_TABLE): New macro.
5275 (gen_indirect_dispatch_tables): Use it. Add itable.
5276 (make_class_data): Add new arg for emit_symbol_table().
5277 Emit itable.
5278 (add_miranda_methods): Make sure search_class has been parsed.
5279 (emit_symbol_table): Add new arg, element_size.
5280
5281 2004-09-06 Andrew Haley <aph@redhat.com>
5282
5283 * verify.c (merge_types): Return Object for all merges of
5284 interfaces.
5285 * expr.c (add_type_assertion): Don't generate assertions when
5286 source type is array of Object.
5287
5288 2004-09-03 Andrew Haley <aph@redhat.com>
5289
5290 * class.c (finish_class): Nullify TYPE_VERIFY_METHOD.
5291
5292 * lang.c (java_post_options): Force flag_verify_invocations if
5293 we're not using indirect dispatch.
5294
5295 * expr.c (pop_type_0): Move test for interfaces before call to
5296 can_widen_reference_to().
5297 (build_signature_for_libgcj): Remove generation of canonical array
5298 type.
5299 (add_type_assertion): Canonicalize both arrays.
5300 Don't assert that type X can be assigned to Object.
5301 Don't assert that type X an be assigned to type X.
5302 Don't assert that Object can be assigned to type X.
5303 (can_widen_reference_to): Warn whenever we generate an assertion.
5304 (process_jvm_instruction): Use throwable_type_node for the type of
5305 an exception class.
5306
5307 2004-09-01 Andrew Haley <aph@redhat.com>
5308
5309 * decl.c (java_init_decl_processing): Change
5310 verify_identifier_node to "__verify".
5311 * expr.c (add_type_assertion): Use verify_identifier_node for name.
5312 * java-tree.h (verify_identifier_node): Change to "__verify".
5313
5314 * expr.c (build_signature_for_libgcj): New function.
5315 (add_type_assertion): Use it to construct signatures for
5316 source_type and target_type.
5317
5318 2004-08-27 Andrew Haley <aph@redhat.com>
5319
5320 * java-tree.h (enum java_tree_index): Add JTI_VERIFY_IDENTIFIER_NODE.
5321 (verify_identifier_node): New.
5322 (TYPE_VERIFY_METHOD): New.
5323 (struct type_assertion): New type.
5324 * expr.c (type_assertion_eq): New function.
5325 (type_assertion_hash): New function.
5326 (add_type_assertion): New function.
5327 (can_widen_reference_to): Call add_type_assertion().
5328 * decl.c (java_init_decl_processing): Add verify_identifier_node.
5329 * class.c (make_class_data): Initialize TYPE_VERIFY_METHOD (type).
5330 (finish_class): Output TYPE_VERIFY_METHOD (type).
5331
5332 * decl.c (end_java_method): Nullify unused fields.
5333
5334 2004-08-17 Andrew Haley <aph@redhat.com>
5335
5336 * verify.c (defer_merging): Quieten.
5337 * jcf-parse.c (load_class): Only try to open a class file if it's
5338 java.lang.Object or if it's part of the current compilation.
5339 Check that the class we just tried to load is the class we just
5340 loaded. Quieten.
5341 (java_parse_file): Set flag_verify_invocations off if we're
5342 compiling from .class.
5343 (parse_zip_file_entries): Abort if we try to read a dummy class.
5344 * expr.c (can_widen_reference_to): Quieten.
5345 (build_invokevirtual): Abort if we try to invokevirtual an
5346 interface.
5347 (expand_invoke): Don't build a non-interface call to an interface.
5348 (build_instanceof): Don't do premature optimization if
5349 flag_verify_invocations is not set.
5350 * class.c (set_super_info): Disable code that inherits TYPE_DUMMY
5351 from superclass.
5352 (build_static_field_ref): Add correct type conversion for
5353 field_address.
5354 (add_miranda_methods): Disable generation of Miranda methods for
5355 dummy classes.
5356 (layout_class_method): Don't complain about non-static method
5357 overrides static method with dummy classes.
5358
5359 2004-08-13 Tom Tromey <tromey@redhat.com>
5360
5361 * class.c (build_static_field_ref): Re-enable atable lookups for
5362 static fields.
5363
5364 * parse.y (strip_out_static_field_access_decl): Indentation fix.
5365
5366 2004-08-11 Tom Tromey <tromey@redhat.com>
5367
5368 * gcj.texi (libgcj Runtime Properties): Document new properties.
5369
5370 2004-08-06 Andrew Haley <aph@redhat.com>
5371
5372 * jcf-parse.c (load_class): Check that we really have loaded the
5373 class we're looking for.
5374
5375 2004-07-19 Andrew Haley <aph@redhat.com>
5376
5377 * verify.c (verify_jvm_instructions): Comment change only.
5378
5379 * typeck.c (build_java_array_type): Add size field to array name.
5380
5381 * java-tree.h (LOCAL_SLOT_P): New.
5382 (update_aliases): Add PC argument.
5383 (pushdecl_function_level): New function.
5384
5385 * java-gimplify.c (java_gimplify_expr): Handle VAR_DECL,
5386 MODIFY_EXPR, and SAVE_EXPR.
5387 (java_gimplify_modify_expr): New function.
5388
5389 * expr.c (push_type_0): Call find_stack_slot() to create temporary.
5390 (expand_iinc): Pass PC to update_aliases().
5391 (STORE_INTERNAL): Likewise.
5392 (process_jvm_instruction): Likewise.
5393
5394 * decl.c (base_decl_map): New variable.
5395 (uniq): New variable.
5396 (update_aliases): Rewrite with more thorough checking.
5397 (debug_variable_p): New function.
5398 (push_jvm_slot): Don't initialize local variable. Don't pushdecl.
5399 (check_local_named_variable): Delete whole function.
5400 (initialize_local_variable): New function.
5401 (check_local_unnamed_variable): Add checks and comments.
5402 (find_local_variable): Rewrite.
5403 (java_replace_reference): New function.
5404 (function_binding_level): New variable.
5405 (pushdecl_function_level): New function.
5406 (maybe_pushlevels): Set DECL_LOCAL_END_PC.
5407 (maybe_pushlevels): Call pushdecl() on each of the new decls.
5408 (start_java_method): Reset uniq. Create base_decl_map. Set
5409 function_binding_level.
5410 (end_java_method): Null unused fields to save memory.
5411
5412 2004-06-29 Andrew Haley <aph@redhat.com>
5413
5414 * except.c (expand_start_java_handler): Push a new binding level.
5415 Don't build a TRY_CATCH_EXPR now, we'll do it later. Call
5416 register_exception_range() to register where we'll do it.
5417 (expand_end_java_handler): Remove old bogus code. Replace with
5418 new logic that simply builds TRY_CATCH_EXPRs and inserts them at
5419 the top of the expression we're curently building.
5420 (maybe_end_try): Delete.
5421 * decl.c (binding_level.exception_range): New field.
5422 (clear_binding_level): Add field exception_range. Reformat.
5423 (poplevel): Call expand_end_java_handler().
5424 (poplevel): Call java_add_stmt only if functionbody is false.
5425 (maybe_poplevels): Don't call maybe_end_try() from here.
5426 (end_java_method): Clear no longer used trees in function decl.
5427 (register_exception_range): New function.
5428 * java-tree.h (register_exception_range, struct eh_range): Declare.
5429
5430 2004-06-22 Andrew Haley <aph@redhat.com>
5431
5432 * class.c (gen_indirect_dispatch_tables): Set the DECL_OWNER of
5433 the otable.
5434 * check-init.c (get_variable_decl): Teach check-init about
5435 FIELD_DECLs addressed via the otable.
5436 * jcf-parse.c (load_class): Check CLASS_LOADED_P, not
5437 CLASS_PARSED_P.
5438
5439 2004-05-28 Andrew Haley <aph@redhat.com>
5440
5441 * jcf-parse.c (load_class): Don't try to read a class that we've
5442 already read.
5443
5444 * expr.c (build_invokeinterface): Use the old-fashioned way of
5445 doing indirect dispatch: look up interfaces by name.
5446 * java-tree.h (enum java_tree_index): Add
5447 JTI_SOFT_LOOKUPINTERFACEMETHODBYNAME_NODE
5448 * decl.c (java_init_decl_processing): Add
5449 soft_lookupinterfacemethodbyname_node.
5450
5451 * gjavah.c (print_method_info): Final methods have vtable entries,
5452 so gjavah needs to output them.
5453 * class.c (layout_class_method): Generate vtable entries for final
5454 methods.
5455 * parse.y (invocation_mode): Use INVOKE_VIRTUAL for indirect
5456 dispatch, even if a method is final.
5457
5458 2004-05-25 Andrew Haley <aph@redhat.com>
5459
5460 * class.c (build_symbol_entry): Convert the names of constructors
5461 to init_identifier_node when generating an entry for the indirect
5462 dispatch table.
5463
5464 * expr.c (build_known_method_ref): Generate indirect calls for
5465 all methods marked DECL_EXTERNAL or TREE_PUBLIC.
5466
5467 2004-05-24 Andrew Haley <aph@redhat.com>
5468
5469 * expr.c (build_known_method_ref): Make sure ARRAY_REF access to
5470 atable element is of the right type.
5471
5472 * class.c (build_static_field_ref): Cast pointer to correct type
5473 for field.
5474
5475 2004-04-20 Bryce McKinlay <mckinlay@redhat.com>
5476
5477 * Merged with HEAD as of 20040514. Diff against
5478 gcj-abi-2-merge-20040514.
5479
5480 2004-04-16 Andrew Haley <aph@redhat.com>
5481
5482 * verify.c (check_pending_block): Disable subroutine checks.
5483 (defer_merging): New function.
5484 (merge_types): If types are dummy, use defer_merging to combine them.
5485 (verify_jvm_instructions): If invocation is invokeinterface and
5486 target is dummy, assume target really is an interface.
5487
5488 * parse.y (patch_invoke): Break out call to java_create_object.
5489
5490 * lang.c (flag_verify_invocations): New.
5491
5492 * jcf-parse.c (load_class): If we've already failed to load a
5493 class, don't try again.
5494 (load_class): If we can't find a .class file, don't fail, but emit
5495 a warning.
5496 (parse_class_file): Don't act on dummy methods.
5497
5498 * java-tree.h (flag_verify_invocations): New.
5499 (TYPE_DUMMY): New.
5500 (lang_type.dummy_class): New field.
5501 (java_create_object): New function.
5502 (METHOD_DUMMY): New.
5503
5504 * expr.c (build_field_ref): Widen field offset.
5505 (pop_type_0): If the type in stack_type_map is a TREE_LIST, check
5506 that each of its elements is compatible with the one we're
5507 popping.
5508 (pop_type_0): Issue a warning to say that we need to generate a
5509 runtime check.
5510 (java_create_object): New function.
5511 (build_field_ref): Only generate hard refs if we're not using
5512 indirect dispatch.
5513 (expand_java_field_op): If we're using !verify_invocations and we
5514 see a missing field, generate a decl for it.
5515
5516 (expand_invoke): If a class doesn't have the method we seek and
5517 we're using !flag_verify_invocations, generate a decl for the
5518 method now.
5519
5520 (build_known_method_ref): Always use indirect dispatch via the
5521 atable for static methods.
5522
5523 (expand_java_NEW): Break out object creation into new function,
5524 java_create_object.
5525
5526 (can_widen_reference_to): Issue a warning to say that we need to
5527 generate a runtime check.
5528
5529 * class.c (set_super_info): Inherit TYPE_DUMMY from sureclass.
5530 (make_method_value): Also use index for interfaces.
5531 (make_class_data): Skip dummy field for inherited data.
5532 Don't build method array for dummy methods.
5533 Set size_in_byte to -1 when using inirect dispatch
5534 Don't build a hard class ref if we don't have a hard ref to our
5535 superclass, or if we're using inirect dispatch.
5536 Null out dispatch tables.
5537
5538 (layout_class_method): Don't complain about non-static method
5539 overrides static method is method is artificial.
5540
5541 (build_static_field_ref): Disable atable references to static
5542 fields for the time being.
5543
5544 (layout_class_methods): Check for CLASS_INTERFACE as
5545 well as CLASS_ABSTRACT.
5546
5547 2004-11-24 Steven Bosscher <stevenb@suse.de>
5548
5549 * class.c (make_class_data): Don't check flag_inline_functions.
5550 * lang.c (flag_really_inline): Remove unused flag.
5551 (java_handle_option): Don't set it here. Remove special handling
5552 of flag_inline_functions for Java.
5553 (java_init): Don't set flag_inline_trees here. Already done...
5554 (java_post_options): ...here. Don't clear flag_inline_functions.
5555
5556 2004-11-24 Steven Bosscher <stevenb@suse.de>
5557
5558 * java-gimplify.c (java_gimplify_labeled_block_expr): New function.
5559 (java_gimplify_exit_block_expr): New function.
5560 (java_gimplify_expr): Use them to gimplify EXIT_BLOCK_EXPR and
5561 LABELED_BLOCK_EXPR.
5562 * java-tree.def (LABELED_BLOCK_EXPR): Moved from tree.def.
5563 (EXIT_BLOCK_EXPR): Likewise.
5564 * java-tree.h (LABELED_BLOCK_LABEL): Moved from tree.h.
5565 (LABELED_BLOCK_BODY): Likewise.
5566 (EXIT_BLOCK_LABELED_BLOCK): Likewise.
5567 * jcf-write.c (generate_bytecode_insns): Don't handle the unused
5568 EXIT_BLOCK_RETURN operand. Use EXIT_BLOCK_LABELED_BLOCK instead of
5569 TREE_OPERAND.
5570 * lang.c (java_tree_inlining_walk_subtrees): Handle EXIT_BLOCK_EXPR.
5571 (java_dump_tree): Use LABELED_BLOCK_LABEL, LABELED_BLOCK_BODY, and
5572 EXIT_BLOCK_LABELED_BLOCK instead of TREE_OPERAND. Don't handle the
5573 second operand of EXIT_BLOCK_EXPR.
5574 * parse.y (find_expr_with_wfl): Use LABELED_BLOCK_BODY instead of
5575 TREE_OPERAND.
5576 (build_bc_statement): Use build1 to build EXIT_BLOCK_EXPR nodes.
5577
5578 2004-11-23 Ben Elliston <bje@au.ibm.com>
5579
5580 * xref.h (xref_flag_value): Remove.
5581 (xref_set_data, xref_get_data): Likewise.
5582 (xref_set_current_fp): Likewise.
5583 (XREF_NONE): Likewise.
5584 (XREF_GET_DATA): Likewise.
5585 * xref.c (xref_flag_value): Remove.
5586 (xref_set_data, xref_get_data): Likewise.
5587 (xref_set_current_fp): Likewise.
5588
5589 2004-11-23 Ben Elliston <bje@au.ibm.com>
5590
5591 * gjavah.c (output_directory): Make static.
5592 (temp_directory): Likewise.
5593
5594 2004-11-15 Tom Tromey <tromey@redhat.com>
5595
5596 * decl.c (instn_ptr_type_node): Removed.
5597 (lineNumbers_ptr_type_node): Removed.
5598 (jint_type): Removed.
5599 (jint_ptr_type): Removed.
5600
5601 2004-11-09 Andrew Pinski <pinskia@physics.uc.edu>
5602
5603 PR java/15576
5604 * check-init.c (check_init): Ignore DECL_EXPR.
5605 * expr.c (always_initialize_class_p): Reenable.
5606 (build_class_init): Use a variable to store the decl. Also use
5607 boolean_false_node instead of integer_zero_node.
5608 * parse.y (attach_init_test_initialization_flags): Add a decl_expr
5609 to the block.
5610
5611 2004-11-08 Tom Tromey <tromey@redhat.com>
5612
5613 PR java/16843:
5614 * gjavah.c (HANDLE_END_FIELD): Call print_field_info when
5615 generating a JNI header.
5616 (print_field_info): Handle JNI headers.
5617 (jni_print_float): Likewise.
5618 (jni_print_double): Likewise.
5619
5620 2004-11-08 Andrew Pinski <pinskia@physics.uc.edu>
5621
5622 * decl.c (end_java_method): Remove duplicated code.
5623
5624 2004-11-06 Zack Weinberg <zack@codesourcery.com>
5625 Gerald Pfeifer <gerald@pfeifer.com>
5626
5627 * lex.h (HAVE_ICONV): Undefine if we do not have HAVE_ICONV_H
5628 as well.
5629
5630 2004-11-02 Bryce McKinlay <mckinlay@redhat.com>
5631
5632 PR java/17265
5633 * class.c: Reinstate 2004-08-18 patch.
5634 (make_local_function_alias): Don't create an alias for extern (native)
5635 functions.
5636
5637 2004-10-22 Eric Botcazou <ebotcazou@libertysurf.fr>
5638
5639 PR java/17265
5640 * class.c (make_local_function_alias): Revert 2004-08-18 change.
5641 (make_method_value): Likewise.
5642
5643 2004-10-21 Andrew Haley <aph@redhat.com>
5644
5645 PR java/18091:
5646 * jcf-parse.c (set_source_filename): Add code to build new sfname.
5647
5648 2004-10-20 Andrew Haley <aph@redhat.com>
5649
5650 * decl.c (end_java_method): Don't expand if flag_syntax_only.
5651 Remove duplicated code block.
5652
5653 2004-10-18 Steven Bosscher <stevenb@suse.de>
5654
5655 * Make-lang.in (java/parse.o-warn, java/parse-scan.o-warn):
5656 New rules to work around old Bison warnings.
5657
5658 2004-10-17 Steven Bosscher <stevenb@suse.de>
5659
5660 * class.c (ident_subst): Always alloca buffer.
5661 * java-opcodes.h (LAST_AND_UNUSED_JAVA_OPCODE): Add this dummy
5662 opcode after including javaop.def.
5663 * jcf-dump.c (CHECK_PC_IN_RANGE): Return 0 from the arm of the
5664 conditional expression that exits, to avoid warnings.
5665 * verify.c (CHECK_PC_IN_RANGE): Mark the __GNUC__ definition as
5666 a user of an extension.
5667 * win32-host.c: Move check down to have non-empty file when
5668 WIN32 is not defined.
5669
5670 * Make-lang.in (java-warn): Add STRICT_WARN.
5671 (java/jcf-io.o-warn): Don't have Werror for this file.
5672 * jcf-io.c (caching_stat): Add FIXME for non-POSIX scandir use.
5673
5674 2004-10-16 Hans-Peter Nilsson <hp@bitrange.com>
5675
5676 * expr.c (expr_add_location): Move declaration to before all
5677 statements.
5678 * parse.y (java_expand_classes): Ditto.
5679 * lex.c (java_peek_unicode): Ditto.
5680
5681 2004-10-16 Ranjit Mathew <rmathew@hotmail.com>
5682
5683 * check-init.c: Use %<, %> and %q for quoting in diagnostics,
5684 if possible, else convert `foo' to 'foo'.
5685 * class.c: Likewise.
5686 * decl.c: Likewise.
5687 * expr.c: Likewise.
5688 * jcf-io.c: Likewise.
5689 * jcf-parse.c: Likewise.
5690 * lang.c: Likewise.
5691 * lex.c: Likewise.
5692 * parse.h: Likewise.
5693
5694 2004-10-16 Ranjit Mathew <rmathew@hotmail.com>
5695
5696 * parse.y (parse_warning_context): Remove ATTRIBUTE_PRINTF_2 and
5697 rename parameter 'msg' to 'msgid' in function declaration.
5698 (issue_warning_error_from_context): Likewise.
5699 (yyerror): Rename parameter 'msg' to 'msgid'.
5700 (all over): Use new quoting style for diagnostics.
5701
5702 2004-10-15 Kazu Hirata <kazu@cs.umass.edu>
5703
5704 * boehm.c, builtins.c, java-except.h, jcf-io.c, jcf-path.c,
5705 jcf.h, lang-specs.h, lex.c, lex.h, resource.c, win32-host.c:
5706 Update copyright.
5707
5708 2004-10-14 Matt Austern <austern@apple.com>
5709
5710 * lang.c (java_tree_inlining_walk_subtrees): Last arg is struct
5711 pointer_set_t* now.
5712
5713 2004-10-13 Tom Tromey <tromey@redhat.com>
5714
5715 PR java/15578:
5716 * lang.opt (--extdirs): Document.
5717 * jvspec.c (lang_specific_driver): Recognize -encoding and
5718 -extdirs.
5719
5720 2004-10-06 Ulrich Weigand <uweigand@de.ibm.com>
5721
5722 * parse.y (issue_warning_error_from_context): Use va_list *
5723 instead of va_list parameter.
5724 (parse_error_context): Update call.
5725 (parse_warning_context): Likewise.
5726
5727 2004-10-05 Zack Weinberg <zack@codesourcery.com>
5728
5729 * parse.y, parse-scan.y: Add list of diagnostic messages to
5730 insulate translation template from version of yacc/bison used
5731 to compile the grammar.
5732
5733 2004-10-05 Ranjit Mathew <rmathew@hotmail.com>
5734
5735 Prepare for %q, %< and %> in diagnostic message strings.
5736 * java-tree.h (parse_error_context): remove ATTRIBUTE_PRINTF_2.
5737 Name second parameter 'msgid'.
5738 * parse.y: Additionally include pretty-print.h and diagnostic.h.
5739 (issue_warning_error_from_context): Use pretty-printer functions
5740 instead of vsprintf for constructing formatted messages. Rename
5741 parameter 'msg' to 'msgid'.
5742 (parse_error_context): Rename parameter 'msg' to 'msgid'.
5743 (parse_warning_context): Likewise.
5744
5745 2004-10-05 Andrew Haley <aph@redhat.com>
5746
5747 PR java/17779
5748 * jcf-parse.c (parse_zip_file_entries): If a class has a
5749 superclass and a TYPE_SIZE of zero, lay it out.
5750
5751 2004-09-30 Andrew Haley <aph@redhat.com>
5752
5753 PR java/17733
5754 * jcf-parse.c (compute_class_name): Rewrite.
5755
5756 2004-10-01 Jan Hubicka <jh@suse.cz>
5757
5758 * java.c (java_expand_body): Update call of tree_rest_of_compilation.
5759
5760 2004-10-01 Kazu Hirata <kazu@cs.umass.edu>
5761
5762 * lex.c: Fix a comment typo.
5763
5764 2004-10-01 Kazu Hirata <kazu@cs.umass.edu>
5765
5766 * java-tree.h: Fix a comment typo.
5767
5768 2004-09-30 Per Bothner <per@bothner.com>
5769
5770 Simplify lexer. Implement --enable-mapped-location support.
5771 * jcf-parse.c (parse_class_file): Use linemap_line_start.
5772 (parse_source_file_1): Pass filename as extra parameter, so we can call
5773 linemap_add and set input_location here, rather than in both callers.
5774 (read_class): Pass copied filename to parse_source_file_1.
5775 Don't initialize wfl_operator - only needed for source compilation.
5776 (read_class, jcf_parse): Call linemap_add with LC_LEAVE.
5777 * lex.h: Remove a bunch of debugging macros.
5778 * lex.h (struct_java_line, struct java_error): Remove types.
5779 (JAVA_COLUMN_DELTA): Remove - use java_lexer.next_colums instead.
5780 (struct java_lc_s): Remove prev_col field.
5781 (struct java_lexer): New fields next_unicode, next_columns, and
5782 avail_unicode. New position field, and maybe token_start field.
5783 Don't need hit_eof field - use next_unicode == -1 instead.
5784 (JAVA_INTEGERAL_RANGE_ERROR): Rename to JAVA_RANGE_ERROR.
5785 (JAVA_RANGE_ERROR, JAVA_FLOAT_ANGE_ERROR): Update accordingly.
5786 * parse.h: Various changes for USE_MAPPED_LOCATION.
5787 (EXPR_WFL_EMIT_LINE_NOTE): XXX
5788 (BUILD_EXPR_WFL, EXPR_WFL_ADD_COL): Remove no-longer-used macros.
5789 (struct parser_ctxt): New file_start_location field.
5790 Remove p_line, c_line fields since we no longer save lines.
5791 Remove elc, lineno, and current_jcf fields - no longer used.
5792 * parse.y: Updates for USE_MAPPED_LOCATION and new lexer.
5793 Don't use EXPR_WFL_ADD_COL since that isn't trivial with
5794 source_location and is probably not needed anymore anyway.
5795 Use new expr_add_Location function.
5796 (SET_EXPR_LOCATION_FROM_TOKEN): New convenience macro.
5797 (java_pop_parser_context): Minor cleanup.
5798 (java_parser_context_save_global, java_parser_context_restore_global,
5799 java_pop_parser_context): Save/restore input_location as a unit.
5800 (issue_warning_error_from_context): If USE_MAPPED_LOCATION take
5801 a source_location instead of a wfl context node.
5802 (check_class_interface_creation): input_filename is not addressable.
5803 (create_artificial_method): Calling java_parser_context_save_global
5804 and java_parser_context_restore_global is overkill. Instead,
5805 temporarily set input_location from class decl.
5806 (java_layout_seen_class_methods): Set input_location from method decl.
5807 (fix_constructors): Make more robust if no EXPR_WITH_FILE_LOCATION.
5808 (finish_loop_body): Likewise.
5809 * lex.c: Updates for USE_MAPPED_LOCATION. Use build_unknwon_wfl.
5810 (java_sprint_unicode): Take a character, not index in line.
5811 (java_sneak_uncode): Replaced by java_peek_unicode.
5812 (java_unget_unicode): No longer used.
5813 (java_allocate_new_line. java_store_unicode): Removed, since we
5814 no longer remember "lines".
5815 (java_new_lexer): Update for new data structures.
5816 (java_read_char): Move unget_value checking to java_read_unicode.
5817 (java_get_unicode, java_peek_unicode, java_next_unicode): New more
5818 efficient functions that are used directly when lexing.
5819 (java_read_unicode_collapsing_terminators): No longer needed.
5820 (java_parse_end_comment, java_parse_escape_sequence, do_java_lex):
5821 Re-organize to use java_peek_unicode to avoid java_unget_unicode.
5822 (java_parse_escape_sequence): Rewrite to be simpler / more efficient.
5823 (do_java_lex): Lots of movings around to avoid java_unget_unicode,
5824 combine switch branches, and test for common token kinds earlier.
5825 (java_lex_error): Rewrite.
5826 * jv-scan.c (expand_location): New function, copied from tree.c.
5827 (main): Set ctxp->filename instead of setting input_filename directly.
5828
5829 2004-09-30 Per Bothner <per@bothner.com>
5830
5831 More cleanup for --enable-mapped-location.
5832 * class.c (push_class): If USE_MAPPED_LOCATION don't set
5833 input_location here. Instead do it in give_name_to_class.
5834 (build_class_ref): Set DECL_ARTIFICIAL, for the sake of dwarf2out.
5835 * expr.c (expand_byte_code): Call linemap_line_start.
5836 * expr.c (build_expr_wfl): If USE_MAPPED_LOCATION, change final
5837 parameters to a source_location. Don't need EXPR_WFL_FILENAME_NODE.
5838 (expr_add_location): New function, if USE_MAPPED_LOCATION.
5839 * class.c (maybe_layout_super_class): Adjust build_expr_wfl call
5840 to USE_MAPPED_LOCATION case.
5841
5842 * java-tree.h (JAVA_FILE_P, ZIP_FILE_P): Remove unused macros.
5843 * jcf-parse.c (java_parse_file): Don't set input_filename.
5844 Use IS_A_COMMAND_LINE_FILENAME_P to check for duplicate filenames.
5845 Create a list of TRANSLATION_UNIT_DECL.
5846 (current_file_list): Is now a TRANSLATION_UNIT_DECL chain. The
5847 reason is so we can set a DECL_SOURCE_LOCATION for each file.
5848 (java_parse_file): Don't set unused ZIP_FILE_P, JAVA_FILE_P..
5849 Create line-map LC_ENTER/LC_LEAVE entries for archive itself.
5850 (file_start_location): New static.
5851 (set_source_filename): Avoid extra access to input_filename macro.
5852 Concatenate new name with class's package prefix.
5853 (set_source_filename, give_name_to_class): Update.
5854 (give_name_to_class): Set class's "line 0" input_location here.
5855 (parse_class_file): Set input_location as a unit.
5856
5857 * jcf-parse.c (load_class): Sanity test if missing inner class file.
5858
5859 2004-09-29 Per Bothner <per@bothner.com>
5860
5861 * java-tree.h: Redefine some macros and add some declaration
5862 to handle the USE_MAPPED_LOCATION case.
5863 * parse.h (EXPR_WFL_QUALIFICATION): Use operand 1, not 2.
5864 * java-tree.h (EXPR_WFL_FILENAME_NODE): Use operand 2, not 1.
5865 * java-tree.def (EXPR_WITH_FILE_LOCATION): Only need two operands in
5866 USE_MAPPED_LOCATION case, since EXPR_WFL_FILENAME_NODE is gone.
5867
5868 * check-init.c (check_init): Handle USE_MAPPED_LOCATION case.
5869 * decl.c (finish_method, java_add_stmt): Likewise.
5870 * java-gimplify.c (java-gimplify.c): Likewise.
5871 * jcf-write.c (generate_bytecode_insns): Likewise.
5872 * lang.c (java_post_options): Likewise - call linemap_add.
5873
5874 2004-09-29 Andrew Haley <aph@redhat.com>
5875
5876 PR java/17007
5877 * parse.y (patch_binop): Don't mess with the TREE_SIDE_EFFECTS of the
5878 result of TRUNC_MOD_EXPR.
5879 (patch_unaryop): Likewise for CONVERT_EXPR, which may throw.
5880 * decl.c (java_init_decl_processing): Mark
5881 soft_lookupinterfacemethod_node and soft_instanceof_node pure.
5882
5883 2004-09-28 Tom Tromey <tromey@redhat.com>
5884
5885 PR java/15710:
5886 * class.c (add_miranda_methods): Load superinterface if not
5887 already loaded.
5888
5889 2004-09-28 Andrew Haley <aph@redhat.com>
5890
5891 PR java/17586
5892 * jcf-parse.c (load_class): Don't try to read a class that we've
5893 already read.
5894
5895 2004-09-28 Andrew Haley <aph@redhat.com>
5896
5897 * jcf-parse.c (load_class): Back out previous broken patch.
5898
5899 2004-09-28 Andrew Haley <aph@redhat.com>
5900
5901 PR java/17586
5902 * jcf-parse.c (load_class): Don't try to read a class that we've
5903 already read.
5904 Check that we really did read the right class.
5905
5906 2004-09-25 Tom Tromey <tromey@redhat.com>
5907
5908 PR java/17500:
5909 * parse.y (create_artificial_method): Use add_method_1.
5910
5911 2004-09-25 Kazu Hirata <kazu@cs.umass.edu>
5912
5913 * expr.c, jcf-dump.c, parse-scan.y, parse.y: Fix
5914 comment typos.
5915 * gcj.texi: Fix typos.
5916
5917 2004-09-24 Tom Tromey <tromey@redhat.com>
5918
5919 PR java/15656:
5920 * parse.y (class_instance_creation_expression): Set `$$' to NULL
5921 in error parts of rule.
5922 (unary_expression): Don't call error_if_numeric_overflow when $1
5923 is NULL.
5924
5925 2004-09-24 Tom Tromey <tromey@redhat.com>
5926
5927 PR java/16789:
5928 * parse.y (resolve_qualified_expression_name): Set
5929 CAN_COMPLETE_NORMALLY on first call when chaining static calls.
5930 * expr.c (force_evaluation_order): Check for empty argument list
5931 after stripping COMPOUND_EXPR.
5932
5933 2004-09-23 Andrew Haley <aph@redhat.com>
5934
5935 PR java/16927:
5936 * parse.y (java_complete_lhs): Call patch_string() on Operand 1 of
5937 COND_EXPRs.
5938
5939 2004-09-23 Tom Tromey <tromey@redhat.com>
5940
5941 PR java/17329:
5942 * java-gimplify.c (java_gimplify_expr) <SAVE_EXPR>: Ignore case
5943 where operand is null.
5944
5945 2004-09-23 Tom Tromey <tromey@redhat.com>
5946
5947 PR java/17380:
5948 * parse.y (not_accessible_p): Allow access to protected members
5949 even when class is not static.
5950
5951 2004-09-22 Kelley Cook <kcook@gcc.gnu.org>
5952
5953 * Make-lang.in: Revert the gcc-none.o change.
5954
5955 2004-09-22 Nathan Sidwell <nathan@codesourcery.com>
5956
5957 * parse.y (patch_anonymous_class): VEC_space returns true if there
5958 is space.
5959
5960 2004-09-21 Matt Austern <austern@apple.com>
5961
5962 Fix bootstrap.
5963 * gjavah.c (free_method_name_list): Fix function definition so
5964 it's a proper C prototype.
5965
5966 2004-09-21 Tom Tromey <tromey@redhat.com>
5967
5968 PR java/17575:
5969 * gjavah.c (free_method_name_list): New method.
5970 (main): Call it.
5971
5972 2004-09-17 Jeffrey D. Oldham <oldham@codesourcery.com>
5973 Zack Weinberg <zack@codesourcery.com>
5974
5975 * java-tree.def: Use tree_code_class enumeration constants
5976 instead of code letters.
5977 * java-gimplify.c, jcf-write.c, lang.c, parse.y: Update for
5978 new tree-class enumeration constants.
5979
5980 2004-09-13 Tom Tromey <tromey@redhat.com>
5981
5982 PR java/17216:
5983 * class.c (layout_class_method): Put synthetic methods into the
5984 vtable.
5985
5986 2004-09-11 Andrew Pinski <apinski@apple.com>
5987
5988 * Make-lang.in (java/ggc-none.c): Change dependency
5989 for ggc.h into $(GGC_H).
5990
5991 2004-09-11 Mohan Embar <gnustuff@thisiscool.com>
5992
5993 * Make-lang.in (java/win32-host.o): Add dependency on
5994 coretypes.h.
5995 * win32-host.c: Add includes for coretypes.h, jcf.h
5996
5997 2004-09-11 Mohan Embar <gnustuff@thisiscool.com>
5998
5999 * Make-lang.in (GCJH_OBJS): Change dependency from
6000 ggc-none.o to java/ggc-none.o
6001 (JCFDUMP_OBJS): Likewise.
6002 (java/ggc-none.o): New target.
6003
6004 2004-08-25 Nathan Sidwell <nathan@codesourcery.com>
6005
6006 * boehm.c (get_boehm_type_descriptor): Adjust build_int_cst calls.
6007 * class.c (build_utf8_ref, build_static_field_ref,
6008 make_field_value, make_method_value, get_dispatch_table,
6009 make_class_data, emit_symbol_table, emit_catch_table): Likewise.
6010 * constants.c (get_tag_node, build_ref_from_constant_pool,
6011 build_constants_constructor): Likewise.
6012 * decl.c (java_init_decl_processing): Likewise.
6013 * expr.c (build_java_array_length_access, build_newarray,
6014 expand_java_multianewarray, expand_java_pushc, expand_iinc,
6015 build_java_binop, build_field_ref, expand_java_add_case,
6016 expand_java_call, build_known_method_ref, build_invokevirtual,
6017 build_invokeinterface, build_jni_stub): Likewise.
6018 * java-gimplify.c (java_gimplify_new_array_init): Likewise.
6019 * jcf-parse.c (get_constant): Likewise.
6020 * lex.c (do_java_lex): Likewise.
6021 * parse.y (patch_binop, patch_unaryop, patch_cast,
6022 build_newarray_node, patch_newarray): Likewise.
6023 * resource.c (compile_resource_data): Likewise.
6024 * typeck.c (build_prim_array_type): Likewise.
6025
6026 2004-08-24 Nathan Sidwell <nathan@codesourcery.com>
6027
6028 * decl.c (java_init_decl_processing): Adjust
6029 initialize_sizetypes call.
6030
6031 2004-08-23 Nathan Sidwell <nathan@codesourcery.com>
6032
6033 * jv-scan.c (fancy_abort): Add.
6034
6035 2004-08-20 Nathan Sidwell <nathan@codesourcery.com>
6036
6037 * expr.c (build_java_arrayaccess): Use convert to change
6038 len's type.
6039
6040 2004-08-19 Bryce McKinlay <mckinlay@redhat.com>
6041
6042 * class.c (make_local_function_alias): Allocate extra space for 'L'
6043 in name buffer. Reported by Thomas Neumann.
6044
6045 2004-08-19 Nathan Sidwell <nathan@codesourcery.com>
6046
6047 * parse.h (JAVA_RADIX10_FLAG): Rename to ...
6048 (JAVA_NOT_RADIX10_FLAG): ... here. Invert meaning.
6049 * lex.c (do_java_lex): Adjust.
6050 (error_if_numeric_overflow): Likewise.
6051
6052 2004-08-18 Andrew Pinski <apinski@apple.com>
6053
6054 * class.c (make_local_function_alias): Only make a new decl if we
6055 support alias attribute on all decls.
6056
6057 2004-08-18 Bryce McKinlay <mckinlay@redhat.com>
6058
6059 * class.c (make_local_function_alias): New function. Create local
6060 alias for public method DECL.
6061 (make_method_value): Use make_local_function_alias.
6062 * parse.y (craft_constructor): Don't special-case anonymous classes.
6063 Always set ctor_name to init_identifier_node.
6064 (lookup_method_invoke): Call layout_class_method when creating
6065 anonymous class constructor.
6066
6067 2004-08-18 Richard Henderson <rth@redhat.com>
6068
6069 * java-gimplify.c (java_gimplify_expr): Move '2' handling into
6070 default case. Treat '<' similarly. Update for
6071 is_gimple_formal_tmp_var name change.
6072
6073 2004-08-17 Andrew Haley <aph@redhat.com>
6074
6075 * lang.c (lang_printable_name): Obey verbose flag.
6076 * parse.y (constructor_circularity_msg): Set VERBOSE arg for
6077 lang_printable_name().
6078 (verify_constructor_circularity, get_printable_method_name,
6079 check_abstract_method_definitions, java_check_regular_methods,
6080 java_check_abstract_methods, check_inner_class_access,
6081 fix_constructors, patch_method_invocation, patch_return):
6082 Likewise.
6083 * expr.c (pop_type_0): Likewise.
6084
6085 * java-tree.h (lang_printable_name_wls): Delete.
6086
6087 2004-08-16 Tom Tromey <tromey@redhat.com>
6088
6089 PR java/8473:
6090 * parse.y (primary): Changed for initialized and uninitialized
6091 array creations.
6092 (array_access): Handle array_creation_initialized.
6093 (array_creation_expression): Split into
6094 array_creation_initialized and array_creation_uninitialized.
6095
6096 2004-08-16 Andrew Haley <aph@redhat.com>
6097
6098 * jcf-write.c (find_constant_index): Canonicalize NaNs when
6099 generating bytecode.
6100
6101 2004-08-16 Elliot Lee <sopwith@redhat.com>
6102
6103 PR java/9677
6104 * jcf-parse.c (java_parse_file): Handle filenames with embedded
6105 spaces, and quoted filelists.
6106
6107 2004-08-15 Nathan Sidwell <nathan@codesourcery.com>
6108
6109 * boehm.c (get_boehm_type_descriptor): Use build_int_cst.
6110 * class.c (build_utf8_ref, build_static_field_ref,
6111 make_field_value, make_method_value, get_dispatch_table,
6112 make_class_data, emit_symbol_table, emit_catch_table): Likewise.
6113 * constants.c (get_tag_node, build_ref_from_constant_pool,
6114 build_constants_constructor): Likewise.
6115 * decl.c (java_init_decl_processing): Likewise.
6116 * expr.c (build_java_array_length_access, build_newarray,
6117 expand_java_multianewarray, expand_java_pushc, expand_iinc,
6118 build_java_binop, build_field_ref, expand_java_add_case,
6119 expand_java_call, build_known_method_ref, build_invokevirtual,
6120 build_invokeinterface, build_jni_stub): Likewise.
6121 * java-gimplify.c (java_gimplify_new_array_init): Likewise.
6122 * jcf-parse.c (get_constant): Likewise.
6123 * lex.c (do_java_lex): Likewise.
6124 * parse.y (patch_binop, patch_unaryop, patch_cast,
6125 build_null_of_type, patch_newarray): Likewise.
6126 * resource.c (compile_resource_data): Likewise.
6127 * typeck.c (build_prim_array_type): Likewise.
6128
6129 2004-08-10 Bryce McKinlay <mckinlay@redhat.com>
6130
6131 * java-gimplify.c (java_gimplify_new_array_init): Use create_tmp_var.
6132 Don't create BLOCK here or call java_gimplify_block.
6133
6134 2004-08-09 H.J. Lu <hongjiu.lu@intel.com>
6135
6136 * java-tree.h (flag_deprecated): Removed.
6137 * lang.opt (Wdeprecated): Use existing Var(warn_deprecated).
6138 * parse.y (check_deprecation): Check warn_deprecated instead of
6139 flag_deprecated.
6140
6141 2004-08-06 Kelley Cook <kcook@gcc.gnu.org>
6142
6143 * lang.c (flag_emit_class_files, flag_filelist_file, flag_redundant,
6144 flag_use_divide_subroutine, flag_use_boehm_gc, flag_store_check,
6145 flag_hash_synchronization, flag_assert, flag_jni, flag_newer,
6146 flag_check_references, flag_extraneous_semicolon, flag_deprecated,
6147 flag_force_classes_archive_check, flag_optimize_sci,
6148 flag_indirect_dispatch): Remove explicit declarations.
6149 * lang.opt: Add implicit declare/define/assign. Remove obsolete
6150 final comment.
6151
6152 2004-08-05 Michael Chastain <mec.gnu@mindspring.com>
6153
6154 PR bootstrap/14893
6155 * Make-lang.in (java.install-man): Install from either build
6156 tree or source tree, whichever has the file first.
6157
6158 2004-08-05 Nathan Sidwell <nathan@codesourcery.com>
6159
6160 * jcf-parse.c (get_constant): Adjust force_fit_type call.
6161 * lex.h (SET_LVAL_NODE_TYPE): Remove.
6162 * lex.c (java_perform_atof): Use SET_LVAL_NODE directly.
6163 (do_java_lex): Likewise. Adjust force_fit_type call.
6164
6165 2004-08-04 Roger Sayle <roger@eyesopen.com>
6166 Andrew Haley <aph@redhat.com>
6167
6168 * typeck.c (convert_ieee_real_to_integer): Call fold on the range
6169 checking trees as they're being built.
6170 (convert): Call convert_ieee_real_to_integer if we're
6171 converting a constant, even if we're writing a class file.
6172
6173 2004-08-02 Bryce McKinlay <mckinlay@redhat.com>
6174
6175 PR java/16701
6176 * parse.y (fold_constant_for_init): Call resolve_field_access with
6177 correct current_class context.
6178
6179 2004-08-01 Roger Sayle <roger@eyesopen.com>
6180
6181 * decl.c (update_aliases, initialize_local_variable): Replace calls
6182 to build with calls to buildN.
6183 * java-gimplify.c (java_gimplify_modify_expr): Likewise.
6184 * java-tree.h (BUILD_MONITOR_ENTER, BUILD_MONITOR_EXIT): Likewise.
6185 * parse.h (BUILD_THROW): Likewise.
6186 * parse.y (switch_expression, synchronized_statement,
6187 catch_clause_parameter, array_creation_expression,
6188 conditional_expression, make_qualified_name,
6189 resolve_qualified_expression_name, patch_method_invocation,
6190 patch_invoke, build_method_invocation, build_new_invocation,
6191 build_assignment, patch_assignment, build_binop, patch_binop,
6192 build_string_concatenation, build_incdec, patch_unaryop,
6193 patch_cast, build_array_ref, build_newarray_node, patch_newarray,
6194 patch_return, build_if_else_statement, build_labeled_block,
6195 build_new_loop, build_loop_body, build_bc_statement,
6196 build_assertion, encapsulate_with_try_catch, build_try_statement,
6197 build_try_finally_statement, patch_synchronized_statement,
6198 emit_test_initialization): Likewise, replace build with buildN.
6199
6200 2004-07-28 Eric Christopher <echristo@redhat.com>
6201
6202 * lang.c (LANG_HOOKS_UNSAFE_FOR_REEVAL): Delete.
6203 (java_unsafe_for_reeval): Ditto.
6204
6205 2004-07-26 <hp@bitrange.com>
6206
6207 * parse.y (build_super_invocation): Adjust declaration order to
6208 avoid declaration after statement.
6209
6210 2004-07-25 Bernardo Innocenti <bernie@develer.com>
6211
6212 * decl.c: Rename all identifiers named `class' to `cl'.
6213
6214 2004-07-25 Richard Henderson <rth@redhat.com>
6215
6216 * decl.c (build_result_decl): Set DECL_ARTIFICIAL and DECL_IGNORED_P.
6217
6218 2004-07-23 Mike Stump <mrs@apple.com>
6219
6220 * boehm.c (set_bit): Improve type safety wrt unsignedness.
6221 * gjavah.c (throwable_p, decode_signature_piece,
6222 print_full_cxx_name, print_include, add_namelet, add_class_decl,
6223 process_file): Likewise.
6224 * jcf-dump.c (main): Likewise.
6225 * jcf-io.c (read_zip_member): Likewise.
6226 * jcf-parse.c (HANDLE_CONSTANT_Utf8, get_constant,
6227 give_name_to_class, get_class_constant): Likewise.
6228 * jcf-write.c (find_constant_wide, push_long_const,
6229 generate_classfile): Likewise.
6230 * lex.c (java_new_lexer, java_read_char, cxx_keyword_p): Likewise.
6231 * parse.y (read_import_dir): Likewise.
6232 * typeck.c (parse_signature_type): Likewise.
6233 * verify.c (verify_jvm_instructions): Likewise.
6234 * zextract.c (find_zip_file_start, read_zip_archive): Likewise.
6235
6236 2004-07-23 Thomas Fitzsimmons <fitzsim@redhat.com>
6237
6238 * Make-lang.in: Replace rmic and rmiregistry references with
6239 grmic and grmiregistry.
6240 * gcj.texi: Likewise.
6241
6242 2004-07-20 Andrew Haley <aph@redhat.com>
6243
6244 PR java/16431.
6245 * verify.c (verify_jvm_instructions): Comment change only.
6246
6247 * typeck.c (build_java_array_type): Add size field to array name.
6248
6249 * java-tree.h (LOCAL_SLOT_P): New.
6250 (update_aliases): Add PC argument.
6251 (pushdecl_function_level): New function.
6252
6253 * java-gimplify.c (java_gimplify_expr): Handle VAR_DECL,
6254 MODIFY_EXPR, and SAVE_EXPR.
6255 (java_gimplify_modify_expr): New function.
6256
6257 * expr.c (push_type_0): Call find_stack_slot() to create temporary.
6258 (expand_iinc): Pass PC to update_aliases().
6259 (STORE_INTERNAL): Likewise.
6260 (process_jvm_instruction): Likewise.
6261
6262 * decl.c (base_decl_map): New variable.
6263 (uniq): New variable.
6264 (update_aliases): Rewrite with more thorough checking.
6265 (debug_variable_p): New function.
6266 (push_jvm_slot): Don't initialize local variable. Don't pushdecl.
6267 (check_local_named_variable): Delete whole function.
6268 (initialize_local_variable): New function.
6269 (check_local_unnamed_variable): Add checks and comments.
6270 (find_local_variable): Rewrite.
6271 (java_replace_reference): New function.
6272 (function_binding_level): New variable.
6273 (pushdecl_function_level): New function.
6274 (maybe_pushlevels): Set DECL_LOCAL_END_PC.
6275 (maybe_pushlevels): Call pushdecl() on each of the new decls.
6276 (start_java_method): Reset uniq. Create base_decl_map. Set
6277 function_binding_level.
6278 (end_java_method): Null unused fields to save memory.
6279
6280 2004-07-20 Nathan Sidwell <nathan@codesourcery.com>
6281
6282 * class.c (add_interface_do): Remove.
6283 (set_super_info, interface_of_p, maybe_add_interface,
6284 add_interface, make_class_data, layout_class,
6285 add_miranda_methods): Adjust BINFO accessors and addition.
6286 * expr.c (can_widen_reference_to, lookup_field): Adjust BINFO
6287 accessors.
6288 * jcf-write.c (generate_classfile): Likewise.
6289 * parse.y (patch_anonymous_class, check_inner_circular_reference,
6290 check_circular_reference, java_complete_class,
6291 check_abstract_method_definitions,
6292 java_check_abstract_method_definitions,
6293 check_interface_throws_clauses, java_check_abstract_methods,
6294 lookup_java_interface_method2,
6295 find_applicable_accessible_methods_list): Adjust BINFO accessors
6296 and addition.
6297 * typeck.c (find_method_in_interfaces): Adjust BINFO accessors.
6298
6299 2004-07-18 Roger Sayle <roger@eyesopen.com>
6300
6301 * builtins.c (max_builtin, min_builtin,
6302 java_build_function_call_expr): Replace calls to build with buildN.
6303 * class.c (build_class_ref, build_static_field_ref,
6304 get_dispatch_table, make_class_data, layout_class_method): Likewise.
6305 * constants.c (build_ref_from_constant_pool): Likewise.
6306 * decl.c (update_aliases, push_jvm_slot, poplevel, finish_method,
6307 add_stmt_to_compound): Likewise.
6308 * except.c (build_exception_object_ref, expand_end_java_handler):
6309 Likewise.
6310 * java-gimplify.c (java_gimplify_case_expr,
6311 java_gimplify_default_expr, java_gimplify_block,
6312 java_gimplify_new_array_init, java_gimplify_try_expr): Likewise.
6313 * jcf-write.c (generate_bytecode_insns): Likewise.
6314 * typeck.c (convert_ieee_real_to_integer): Likewise.
6315
6316 2004-07-17 Joseph S. Myers <jsm@polyomino.org.uk>
6317
6318 * java-tree.h (builtin_function): Declare.
6319
6320 2004-07-16 Steven Bosscher <stevenb@suse.de>
6321
6322 * parse.y (java_complete_expand_methods, java_expand_classes): Don't
6323 abuse restore_line_number_status.
6324
6325 2004-07-15 Frank Ch. Eigler <fche@redhat.com>
6326
6327 g++/15861
6328 * jcf-parse.c (java_emit_static_constructor): Specify default
6329 priority.
6330
6331 2004-07-13 Per Bothner <per@bothner.com>
6332
6333 * java-tree.h (all_class_filename): Remove useless macro.
6334 (enum java_tree_index): Remove JTI_ALL_CLASS_FILENAME constant.
6335 (BUILD_FILENAME_IDENTIFIER_NODE): Remove useless macro.
6336 * parse.y (java_parser_context_restore_global): Replace
6337 BUILD_FILENAME_IDENTIFIER_NODE by plain get_identifier.
6338 * jcf-parse.c (read_class, java_parse_file): Likewise.
6339
6340 2004-07-12 Bryce McKinlay <mckinlay@redhat.com>
6341
6342 PR java/16474
6343 gjavah.c (print_field_info): Emit constant only if field is static.
6344
6345 2004-07-11 Roger Sayle <roger@eyesopen.com>
6346
6347 * expr.c (java_truthvalue_conversion, flush_quick_stack,
6348 java_stack_swap, java_stack_dup, build_java_athrow, build_java_jsr,
6349 build_java_ret, build_java_throw_out_of_bounds_exception,
6350 build_java_array_length_access, java_check_reference,
6351 build_java_arrayaccess, build_java_arraystore_check, build_newarray,
6352 build_anewarray, expand_java_multianewarray, expand_java_arraystore,
6353 expand_java_arrayload, build_java_monitor, expand_java_return,
6354 expand_load_internal, expand_java_NEW, build_get_class,
6355 build_instanceof, expand_java_CHECKCAST, expand_iinc,
6356 build_java_soft_divmod, build_java_binop, build_field_ref,
6357 expand_compare, expand_java_goto, expand_java_switch,
6358 expand_java_add_case, build_class_init, build_known_method_ref,
6359 invoke_build_dtable, build_invokevirtual, build_invokeinterface,
6360 expand_invoke, build_jni_stub, expand_java_field_op,
6361 java_expand_expr, expand_byte_code, STORE_INTERNAL,
6362 force_evaluation_order, emit_init_test_initialization): Convert
6363 calls to "build" into calls to the prefered "buildN" functions.
6364
6365 2004-07-11 Joseph S. Myers <jsm@polyomino.org.uk>
6366
6367 * java-tree.h (set_block): Remove.
6368 * lang.c (java_clear_binding_stack): New.
6369 (LANG_HOOKS_CLEAR_BINDING_STACK): Define.
6370 * decl.c (struct binding_level): Remove this_block.
6371 (clear_binding_level): Likewise.
6372 (poplevel): Don't handle this_block.
6373 (set_block): Remove.
6374
6375 2004-07-10 Bryce McKinlay <mckinlay@redhat.com>
6376
6377 * class.c (common_enclosing_context_p): Remove statement with no
6378 side-effects.
6379
6380 2004-07-09 Bryce McKinlay <mckinlay@redhat.com>
6381
6382 PR java/8618
6383 * parse.y (create_anonymous_class): Remove 'location' argument. Use
6384 the WFL from TYPE_NAME to get line number for the decl. Fix comment.
6385 (craft_constructor): Inherit access flags for implicit constructor
6386 from the enclosing class.
6387 (create_class): Fix comment typo.
6388 (resolve_qualified_expression_name): Pass type of qualifier to
6389 not_accessible_p, not the type in which target field was found.
6390 (not_accessible_p): Handle inner classes. Expand protected
6391 qualifier-subtype check to enclosing instances, but don't apply this
6392 check to static members. Allow protected access to inner classes
6393 of a subtype. Allow private access within common enclosing context.
6394 (build_super_invocation): Get WFL line number info from current
6395 class decl.
6396 (build_incomplete_class_ref): Update for new create_anonymous_class
6397 signature.
6398 * parse.h (INNER_ENCLOSING_SCOPE_CHECK): Use
6399 common_enclosing_instance_p.
6400 * class.c (common_enclosing_context_p): New. Determine if types
6401 share a common enclosing context, even across static contexts.
6402 (common_enclosing_instance_p): Renamed from
6403 common_enclosing_context_p. Determines if types share a common
6404 non-static enclosing instance.
6405 * java-tree.h (common_enclosing_instance_p): Declare.
6406 * jcf-write.c (get_method_access_flags): New. Surpress private flag
6407 for inner class constructors.
6408 (generate_classfile): Use get_method_access_flags.
6409
6410 2004-07-09 Bryce McKinlay <mckinlay@redhat.com>
6411
6412 * class.c (interface_of_p): Check for null TYPE_BINFO.
6413
6414 2004-07-09 Nathan Sidwell <nathan@codesourcery.com>
6415
6416 * class.c (make_class): Do not create binfo here.
6417 (set_super_info): Create it here.
6418 * java-tree.h (CLASS_HAS_SUPER): Cope with lack of a binfo.
6419
6420 2004-07-08 Richard Henderson <rth@redhat.com>
6421
6422 * expr.c (case_identity, get_primitive_array_vtable,
6423 java_expand_expr, emit_init_test_initialization): Remove.
6424 * java-tree.h (java_expand_expr): Remove.
6425 * lang.c (LANG_HOOKS_EXPAND_EXPR): Remove.
6426
6427 2004-07-07 Per Bothner <per@bothner.com>
6428
6429 * class.c (build_static_field_ref): Add a NOP_EXPR; otherwise we
6430 get internal error due to mismatched types.
6431
6432 * gcj.texi (Invoking gij): Document new -verbose:class flag.
6433
6434 * gcj.texi (Linking): New node. Document -lgij usage.
6435
6436 2004-07-07 Nathan Sidwell <nathan@codesourcery.com>
6437
6438 * java-tree.h (CLASSTYPE_SPUER): Adjust BINFO macros.
6439 (TYPE_NVIRTUALS, TYPE_VTABLE): Likewise.
6440 * java/class.c (set_super_info, class_depth, interface_of_p,
6441 maybe_add_interface, add_interface, make_class_data,
6442 layout_class, add_miranda_methods): Adjust BINFO macros.
6443 * expr.c (can_widen_reference_to, lookup_field): Likewise.
6444 * jcf-write.c (generate_classfile): Likewise.
6445 * parse.y (patch_anonymous_class,
6446 check_inner_circular_reference, check_circular_reference,
6447 java_complete_class, check_abstract_method_definitions,
6448 java_check_abstract_method_definitions,
6449 check_interface_throws_clauses, java_check_abstract_methods,
6450 lookup_java_interface_method2,
6451 find_applicable_accessible_methods_list): Likewise.
6452 * typeck.c (find_method_in_interface): Likewise.
6453 * verify.c (merge_types): Likewise.
6454
6455 2004-07-06 Nathan Sidwell <nathan@codesourcery.com>
6456
6457 * java-tree.h (CLASS_HAS_SUPER_FLAG): Use BINFO_FLAG_1.
6458 * class.c (add_interface_do): Use BINFO_VIRTUAL_P.
6459
6460 2004-07-05 Nathan Sidwell <nathan@codesourcery.com>
6461
6462 * class.c (make_class): Use make_tree_binfo.
6463 (set_super_info, add_interface_do): Likewise.
6464 * java-tree.h (CLASS_HAS_SUPER_FLAG): Expect a BINFO.
6465
6466 2004-07-04 Ranjit Mathew <rmathew@hotmail.com>
6467
6468 * verify.c: Correct array element access formatting thinko.
6469
6470 2004-07-04 Ranjit Mathew <rmathew@hotmail.com>
6471
6472 * verify.c: Insert a short blurb at the start referring to the JVMS.
6473 (merge_type_state): Remove redundant nested if statement.
6474 (verify_jvm_instructions): Ensure current_subr is initialised to
6475 NULL_TREE.
6476 Minor formatting fixes all over the place.
6477
6478 2004-07-02 Richard Henderson <rth@redhat.com>
6479
6480 * jcf-write.c (generate_bytecode_insns <case SAVE_EXPR>): Rewrite.
6481
6482 2004-07-01 Richard Henderson <rth@redhat.com>
6483
6484 * class.c (registerClass_libfunc): Remove.
6485 (init_class_processing): Don't set it.
6486 (emit_register_classes): Take list_p parameter. Fill it in
6487 with _Jv_RegisterClass calls.
6488 * decl.c (java_init_decl_processing): Don't call
6489 init_resource_processing.
6490 * jcf-parse.c (java_emit_static_constructor): New.
6491 (java_parse_file): Call it.
6492 * resource.c (registerResource_libfunc): Remove.
6493 (init_resource_processing): Remove.
6494 (write_resource_constructor): Take list_p parameter. Fill it in
6495 with _Jv_RegisterResource calls.
6496 * java-tree.h: Update prototypes.
6497
6498 2004-06-29 Bryce McKinlay <mckinlay@redhat.com>
6499
6500 PR java/1262
6501 * class.c (layout_class_method): Do not override package-private
6502 method if its in a different package.
6503 (split_qualified_name): Move here from parse.y. Rename from
6504 breakdown_qualified. Add comment.
6505 (in_same_package): Move here from parse.y. Add comment.
6506 * java-tree.h (break_down_qualified, in_same_package): Declare.
6507 (in_same_package): Likewise.
6508 * parse.y (breakdown_qualified, in_same_package): Moved to class.c.
6509 Callers updated.
6510
6511 2004-06-29 Andrew Haley <aph@redhat.com>
6512
6513 * except.c (expand_start_java_handler): Push a new binding level.
6514 Don't build a TRY_CATCH_EXPR now, we'll do it later. Call
6515 register_exception_range() to register where we'll do it.
6516 (expand_end_java_handler): Remove old bogus code. Replace with
6517 new logic that simply builds TRY_CATCH_EXPRs and inserts them at
6518 the top of the expression we're curently building.
6519 (maybe_end_try): Delete.
6520 * decl.c (binding_level.exception_range): New field.
6521 (clear_binding_level): Add field exception_range. Reformat.
6522 (poplevel): Call expand_end_java_handler().
6523 (poplevel): Call java_add_stmt only if functionbody is false.
6524 (maybe_poplevels): Don't call maybe_end_try() from here.
6525 (end_java_method): Clear no longer used trees in function decl.
6526 (register_exception_range): New function.
6527 * java-tree.h (register_exception_range, struct eh_range): Declare.
6528
6529 2004-06-28 Bryce McKinlay <mckinlay@redhat.com>
6530
6531 * jcf-write.c (get_classfile_modifiers): Formatting fixes.
6532
6533 2004-06-27 Ranjit Mathew <rmathew@hotmail.com>
6534
6535 Formatting fixes.
6536 * expr.c (class_has_finalize_method): Fix method name indentation.
6537 (expand_java_call): Remove K&R style parameter declaration.
6538 (expand_invoke): Fix statement indentation.
6539 (expand_java_field_op): Likewise.
6540 * parse-scan.y: Fix typo.
6541 (reset_report): Fix method name indentation.
6542 * parse.y (unresolved_type_p, build_expr_block): Remove extra blank
6543 line. Fix typos.
6544 * verify.c (verify_jvm_instructions): Document parameters, insert
6545 page break.
6546 * lang.c (lang_init_source): Fix method name indentation.
6547 * class.c (common_enclosing_context_p): Likewise.
6548 (emit_symbol_table): Fix parameter list indentation.
6549 * decl.c (add_stmt_to_compound, java_add_stmt): Remove K&R style
6550 parameter declaration.
6551 * constants.c: Fix copyright notice indentation.
6552 * typeck.c (find_method_in_superclasses): Fix parameter list
6553 indentation.
6554 (find_method_in_interfaces): Likewise.
6555 * zextract.c (makelong): Fix method name indentation.
6556
6557 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
6558
6559 PR java/15715.
6560 * parse.y (create_interface): Set correct access modifiers for
6561 interfaces.
6562 * jcf-write.c (get_classfile_modifiers): New function.
6563 (generate_classfile): Use get_classfile_modifiers, not
6564 get_access_flags.
6565
6566 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
6567
6568 * parse.y (register_incomplete_type): Set JDEP_ENCLOSING for "super"
6569 dependency to current parser context, not NULL_TREE, for top-level
6570 classes.
6571 (jdep_resolve_class): Enable member access check for all inner
6572 class dependencies.
6573
6574 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
6575
6576 * parse.y (qualify_and_find): Pass type decl, not identifier, to
6577 load_class.
6578
6579 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
6580
6581 PR java/15734
6582 * expr.c (expand_java_field_op): Ensure that target class for static
6583 field access has been loaded.
6584
6585 2004-06-26 Bryce McKinlay <mckinlay@redhat.com>
6586 Ranjit Mathew <rmathew@hotmail.com>
6587
6588 PR java/1207, java/16178
6589 * jcf-parse.c (load_class): Return immediately if passed a type decl
6590 where CLASS_FROM_SOURCE_P is set. Remove FIXME.
6591 * parse.y (do_resolve_class): Remove checks for CLASS_FROM_SOURCE_P
6592 before calling load_class.
6593 (qualify_and_find): Likewise.
6594 (find_in_imports_on_demand): Likewise.
6595 (find_applicable_accessible_methods_list): Likewise.
6596
6597 2004-06-24 Bryce McKinlay <mckinlay@redhat.com>
6598
6599 * parse.y (java_layout_seen_class_methods): Don't call load_class
6600 on class defined by source parser.
6601
6602 2004-06-23 Bryce McKinlay <mckinlay@redhat.com>
6603
6604 * parse.y (set_nested_class_simple_name_value): Removed.
6605 (java_complete_expand_class): Remove calls to
6606 set_nested_class_simple_name_value.
6607
6608 2004-06-22 Andrew Haley <aph@redhat.com>
6609 Ranjit Mathew <rmathew@hotmail.com>
6610
6611 Fixes PR java/16113.
6612 * decl.c (force_poplevels): Remove call to expand_end_bindings.
6613
6614 2004-06-22 Ranjit Mathew <rmathew@hotmail.com>
6615
6616 * parse.y (create_class): Correct diagnostic message about
6617 java.lang.Object extending anything else.
6618
6619 2004-06-21 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
6620
6621 * class.c (build_class_ref): Add new operand for COMPONENT_REF.
6622 (build_static_field_ref): Likewise and add new operands for ARRAY_REF.
6623 * constants.c (build_ref_from_constant_pool): Likewise.
6624 * expr.c (build_java_array_length_access): Likewise.
6625 (build_get_class, build_field_ref, build_known_method_ref): Likewise.
6626 (invoke_build_dtable, build_invokevirtual): Likewise.
6627 (build_invokeinterface, java_expand_expr): Likewise.
6628 (emit_init_test_initialization): Likewise.
6629 * java-gimplify.c (java_gimplify_new_array_init): Likewise.
6630 * parse.y (make_qualifed_name, build_array_ref): Likewise.
6631
6632 2004-06-21 Andrew Haley <aph@redhat.com>
6633
6634 * java-gimplify.c (java_gimplify_block): set TREE_USED on the new
6635 block.
6636
6637 2004-06-21 Joseph S. Myers <jsm@polyomino.org.uk>
6638
6639 * jcf.h (struct JCF): Change java_source, right_zip and finished
6640 to unsigned int.
6641 * lex.h (struct java_lexer): Change hit_eof, read_anything,
6642 byte_swap and use_fallback to unsigned int.
6643 * parse.h (struct _jdep): Change flag0 to unsigned int.
6644
6645 2004-06-17 Ranjit Mathew <rmathew@hotmail.com>
6646
6647 Fixes PR java/13948
6648 * parse.y (java_layout_seen_class_methods): Ensure class is loaded
6649 before trying to lay out its methods.
6650 * jcf-parse.c (read_class): Track parsed files using canonical paths
6651 obtained via lrealpath from libiberty.
6652 (java_parse_file): Likewise.
6653 (parse_source_file_1): Rename formal parameter to reflect its
6654 modified purpose. Minor formatting fix.
6655
6656 2004-06-15 Paolo Bonzini <bonzini@gnu.org>
6657
6658 * class.c (emit_register_classes): Make the function uninlinable,
6659 do not set current_function_cannot_inline.
6660 * resource.c (write_resource_constructor): Do not reset
6661 flag_inline_functions around rest_of_compilation.
6662
6663 2004-06-08 Andrew Pinski <pinskia@physics.uc.edu>
6664
6665 PR java/15769
6666 * expr.c (java_truthvalue_conversion): Handle
6667 UNEQ_EXPR, UNLE_EXPR, UNGE_EXPR, UNLT_EXPR, UNGT_EXPR,
6668 ORDERED_EXPR, and UNORDERED_EXPR as comparison operators,
6669 i.e. return the expression.
6670
6671 2004-06-03 Mark G. Adams <mark.g.adams@sympatico.ca>
6672
6673 * gjavah.c: Include version.h
6674
6675 2004-05-31 Bryce McKinlay <mckinlay@redhat.com>
6676
6677 * jcf-write.c (generate_bytecode_conditional): Correct handling
6678 of unordered conditionals. Add comment.
6679
6680 2004-05-29 Ranjit Mathew <rmathew@hotmail.com>
6681 Per Bothner <per@bothner.com>
6682
6683 * java-tree.h (DECL_LOCAL_FINAL_IUD): New macro to test if a
6684 local variable was initialised upon declaration.
6685 * parse.y (declare_local_variables): Set DECL_LOCAL_FINAL_IUD if
6686 variable was final and initialised upon declaration.
6687 * check-init.c (check_final_reassigned): Give error only if a blank
6688 final is not definitely unassigned or if an initialised final is
6689 reassigned.
6690 (check_bool_init): Respect JLS2 16.1.7 requirements for boolean
6691 assignment expressions. Remove case MODIFY_EXPR, label do_default.
6692 (check_init): Perform initialised-variable-removing-optimisation
6693 only on non-final local variables.
6694
6695 2004-05-28 Bryce McKinlay <mckinlay@redhat.com>
6696
6697 * jcf-write.c (generate_bytecode_conditional): Handle binops
6698 UNLT_EXPR, UNLE_EXPR, UNGT_EXPR, UNGE_EXPR, UNEQ_EXPR,
6699 and LTGT_EXPR.
6700 (generate_bytecode_insns): Likewise.
6701
6702 2004-05-28 Bryce McKinlay <mckinlay@redhat.com>
6703
6704 * check-init.c (check_init): Handle binops UNLT_EXPR, UNLE_EXPR,
6705 UNGT_EXPR, UNGE_EXPR, UNEQ_EXPR, and LTGT_EXPR.
6706
6707 2004-05-28 Bryce McKinlay <mckinlay@redhat.com>
6708
6709 * gcj.texi (Object allocation): Remove _Jv_AllocBytes.
6710 (Mixing with C++): Document JvAllocBytes and RawDataManaged.
6711
6712 2004-05-26 Bryce McKinlay <mckinlay@redhat.com>
6713
6714 * decl.c (struct binding_level): Add GTY marker. Compile
6715 binding_depth unconditionally.
6716 (current_binding_level, free_binding_level, global_binding_level):
6717 Likewise.
6718 (clear_binding_level): Unconditionally set binding_depth.
6719 (make_binding_level): Use ggc_alloc_cleared, not xmalloc.
6720
6721 2004-05-26 Bryce McKinlay <mckinlay@redhat.com>
6722
6723 * lex.c (java_new_lexer): Set 'encoding'.
6724 (java_read_char): Improve error message for unrecognized characters.
6725 * lex.h (struct java_lexer): New field 'encoding'.
6726
6727 2004-05-23 Paolo Bonzini <bonzini@gnu.org>
6728
6729 * Make-lang.in: Link in $(LIBCPP) instead of mkdeps.o.
6730
6731 2004-05-21 Mark Wielaard <mark@klomp.org>
6732
6733 * gjavah.c (print_stub_or_jni): Mark functions only JNIEXPORT, not
6734 extern.
6735
6736 2004-05-19 Paolo Bonzini <bonzini@gnu.org>
6737
6738 * typeck.c: Remove non-printable character 160.
6739
6740 2004-05-17 Ranjit Mathew <rmathew@hotmail.com>
6741
6742 * check-init.c: Correct minor typos.
6743
6744 2004-05-13 Diego Novillo <dnovillo@redhat.com>
6745
6746 * Make-lang.in, expr.c, java-gimplify.c: Rename
6747 tree-simple.[ch] to tree-gimple.[ch].
6748
6749 2004-05-14 Ranjit Mathew <rmathew@hotmail.com>
6750
6751 * java-gimplify.c (java_gimplify_expr): Correct minor typos.
6752
6753 2004-05-13 Diego Novillo <dnovillo@redhat.com>
6754
6755 Merge from tree-ssa-20020619-branch. See
6756 ChangeLog.tree-ssa for details.
6757
6758 * Make-lang.in, builtins.c, check-init.c, class.c,
6759 constants.c, decl.c, except.c, expr.c, java-except.h,
6760 java-tree.def, java-tree.h, jcf-parse.c, jcf-write.c,
6761 lang.c, lang.opt, parse.y, resource.c: Merged.
6762 * java-gimplify.c: New file.
6763
6764 2004-05-10 Andrew Haley <aph@redhat.com>
6765
6766 * parse.y (create_class): Set TYPE_VFIELD.
6767 * decl.c (java_init_decl_processing): Likewise.
6768
6769 * expr.c (build_invokevirtual): Remove DECL_VINDEX offset adjustment.
6770 * class.c (make_method_value): Replace DECL_VINDEX with call to
6771 get_method_index().
6772 (get_dispatch_vector): Likewise.
6773 (layout_class_method): Likewise.
6774 Replace set of DECL_VINDEX with call to set_method_index().
6775 (set_method_index): New function.
6776 (get_method_index): New function.
6777 * java-tree.h (set_method_index): New function decl.
6778 (get_method_index): New function decl.
6779
6780 2004-05-10 Andrew Pinski <pinskia@physics.uc.edu>
6781
6782 * parse.y (check_pkg_class_access): Add new argument
6783 and use it when cl is NULL to call lookup_cl on it.
6784 (parser_check_super_interface): Do not call lookup_cl.
6785 Pass this_decl to check_pkg_class_access and NULL
6786 instead of lookup_cl.
6787 (parser_check_super): Update for change in
6788 check_pkg_class_access.
6789 (do_resolve_class): Likewise.
6790 (process_imports): Likewise.
6791 (find_in_imports_on_demand): Likewise.
6792 (resolve_qualified_expression_name): Likewise.
6793
6794 2004-05-06 Ranjit Mathew <rmathew@hotmail.com>
6795
6796 Fixes PR java/9685, PR java/15073
6797 * parse.y (accessibility_string): New method.
6798 (not_accessible_field_error): Use accessibility_string()
6799 instead of java_accstring_lookup().
6800 (resolve_qualified_expression_name): Check with
6801 check_pkg_class_access() before allowing access using
6802 qualified names.
6803 Fix comment typo.
6804 Use check_pkg_class_access() instead of not_accessible_p()
6805 for unqualified types.
6806 (not_accessible_p): Use DECL_CONTEXT (member) instead of
6807 REFERENCE for package-private access checking.
6808 (patch_method_invocation): Use accessibility_string() instead
6809 of java_accstring_lookup().
6810
6811 2004-04-30 Ranjit Mathew <rmathew@hotmail.com>
6812
6813 Fixes PR java/15133
6814 * gjavah.c (struct method_name): Add member is_native.
6815 (overloaded_jni_method_exists_p): Match candidate method only if
6816 it is native.
6817 (print_method_info): Initialise is_native flag from the method's
6818 access flags.
6819
6820 2004-04-30 Roger Sayle <roger@eyesopen.com>
6821
6822 * builtins.c (java_builtins): Add acos, asin, ceil and floor.
6823 (initialize_builtins): Likewise, define acos, asin, ceil and floor.
6824
6825 2004-04-22 Roger Sayle <roger@eyesopen.com>
6826
6827 * resource.c (write_resource_constructor): Guard call to possibly
6828 NULL targetm.asm_out.constructor with targetm.have_ctors_dtors.
6829
6830 2004-04-19 Bryce McKinlay <mckinlay@redhat.com>
6831
6832 * class.c (make_class_data): Add new field aux_info.
6833 * decl.c (java_init_decl_processing): Push type and decl for
6834 `aux_info'.
6835
6836 2004-04-15 Bryce McKinlay <mckinlay@redhat.com>
6837
6838 * expr.c (expand_java_NEW): Don't use size argument for
6839 _Jv_AllocObject calls.
6840 * parse.y (patch_invoke): Likewise.
6841
6842 2004-04-12 Bryce McKinlay <mckinlay@redhat.com>
6843
6844 * expr.c (build_invokeinterface): Remove unused variables to
6845 fix warnings.
6846
6847 2004-04-12 Bryce McKinlay <mckinlay@redhat.com>
6848
6849 * class.c (get_interface_method_index): New function. Return dispatch
6850 index for interface method.
6851 (make_method_value): For interface methods, set index field to
6852 iface dispatch index, not DECL_VINDEX.
6853 * expr.c (build_invokeinterface): Use get_interface_method_index.
6854
6855 2004-03-31 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
6856
6857 * jcf-write.c (generate_bytecode_insns): Use TYPE_UNSIGNED.
6858
6859 2004-03-31 Andrew Haley <aph@redhat.com>
6860
6861 PR java/14104
6862 * jcf-io.c (opendir_in_zip): Tidy up error handling.
6863
6864 2004-03-30 Zack Weinberg <zack@codesourcery.com>
6865
6866 * builtins.c, expr.c, jcf.h, parse.h: Use new shorter
6867 form of GTY markers.
6868
6869 2004-03-25 Marcus Meissner <meissner@suse.de>
6870
6871 PR java/14689:
6872 * jcf-path.c (jcf_path_extdirs_arg): Add missing closedir.
6873
6874 2004-03-23 Tom Tromey <tromey@redhat.com>
6875
6876 PR java/14315:
6877 * jcf-write.c (make_class_file_name): Don't report if mkdir
6878 failed with EEXIST.
6879
6880 2004-03-23 Tom Tromey <tromey@redhat.com>
6881
6882 * gcj.texi (Extensions): Document GCJ_PROPERTIES.
6883
6884 2004-03-20 Kazu Hirata <kazu@cs.umass.edu>
6885
6886 * class.c, gjavah.c, lang.c: Fix comment typos.
6887 * gcj.texi: Fix typos.
6888
6889 2004-03-19 Per Bothner <per@bothner.com>
6890
6891 * gcj.texi (Code Generation): Document new flags and assert defaults.
6892
6893 * class.c (assume_compiled_node_struct): Rename type to
6894 class_flag_node_struct, as it is now also used for enable_assertions.
6895 Rename assume_compiled_node typedef. Rename excludep field to value.
6896 (find_assume_compiled_node): Rename function to find_class_flag_node.
6897 Minor optimization - avoid needless strlen.
6898 (add_assume_compiled): Some tweaking and optimization.
6899 Rename and generalize to add_class_flag takem an extra parameter.
6900 (add_assume_compled): New just calls add_class_flag.
6901 (add_enable_assert, enable_assertions): New functions.
6902 (enable_assert_tree): New static.
6903 * java-tree.h (add_enable_assert, enable_assertions): New declarations.
6904 * lang.opt (fenable-assertions, fenable-assertions=,
6905 fdisable-assertions, fdisable-assertions=): New options.
6906 * lang.c (java_handle_option): Handle new options.
6907 * parse.y (build_incomplete_class_ref): Handle class$ in an inner
6908 class in an interface - create helper class nested in outer interface.
6909 (build_assertion): Short-circuit if enable_assertions is false.
6910
6911 2004-03-18 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
6912
6913 * java-tree.h: Changes throughout to add checking to macros
6914 and numerous whitespace changes.
6915 (VAR_OR_FIELD_CHECK): New macro.
6916 * jcf-write.c (get_access_flags): Use FIELD_PUBLIC, METHOD_PUBLIC,
6917 FIELD_FINAL, and METHOD_FINAL instead of CLASS_PUBLIC and CLASS_FINAL.
6918
6919 2004-03-16 Per Bothner <per@bothner.com>
6920
6921 * jcf-jump.c (options): New --print-constants option.
6922 * gcj.texi (Invoking jcf-dump): Document --print-constants.
6923
6924 * jcf-dump.c (flag_print_constant_pool): Default to off.
6925 (print_constant_terse_with_index): New helper function.
6926 (various places): Check flag_print_constant_pool where missing.
6927 (main): If verbose set flag_print_constant_pool.
6928 (HANDLE_INNERCLASSES_ATTRIBUTE): Null inner class name is anonymous.
6929
6930 2004-03-15 Andrew Haley <aph@redhat.com>
6931
6932 PR java/14581
6933 * parse.y (java_complete_lhs): Check that final variable has an
6934 initializer.
6935
6936 2004-03-12 Andrew Haley <aph@redhat.com>
6937
6938 PR java/14551
6939 * typeck.c (convert): Clear TREE_OVERFLOW after an integer
6940 conversion.
6941
6942 2004-02-29 Roger Sayle <roger@eyesopen.com>
6943
6944 * jcf-parse.c (java_parse_file): Handle the case that input_filename
6945 is NULL.
6946
6947 2004-02-27 Per Bothner <per@bothner.com>
6948
6949 * parse.y (build_assertion): Re-do 02-25 change following Jeff Sturm
6950 suggestion: Use build_incomplete_class_ref.
6951 This fixes PR java/13508, java/11714.
6952
6953 2004-02-27 Kazu Hirata <kazu@cs.umass.edu>
6954
6955 * java/parse.h: Update copyright.
6956
6957 2004-02-26 Andrew Haley <aph@redhat.com>
6958
6959 PR java/14231:
6960 * parse.y (check_interface_throws_clauses): Check for
6961 !METHOD_INVISIBLE (iface_method).
6962 * class.c (layout_class_methods): Check for CLASS_INTERFACE as
6963 well as CLASS_ABSTRACT.
6964
6965 2004-02-25 Per Bothner <per@bothner.com>
6966
6967 * parse.y (build_assertion): If we're in an inner class, create the
6968 class$ helper routine in the outer class.
6969
6970 2004-02-19 Richard Henderson <rth@redhat.com>
6971
6972 * parse.y (switch_label): Use make_node for DEFAULT_EXPR.
6973
6974 2004-02-16 Geoffrey Keating <geoffk@apple.com>
6975
6976 * Make-lang.in (java.install-man): Add extra dependencies.
6977
6978 2004-02-13 Geoffrey Keating <geoffk@apple.com>
6979
6980 * Make-lang.in: Install man pages under the same names
6981 (possibly transformed) as the program they document.
6982
6983 2004-02-10 Joseph S. Myers <jsm@polyomino.org.uk>
6984
6985 * gjavah.c: Include "intl.h".
6986 (error): New function.
6987 (main): Call gcc_init_libintl.
6988 (get_field_name, throwable_p, print_c_decl, print_full_cxx_name,
6989 print_stub_or_jni, process_file, main): Use error rather than
6990 fprintf.
6991 (print_method_info, usage, help, version, main): Mark strings for
6992 translation with _. Avoid splitting up sentences. Send
6993 information messages to stdout.
6994 * jcf-dump.c: Include "intl.h".
6995 (main): Call gcc_init_libintl.
6996 (process_class, usage, help, version, main, CHECK_PC_IN_RANGE):
6997 Mark error, usage and version messages for translation with _.
6998 Avoid splitting up sentences.
6999 * jv-scan.c: Include "intl.h".
7000 (fatal_error, warning): Change parameter s to msgid. Translate
7001 messages.
7002 (main): Call gcc_init_libintl.
7003 (usage, help, version): Mark error, usage and version messages for
7004 translation with _. Avoid splitting up sentences.
7005 * jvgenmain.c: Include "intl.h".
7006 (main): Call gcc_init_libintl.
7007 (usage, main): Mark error messages for translation with _.
7008 * Make-lang.in (GCJH_OBJS, JVSCAN_OBJS, JCFDUMP_OBJS,
7009 JVGENMAIN_OBJS): Add intl.o.
7010 (java/jcf-dump.o, java/gjavah.o, java/jv-scan.o,
7011 java/jvgenmain.o): Update dependencies.
7012
7013 2004-02-08 Per Bothner <per@bothner.com>
7014
7015 * parse.y (resolve_qualified_expression_name): In case of inaccessible
7016 class don't use not_accessible_field_error, which can get confused.
7017
7018 2004-02-05 Kelley Cook <kcook@gcc.gnu.org>
7019
7020 Make-lang.in (po-generated): Delete.
7021
7022 2004-02-05 Kazu Hirata <kazu@cs.umass.edu>
7023
7024 * Make-lang.in (java/decl.o, java/expr.o, java/parse.o):
7025 Depend on target.h.
7026 * decl.c: Include target.h.
7027 (start_java_method): Replace PROMOTE_PROTOTYPES with
7028 targetm.calls.promote_prototypes.
7029 * expr.c: Include target.h.
7030 (pop_arguments): Replace PROMOTE_PROTOTYPES with
7031 targetm.calls.promote_prototypes.
7032 * parse.y: Include target.h.
7033 (start_complete_expand_method): Replace PROMOTE_PROTOTYPES
7034 with targetm.calls.promote_prototypes.
7035
7036 2004-02-04 Kazu Hirata <kazu@cs.umass.edu>
7037
7038 * typeck.c: Update copyright.
7039
7040 2004-02-02 Tom Tromey <tromey@redhat.com>
7041
7042 * decl.c (java_init_decl_processing): Remove duplicate
7043 gnu/gcj/RawData.
7044
7045 2004-01-30 Kelley Cook <kcook@gcc.gnu.org>
7046
7047 * Make-lang.in (doc/gcj.dvi): Use $(abs_docdir).
7048
7049 2004-01-28 Andrew Pinski <pinskia@physics.uc.edu>
7050
7051 * expr.c (build_field_ref): Move variable
7052 definition up.
7053
7054 2004-01-28 Andrew Haley <aph@redhat.com>
7055
7056 * expr.c (build_field_ref): Widen field offset.
7057
7058 2004-01-27 Andrew Haley <aph@redhat.com>
7059
7060 java/13273
7061 * parse.y (check_interface_throws_clauses): Make sure class_decl
7062 has been loaded.
7063
7064 2004-01-22 Jeff Sturm <jsturm@one-point.com>
7065
7066 PR java/13733
7067 * parse.y (patch_assignment): Don't modify lhs_type for
7068 reference assignments.
7069
7070 2004-01-20 Kelley Cook <kcook@gcc.gnu.org>
7071
7072 * Make-lang.in: Replace $(docdir) with doc.
7073 (java.info, java.srcinfo, java.man, java.srcman): New rules.
7074 (java.install-man): Revamp rule.
7075
7076 2004-01-20 Kelley Cook <kcook@gcc.gnu.org>
7077
7078 * Make-lang.in (JAVA_INSTALL_NAME, JAVA_TARGET_INSTALL_NAME,
7079 GCJH_TARGET_INSTALL_NAME): Define via a immediate $(shell)
7080 instead of deferred backquote.
7081
7082 2004-01-16 Andrew Pinski <pinskia@physics.uc.edu>
7083
7084 * typeck.c (find_method_in_interfaces): Move variable
7085 definition up.
7086
7087 2004-01-16 Andrew Haley <aph@redhat.com>
7088
7089 PR java/13273:
7090 * typeck.c (shallow_find_method): New.
7091 (find_method_in_superclasses): New.
7092 (find_method_in_interfaces): New.
7093 (lookup_do): Rewrite.
7094 * java-tree.h (SEARCH_ONLY_INTERFACE): Delete.
7095
7096 * jcf-parse.c (read_class): Save and restore output_class.
7097 * decl.c (java_expand_body): Set output_class from fndecl.
7098
7099 2004-01-15 Michael Chastain <mec.gnu@mindspring.com>
7100
7101 * class.c (gen_indirect_dispatch_tables): Fix string length
7102 calculations.
7103
7104 2004-01-15 Kelley Cook <kcook@gcc.gnu.org>
7105
7106 * Make-lang.in (parse.c, parse-scan.c): Always build in doc directory.
7107 (java.srcextra): Copy above back to source directory if requested.
7108 (po-generated): Delete reference to $(parsedir).
7109 (java/parse.o, java/parse-scan.o): Delete reference to $(parsedir).
7110 Use implicit rule.
7111
7112 2004-01-14 Jan Hubicka <jh@suse.cz>
7113
7114 * lang.c (java_estimate_num_insns_1): Fix bug in MODIFY_EXPR cost
7115 estimation.
7116
7117 2004-01-09 Mark Mitchell <mark@codesourcery.com>
7118
7119 * java-tree.h (java_expand_expr): Change prototype.
7120 * expr.c (java_expand_expr): Add alt_rtl parameter.
7121
7122 2004-01-09 Andrew Haley <aph@redhat.com>
7123
7124 PR java/12755:
7125 * parse.y (java_fix_constructors): Set output_class.
7126 (java_reorder_fields): Likewise.
7127 (java_layout_classes): Likewise.
7128 (java_expand_classes): Generate indirect dispatch tables.
7129 (java_expand_classes): Set output_class.
7130 (java_finish_classes): Likewise.
7131 * lang.c (java_init): Turn on always_initialize_class_p if we're
7132 using indirect dis[atch.
7133 (java_decl_ok_for_sibcall): Use output_class, not current_class.
7134 (java_get_callee_fndecl): Use class local atable.
7135 * jcf-parse.c
7136 (always_initialize_class_p): Decl moved to java-tree.h.
7137 (HANDLE_CLASS_INFO): Set output_class.
7138 (read_class): Likewise.
7139 (parse_class_file): Call gen_indirect_dispatch_tables.
7140 (parse_zip_file_entries): Set output_class.
7141 (java_parse_file): Set output_class. Don't emit symbol tables.
7142 * java-tree.h (output_class): New.
7143 Remove global declarations for otable, atable, and ctable.
7144 (always_initialize_class_p): moved here from decl.c.
7145 (DECL_OWNER): New.
7146 (TYPE_ATABLE_METHODS, TYPE_ATABLE_SYMS_DECL, TYPE_ATABLE_DECL,
7147 TYPE_OTABLE_METHODS, TYPE_OTABLE_SYMS_DECL, TYPE_OTABLE_DECL,
7148 TYPE_CTABLE_DECL, TYPE_CATCH_CLASSES): New.
7149 (struct lang_type): Add otable_methods, otable_decl,
7150 otable_syms_decl, atable_methods, atable_decl, atable_syms_decl,
7151 ctable_decl, catch_classes, type_to_runtime_map.
7152 * expr.c (build_field_ref): Make otable, atable, and ctable class
7153 local rather than global.
7154 (build_known_method_ref): Likewise.
7155 (build_invokeinterface): Likewise.
7156 (java_expand_expr): Pass runtime type (rather than actual type) to
7157 expand_start_catch.
7158 * except.c (prepare_eh_table_type): Create TYPE_TO_RUNTIME_MAP for
7159 this class. Look up each class in that map to delete duplicates.
7160 (expand_end_java_handler): Pass runtime type (rather than actual
7161 type) to expand_start_catch.
7162 * decl.c: (always_initialize_class_p): Decl moved to java-tree.h.
7163 (do_nothing): New.
7164 (java_init_decl_processing): Rearrange things. Remove global
7165 declarations of otable, atable, and ctable.
7166 (java_init_decl_processing): Make lang_eh_runtime_type do_nothing.
7167 (java_expand_body): Set output_class.
7168 * constants.c (build_constant_data_ref): Use output_class, not
7169 current_class.
7170 (alloc_name_constant): Likewise.
7171 * class.c (gen_indirect_dispatch_tables): New.
7172 (build_class_ref): Generate hard reference to superclass, even if
7173 using indirect dispatch.
7174 (build_static_field_ref): Use class local atable.
7175 (make_class_data): Generate hard reference to superclass, even if
7176 using indirect dispatch.
7177 Generate symbolic references to interfaces when using indirect
7178 dispatch.
7179 (make_class_data): Emit otable, atable, and ctable.
7180 Make otable, atable, and ctable class local rather than global.
7181 (emit_catch_table): Make otable, atable, and ctable class local
7182 rather than global.
7183
7184 2003-12-25 Andrew Pinski <pinskia@physics.uc.edu>
7185
7186 * parse.y (catch_clause_parameter): Fix typo.
7187
7188 PR java/13404
7189 * parse.y: (catch_clause_parameter): Return early if $3, aka
7190 formal_parameter, is null.
7191
7192 2003-12-20 Kazu Hirata <kazu@cs.umass.edu>
7193
7194 * class.c: Remove uses of "register" specifier in
7195 declarations of arguments and local variables.
7196 * decl.c: Likewise.
7197 * expr.c: Likewise.
7198 * gjavah.c: Likewise.
7199 * jcf-dump.c: Likewise.
7200 * jcf-io.c: Likewise.
7201 * jcf-parse.c: Likewise.
7202 * jcf-write.c: Likewise.
7203 * keyword.h: Likewise.
7204 * parse.y: Likewise.
7205 * typeck.c: Likewise.
7206 * verify.c: Likewise.
7207
7208 2003-12-06 Kelley Cook <kcook@gcc.gnu.org>
7209
7210 * Make-lang.in (GCJ_CROSS_NAME): Delete.
7211 (java.install_common, java.install-man): Adjust for above.
7212 (java.uninstall): Likewise.
7213
7214 2003-12-03 Michael Koch <konqueror@gmx.de>
7215
7216 * class.c (make_class_data):
7217 Push field value to 'hack_signers' instead of 'signers'.
7218 * decl.c (java_init_decl_processing):
7219 Push field 'hack_signers' instead of 'signers'.
7220
7221 2003-12-03 Zack Weinberg <zack@codesourcery.com>
7222
7223 * lex.h: Check both HAVE_ICONV and HAVE_ICONV_H before
7224 including iconv.h.
7225
7226 2003-12-03 Ralph Loader <rcl@ihug.co.nz>
7227
7228 PR java/12374:
7229 * parse.y (qualify_ambiguous_name): Remove lots of broken
7230 field access processing - there's no need to do that here,
7231 because we have resolve_field_access. Remove
7232 RESOLVE_EXPRESSION_NAME_P as it isn't used anywhere else.
7233 * java-tree.h: Remove RESOLVE_EXPRESSION_NAME_P as it isn't
7234 used.
7235
7236 2003-12-01 Jeff Sturm <jsturm@one-point.com>
7237
7238 Fix PR java/13237
7239 * parse.y (java_complete_lhs): Save location prior to patching
7240 CALL_EXPR.
7241
7242 2003-11-25 Mohan Embar <gnustuff@thisiscool.com>
7243
7244 PR java/12548
7245 * resource.c (write_resource_constructor): Append
7246 "_resource" to constructor identifier name.
7247
7248 2003-11-25 Jeff Sturm <jsturm@one-point.com>
7249
7250 Fix PR java/13183.
7251 * constants.c (cpool_for_class): New function.
7252 (outgoing_cpool): Remove global variable.
7253 (alloc_name_constant): Use cpool_for_class.
7254 (build_constants_constructor): Likewise.
7255 * decl.c (java_expand_body): Set current_class.
7256 * java-tree.h (outgoing_cpool) Remove declaration.
7257 (init_outgoing_cpool): Likewise.
7258 * jcf-parse.c (init_outgoing_cpool): Remove function.
7259 (parse_class_file): Don't call init_outgoing_cpool.
7260 * parse.y (java_complete_expand_methods): Don't call
7261 init_outgoing_cpool. Don't save outgoing_cpool.
7262 (java_expand_classes): Don't restore outgoing_cpool.
7263 (java_finish_classes): Likewise.
7264
7265 2003-11-24 Mohan Embar <gnustuff@thisiscool.com>
7266
7267 * Make-lang.in: (java.install-common) Add
7268 symlink for $(target_noncanonical)-gcjh for
7269 native builds.
7270
7271 2003-11-20 Joseph S. Myers <jsm@polyomino.org.uk>
7272
7273 * Make-lang.in (java.extraclean): Delete.
7274
7275 2003-11-20 Joseph S. Myers <jsm@polyomino.org.uk>
7276
7277 * Make-lang.in (check-java): Add.
7278
7279 2003-11-19 Jeff Sturm <jsturm@one-point.com>
7280
7281 Fix PR java/13024.
7282 * except.c (prepare_eh_table_type): Allocate variable-sized
7283 buffer `buf' with alloca.
7284
7285 2003-11-17 Jeff Sturm <jsturm@one-point.com>
7286
7287 Fix PR java/12857.
7288
7289 decl.c (java_init_decl_processing): Don't initialize
7290 class_not_found_type_node, no_class_def_found_type_node.
7291
7292 java-tree.h (JTI_CLASS_NOT_FOUND_TYPE_NODE,
7293 JTI_NO_CLASS_DEF_FOUND_TYPE_NODE): Remove from java_tree_index.
7294 (class_not_found_type_node, no_class_def_found_type_node):
7295 Don't define.
7296
7297 parse.y (build_dot_class_method_invocation): Add this_class
7298 argument. Qualify method invocations to a different class.
7299 (create_new_parser_context): Initialize saved_data_ctx to 0.
7300 (java_parser_context_save_global): Initialize saved_data_ctx to 1.
7301 (build_dot_class_method): Don't load classes. Register
7302 incomplete types.
7303 (build_incomplete_class_ref): Special cases for interfaces
7304 and inner classes. Move build_dot_class_method call to here...
7305 (patch_incomplete_class_ref): ...from here. Pass current_class
7306 to build_dot_class_method_invocation.
7307 (build_assertion): Pass class_type to
7308 build_dot_class_method_invocation.
7309 (encapsulate_with_try_catch): Handle EXPR_WITH_FILE_LOCATION node.
7310
7311 2003-11-17 Jeff Sturm <jsturm@one-point.com>
7312
7313 Fix PR java/12739.
7314 * java-tree.h (BLOCK_EMPTY_P): Define.
7315 * parse.y (java_complete_lhs): Check for empty blocks
7316 in TRY_FINALLY_EXPR case.
7317
7318 2003-11-17 Andrew Haley <aph@redhat.com>
7319
7320 * java-tree.h (LOCAL_VAR_OUT_OF_SCOPE_P): New.
7321 (struct lang_decl_var:freed): New variable.
7322 * decl.c (poplevel): Mark local vars that have gone out of scope.
7323 (push_jvm_slot): Don't use the RTL of a var that has gone out of
7324 scope.
7325
7326 2003-11-16 Jason Merrill <jason@redhat.com>
7327
7328 * Make-lang.in (java.tags): Create TAGS.sub files in each directory
7329 and TAGS files that include them for each front end.
7330
7331 2003-11-15 Tom Tromey <tromey@redhat.com>
7332
7333 * gjavah.c (print_stub_or_jni): Pass `env' to FatalError.
7334
7335 2003-11-12 Jason Merrill <jason@redhat.com>
7336
7337 PR optimization/12547
7338 * lang.c (java_tree_inlining_walk_subtrees): Just walk
7339 BLOCK_EXPR_BODY directly.
7340
7341 2003-11-12 Andrew Haley <aph@redhat.com>
7342
7343 PR java/11045
7344 * parse.y (fold_constant_for_init): Check that we really do have a
7345 constant.
7346
7347 PR java/11533
7348 * lang.c (merge_init_test_initialization): Clear DECL_INITIAL for
7349 init_test_decls being inlined.
7350
7351 PR java/12890:
7352 * parse.y (do_resolve_class): Check return value from
7353 breakdown_qualified().
7354
7355 2003-11-11 Tom Tromey <tromey@redhat.com>
7356
7357 PR java/12915:
7358 * parse.y (merge_string_cste): Handle case where we have a
7359 pointer that happens to be zero, not null_pointer_node.
7360
7361 2003-11-10 Tom Tromey <tromey@redhat.com>
7362
7363 * jcf-parse.c (classify_zip_file): Correctly compare
7364 filename_length against length of manifest file's name.
7365
7366 2003-11-08 Tom Tromey <tromey@redhat.com>
7367
7368 PR java/12894:
7369 * jcf-parse.c (classify_zip_file): Only skip MANIFEST.MF file.
7370
7371 2003-11-06 Andrew Haley <aph@redhat.com>
7372
7373 * expr.c (java_stack_swap): Make sure destination stack slots are
7374 of the correct type.
7375
7376 2003-11-03 Kelley Cook <kcook@gcc.gnu.org>
7377
7378 * Make-lang.in (dvi): Move targets to $(docobjdir).
7379 (gcj.dvi): Simplify rule and adjust target.
7380 (gcj.info): Simplify rule.
7381 (gcj.pod): New intermediate rule.
7382 (gcjh.pod): Likewise.
7383 (jv-scan.pod): Likewise.
7384 (jcf-dump.pod): Likewise.
7385 (gij.pod): Likewise.
7386 (jv-convert.pod): Likewise.
7387 (rmic.pod): Likewise.
7388 (rmiregistry.pod): Likewise.
7389 (gcj.1): Delete.
7390 (gcjh.1): Delete.
7391 (jv-scan.1): Delete.
7392 (jcf-dump.1): Delete.
7393 (gij.1): Delete.
7394 (jv-convert.1): Delete.
7395 (rmic.1): Delete.
7396 (rmiregistry.1): Delete.
7397
7398 2003-11-02 Jeff Sturm <jsturm@one-point.com>
7399
7400 Fixes PR java/12866.
7401 * parse.y (resolve_qualified_expression_name): Move test
7402 for outer field access methods from here...
7403 (check_thrown_exceptions) ...to here.
7404
7405 2003-11-01 Kelley Cook <kcook@gcc.gnu.org>
7406
7407 * .cvsignore: Delete.
7408
7409 2003-10-28 Frank Ch. Eigler <fche@redhat.com>
7410
7411 * verify.c (verify_jvm_instructions): Don't warn about legal
7412 eh binding regions generated for example by jdk 1.4.1.
7413
7414 2003-10-24 David S. Miller <davem@redhat.com>
7415
7416 * jcf-parse.c (jcf_parse): Fix args to fatal_error().
7417
7418 2003-10-22 Andrew Haley <aph@redhat.com>
7419
7420 * lang.c (LANG_HOOKS_GET_CALLEE_FNDECL): New.
7421 (java_get_callee_fndecl): New.
7422
7423 * jcf-parse.c (java_parse_file): Call emit_catch_table().
7424
7425 * java-tree.h (ctable_decl): New.
7426 (catch_classes): New.
7427 (java_tree_index): Add JTI_CTABLE_DECL, JTI_CATCH_CLASSES.
7428
7429 * decl.c (java_init_decl_processing): Add catch_class_type.
7430 Add ctable_decl.
7431 Add catch_classes field.
7432
7433 * class.c (build_indirect_class_ref): Break out from
7434 build_class_ref.
7435 (make_field_value): Check flag_indirect_dispatch.
7436 (make_class_data): Ditto.
7437 Tidy uses of PUSH_FIELD_VALUE.
7438 Add field catch_classes.
7439 (make_catch_class_record): New.
7440
7441 * java-tree.h (PUSH_FIELD_VALUE): Tidy.
7442
7443 2003-10-22 Kazu Hirata <kazu@cs.umass.edu>
7444
7445 * jcf-write.c: Follow spelling conventions.
7446 * parse.y: Likewise.
7447
7448 2003-10-22 Kazu Hirata <kazu@cs.umass.edu>
7449
7450 * ChangeLog: Fix typos.
7451 * expr.c: Fix comment typos.
7452 * jcf-write.c: Likewise.
7453 * lang.c: Likewise.
7454 * lex.c: Likewise.
7455 * mangle.c: Likewise.
7456 * parse-scan.y: Likewise.
7457 * parse.y: Likewise.
7458
7459 2003-10-22 Tom Tromey <tromey@redhat.com>
7460
7461 * expr.c (expand_byte_code): Only warn about dead bytecode when
7462 extra_warnings is set.
7463
7464 2003-10-22 Bryce McKinlay <bryce@mckinlay.net.nz>
7465
7466 Fix for PR java/12586.
7467 * mangle.c (find_compression_record_match): Don't iterate through
7468 package namespace elements unless they all match compression_table
7469 entries.
7470
7471 2003-10-20 Kelley Cook <kcook@gcc.gnu.org>
7472
7473 * Make-lang.in (info): Honor $(parsedir) and $(docobjdir).
7474 (generate-manpages): Likewise.
7475 (java.maintainer-clean): Likewise.
7476 (gcj.info): Likewise.
7477 (gcj.1): Likewise.
7478 (gcjh.1): Likewise.
7479 (jv-scan.1): Likewise.
7480 (jcf-dump.1): Likewise.
7481 (gij.1): Likewise.
7482 (jv-convert.1): Likewise.
7483 (rmic.1): Likewise.
7484 (rmiregistry.1): Likewise.
7485 (java.install-man): Likewise.
7486 (parse-scan.o): Move and define complete compile line.
7487 (parse.o): Likewise.
7488 (jcf-tree-inline.o): Move.
7489
7490 2003-10-20 Mark Mitchell <mark@codesourcery.com>
7491
7492 * Make-lang.in (info): Update dependencies.
7493 (java.install-info): Remove.
7494 ($(srcdir)/java/gcj.info): Replace with ...
7495 ($(docobjdir)/gcj.info): ... this.
7496
7497 2003-10-14 Nathanael Nerode <neroden@gcc.gnu.org>
7498
7499 * Make-lang.in: Replace uses of $(target_alias) with
7500 $(target_noncanonical).
7501
7502 2003-10-09 Tom Tromey <tromey@redhat.com>
7503
7504 * decl.c (java_init_decl_processing): Declare signers field.
7505 * class.c (make_class_data): Set signers field.
7506
7507 2003-10-09 Jason Merrill <jason@redhat.com>
7508
7509 * parse.y (patch_assignment): Use make_node to create a BLOCK.
7510 * parse.h (BUILD_PTR_FROM_NAME): Use make_node to create a
7511 POINTER_TYPE.
7512
7513 2003-10-06 Mark Mitchell <mark@codesourcery.com>
7514
7515 * Make-lang.in (java.info): Replace with ...
7516 (info): ... this.
7517 (java.dvi): Replace with ...
7518 (dvi): ... this.
7519 (java.generated-manpages): Replace with ...
7520
7521 2003-10-03 Kelley Cook <kelleycook@wideopenwest.com>
7522
7523 * builtins.c, jcf.h, jvspec.c: Remove PARAMS macros.
7524
7525 2003-10-01 Andrew Haley <aph@redhat.com>
7526
7527 * jcf-parse.c (java_parse_file): Write otable and atable.
7528 * java-tree.h (atable_methods): New.
7529 (atable_decl): New.
7530 (atable_syms_decl): New.
7531 (enum java_tree_index): Add JTI_ATABLE_METHODS, JTI_ATABLE_DECL,
7532 JTI_ATABLE_SYMS_DECL. Rename JTI_METHOD_SYMBOL* to JTI_SYMBOL*.
7533 (symbol_*type): Rename method_symbol* to symbol*type.
7534 (emit_offset_symbol_table): Delete.
7535 (emit_symbol_table): New.
7536 (get_symbol_table_index): New.
7537 (atable_type): New.
7538 * expr.c (build_field_ref): Handle flag_indirect_dispatch.
7539 (build_known_method_ref): Likewise.
7540 (get_symbol_table_index): Rename from get_offset_table_index.
7541 Parameterize to allow re-use by differing types of symbol table.
7542 (build_invokevirtual): Pass table to get_offset_table_index.
7543 * decl.c (java_init_decl_processing): Push types and decls for
7544 atable and atable_syyms.
7545 * class.c (build_static_field_ref): Handle flag_indirect_dispatch.
7546 (make_class_data): Add new fields atable and atable_syms.
7547 (emit_symbol_table): Rename from emit_offset_symbol_table.
7548 Parameterize to allow re-use by different types of symbol table.
7549 (build_symbol_entry): Renamed from build_method_symbols_entry.
7550
7551 2003-09-30 Roger Sayle <roger@eyesopen.com>
7552
7553 * jcf-write.c (generate_bytecode_insns): Implement evaluate-once
7554 semantics for SAVE_EXPR, by caching the result in a temporary.
7555
7556 2003-09-28 Richard Henderson <rth@redhat.com>
7557
7558 * check-init.c (check_init): Save and restore input_location
7559 instead of file and line separately.
7560 * decl.c (java_expand_body): Likewise.
7561 * jcf-write.c (generate_bytecode_insns): Likewise.
7562 * parse.y (safe_layout_class): Likewise.
7563 * jcf-parse.c (read_class, parse_class_file): Likewise.
7564 (java_parse_file): Use %H for warning locator.
7565
7566 2003-09-28 Roger Sayle <roger@eyesopen.com>
7567
7568 * expr.c (java_check_reference): Use the semantics of COND_EXPRs
7569 with void-type branches instead of using a COMPOUND_EXPR.
7570
7571 2003-09-28 Jeff Sturm <jsturm@one-point.com>
7572
7573 * decl.c (java_optimize_inline, dump_function): Remove.
7574 * java-tree.h (java_optimize_inline): Remove declaration.
7575 * jcf-parse.c (java_parse_file): Assume flag_unit_at_a_time is set.
7576 * parse.y (source_end_java_method, java_expand_classes):
7577 Likewise. Remove dead code.
7578
7579 2003-09-27 Roger Sayle <roger@eyesopen.com>
7580
7581 * lang.c (java_init_options): Set flag_evaluation_order.
7582 * expr.c (force_evaluation_order): Don't attempt to force
7583 evaluation order of binary operations using save_expr.
7584 * parse.y (java_complete_lhs): No longer need to call
7585 force_evaluation_order when constructing binary operators.
7586
7587 2003-09-27 Alexandre Petit-Bianco <apbianco@redhat.com>
7588 Bryce McKinlay <bryce@mckinlay.net.nz>
7589
7590 PR java/1333:
7591 * parse.y (not_accessible_field_error): New function.
7592 (resolve_expression_name): Check field access permissions.
7593 (resolve_qualified_expression_name): Use
7594 not_accessible_field_error.
7595 (resolve_qualified_expression_name): Likewise.
7596
7597 2003-09-24 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
7598
7599 * class.c (build_utf8_ref): Test for HAVE_GAS_SHF_MERGE value.
7600
7601 2003-09-23 Roger Sayle <roger@eyesopen.com>
7602
7603 * jcf-write.c (generate_bytecode_insns): Optimize binary operations
7604 with equal operands without side-effects.
7605
7606 2003-09-22 Jeff Sturm <jsturm@one-point.com>
7607
7608 * decl.c (java_init_decl_processing): Don't emit otable decls
7609 if flag_indirect_dispatch is not set.
7610
7611 2003-09-21 Richard Henderson <rth@redhat.com>
7612
7613 * class.c, decl.c, jcf-parse.c, jcf-write.c, parse.y,
7614 resource.c: Revert.
7615
7616 2003-09-21 Richard Henderson <rth@redhat.com>
7617
7618 * class.c, decl.c, jcf-parse.c, jcf-write.c, parse.y,
7619 resource.c: Update for DECL_SOURCE_LOCATION rename and change to const.
7620
7621 2003-09-20 Richard Henderson <rth@redhat.com>
7622
7623 * check-init.c, class.c, decl.c, expr.c: Use %J in diagnostics.
7624
7625 2003-09-18 Roger Sayle <roger@eyesopen.com>
7626
7627 * expr.c (java_truthvalue_conversion): Remove FFS_EXPR case.
7628 * check-init.c (check_init): Likewise.
7629
7630 2003-09-18 Roger Sayle <roger@eyesopen.com>
7631
7632 * jcf-write.c (generate_bytecode_insns): Add support for fconst_2.
7633
7634 2003-09-16 Andrew Haley <aph@redhat.com>
7635
7636 * jcf-write.c (generate_bytecode_insns): Add MIN_EXPR and MAX_EXPR.
7637
7638 2003-09-17 Ranjit Mathew <rmathew@hotmail.com>
7639
7640 Fixes PR java/9577
7641 * mangle.c (find_compression_record_match): Skip
7642 over a "6JArray" (the array template mangled string)
7643 IDENTIFIER_NODE.
7644 (mangle_array_type): Correct minor typo.
7645 (atms): Move definition to the beginning.
7646
7647 2003-09-16 Bryce McKinlay <bryce@mckinlay.net.nz>
7648
7649 * class.c (add_miranda_methods): Ensure super-interfaces are laid
7650 out. Fix for PR java/12254.
7651
7652 2003-09-11 Richard Henderson <rth@redhat.com>
7653
7654 * parse.y (source_end_java_method): Update for new
7655 cgraph_finalize_function argument.
7656
7657 2003-09-09 Richard Henderson <rth@redhat.com>
7658
7659 * parse.y (source_end_java_method): Update call to
7660 cgraph_finalize_function.
7661
7662 2003-09-03 Jeff Sturm <jsturm@one-point.com>
7663
7664 * decl.c (java_expand_body): New function.
7665 * expr.c (build_class_init): Set DECL_IGNORED_P.
7666 * java-tree.h (start_complete_expand_method,
7667 java_expand_body): Declare.
7668 * jcf-parse.c (cgraph.h): Include.
7669 (java_parse_file): Handle flag_unit_at_a_time.
7670 * lang.c (LANG_HOOKS_TREE_INLINING_START_INLINING,
7671 LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): Define.
7672 (java_estimate_num_insns): Use walk_tree_without_duplicates.
7673 (java_start_inlining): New function.
7674 * parse.h (java_finish_classes): Declare.
7675 * parse.y: Include cgraph.h.
7676 (block): Don't special-case empty block production.
7677 (craft_constructor): Set DECL_INLINE.
7678 (source_end_java_method): Handle flag_unit_at_a_time.
7679 Replace inline code with call to java_expand_body.
7680 (start_complete_expand_method): Remove static modifier.
7681 (java_expand_method_bodies): Patch function tree for
7682 class initialization and/or synchronization as needed.
7683 Don't begin RTL expansion yet.
7684 (java_expand_classes): Check flag_unit_at_a_time before
7685 calling finish_class.
7686 (java_finish_classes): New function.
7687 (java_complete_lhs): Ensure COMPOUND_EXPR has non-NULL type.
7688 (patch_assignment): Set DECL_CONTEXT on temporary variable.
7689 (emit_test_initialization): Set DECL_IGNORED_P.
7690
7691 2003-09-03 Roger Sayle <roger@eyesopen.com>
7692
7693 * builtins.c (enum builtin_type): Delete unused enumeration.
7694 * Make-lang.in (java/builtins.o): Remove built-types.def dependency.
7695
7696 2003-08-28 Tom Tromey <tromey@redhat.com>
7697
7698 * gcj.texi (Extensions): Document gcjlib URLs.
7699
7700 2003-08-20 Tom Tromey <tromey@redhat.com>
7701
7702 * gcj.texi (Extensions): Added xref.
7703 (libgcj Runtime Properties): Document
7704 gnu.gcj.runtime.VMClassLoader.library_control.
7705
7706 2003-08-20 Andrew Haley <aph@redhat.com>
7707
7708 * except.c (prepare_eh_table_type): Use new encoding for exception
7709 handlers when using -fno-assume-compiled.
7710
7711 2003-08-13 Tom Tromey <tromey@redhat.com>
7712
7713 * gcj.texi (Invoking gij): Document -X and -?.
7714
7715 2003-08-13 Mohan Embar <gnustuff@thisiscool.com>
7716
7717 * Make-lang.in: Added missing win32-host.o to JAVA_OBJS,
7718 GCJH_OBJS, JCFDUMP_OBJS
7719 * win32-host.c: Removed the unnecessary and broken dependency
7720 on jcf.h
7721
7722 2003-08-11 Tom Tromey <tromey@redhat.com>
7723
7724 * parse.y (java_check_regular_methods): Typo fixes. Call
7725 check_interface_throws_clauses. Use
7726 check_concrete_throws_clauses.
7727 (check_interface_throws_clauses): New function.
7728 (check_concrete_throws_clauses): New function.
7729 (hack_is_accessible_p): New function.
7730 (find_most_specific_methods_list): Added FIXME.
7731 * typeck.c (lookup_do): Use `flags' argument to decide what to
7732 do. Reimplemented.
7733 (lookup_argument_method_generic): New function.
7734 (lookup_argument_method2): Removed.
7735 * jcf.h (ACC_INVISIBLE): New define.
7736 * jcf-write.c (generate_classfile): Skip invisible methods.
7737 * class.c (add_miranda_methods): New function.
7738 (layout_class_methods): Use it.
7739 (get_access_flags_from_decl): Use ACC_INVISIBLE.
7740 * java-tree.h (METHOD_INVISIBLE): New define.
7741 (lang_decl_func) [invisible]: New field.
7742 (lookup_argument_method_generic): Declare.
7743 (SEARCH_INTERFACE): New define.
7744 (SEARCH_SUPER): Likewise.
7745 (SEARCH_ONLY_INTERFACE): Likewise.
7746 (SEARCH_VISIBLE): Likewise.
7747 (lookup_argument_method2): Removed declaration.
7748
7749 2003-08-05 Tom Tromey <tromey@redhat.com>
7750
7751 Fix for PR java/11600:
7752 * parse.y (java_complete_lhs): See whether we're calling a method
7753 on an array.
7754 (check_thrown_exceptions): Added `is_array_call' argument;
7755 fixed `clone' checking; updated all callers.
7756
7757 2003-08-05 Steven Bosscher <steven@gcc.gnu.org>
7758
7759 * java-tree.h (DECL_ESTIMATED_INSNS): Remove (moved to tree.h).
7760
7761 2003-08-03 Tom Tromey <tromey@redhat.com>
7762
7763 * java-tree.h (METHOD_TRANSIENT): Removed.
7764 * decl.c (pushdecl): Removed some dead code.
7765 * class.c (get_access_flags_from_decl): Can't have transient
7766 method.
7767 (add_method_1): Can't have a transient method.
7768
7769 2003-07-28 Andreas Jaeger <aj@suse.de>
7770
7771 * jvspec.c: Convert to ISO C90 prototypes.
7772
7773 2003-07-25 Nathan Sidwell <nathan@codesourcery.com>
7774
7775 * decl.c (force_poplevels): Fix warning call.
7776
7777 2003-07-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
7778
7779 * expr.c (expand_java_field_op): Don't use xxx_with_decl
7780 (expand_java_field_op): Likewise.
7781 * class.c (layout_class_method): Likewise
7782 (emit_register_classes): Likewise.
7783 * decl.c (pushdecl): Likewise.
7784 (poplevel): Likewise.
7785 (force_poplevels): Likewise.
7786 (give_name_to_locals): Likewise.
7787 * check-init.c (check_for_initialization): Likewise.
7788
7789 2003-07-24 Jason Merrill <jason@redhat.com>
7790
7791 * java-tree.h: Move boolean_type_node et al to the back end.
7792
7793 2003-07-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
7794
7795 * class.c java-tree.h jcf-write.c jvspec.c: Remove unnecessary
7796 casts.
7797
7798 2003-07-19 Neil Booth <neil@daikokuya.co.uk>
7799
7800 * lang.opt: Don't show -MD_ and -MDD_.
7801
7802 2003-07-18 Neil Booth <neil@daikokuya.co.uk>
7803
7804 * lang-options.h: Remove.
7805 * lang.opt: Add help text.
7806
7807 2003-07-15 Kazu Hirata <kazu@cs.umass.edu>
7808
7809 * expr.c: Remove the last argument to expand_assignment().
7810
7811 2003-07-09 Jan Hubicka <jh@suse.cz>
7812
7813 * java-tree.h (DECL_NUM_STMTS): Rename to...
7814 (DECL_ESTIMATED_INSNS): ... this.
7815 * lang.c (java_estimate_num_insns, java_estimate_num_insns_1):
7816 New static functions.
7817 (LANG_HOOKS_TREE_INLINING_ESTIMATE_NUM_INSNS): Define.
7818 * parser.y (add_stmt_to_compound): Do not account statements.
7819
7820 2003-07-08 Mark Wielaard <mark@klomp.org>
7821
7822 * gcj.texi: CNI now expands to Compiled Native Interface.
7823
7824 2003-07-08 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
7825
7826 * Make-lang.in (java/gcj.dvi): Use PWD_COMMAND.
7827
7828 2003-07-07 Nathan Sidwell <nathan@codesourcery.com>
7829
7830 * expr.c (expand_byte_code): Adjist emit_line_note call.
7831
7832 2003-07-06 Neil Booth <neil@daikokuya.co.uk>
7833
7834 * lang.c (java_handle_option): Don't handle filenames.
7835
7836 2003-07-02 Zack Weinberg <zack@codesourcery.com>
7837
7838 * jcf-path.c: Don't default-define PATH_SEPARATOR nor
7839 DIR_SEPARATOR.
7840 Use FILENAME_CMP.
7841 * jcf-write.c: Don't default-define DIR_SEPARATOR.
7842 * jcf.h: Delete COMPARE_FILENAMES definition.
7843
7844 2003-07-02 Neil Booth <neil@daikokuya.co.uk>
7845
7846 * lang.c (java_init_options): Update prototype.
7847
7848 2003-07-01 Nathan Sidwell <nathan@codesourcery.com>
7849
7850 * decl.c (poplevel): Adjust define_label call.
7851
7852 2003-06-27 Zack Weinberg <zack@codesourcery.com>
7853
7854 * gjavah.c (flag_jni): Make non-static.
7855 * parse-scan.y (ctxp): Make non-static.
7856
7857 * class.c (build_method_symbols_entry)
7858 * expr.c (get_offset_table_index)
7859 * jcf-parse.c (jcf_parse):
7860 Mark the definition static, matching the forward declaration.
7861
7862 2003-06-26 Neil Booth <neil@daikokuya.co.uk>
7863
7864 * lang.c (java_handle_option): Don't check for missing arguments.
7865
7866 2003-06-20 Nathan Sidwell <nathan@codesourcery.com>
7867
7868 * class.c (push_class): Use a location_t to save place.
7869 (emit_register_classes): Set input_location. Adjust
7870 expand_function_end call.
7871 * resource.c (write_resource_constructor): Likewise.
7872 * decl.c (end_java_method): Adjust expand_function_end call.
7873 * parse.y (source_end_java_method): Likewise.
7874
7875 2003-06-17 Robert Abeles <rabeles@archaelogic.com>
7876
7877 * lang.c (java_handle_option): Likewise.
7878
7879 2003-06-16 Neil Booth <neil@daikokuya.co.uk>
7880
7881 * lang.c (java_handle_option): Special-casing of optional
7882 joined arguments no longer needed.
7883 * lang.opt: Update switches that take optional argument.
7884
7885 2003-06-15 Neil Booth <neil@daikokuya.co.uk>
7886
7887 * lang.opt: Declare Java.
7888 * lang.c (java_init_options): Update.
7889
7890 2003-06-15 Neil Booth <neil@daikokuya.co.uk>
7891
7892 * lang.c (version_flag): Rename to v_flag to avoid clash w/ toplev.h.
7893
7894 2003-06-14 Neil Booth <neil@daikokuya.co.uk>
7895
7896 * lang-specs.h: Rewrite -MD and -MMD to append an underscore.
7897 * lang.c (java_handle_option): -MD and -MMD have an underscore.
7898 * lang.opt: -MD and -MMD have an underscore.
7899
7900 2003-06-14 Nathan Sidwell <nathan@codesourcery.com>
7901
7902 * class.c (emit_register_classes): Adjust init_function_start
7903 call.
7904 * decl.c (complete_start_java_method): Likewise.
7905 * resource.c (write_resource_constructor): Likewise.
7906
7907 2003-06-14 Neil Booth <neil@daikokuya.co.uk>
7908
7909 * Make-lang.in: Update to use options.c and options.h.
7910 * lang.c: Include options.h not j-options.h.
7911 (java_handle_option): Abort on unrecognized option.
7912 (java_init_options): Request Java switches.
7913
7914 2003-06-11 Neil Booth <neil@daikokuya.co.uk>
7915
7916 * Make-lang.in: Handle mostlyclean.
7917
7918 2003-06-11 Tom Tromey <tromey@redhat.com>
7919
7920 * lang.c (java_handle_option): Update dependency_tracking for
7921 OPT_MF case.
7922
7923 * lang.c (java_handle_option): OPT_fbootclasspath_ can take an
7924 empty argument.
7925
7926 2003-06-10 Andrew Haley <aph@redhat.com>
7927
7928 * resource.c (write_resource_constructor): Use expand_expr to
7929 generate the address of the label attached to a resource.
7930 * Make-lang.in (java/resource.o): Add expr.h
7931
7932 2003-06-10 Andrew Haley <aph@redhat.com>
7933
7934 * lang.c (LANG_HOOKS_DECL_OK_FOR_SIBCALL): New.
7935 (java_decl_ok_for_sibcall): New.
7936
7937 2003-06-09 Neil Booth <neil@daikokuya.co.uk>
7938
7939 * Make-lang.in (JAVA_OBJS, java/lang.o): Update.
7940 (java/j-options.c, java/j-options.h): New.
7941 * java-tree.h (resource_name, compile_resource_file,
7942 compile_resource_data): Constify.
7943 * jcf-write.c (jcf_write_base_directory): Similarly.
7944 * jcf.h (jcf_write_base_directory): Similarly.
7945 * lang.c: Include j-options.h.
7946 (cl_options_count, cl_options, string_option, java_decode_option,
7947 lang_f_options, lang_W_options, LANG_HOOKS_DECODE_OPTION,
7948 process_option_with_no): Remove.
7949 (resource_name): Constify.
7950 (LANG_HOOKS_HANDLE_OPTION): Override.
7951 (java_handle_option): New.
7952 (java_init): Don't call jcf_path_init.
7953 (java_init_options): Call jcf_path_init.
7954 * lang.opt: New.
7955 * resource.c (compile_resource_data, compile_resource_file): Constify.
7956
7957 2003-06-09 Nathan Sidwell <nathan@codesourcery.com>
7958
7959 * java-tree.h (DECL_FUNCTION_LAST_LINE): New.
7960 (struct lang_decl_func): Add last_line field.
7961 * parse.h (DECL_SOURCE_LINE_MERGE, DECL_SOURCE_LINE_FIRST,
7962 DECL_SOURCE_LINE_LAST): Remove.
7963 * parse.y (missing_return_error, finish_method_declaration,
7964 lookup_cl, start_artificial_method_body, source_end_java_method,
7965 start_complete_expand_method): Adjust.
7966
7967 2003-06-08 Tom Tromey <tromey@redhat.com>
7968
7969 * jvspec.c (jvgenmain_spec): Added `*' after fassume-compiled and
7970 fno-assume-compiled.
7971
7972 2003-06-08 Roger Sayle <roger@eyesopen.com>
7973
7974 * builtins.c (define_builtin_type, builtin_types): Delete.
7975 (define_builtin): Rewritten to take just the built-in code,
7976 the function's name, type and fallback library function name.
7977 All built-ins used by Java are implicit and BUILT_IN_NORMAL.
7978 (initialize_builtins): Overhaul to define the GCC builtins
7979 used by gcj manually, providing the Java run-time's
7980 implementations as the fallback library function.
7981
7982 2003-06-08 Anthony Green <green@redhat.com>
7983
7984 * parse.y (patch_cast): Fix conversions from floating-point to
7985 integral types.
7986
7987 2003-06-08 Neil Booth <neil@daikokuya.co.uk>
7988
7989 * Make-lang.in: Update.
7990 * lang.c: Include opts.h. Define cl_options_count and cl_options.
7991
7992 2003-06-07 Neil Booth <neil@daikokuya.co.uk>
7993
7994 * lang.c (java_init_options): Update.
7995
7996 2003-06-05 Jan Hubicka <jh@suse.cz>
7997
7998 * Make-lang.in: Add support for stageprofile and stagefeedback
7999
8000 2003-05-31 Roger Sayle <roger@eyesopen.com>
8001
8002 * lang.c (java_init_options): Prescribe wrap-around two's
8003 complement arithmetic overflow by setting flag_wrapv.
8004
8005 2003-05-29 Roger Sayle <roger@eyesopen.com>
8006
8007 * builtins.c (cos_builtin, sin_builtin, sqrt_builtin): Delete.
8008 (builtin_record): Add an additional builtin_code field to
8009 record which GCC built-in corresponds to the Java function.
8010 (java_builtins): Add new entries for atan, atan2, exp, log,
8011 pow and tan.
8012 (max_builtin, min_builtin, abs_builtin): Perform constant
8013 folding on the resulting tree.
8014 (java_build_function_call_expr): Likewise, perform constant
8015 folding on the resulting tree.
8016 (initialize_builtins): The NULL creators are now allowed in
8017 the java_builtins table, which is now terminated by an entry
8018 with builtin_code == END_BUILTINS.
8019 (check_for_builtin): Likewise. If the matching creator is
8020 NULL, construct the call using java_build_function_call_expr
8021 directly with the decl for the corresponding builtin_code.
8022
8023 2003-05-23 Nathanael Nerode <neroden@gcc.gnu.org>
8024
8025 * win32-host.c: Normalize copyright boilerplate.
8026
8027 2003-05-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8028
8029 * parse.y (print_int_node): Use string concatentation on
8030 HOST_WIDE_INT_PRINT_* format specifier to collapse multiple
8031 function calls into one.
8032
8033 2003-05-13 Zack Weinberg <zack@codesourcery.com>
8034
8035 * jcf-parse.c, jcf-write.c, lex.c: Replace all calls to
8036 fatal_io_error with calls to fatal_error; add ": %m" to the end of
8037 all the affected error messages.
8038
8039 2003-05-13 Richard Henderson <rth@redhat.com>
8040
8041 * class.c (layout_class_method): Set DECL_EXTERNAL.
8042 * decl.c (java_mark_decl_local, java_mark_class_local): New.
8043 * java-tree.h (java_mark_class_local): Declare.
8044 * jcf-parse.c (parse_class_file): Use it.
8045 * parse.y (java_expand_classes): Likewise.
8046
8047 2003-05-04 Nathan Sidwell <nathan@codesourcery.com>
8048
8049 * Make-lang.in (java/parse.o, java/parse-scan.o): Depend on input.h.
8050 * lex.h: #include input.h.
8051 * jv-scan.c (input_filename): Remove.
8052
8053 2003-05-02 Tom Tromey <tromey@redhat.com>
8054
8055 PR java/10491:
8056 * gjavah.c (HANDLE_INNERCLASSES_ATTRIBUTE): New macro.
8057 (handle_inner_classes): New function.
8058
8059 2003-05-01 Tom Tromey <tromey@redhat.com>
8060
8061 PR java/10459:
8062 * parse.y (finish_for_loop): Do nothing if update expression is a
8063 EXPR_WFL_NODE wrapping nothing.
8064 (java_complete_lhs) <COMPOUND_EXPR>: Likewise.
8065
8066 2003-05-02 Nathan Sidwell <nathan@codesourcery.com>
8067
8068 * lex.h (input_lineno): Remove declaration.
8069 * parse-scan.y: #include input.h.
8070 (input_filename): Remove declaration.
8071 (input_location): Add definition.
8072 (input_line): Remove definition.
8073
8074 2003-05-01 Nathan Sidwell <nathan@codesourcery.com>
8075
8076 * lex.h (lineno): Rename to ...
8077 (input_line): ... here
8078 * parse-scan.y (lineno): Rename to ...
8079 (input_line): ... here.
8080 (reset_report): Rename lineno to input_line.
8081 * check-init.c (check_init): Likewise.
8082 * class.c (push_class): Likewise.
8083 * decl.c (complete_start_java_method, end_java_method): Likewise.
8084 * expr.c (expand_byte_code): Likewise.
8085 * jcf-parse.c (give_name_to_class, parse_class_file): Likewise.
8086 * jcf-write.c (generate_bytecode_insns): Likewise.
8087 * lex.c (java_init_lex, java_allocate_new_line,
8088 do_java_lex): Likewise.
8089 * parse.h (YYNOT_TWICE): Likewise.
8090 * parse.y (empty_statement, expression_statement,
8091 java_pop_parser_context, java_parser_context_save_global,
8092 yyerror, register_fields, method_header, safe_layout_class,
8093 find_in_imports_on_demand, create_artificial_method,
8094 source_end_java_method, start_complete_expand_method,
8095 build_thisn_assign, java_complete_lhs,
8096 maybe_absorb_scoping_block): Likewise.
8097
8098 2003-04-20 Mohan Embar <gnustuff@thisiscool.com>
8099
8100 * jcf-io.c (find_class): use DIR_SEPARATOR instead of
8101 '/' when computing java source filename
8102
8103 2003-04-13 Tom Tromey <tromey@redhat.com>
8104
8105 * gjavah.c (print_c_decl): Indentation fix.
8106
8107 2003-04-12 Zack Weinberg <zack@codesourcery.com>
8108
8109 * class.c (make_field_value, make_method_value, get_dispatch_table)
8110 (make_class_data, emit_offset_symbol_table)
8111 * constants.c (build_constants_constructor)
8112 * java-tree.h (START_RECORD_CONSTRUCTOR)
8113 * parse.y (maybe_build_array_element_wfl):
8114 Use build_constructor.
8115
8116 2003-04-10 Eric Blake <ebb9@email.byu.edu>
8117
8118 PR java/10253:
8119 * parse.y (string_convert_int_cst): Always use at least one digit
8120 in string conversion. Remove ASCII dependence.
8121 (merge_string_cste): Fix merging of 3-byte UTF-8 characters.
8122
8123 2003-03-16 Mohan Embar <gnustuff@thisiscool.com>
8124
8125 * Make-lang.in: added win32-host.c
8126 * jcf.h: defined macro JCF_OPEN_EXACT_CASE which
8127 resolves to open() on non-Win32 platforms and
8128 Win32-specific jcf_open_exact_case() on Win32
8129 * jcf-io.c (find_class): use JCF_OPEN_EXACT_CASE
8130 when trying .java and .class files
8131 * win32-host.c: added to repository. Defines
8132 Win32-specific jcf_open_exact_case()
8133
8134 2003-04-10 Andrew Haley <aph@redhat.com>
8135
8136 * jcf-write.c (struct jcf_partial): num_jsrs: new field.
8137 (maybe_free_localvar): Renamed from localvar_free.
8138 Add new arg, really.
8139 (generate_bytecode_insns): Set new variable, jsrs.
8140 Only free local vars if no jsr insns have been emittted.
8141 Call maybe_free_localvar, not localvar_free.
8142
8143 2003-03-30 Joseph S. Myers <jsm@polyomino.org.uk>
8144
8145 * gcj.texi: Remove @ at start of file.
8146
8147 2003-03-25 Tom Tromey <tromey@redhat.com>
8148
8149 * parse.y (create_interface): Call CHECK_DEPRECATED.
8150
8151 2003-03-23 Zack Weinberg <zack@codesourcery.com>
8152
8153 * Make-lang.in: Link jcf-dump against $(LDEXP_LIB).
8154
8155 2003-03-21 Zack Weinberg <zack@codesourcery.com>
8156
8157 * javaop.h (jfloat, jdouble): Make them structures mirroring
8158 the bit fields of IEEE float and double respectively.
8159 (JFLOAT_FINITE, JFLOAT_QNAN_MASK, JFLOAT_EXP_BIAS,
8160 JDOUBLE_FINITE, JDOUBLE_QNAN_MASK, JDOUBLE_EXP_BIAS): New.
8161 (union Word, union DWord): Delete.
8162 (WORD_TO_FLOAT, WORDS_TO_DOUBLE): Update to match.
8163
8164 * gjavah.c (java_float_finite, java_double_finite, F_NAN_MASK,
8165 D_NAN_MASK): Delete.
8166 (jni_print_float, jni_print_double): New. Generate
8167 hexadecimal floating constants.
8168 (print_field_info): Use jni_print_float/double.
8169
8170 * jcf-dump.c: Include math.h. Use ldexp/frexp to assemble
8171 finite floating point numbers for output; special case
8172 non-finite floats.
8173
8174 2003-03-19 Nathanael Nerode <neroden@gcc.gnu.org>
8175
8176 * lang.c (java_dump_tree): Change return type from 'int' to 'bool'.
8177 Replace 0 and 1 with true and false in return statements.
8178
8179 2003-03-19 Tom Tromey <tromey@redhat.com>
8180
8181 * lex.c (do_java_lex): Renamed from java_lex.
8182 (java_lex): New function.
8183 Include timevar.h.
8184
8185 2003-03-13 Tom Tromey <tromey@redhat.com>
8186
8187 * parse.y (resolve_inner_class): Error if qualifier is a primitive
8188 type.
8189
8190 2003-03-04 Andrew Haley <aph@redhat.com>
8191
8192 * gjavah.c (is_first_data_member): New global variable.
8193 (print_c_decl): If it's the first data member, align it as the
8194 superclass.
8195 (process_file): Set is_first_data_member.
8196
8197 2003-03-11 Tom Tromey <tromey@redhat.com>
8198
8199 * parse.y (resolve_field_access): Initialize class if field is
8200 found in another static field.
8201 * expr.c (build_class_init): Don't optimize out initialization of
8202 implemented interface.
8203
8204 2003-03-11 Andrew Haley <aph@redhat.com>
8205
8206 * jcf-io.c (caching_stat): Initialize origsep to remove compiler
8207 warning.
8208
8209 2003-03-10 Ranjit Mathew <rmathew@hotmail.com>
8210
8211 * jcf-io.c (caching_stat): Account for both DIR_SEPARATOR
8212 and DIR_SEPARATOR_2 for a target.
8213 Correct minor typos.
8214
8215 * jcf-write.c (make_class_file_name): Take both DIR_SEPARATOR
8216 and DIR_SEPARATOR_2 for a target into account.
8217
8218 2003-03-08 Neil Booth <neil@daikokuya.co.uk>
8219
8220 * lang.c (java_init): Update prototype, move code to java_post_options.
8221 (java_post_options): Similarly.
8222
8223 2003-03-05 Ranjit Mathew <rmathew@hotmail.com>
8224
8225 * jcf.h (COMPARE_FILENAMES): New macro similar to "strcmp" to
8226 compare file name components depending on the case-sensitivity
8227 or otherwise of the host file system.
8228
8229 * jcf-path.c (add_entry): Use COMPARE_FILENAMES instead of
8230 "strcmp" to compare file name components.
8231 Use IS_DIR_SEPARATOR instead of comparing directly against
8232 DIR_SEPARATOR.
8233 (jcf_path_extdirs_arg): Use IS_DIR_SEPARATOR instead of
8234 comparing directly against DIR_SEPARATOR.
8235
8236 2003-03-04 Tom Tromey <tromey@redhat.com>
8237
8238 * Make-lang.in (java.tags): New target.
8239
8240 2003-03-01 Roger Sayle <roger@eyesopen.com>
8241
8242 * java/builtins.c (builtin_type): Handle DEF_FUNCTION_TYPE_VAR_3.
8243 (initialize_builtins): Handle DEF_FUNCTION_TYPE_VAR_3.
8244
8245 2003-03-01 Tom Tromey <tromey@redhat.com>
8246
8247 * parse.y (jdep_resolve_class): Only check deprecation if we found
8248 a decl.
8249
8250 2003-02-28 Tom Tromey <tromey@redhat.com>
8251
8252 PR java/9695:
8253 * class.c (maybe_layout_super_class): Always pass a WFL to
8254 do_resolve_class.
8255 * parse.y (do_resolve_class): Updated comment to explain
8256 parameters.
8257
8258 2003-02-26 Tom Tromey <tromey@redhat.com>
8259
8260 * jcf-write.c (generate_classfile): Check whether class is
8261 deprecated before writing attribute count.
8262
8263 2003-02-25 Roger Sayle <roger@eyesopen.com>
8264
8265 * java/decl.c (java_init_decl_processing): Get soft_fmod_node from
8266 built_in_decls[BUILT_IN_FMOD] rather than define it ourselves.
8267
8268 2003-02-23 Tom Tromey <tromey@redhat.com>
8269
8270 * lang-options.h: Added -Wdeprecated.
8271 * gcj.texi (Warnings): Document -Wdeprecated.
8272 * java-tree.h (flag_deprecated): Declare.
8273 * lang.c (lang_W_options): Added deprecated.
8274 (flag_deprecated): New global.
8275 * chartables.h: Rebuilt.
8276 * gen-table.pl (process_one): Look at whitespace.
8277 (print_tables): Define LETTER_SPACE, LETTER_MASK.
8278 * parse.h (CLEAR_DEPRECATED): New macro.
8279 (CHECK_DEPRECATED_NO_RESET): New macro.
8280 * jcf-parse.c (handle_deprecated): New function.
8281 (HANDLE_DEPRECATED_ATTRIBUTE): New define.
8282 * jcf-reader.c (get_attribute): Handle Deprecated attribute.
8283 * parse.y (resolve_type_during_patch): Check deprecation.
8284 (jdep_resolve_class): Likewise.
8285 (process_imports): Likewise.
8286 (resolve_expression_name): Likewise.
8287 (check_deprecation): Strip arrays from decl. Check
8288 flag_deprecated.
8289 (patch_method_invocation): Also check the particular constructor
8290 for deprecation.
8291 (register_fields): Use CHECK_DEPRECATED_NO_RESET in loop.
8292 * jcf-write.c (append_deprecated_attribute): New function.
8293 (generate_classfile): Generate deprecated attribute when
8294 appropriate.
8295 * lex.c (java_parse_doc_section): Return type now void. Rewrote.
8296 (java_lex) [case '*']: Simplify logic.
8297 (java_start_char_p): Use LETTER_MASK.
8298 (java_part_char_p): Likewise.
8299 (java_space_char_p): New function.
8300
8301 2003-02-20 Nathan Sidwell <nathan@codesourcery.com>
8302
8303 Change base class access representation.
8304 * java/class.c (set_super_info): Don't set TREE_VIA_PUBLIC.
8305 (add_interface_do): Likewise.
8306
8307 2003-02-12 Ranjit Mathew <rmathew@hotmail.com>
8308
8309 * decl.c (java_init_decl_processing): Change
8310 soft_lookupjnimethod_node to reflect the change in
8311 signature of _Jv_LookupJNIMethod in libjava/jni.cc
8312 * expr.c (build_jni_stub): Calculate and pass the size
8313 on the stack of the arguments to a JNI function. Use
8314 new target macro MODIFY_JNI_METHOD_CALL to allow a
8315 target to modify the call to a JNI method.
8316
8317 2003-02-08 Roger Sayle <roger@eyesopen.com>
8318
8319 * jcf-io.c (java_or_class_file): Use libiberty's lbasename
8320 instead of basename to avoid compiler warnings on Tru64.
8321
8322 2003-02-04 Joseph S. Myers <jsm@polyomino.org.uk>
8323
8324 * gcj.texi: Update to GFDL 1.2.
8325
8326 2003-01-31 Andrew Haley <aph@redhat.com>
8327
8328 * parse.y (java_expand_classes): Scan the whole class list looking
8329 for access methods that haven't yet been expanded.
8330
8331 2003-01-31 Adrian Bunk <bunk@fs.tum.de>
8332
8333 Fix for java/4269:
8334
8335 * jv-scan.c: Use HAVE_LANGINFO_CODESET instead of HAVE_NL_LANGINFO
8336 to fix bootstrap on sparc-unknown-netbsdelf1.5.
8337 * jcf-parse.c: Likewise.
8338
8339 2003-01-31 Mark Wielaard <mark@klomp.org>
8340
8341 * gjavah.c (throwable_p): Allocate 1 more byte for string.
8342
8343 2003-01-31 Nathan Sidwell <nathan@codesourcery.com>
8344
8345 * class.c (make_class): Use BINFO_ELTS.
8346 (set_super_info): Likewse.
8347 (add_interface_do): Likewise.
8348
8349 2003-01-30 Tom Tromey <tromey@redhat.com>
8350
8351 * jcf-parse.c (read_class): Update identifier's class value if it
8352 changed during parsing.
8353
8354 2003-01-30 Loren James Rittle <ljrittle@acm.org>
8355
8356 * Make-lang.in (po-generated): Find the targets in $(parsedir).
8357 Propagate change to all other rules as required.
8358 (java/parse-scan.o): Add explicit dependency on
8359 $(parsedir)/java/parse-scan.c .
8360
8361 2003-01-29 Tom Tromey <tromey@redhat.com>
8362
8363 * parse.y (patch_assignment): Only transform the rhs of an
8364 assignment when compiling to native.
8365
8366 2003-01-28 Tom Tromey <tromey@redhat.com>
8367
8368 * jcf-write.c (generate_bytecode_conditional): Typo fixes.
8369
8370 2003-01-28 Tom Tromey <tromey@redhat.com>
8371
8372 * lex.c (java_lex): Don't include UEOF as part of token.
8373 (java_read_unicode): Error if \u sequence prematurely terminated.
8374
8375 2003-01-27 Tom Tromey <tromey@redhat.com>
8376
8377 * parse.y (java_check_regular_methods): Check for construct after
8378 checking types in throws clause.
8379
8380 2003-01-24 Tom Tromey <tromey@redhat.com>
8381
8382 * class.c (build_static_field_ref): Only a String or numeric field
8383 can fold to a constant.
8384
8385 2003-01-23 Tom Tromey <tromey@redhat.com>
8386
8387 * jcf-parse.c (parse_zip_file_entries): Overwrite trailing \0 of
8388 file name in resource buffer.
8389
8390 2003-01-23 Tom Tromey <tromey@redhat.com>
8391
8392 * expr.c (build_known_method_ref): Use method's context to find
8393 method table index.
8394
8395 2003-01-23 Tom Tromey <tromey@redhat.com>
8396
8397 * constants.c (set_constant_entry): Allocated cleared memory.
8398
8399 2003-01-22 Tom Tromey <tromey@redhat.com>
8400
8401 * java-tree.h: Don't use PARAMS.
8402 * resource.c: Add prototypes for all functions.
8403 (write_resource_constructor): Use `const char *' to avoid
8404 warning.
8405
8406 2003-01-22 Nathanael Nerode <neroden@gcc.gnu.org>
8407
8408 * jcf-parse.c (process_zip_dir): Remove unused variable.
8409
8410 2003-01-22 Tom Tromey <tromey@redhat.com>
8411
8412 * expr.c (build_invokeinterface): Abort if method's context is not
8413 an interface.
8414
8415 2003-01-22 Tom Tromey <tromey@redhat.com>
8416
8417 * gcj.texi (Input and output files): Mention non-class entries.
8418 * decl.c (java_init_decl_processing): Call
8419 init_resource_processing.
8420 * java-tree.h (compile_resource_data, write_resource_constructor,
8421 compile_resource_file, init_resource_processing): Declare.
8422 * config-lang.in (gtfiles): Added resource.c.
8423 * Make-lang.in (gt-java-resource.h): New target.
8424 (JAVA_OBJS): Added resource.o.
8425 (java/resource.o): New target.
8426 * resource.c: New file.
8427 * class.c (compile_resource_file): Moved to resource.c.
8428 (registerResource_libfunc): Likewise.
8429 (utf8_decl_list): Mark with GTY; now static.
8430 * jcf-parse.c (classify_zip_file): New function.
8431 (parse_zip_file_entries): Use it; compile .properties files.
8432 (process_zip_dir): Use classify_zip_file and compute_class_name.
8433 Don't write class name into zip directory.
8434 (java_parse_file): Call write_resource_constructor.
8435 (compute_class_name): New function.
8436 * jcf-io.c (read_zip_member): Reindented.
8437
8438 2003-01-21 Tom Tromey <tromey@redhat.com>
8439
8440 * class.c (supers_all_compiled): New function.
8441 (make_class_data): Use it.
8442
8443 2003-01-21 Tom Tromey <tromey@redhat.com>
8444
8445 * parse.y (method_header): Native method can't be strictfp.
8446 No method can be transient or volatile.
8447
8448 2003-01-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8449
8450 Make-lang.in (jvspec.o-warn): Add -Wno-error.
8451
8452 2003-01-18 Kazu Hirata <kazu@cs.umass.edu>
8453
8454 * check-init.c: Fix comment typos.
8455 * class.c: Likewise.
8456 * constants.c: Likewise.
8457 * decl.c: Likewise.
8458 * except.c: Likewise.
8459 * expr.c: Likewise.
8460 * java-except.h: Likewise.
8461 * java-tree.h: Likewise.
8462 * javaop.h: Likewise.
8463 * jcf-dump.c: Likewise.
8464 * jcf-io.c: Likewise.
8465 * jcf-parse.c: Likewise.
8466 * jcf-write.c: Likewise.
8467 * lang.c: Likewise.
8468 * mangle.c: Likewise.
8469 * typeck.c: Likewise.
8470 * verify.c: Likewise.
8471
8472 2003-01-18 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8473
8474 * Make-lang.in (java/jcf-write.o): Depend on $(TM_P_H).
8475 * jcf-write.c: Include "tm_p.h".
8476
8477 2003-01-17 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8478
8479 * jcf-io.c (caching_stat): Cast the 3rd arg of scandir to void*.
8480
8481 2003-01-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8482
8483 * builtins.c (java_build_function_call_expr): Renamed from
8484 build_function_call_expr. All callers changed.
8485
8486 * Make-lang.in (java/jcf-parse.o): Depend on $(TM_P_H).
8487 * jcf-parse.c: Include tm_p.h.
8488
8489 * jcf-write.c (generate_bytecode_insns): Avoid signed/unsigned
8490 warning.
8491
8492 2003-01-14 Tom Tromey <tromey@redhat.com>
8493
8494 * class.c (make_class_data): Check that super is compiled before
8495 building class reference to it.
8496
8497 2003-01-14 Andrew Haley <aph@redhat.com>
8498
8499 * decl.c (java_init_decl_processing): _Jv_NewMultiArray is a
8500 varargs function -- correct.
8501
8502 2003-01-14 Andrew Haley <aph@redhat.com>
8503
8504 * decl.c (java_init_decl_processing): Temporarily back out previous patch.
8505
8506 2003-01-14 Andrew Haley <aph@redhat.com>
8507
8508 * decl.c (java_init_decl_processing): _Jv_NewMultiArray is a
8509 varargs function -- correct.
8510
8511 * parse.y (patch_assignment): Copy the rhs of an assignment into a
8512 temporary if the RHS is a reference.
8513
8514 2003-01-11 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8515
8516 * Make-lang.in (keyword.h): Pass "-L ANSI-C" to gperf.
8517 * keyword.h: Regenerated.
8518
8519 * All Files: Convert to ISO C style function definitions.
8520
8521 2003-01-09 Nathanael Nerode <neroden@gcc.gnu.org>
8522
8523 * parse.y (check_pkg_class_access): ANSIfy definition.
8524
8525 2003-01-09 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8526
8527 * decl.c, parse-scan.y, parse.y: Don't cast return value of
8528 xmalloc et al.
8529
8530 * class.c, gjavah.c, parse.y, verify.c: Don't use PTR.
8531
8532 2003-01-09 Geoffrey Keating <geoffk@apple.com>
8533
8534 Merge from pch-branch:
8535
8536 2002-12-02 Geoffrey Keating <geoffk@apple.com>
8537
8538 * Make-lang.in (java/gjavah.o): Update dependencies.
8539 * gjavah.c: Include ggc.h.
8540
8541 2002-08-16 Geoffrey Keating <geoffk@redhat.com>
8542
8543 * Make-lang.in (GCJH_OBJS): Add ggc-none.o.
8544 (JCFDUMP_OBJS): Add ggc-none.o.
8545 (java/jcf-dump.o): Depend on GGC_H.
8546 * jcf-reader.c (jcf_parse_constant_pool): Use ggc_alloc to allocate
8547 CPool substructures.
8548 * jcf-parse.c (process_zip_dir): Use ggc_alloc to allocate JCFs.
8549 * jcf-dump.c: Include ggc.h.
8550
8551 2002-08-08 Geoffrey Keating <geoffk@redhat.com>
8552
8553 * jcf.h (union cpool_entry): New.
8554 (struct CPool): Use gengtype to mark. Change field 'data' to be
8555 an array of unions.
8556 (struct JCF): Use gengtype to mark.
8557 (CPOOL_UINT): Update for new cpool_entry type.
8558 (CPOOL_USHORT1): Likewise.
8559 (CPOOL_USHORT2): Likewise.
8560 (CPOOL_FINISH): Use GC to free cpool subfields.
8561 * parse.h (struct parser_ctxt): Mark field current_jcf.
8562 * lex.c (java_init_lex): Use GC to allocate struct JCF.
8563 * jcf-parse.c (HANDLE_CONSTANT_Utf8): Update for new cpool_entry type.
8564 (main_jcf): Use gengtype to mark.
8565 (ggc_mark_jcf): Delete.
8566 (get_constant): Update for new cpool_entry type.
8567 (give_name_to_class): Likewise.
8568 (get_class_constant): Likewise.
8569 (init_outgoing_cpool): Use GGC to allocate struct CPool.
8570 (java_parse_file): Use GGC to allocate struct JCF.
8571 (init_jcf_parse): Don't call ggc_add_root.
8572 * jcf-reader.c (jcf_parse_constant_pool): Update for new
8573 cpool_entry type.
8574 * java-tree.h (current_jcf): Use gengtype to mark.
8575 (CPOOL_UTF): Update for new cpool_entry type.
8576 (outgoing_cpool): Use gengtype to mark.
8577 (struct lang_type): GC struct JCF and struct CPool.
8578 * config-lang.in (gtfiles): Add jcf.h.
8579 * constants.c (find_tree_constant): New.
8580 (set_constant_entry): Allocate cpool subfields using GGC. Update
8581 for new cpool_entry type.
8582 (find_constant1): Update for new cpool_entry type.
8583 (find_constant2): Likewise.
8584 (find_utf8_constant): Use find_tree_constant.
8585 (find_class_or_string_constant): Remove unnecessary cast to jword.
8586 Update for new cpool_entry type.
8587 (count_constant_pool_bytes): Update for new cpool_entry type.
8588 (write_constant_pool): Likewise.
8589 (alloc_name_constant): Use find_tree_constant.
8590 (build_constants_constructor): Update for new cpool_entry type.
8591
8592 2002-08-08 Geoffrey Keating <geoffk@redhat.com>
8593
8594 * parse.y (mark_parser_ctxt): Delete.
8595 (goal): Don't use ggc_add_root.
8596 (create_new_parser_context): Use GC to allocate struct parser_ctxt.
8597 (java_pop_parser_context): Let GC free parser_ctxt.
8598 (java_parser_context_resume): Likewise.
8599 * parse.h (struct parser_ctxt): Use gengtype to mark.
8600 (ctxp): Likewise.
8601 (ctxp_for_generation): Likewise.
8602 * lex.h (struct java_lc_s): Mark for gengtype.
8603 (java_lexer): Rearrange for gengtype.
8604 * config-lang.in (gtfiles): Add lex.h, parse.h.
8605
8606 2003-01-09 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8607
8608 * All Files: Remove PARAMS macro.
8609
8610 * expr.c, gjavah.c, javaop.h, jcf-dump.c, jcf-io.c, jcf-reader.c,
8611 jcf-write.c, jcf.h, jv-scan.c: Don't rely on the `DEFUN', `AND' or
8612 `__STDC__' macros.
8613
8614 * jv-scan.c, parse.y: Remove VPARAMS, VA_OPEN, VA_FIXEDARG and
8615 VA_CLOSE.
8616
8617 2003-01-09 Christian Cornelssen <ccorn@cs.tu-berlin.de>
8618
8619 * Make-lang.in (java.install-common, java.uninstall,
8620 java.install-info, java.install-man): Prepend $(DESTDIR)
8621 to destination paths in all (un)installation commands.
8622 (java.install-common): Rewrite $(LN) command to support
8623 DESTDIR with "ln" as well as with "ln -s".
8624
8625 2003-01-08 Nathanael Nerode <neroden@gcc.gnu.org>
8626
8627 * java-tree.h: Protect against multiple inclusion.
8628
8629 2003-01-07 Tom Tromey <tromey@redhat.com>
8630
8631 * class.c (add_assume_compiled): Don't adjust parent if we're
8632 already at the root of tree.
8633
8634 2003-01-05 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8635
8636 * lang.c (dump_compound_expr): Prototype.
8637
8638 2003-01-03 Tom Tromey <tromey@redhat.com>
8639
8640 Fix for PR java/8712:
8641 * expr.c (build_instanceof): Build an NE_EXPR, not a COND_EXPR,
8642 when simply checking against `null'.
8643
8644 2003-01-03 Tom Tromey <tromey@redhat.com>
8645
8646 * gcj.texi (Standard Properties): Document http.proxyHost and
8647 http.proxyPort.
8648
8649 * gcj.texi (GNU Classpath Properties): Document new properties.
8650
8651 2003-01-02 Steven Bosscher <s.bosscher@student.tudelft.nl>
8652
8653 * java/jcf-reader.c, java/jvgenmain.c, java/keyword.gperf,
8654 java/lang-options.h, java/mangle.c, java/mangle_name.c,
8655 java/xref.c, java/zextract.c,java/zipfile.h: Fix copyright years.
8656
8657 2003-01-01 Steven Bosscher <s.bosscher@student.tudelft.nl>
8658
8659 * Make-lang.in, boehm.c, buffer.c,
8660 buffer.h, builtins.c, class.c,
8661 config-lang.in, constants.c,
8662 convert.h, decl.c, except.c,
8663 expr.c, java-except.h,
8664 java-tree.h, javaop.def,
8665 jcf-parse.c, jcf-write.c,
8666 jv-scan.c, jvgenmain.c,
8667 jvspec.c, keyword.gperf,
8668 keyword.h, lang-options.h,
8669 lang-specs.h, lang.c, lex.c,
8670 lex.h, mangle.c, mangle_name.c,
8671 parse-scan.y, parse.h, parse.y,
8672 typeck.c, verify.c, xref.c,
8673 xref.h: Replace "GNU CC" with
8674 "GCC" in the copyright header.
8675
8676 * check-init.c, gjavah.c, javaop.h,
8677 jcf-depend.c, jcf-dump.c, jcf-io.c,
8678 jcf-path.c, jcf-reader.c, jcf.h,
8679 zextract.c, zipfile.h: These files are
8680 "part of GCC". Also say "GCC" not "GNU CC".
8681
8682 2002-12-30 DJ Delorie <dj@redhat.com>
8683
8684 * Make-lang.in: Protect against texi2pod/pod2man failing.
8685
8686 2002-12-28 Joseph S. Myers <jsm@polyomino.org.uk>
8687
8688 * gcj.texi: Use @copying.
8689
8690 2002-12-27 Mark Mitchell <mark@codesourcery.com>
8691
8692 * gjavah.c (print_name_for_stub_or_jni): Adjust call to
8693 print_cxx_classname.
8694 (print_cxx_classname): Add add_scope parameter.
8695 (print_class_decls): Do not emit a semicolon after the extern
8696 "Java" block.
8697 (process_file): Adjust calls to print_cxx_classname.
8698
8699 2002-12-23 Joseph S. Myers <jsm@polyomino.org.uk>
8700
8701 * gcj.texi: Include Cover Texts in man page.
8702
8703 2002-12-23 Jeff Sturm <jsturm@one-point.com>
8704
8705 * class.c (build_static_field_ref): Check FIELD_FINAL.
8706
8707 * constants.c (alloc_class_constant): Use TYPE_CPOOL_DATA_REF
8708 instead of current_constant_pool_data_ref.
8709 * java-tree.h (current_constant_pool_data_ref): Undefine.
8710 (JTI_CURRENT_CONSTANT_POOL_DATA_REF): Remove.
8711 * jcf-parse.c (init_outgoing_cpool): Don't initialize
8712 current_constant_pool_data_ref.
8713
8714 * except.c (prepare_eh_table_type ): Use DECL_NAME of class type,
8715 not build_internal_class_name.
8716
8717 * parse.y (patch_incomplete_class_ref): Always emit `class$' method.
8718 Use it when class ref isn't certain to be compiled.
8719
8720 2002-12-23 Joseph S. Myers <jsm@polyomino.org.uk>
8721
8722 * gcj.texi: Include gcc-common.texi.
8723 * Make-lang.in ($(srcdir)/java/gcj.info, java/gcj.dvi): Depend on
8724 $(srcdir)/doc/include/gcc-common.texi.
8725
8726 2002-12-22 Anthony Green <green@redhat.com>
8727
8728 * gcj.texi (Limitations): Add note about org.xml.sax and
8729 org.w3c.dom.
8730
8731 2002-12-20 Tom Tromey <tromey@redhat.com>
8732
8733 * jcf-write.c (generate_bytecode_insns) [SWITCH_EXPR]: Handle case
8734 where minimum case value is Integer.MIN_VALUE.
8735 Fixes PR java/8955.
8736
8737 2002-12-18 Andrew Haley <aph@redhat.com>
8738
8739 * parse.y (patch_invoke): Force evaluation order when `check' is
8740 set. For PR libgcj/8945.
8741
8742 2002-12-16 Mark Mitchell <mark@codesourcery.com>
8743
8744 * gcj.texi: Change version number to 3.4.
8745
8746 2002-12-05 Ranjit Mathew <rmathew@hotmail.com>
8747 Andrew Haley <aph@redhat.com>
8748
8749 * parse.y (source_end_java_method): Remove custom encoding of line
8750 numbers for a function decl before passing it to the back end.
8751
8752 2002-12-03 Andrew Haley <aph@redhat.com>
8753
8754 * class.c (make_class_data): New field, "chain".
8755 * decl.c (java_init_decl_processing): Likewise.
8756
8757 2002-12-02 Tom Tromey <tromey@redhat.com>
8758
8759 For PR java/8740:
8760 * parse.y (do_resolve_class): Handle qualified name via
8761 recursion.
8762
8763 2002-11-30 Zack Weinberg <zack@codesourcery.com>
8764
8765 * boehm.c, buffer.c, builtins.c, check-init.c, class.c,
8766 constants.c, decl.c, except.c, expr.c, gjavah.c, jcf-depend.c,
8767 jcf-dump.c, jcf-io.c, jcf-parse.c, jcf-path.c, jcf-write.c,
8768 jv-scan.c, jvgenmain.c, jvspec.c, lang.c, mangle.c, mangle_name.c,
8769 parse-scan.y, parse.y, typeck.c, verify.c, xref.c, zextract.c:
8770 Include coretypes.h and tm.h.
8771 * Make-lang.in: Update dependencies.
8772
8773 2002-11-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8774
8775 * decl.c (java_init_decl_processing): Use `LL' on 64-bit constant.
8776
8777 2002-11-25 Diego Novillo <dnovillo@redhat.com>
8778
8779 * jcf-reader.c: Don't expand JCF_readu4 inside the
8780 expansion of JCF_SKIP.
8781
8782 2002-11-25 Diego Novillo <dnovillo@redhat.com>
8783
8784 * jcf-reader.c: Don't expand JCF_readu4 inside the
8785 expansion of JCF_SKIP.
8786
8787 2002-11-22 Tom Tromey <tromey@redhat.com>
8788
8789 * parse.y (patch_binop): Cast right hand side of shift expression
8790 to `int'. Fixes PR java/8676.
8791
8792 2002-11-22 Ranjit Mathew <rmathew@hotmail.com>
8793 Andrew Haley <aph@redhat.com>
8794
8795 * gcc/java/jcf-write.c (write_classfile): Remove target
8796 class file, if it exists, before renaming the temporary
8797 class file to it.
8798
8799 2002-11-19 Jason Thorpe <thorpej@wasabisystems.com>
8800
8801 * jvspec.c (lang_specific_spec_functions): New.
8802
8803 2002-11-18 Tom Tromey <tromey@redhat.com>
8804
8805 Fix for PR java/7912:
8806 * expr.c (can_widen_reference_to): Allow cast of array to
8807 Cloneable or Serializable.
8808 * java-tree.h (java_lang_cloneable_identifier_node): Declare.
8809 (java_io_serializable_identifier_node): Likewise.
8810 * parse.y (java_lang_cloneable, java_io_serializable): Removed.
8811 (valid_ref_assignconv_cast_p): Use new identifier nodes.
8812 * lex.c (java_init_lex): Don't initialize java_lang_cloneable and
8813 java_io_serializable.
8814 * decl.c (java_init_decl_processing): Initialize
8815 java_lang_cloneable_identifier_node and
8816 java_io_serializable_identifier_node.
8817 (java_lang_cloneable_identifier_node): New global.
8818 (java_io_serializable_identifier_node): Likewise.
8819
8820 2002-11-14 Jens-Michael Hoffmann <jensmh@gmx.de>
8821
8822 * buffer.c: Remove unnecessary casts.
8823 * check-init.c: Likewise.
8824 * class.c: Likewise.
8825 * constants.c: Likewise.
8826 * decl.c: Likewise.
8827 * except.c: Likewise.
8828 * gjavah.c: Likewise.
8829 * jcf-io.c: Likewise.
8830 * jcf-parse.c: Likewise.
8831 * jcf-path.c: Likewise.
8832 * jvspec.c: Likewise.
8833 * lang.c: Likewise.
8834 * lex.c: Likewise.
8835 * verify.c: Likewise.
8836
8837 2002-11-06 Tom Tromey <tromey@redhat.com>
8838
8839 * gjavah.c (print_stub_or_jni): Include JNIEXPORT and JNICALL in
8840 a JNI header.
8841
8842 2002-11-05 Tom Tromey <tromey@redhat.com>
8843
8844 Fix for PR java/6388.
8845 * lex.h (JAVA_INTEGRAL_RANGE_ERROR): Wrap in do...while.
8846 * java-tree.h (enum java_tree_index): New values
8847 JTI_DECIMAL_INT_MAX_NODE, JTI_DECIMAL_LONG_MAX_NODE.
8848 (decimal_int_max, decimal_long_max): New defines.
8849 * lex.c (yylex): Rewrote range checking. Sign extend literals.
8850 (error_if_numeric_overflow): Rewrote range checking.
8851 * decl.c (java_init_decl_processing): Initialize decimal_int_max,
8852 decimal_long_max.
8853
8854 2002-11-02 Tom Tromey <tromey@redhat.com>
8855
8856 * java-tree.h: Move JV_STATE_ERROR before JV_STATE_DONE.
8857
8858 * class.c (make_method_value): Put class name, not signature, into
8859 `throws' field. For PR java/8415.
8860
8861 2002-10-24 Tom Tromey <tromey@redhat.com>
8862
8863 * gcj.texi (Invoking gij): Document --showversion.
8864 (Standard Properties): java.library.path now set.
8865
8866 2002-10-23 Tom Tromey <tromey@redhat.com>
8867
8868 * gjavah.c (decode_signature_piece): In JNI mode, print
8869 `jobjectArray' when array depth is nonzero.
8870 Fixes PR java/8296.
8871
8872 2002-10-15 Andrew Haley <aph@redhat.com>
8873
8874 * parse.y (patch_invoke): Call force_evaluation_order on a static
8875 arg list.
8876 (resolve_qualified_expression_name): Call force_evaluation_order
8877 on a arg list that is part of a Qualified Expression Name.
8878
8879 * lang.c (dump_compound_expr): New.
8880 (java_dump_tree): New.
8881
8882 2002-10-20 Ranjit Mathew <rmathew@hotmail.com>
8883
8884 * gcj.texi: Added item describing the GCJ runtime property
8885 "gnu.gcj.progname".
8886
8887 2002-10-15 Richard Henderson <rth@redhat.com>
8888
8889 * jcf-parse.c (get_constant): Fix type warning.
8890
8891 2002-10-15 Andrew Haley <aph@redhat.com>
8892
8893 * java-tree.h (java_inlining_merge_static_initializers): Declare.
8894 (java_inlining_map_static_initializers): Declare.
8895
8896 2002-10-14 Andrew Haley <aph@redhat.com>
8897
8898 * tree-inline.c (remap_block): All local class initialization
8899 flags go in the outermost scope.
8900 (expand_call_inline): Call java_inlining_map_static_initializers.
8901 (expand_call_inline): Call java_inlining_merge_static_initializers.
8902 * java/lang.c (merge_init_test_initialization): New.
8903 (java_inlining_merge_static_initializers): New.
8904 (inline_init_test_initialization): New.
8905 (java_inlining_map_static_initializers): New.
8906
8907 2002-10-11 Mark Wielaard <mark@klomp.org>
8908
8909 * gcj.texi (Compatibility): Add Limitations and Extensions section.
8910
8911 2002-10-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8912
8913 * class.c (JAVA_TREEHASHHASH_H): Use htab_hash_pointer.
8914
8915 2002-10-09 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8916
8917 * parse.y (merge_string_cste): Add parentheses around & within |.
8918
8919 2002-10-08 Tom Tromey <tromey@redhat.com>
8920
8921 * parse.y (variable_declarator_id): Simplify error path for
8922 array declarator error. For PR java/8003.
8923
8924 2002-10-08 Zack Weinberg <zack@codesourcery.com>
8925
8926 * gjavah.c, jcf-dump.c, jv-scan.c: Globally replace GCCBUGURL with
8927 bug_report_url.
8928
8929 2002-10-08 Andrew Haley <aph@redhat.com>
8930
8931 * parse.y (attach_init_test_initialization_flags): Check for
8932 error_mark_node.
8933
8934 2002-10-07 Anthony Green <green@redhat.com>
8935
8936 * parse.y (merge_string_cste): Fix bug in string concatenation.
8937
8938 2002-10-03 Michael Koch <konqueror@gmx.de>
8939
8940 * gcj.texi (Standard properties):
8941 Change default of java.awt.toolkit to gnu.awt.gtk.GtkToolkit.
8942
8943 2002-10-02 Roger Sayle <roger@eyesopen.com>
8944
8945 PR optimization/6627
8946 * lang.c (java_init): If storing the vbit in function
8947 pointers, ensure that force_align_functions_log is atleast
8948 one to aid compatability with g++ vtables.
8949
8950 2002-10-01 Nathan Sidwell <nathan@codesourcery.com>
8951
8952 * jcf-dump.c (print_constant, case CONSTANT_float): Don't fall
8953 foul of type-based aliasing.
8954
8955 2002-09-30 Anthony Green <green@redhat.com>
8956
8957 * gcj.texi (Invoking jv-scan): Fix texinfo.
8958
8959 2002-09-28 Anthony Green <green@redhat.com>
8960
8961 * gcj.texi (Invoking jv-scan): Add --no-assert documentation.
8962 (Code Generation): Add -fno-assert documentation.
8963 * jv-scan.c (flag_assert): New global.
8964 (options): Add assert option.
8965 (help): Add --no-assert documentation.
8966 * parse-scan.y (flag_assert): New global.
8967 * lang.c (lang_f_options): Add -fassert/-fno-assert support.
8968 (flag_assert): New global.
8969 * java-tree.h (flag_assert): New global.
8970 * lex.c (java_lex): Obey flag_assert.
8971 * jvspec.c (jvgenmain_spec): Strip -fassert/-fno-assert when
8972 calling cc1.
8973
8974 2002-09-26 Andrew Haley <aph@redhat.com>
8975
8976 * expr.c (build_java_array_length_access): Check for null pointer.
8977 * expr.c (expand_java_arrayload): Likewise.
8978
8979 2002-09-21 Richard Henderson <rth@redhat.com>
8980
8981 * jcf-parse.c (get_constant): Decode from IEEE no matter
8982 what the target format.
8983
8984 2002-09-20 Kazu Hirata <kazu@cs.umass.edu>
8985
8986 * ChangeLog: Follow spelling conventions.
8987 * class.c: Likewise.
8988 * decl.c: Likewise.
8989 * expr.c: Likewise.
8990 * gjavah.c: Likewise.
8991 * java-tree.h: Likewise.
8992 * jcf-dump.c: Likewise.
8993 * jcf-parse.c: Likewise.
8994 * jvspec.c: Likewise.
8995 * lang.c: Likewise.
8996 * mangle.c: Likewise.
8997 * parse.y: Likewise.
8998
8999 2002-09-17 Tom Tromey <tromey@redhat.com>
9000
9001 * lex.c (java_read_unicode_collapsing_terminators): Handle case
9002 where \r appears at EOF. Fixes PR java/7950.
9003
9004 2002-09-16 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
9005
9006 * jvspec.c (lang_specific_driver): Remove unused variable.
9007
9008 2002-09-16 Geoffrey Keating <geoffk@apple.com>
9009
9010 * java-tree.h (union lang_tree_node): Add chain_next option.
9011
9012 2002-09-16 Richard Henderson <rth@redhat.com>
9013
9014 * jcf-parse.c (get_constant): Runtime check for IEEE format;
9015 use new real.h interface.
9016 * jcf-write.c (find_constant_index): Use new real.h interface.
9017 * lex.c (IS_ZERO): Use REAL_VALUES_EQUAL.
9018
9019 2002-09-15 Kazu Hirata <kazu@cs.umass.edu>
9020
9021 * lang.c: Follow spelling conventions.
9022
9023 2002-09-11 Per Bothner <per@bothner.com>
9024
9025 * parse.y (fold_constant_for_init): If a VAR_DECL, convert numerical
9026 constant to the type of the field.
9027 (java_complete_tree): Remove now-redundant code.
9028
9029 * parse.y (fold_constant_for_init): 'null' is not a constant expr.
9030
9031 2002-09-03 Jesse Rosenstock <jmr@ugcs.caltech.edu>
9032
9033 For PR java/5794:
9034 * verify.c (verify_jvm_instructions) [OPCODE_jsr]: Only push the
9035 return label if a ret instruction for the jsr has been reached.
9036
9037 2002-09-09 Ranjit Mathew <rmathew@hotmail.com>
9038
9039 * parse.y (DIR_SEPARATOR): Don't define.
9040 (check_class_interface_creation): Use IS_DIR_SEPARATOR.
9041
9042 2002-08-28 Andrew Haley <aph@redhat.com>
9043
9044 * verify.c (verify_jvm_instructions): Allow exception handler
9045 inside code that is being protected, but generate a warning.
9046 * except.c (link_handler): Initialize `expanded' in new eh_range.
9047 (binding_depth, is_class_level, current_pc): Declare extern.
9048
9049 2002-09-01 Mark Wielaard <mark@klomp.org>
9050
9051 * gcj.texi: Add chapter about system properties.
9052 Fixed some typos.
9053
9054 2002-08-26 Tom Tromey <tromey@redhat.com>
9055
9056 * parse.y (try_builtin_assignconv): Allow narrowing primitive
9057 conversion if RHS_TYPE is byte, short, or char.
9058
9059 2002-08-22 Tom Tromey <tromey@redhat.com>
9060
9061 * gcj.texi (Invoking gij): Document -cp and -classpath.
9062
9063 2002-08-21 Tom Tromey <tromey@redhat.com>
9064
9065 * Make-lang.in (java/jcf-path.o): Use $(datadir), not
9066 $(prefix)/share. For PR libgcj/7633.
9067
9068 For PR java/6005 and PR java/7611:
9069 * lang.c (LANG_HOOKS_CAN_USE_BITFIELDS_P): New define.
9070 (java_can_use_bit_fields_p): New function.
9071
9072 2002-08-16 Tom Tromey <tromey@redhat.com>
9073
9074 * gcj.texi (Class Initialization): Mention class initialization of
9075 arrays.
9076
9077 2002-07-30 Andrew Haley <aph@cambridge.redhat.com>
9078
9079 * Make-lang.in (java-tree-inline.o): New.
9080 (JAVA_OBJS): Add java-tree-inline.o.
9081 * parse.y (source_end_java_method): Call java_optimize_inline.
9082 (java_expand_method_bodies): Save method's tree in
9083 DECL_SAVED_TREE.
9084 (add_stmt_to_compound): Keep track of the number of statments.
9085 * lang.c (java_init): Enable flag_inline_trees.
9086 (java_post_options): If flag_inline_functions is on, enable
9087 flag_inline_trees instread.
9088 (decl_constant_value): New.
9089 (java_tree_inlining_walk_subtrees): New.
9090 * java-tree.h (DECL_NUM_STMTS): New macro.
9091 (java_optimize_inline): Declare.
9092 * expr.c (java_expand_expr): Allow a BLOCK to return a value.
9093 Handle a LABEL_EXPR.
9094 * decl.c (build_result_decl): If we already have a DECL_RESULT
9095 don't make another.
9096 (dump_function): New.
9097 (java_optimize_inline): New.
9098 (dump_function): New.
9099
9100 2002-08-13 Jesse Rosenstock <jmr@fulcrummicro.com>
9101
9102 For PR java/7483:
9103 * parse.y (build_assertion): Invert return from
9104 desiredAssertionStatus.
9105
9106 2002-08-08 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9107
9108 * jcf-write.c (get_access_flags): Return correct access flags for
9109 private and protected inner classes.
9110
9111 2002-08-08 Nathan Sidwell <nathan@codesourcery.com>
9112
9113 * java/Make-lang.in (java.mostlyclean): Remove coverage files.
9114
9115 2002-08-05 Geoffrey Keating <geoffk@redhat.com>
9116
9117 * mangle_name.c: Don't include obstack.h twice.
9118 * xref.c: Don't include obstack.h.
9119
9120 2002-08-04 Geoffrey Keating <geoffk@redhat.com>
9121
9122 * class.c: (permanent_obstack): Delete declaration.
9123 * constants.c: (permanent_obstack): Delete declaration.
9124 * except.c: (permanent_obstack): Delete declaration.
9125 * expr.c: (permanent_obstack): Delete declaration.
9126 * jcf-parse.c: (permanent_obstack): Delete declaration.
9127 (saveable_obstack): Delete declaration.
9128 * parse.h: (permanent_obstack): Delete declaration.
9129 * typeck.c: (permanent_obstack): Delete declaration.
9130
9131 2002-08-04 Joseph S. Myers <jsm@polyomino.org.uk>
9132
9133 * gcj.texi (version-gcc): Increase to 3.3.
9134
9135 2002-07-22 Tom Tromey <tromey@redhat.com>
9136
9137 * lex.c (java_lex): Check for `e' or `E' after 0.
9138
9139 2002-07-21 Richard Henderson <rth@redhat.com>
9140
9141 * lang.c (java_unsafe_for_reeval): New.
9142 (LANG_HOOKS_UNSAFE_FOR_REEVAL): New.
9143
9144 2002-07-21 Neil Booth <neil@daikokuya.co.uk>
9145
9146 * jcf-path.c (GET_ENV_PATH_LIST): Remove.
9147 (jcf_path_init): Use GET_ENVIRONMENT.
9148
9149 2002-07-10 Roger Sayle <roger@eyesopen.com>
9150 Zack Weinberg <zack@codesourcery.com>
9151
9152 * builtins.c (initialize_builtins): Remove defines that
9153 handled C/C++ specific junk hereby removed from builtins.def.
9154
9155 2002-07-07 Neil Booth <neil@daikokuya.co.uk>
9156
9157 * lang.c (java_post_options): Update prototype.
9158
9159 2002-07-05 Roger Sayle <roger@eyesopen.com>
9160
9161 * builtins.c (initialize_builtins): Ignore the additional
9162 parameter to DEF_BUILTIN. Handle more C/C++ specific junk in
9163 the builtins.def file.
9164
9165 2002-07-01 Tom Tromey <tromey@redhat.com>
9166
9167 For PR libgcj/7073:
9168 * parse.y (patch_incomplete_class_ref): Handle VOID_TYPE
9169 specially.
9170
9171 2002-07-01 Roger Sayle <roger@eyesopen.com>
9172
9173 * java/decl.c (builtin_function): Accept additional parameter.
9174 (java_init_decl_processing): Pass an additional NULL_TREE
9175 argument to builtin_function.
9176
9177 2002-06-29 T.J. Mather <tjmather@maxmind.com>
9178
9179 * gcj.texi: Fixed gcj invocation example so that it compiles.
9180
9181 2002-06-26 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
9182
9183 * lex.c (java_init_lex): Avoid incorrect hardcoded constant 11.
9184 * parse.y (mark_parser_ctxt): Likewise.
9185 (check_modifiers, declare_local_variables): Avoid incorrect
9186 hardcoded constant 10.
9187
9188 * lex.c (java_read_char): Avoid "comparison is always true"
9189 warning.
9190
9191 2002-06-25 Andreas Schwab <schwab@suse.de>
9192
9193 * expr.c (JSR): Avoid undefined operation on PC.
9194
9195 2002-06-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
9196
9197 * decl.c (clear_binding_level): Const-ify.
9198
9199 2002-06-13 Akim Demaille <akim@epita.fr>
9200
9201 * parse.y (class_declaration, interface_declaration): Make sure
9202 all their rules have an action, in order to avoid meaningless `$$
9203 = $1' and their type clashes.
9204
9205 2002-06-11 Tom Tromey <tromey@redhat.com>
9206
9207 * jcf-write.c (generate_classfile): Use FIELD_SYNTHETIC.
9208 * parse-scan.y (statement_without_trailing_substatement): Added
9209 assert_statement.
9210 (assert_statement): New rule.
9211 * java-tree.h (struct lang_type) [assertions]: New field.
9212 (TYPE_USES_ASSERTIONS): New macro.
9213 (CLASS_USES_ASSERTIONS): Likewise.
9214 (FIELD_SYNTHETIC): New define.
9215 * lex.c (java_lval;): Added ASSERT_TK.
9216 * parse.y (ASSERT_TK): Added.
9217 (statement_without_trailing_substatement): Added assert_statement.
9218 (assert_statement): New rule.
9219 (build_assertion): New function.
9220 (maybe_generate_pre_expand_clinit): Create and initialize
9221 $assertionsDisabled.
9222 (lookup_package_type): Removed decl.
9223 * keyword.h: Rebuilt.
9224 * keyword.gperf (assert): New token.
9225
9226 2002-06-10 Akim Demaille <akim@epita.fr>
9227
9228 * parse.y (interface_type_list, class_member_declaration)
9229 (unary_expression_not_plus_minus): Remove duplicate %type.
9230 Whitespace changes.
9231
9232 2002-06-09 Tom Tromey <tromey@redhat.com>
9233
9234 * Make-lang.in (java/lang.o): Use LANGHOOKS_DEF_H.
9235
9236 * parse.y (method_header): Give error message in all cases.
9237 Fixes PR java/6865.
9238
9239 2002-06-10 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9240
9241 Don't use RTL inlining. Fix for PR java/6820.
9242 * lang.c (LANG_HOOKS_POST_OPTIONS): Define.
9243 (flag_really_inline): New.
9244 (java_decode_option): Set flag_really_inline if -finline-functions
9245 is seen.
9246 (java_post_options): New function. Turn off inlining unless
9247 flag_really_inline is set.
9248
9249 2002-06-10 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9250
9251 * gjavah.c (throwable_p): Accept argument as either a classname or
9252 signature fragment. Create null-terminated classname string for super
9253 when calling itself recursively.
9254 (decode_signature_piece): Skip first character from class name
9255 signature when calling throwable_p.
9256
9257 2002-06-08 H.J. Lu (hjl@gnu.org)
9258
9259 * jcf-path.c (jcf_path_init): Allocate 1 more byte for string.
9260
9261 2002-06-04 Tom Tromey <tromey@redhat.com>
9262
9263 * jcf-write.c (perform_relocations): Optmize a goto to a goto.
9264
9265 2002-06-04 Michael Koch <konqueror@gmx.de>
9266
9267 * gcj.texi (Input Options): Fixed typo.
9268
9269 2002-06-04 Zack Weinberg <zack@codesourcery.com>
9270
9271 * java-tree.h, class.c, expr.c, jcf-parse.c, parse.y,
9272 typeck.c, verify.c: Remove all #if JAVA_USE_HANDLES blocks,
9273 all mention of CLASS_TO_HANDLE_TYPE or HANDLE_TO_CLASS_TYPE,
9274 and all now-pointless local variables. Rename other local
9275 variables to reflect their not being handles.
9276
9277 * java-tree.h, jcf-dump.c, jcf-io.c: Remove all
9278 #if JCF_USE_STDIO blocks.
9279
9280 * parse.y: Add missing semicolon at end of rule.
9281
9282 2002-06-03 Geoffrey Keating <geoffk@redhat.com>
9283
9284 * check-init.c (attach_initialized_static_class): Delete, unused.
9285 * parse.y: Use htab_t instead of struct hashtable, update
9286 all uses.
9287 * java-tree.h: Include hashtab.h instead of hash.h.
9288 (struct lang_decl_func): Use htab_t, set up for gengtype.
9289 (struct init_test_hash_entry): Delete.
9290 (struct treetreehash_entry): New.
9291 (java_treetreehash_find): New
9292 (java_treetreehash_new): New prototype.
9293 (java_treetreehash_create): New prototype.
9294 (java_mark_tree): Delete prototype.
9295 (java_hash_hash_tree_node): Delete prototype.
9296 (java_hash_compare_tree_node): Delete prototype.
9297 (attach_initialized_static_class): Delete prototype.
9298 * expr.c (build_class_init): Update to use java_treetreehash
9299 functions.
9300 (java_expand_expr): Update to use htab_t.
9301 (emit_init_test_initialization): Likewise.
9302 * decl.c (java_mark_tree): Delete.
9303 * class.c (init_test_hash_newfunc): Delete.
9304 (java_hash_hash_tree_node): Delete.
9305 (java_hash_compare_tree_node): Delete.
9306 (add_method_1): Update to use java_treetreehash functions.
9307 (JAVA_TREEHASHHASH_H): New macro.
9308 (java_treetreehash_hash): New function.
9309 (java_treetreehash_compare): New function.
9310 (java_treetreehash_find): New function.
9311 (java_treetreehash_new): New function.
9312 (java_treetreehash_create): New function.
9313 * Make-lang.in (JAVA_TREE_H): Replace hash.h by HASHTAB_H.
9314
9315 * Make-lang.in (java/parse.o): Depend on debug.h.
9316 * java-tree.h (struct lang_identifier): Use gengtype.
9317 (union lang_tree_node): New.
9318 (struct lang_decl_func): Use gengtype.
9319 (struct lang_decl_var): Likewise.
9320 (struct lang_decl): Likewise.
9321 * parse.y: Include debug.h.
9322 * lang.c (LANG_HOOKS_MARK_TREE): Delete.
9323
9324 * lang.c (struct language_function): New dummy structure.
9325
9326 * java-tree.h (MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC): Set
9327 descriminator for DECL_LANG_SPECIFIC.
9328 (struct lang_decl_func): Rename from struct lang_decl.
9329 (enum lang_decl_desc): New.
9330 (struct lang_decl): Make it a union. Update all the accessor macros.
9331 (struct lang_type): Use gengtype.
9332 * class.c (add_method_1): Set descriminator for DECL_LANG_SPECIFIC.
9333 * decl.c (java_dup_lang_specific_decl): All lang_decl structures
9334 are now the same size.
9335 (lang_mark_tree): Use gengtype to mark TYPE_LANG_SPECIFIC;
9336 use discriminator to mark DECL_LANG_SPECIFIC.
9337
9338 * Make-lang.in (gt-java-builtins.h): New rule.
9339 (java/builtins.o): Add dependency on gt-<filename>.h.
9340 * builtins.c: Use gengtype for roots.
9341 (union string_or_tree): Use gengtype.
9342 (struct builtin_record): Use gengtype.
9343 * config-lang.in (gtfiles): Add builtins.c.
9344
9345 * Make-lang.in (gt-java-class.h, gt-java-constants.h,
9346 gt-java-decl.h, gt-java-expr.h, gt-java-jcf-parse.h,
9347 gt-java-jcf-write.h, gt-java-lang.h, gt-java-mangle.h,
9348 gt-java-parse.h, gtype-java.h): Add rules to generate.
9349 (parse.o): Add dependency on gt-java-parse.h, gt-java.h.
9350 (class.o): Add dependency on gt-*.h.
9351 (constants.o): Likewise.
9352 (decl.o): Likewise.
9353 (expr.o): Likewise.
9354 (jcf-parse.o): Likewise.
9355 (jcf-write.o): Likewise.
9356 (lang.o): Likewise.
9357 * config-lang.in (gtfiles): New.
9358 * class.c: Replace uses of ggc_add_* with GTY markers. Include gt-*.h.
9359 * constants.c: Replace uses of ggc_add_* with GTY markers.
9360 Include gt-*.h.
9361 * decl.c: Replace uses of ggc_add_* with GTY markers. Include gt-*.h.
9362 * expr.c: Replace uses of ggc_add_* with GTY markers. Include gt-*.h.
9363 * java-tree.h: Replace uses of ggc_add_* with GTY markers.
9364 * jcf-parse.c: Replace uses of ggc_add_* with GTY markers.
9365 Include gt-*.h.
9366 * jcf-write.c: Replace uses of ggc_add_* with GTY markers.
9367 Include gt-*.h.
9368 * lang.c: Replace uses of ggc_add_* with GTY markers. Include gt-*.h.
9369 * mangle.c: Replace uses of ggc_add_* with GTY markers. Include
9370 gt-*.h.
9371 * parse.y: Replace uses of ggc_add_* with GTY markers. Include gt-*.h.
9372 Include gtype-java.h.
9373
9374 2002-06-02 Tom Tromey <tromey@redhat.com>
9375
9376 Fix for PR java/5913:
9377 * parse.y (patch_binop): Call patch_string on op1.
9378
9379 2002-06-02 Tom Tromey <tromey@redhat.com>
9380
9381 Fix for PR java/1343, PR java/6336:
9382 * parse.y (make_nested_class_name): Remove extraneous `else'; fix
9383 formatting. Changed return type.
9384 (anonymous_class_counter): Moved to top of file.
9385 (maybe_make_nested_class_name): Append number to class name for
9386 function-local classes.
9387
9388 2002-05-28 Zack Weinberg <zack@codesourcery.com>
9389
9390 * decl.c, jcf-parse.c, parse.y, typeck.c: Include real.h.
9391 * Make-lang.in: Update dependency lists.
9392
9393 2002-05-18 Mark Mitchell <mark@codesourcery.com>
9394
9395 * gjavah.c (throwable_p): Do not free the name of the class after
9396 passing it to find_class.
9397 * java-tree.h (CLASS_BEING_LAIDOUT): Remove duplicate definition.
9398 * jcf-io.c (dirent.h): Include it.
9399 (fnmatch.h): Likewise.
9400 (compare_path): New function.
9401 (java_or_class_file): Likewise.
9402 (memoized_dirlist_entry): New type.
9403 (memoized_dirlist_lookup_eq): New function.
9404 (memoized_dirlists): New variable.
9405 (caching_stat): New function.
9406 (memoized_class_lookup_eq): New function.
9407 (memoized_class_lookups): Likewise.
9408 (find_class): Use memoized_class_lookups and caching_stat.
9409 * jcf.h (JCF_USE_SCANDIR): Define.
9410 * parse.y (java_expand_classes): Write the class files in reverse
9411 order.
9412
9413 2002-05-16 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
9414
9415 * Make-lang.in: Allow for PWDCMD to override hardcoded pwd.
9416
9417 2002-05-13 Mark Mitchell <mark@codesourcery.com>
9418
9419 * jcf-write.c (write_classfile): Unlink the temporary file if it
9420 cannot be renamed. Use concat to build up the name of the
9421 temporary file.
9422
9423 2002-05-08 Mark Mitchell <mark@codesourcery.com>
9424
9425 * jcf-write.c (write_classfile): Write the file to a
9426 temporary file and then rename it.
9427
9428 2002-05-07 Tom Tromey <tromey@redhat.com>
9429
9430 * gjavah.c (throwable_p): Use xstrdup, not strdup.
9431
9432 Fix for PR java/1200:
9433 * gjavah.c (throwable_p): New function.
9434 (decode_signature_piece): Use it. A `WeakReference' isn't the
9435 same as a `jweak'.
9436 Include hashtab.h.
9437 (gcjh_streq): New function.
9438
9439 2002-05-07 Andreas Jaeger <aj@suse.de>
9440
9441 * parse.y (finish_for_loop): Fix if statement.
9442
9443 2002-05-06 Tom Tromey <tromey@redhat.com>
9444
9445 Fix for PR java/5941:
9446 * parse.y (finish_for_loop): Set SUPPRESS_UNREACHABLE_ERROR for
9447 loop update expression.
9448 (java_complete_lhs): Use SUPPRESS_UNREACHABLE_ERROR.
9449 * java-tree.h (SUPPRESS_UNREACHABLE_ERROR): New macro.
9450
9451 2002-05-04 Mark Wielaard <mark@klomp.org>
9452
9453 For PR java/6519:
9454 * parse.y (build_string_concatenation): Return just op1 only when op2
9455 is null and op1 is a STRING_CST, otherwise always construct a
9456 StringBuffer.
9457
9458 2002-04-27 Tom Tromey <tromey@redhat.com>
9459
9460 For PR java/6382:
9461 * parse.y (string_convert_int_cst): New function.
9462 (merge_string_cste): Use it.
9463
9464 2002-04-25 Neil Booth <neil@daikokuya.demon.co.uk>
9465
9466 * java-tree.h (java_parse_file): Update.
9467 (java_set_yydebug): Remove.
9468 * jcf-parse.c (yydebug): Remove.
9469 (java_set_yydebug): Die.
9470 (java_parse_file): Update.
9471 * lang.c (LANG_HOOKS_SET_YYDEBUG): Remove.
9472
9473 2002-04-24 Tom Tromey <tromey@redhat.com>
9474
9475 For PR java/6425:
9476 * parse.y (qualify_ambiguous_name) [case CALL_EXPR]: Always choose
9477 EXPR_WFL_QUALIFICATION of qual_wfl.
9478
9479 2002-04-23 Per Bothner <per@bothner.com>
9480
9481 * expr.c (PRE_JSR): Call NOTE_LABEL for return address.
9482 * java-tree.h (BCODE_RETURN_TARGET): Removed - never set.
9483 (BCODE_TARGET): Remove BCODE_RETURN_TARGET.
9484
9485 2002-04-23 Tom Tromey <tromey@redhat.com>
9486
9487 For PR java/6314:
9488 * jvspec.c (lang_specific_driver): Use --resource, not -R. Also
9489 recognize `-fcompile-resource='.
9490 * gcj.texi (Invoking gcj): Use --resource, not -R. Expanded text
9491 a bit.
9492
9493 2002-04-22 Alexandre Petit-Bianco <apbianco@redhat.com>
9494
9495 * jcf-parse.c: (yyparse): Don't prepend "./" to relative
9496 paths. Fixes PR java/2791.
9497
9498 2002-04-19 Andrew Haley <aph@redhat.com>
9499
9500 * jcf-write.c (push_long_const): lo, hi: New variables.
9501 Use rshift_double to extract the high part of a 64-bit long.
9502 Use WORD_TO_INT to extract the low part.
9503
9504 * jcf-parse.c (get_constant): CONSTANT_Integer: Use an unsigned
9505 HOST_WIDE_INT for num. Use JPOOL_UINT to get it.
9506 CONSTANT_Double: Use JPOOL_UINT to get both halve of a double.
9507
9508 2002-04-18 Neil Booth <neil@daikokuya.demon.co.uk>
9509
9510 * typeck.c (incomplete_type_error): Remove.
9511
9512 2002-04-18 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9513
9514 * class.c (make_class_data): Set DECL_ALIGN on static class data,
9515 for hash synchronization.
9516 * expr.c (java_expand_expr): Set DECL_ALIGN on static array objects.
9517 * decl.c (java_init_decl_processing): Don't set TYPE_ALIGN for
9518 class_type_node.
9519
9520 2002-04-16 Mark Wielaard <mark@klomp.org>
9521
9522 * jcf-write.c (generate_bytecode_insns): Only write const_0 if not
9523 negative zero.
9524
9525 2002-04-16 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9526
9527 Fix for PR java/6294:
9528 * parse.h (INNER_INTERFACE_MODIFIERS): Allow ACC_PRIVATE for inner
9529 interfaces.
9530
9531 2002-04-15 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9532
9533 Fix for PR java/6085:
9534 * parse.y (patch_method_invocation): Always use build_access_to_thisn
9535 to get enclosing "this" argument for inner-class constructor
9536 invocation. Pass correct arguments to build_access_to_thisn.
9537
9538 2002-04-10 Andreas Jaeger <aj@suse.de>
9539
9540 * gcj.texi (Input Options): Fix extdirs patch.
9541
9542 2002-04-10 Anthony Green <green@redhat.com>
9543
9544 * jcf-path.c (jcf_path_init) : Clean up local extdirs declaration.
9545
9546 2002-04-09 Anthony Green <green@redhat.com>
9547
9548 * gcj.texi (Input Options): Add --extdirs documentation.
9549 * jcf-dump.c (OPT_extdirs): New macro.
9550 (options): Add extdirs option.
9551 (help): Describe --extdirs.
9552 (main): Handle OPT_extdirs.
9553 * gjavah.c (OPT_extdirs): New macro.
9554 (options): Add extdirs option.
9555 (help): Describe --extdirs.
9556 (main): Handle OPT_extdirs.
9557 * jcf-path.c (jcf_path_init): Add extdirs support.
9558 (jcf_path_extdirs_arg): New function.
9559 (extensions): New variable to hold extensions path entries.
9560 * jvspec.c: Remove -fextdirs= when compiling main().
9561 * lang.c (java_decode_option): Handle -fextdirs=.
9562 * jcf.h (jcf_path_extdirs_arg): Declare new function.
9563 * Make-lang.in: Compile jcf-path with version info for use in
9564 identifying the appropriate libgcj.jar.
9565
9566 2002-04-08 Tom Tromey <tromey@redhat.com>
9567
9568 For PR libgcj/5303:
9569 * .cvsignore: Added rmic.1 and rmiregistry.1.
9570 * gcj.texi (Top): Link to new nodes.
9571 (Invoking rmic): New node.
9572 (Invoking rmiregistry): Likewise.
9573 * Make-lang.in (java.generated-manpages): Added rmic.1 and
9574 rmiregistry.1.
9575 (java.maintainer-clean): Likewise.
9576 ($(srcdir)/java/rmic.1): New target.
9577 ($(srcdir)/java/rmiregistry.1): Likewise.
9578 (java.install-man): Handle rmic.1 and rmiregistry.1.
9579
9580 2002-04-08 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9581
9582 * gcj.texi (Invocation): Update JvAttachCurrentThread documentation.
9583 Add note about handling uncaught exceptions. Add an exception handler
9584 to example.
9585
9586 2002-04-08 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9587
9588 * parse.y (resolve_qualified_expression_name): Clear "from_super" flag
9589 after using it to patch CALL_EXPR.
9590
9591 2002-04-08 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9592
9593 * gcj.texi (Invocation): Document CNI invocation API.
9594
9595 2002-04-04 Neil Booth <neil@daikokuya.demon.co.uk>
9596
9597 * expr.c (truthvalue_conversion): Rename. Update.
9598 (expand_compare): Update.
9599 * java-tree.h (java_truthvalue_conversion): New.
9600 * lang.c (LANG_HOOKS_TRUTHVALUE_CONVERSION): Redefine.
9601
9602 2002-04-01 Neil Booth <neil@daikokuya.demon.co.uk>
9603
9604 * java-tree.h (java_mark_addressable): New.
9605 * lang.c (LANG_HOOKS_MARK_ADDRESSABLE): Redefine.
9606 * typeck.c (mark_addressable): Rename, update.
9607
9608 2002-04-01 Neil Booth <neil@daikokuya.demon.co.uk>
9609
9610 * expr.c (build_java_binop): Update.
9611 * java-tree.h (java_signed_type, java_unsigned_type,
9612 java_signed_or_unsigned_type): Update.
9613 * lang.c (LANG_HOOKS_SIGNED_TYPE, LANG_HOOKS_UNSIGNED_TYPE,
9614 LANG_HOOKS_SIGNED_OR_UNSIGNED_TYPE): New.
9615 * parse.y (patch_binop): Update.
9616 * typeck.c (signed_or_unsigned_type, unsigned_type,
9617 signed_type): Update.
9618
9619 2002-03-31 Neil Booth <neil@daikokuya.demon.co.uk>
9620
9621 * lang.c (LANG_HOOKS_PRINT_ERROR_FUNCTION): Redefine.
9622 (java_dummy_print): Remove.
9623 (lang_print_error): Rename. Exit early if inhibiting output.
9624 (inhibit_error_printing_function): New.
9625 (java_init): Don't set hook.
9626 (lang_init_source): Use new boolean.
9627
9628 2002-03-29 Martin Kahlert <martin.kahlert@infineon.com>
9629
9630 * parse.y (do_resolve_class): Fix infinite recursion.
9631
9632 2002-03-29 Tom Tromey <tromey@redhat.com>
9633
9634 * parse.y (check_inner_circular_reference): Ignore incomplete
9635 types.
9636
9637 2002-03-29 Neil Booth <neil@daikokuya.demon.co.uk>
9638
9639 * Make-lang.in (builtins.o): Update.
9640 * boehm.c (get_boehm_type_descriptor): Update.
9641 * builtins.c: Include langhooks.h.
9642 * decl.c (java_init_decl_processing): Update.
9643 * java-tree.h (java_type_for_mode, java_type_for_size): New.
9644 * lang.c (LANG_HOOKS_TYPE_FOR_MODE, LANG_HOOKS_TYPE_FOR_SIaZE):
9645 Redefine.
9646 * typeck.c (type_for_mode, type_for_size): Update.
9647
9648 2002-03-29 Martin Kahlert <martin.kahlert@infineon.com>
9649
9650 * lex.c (java_new_lexer): Alias "646" to DEFAULT_ENCODING.
9651
9652 2002-03-28 Tom Tromey <tromey@redhat.com>
9653
9654 * except.c (expand_end_java_handler): If the handler type is NULL,
9655 use java.lang.Throwable. Fixes PR java/5986.
9656
9657 2002-03-28 Alexandre Petit-Bianco <apbianco@redhat.com>
9658
9659 Fix for PR java/4715:
9660 * jcf-parse.c (parse_source_file_3): New function.
9661 (read_class): Call it.
9662 (java_parse_file): Likewise.
9663
9664 2002-03-28 Jan Hubicka <jh@suse.cz>
9665
9666 * java/lang.c (java_init_options): Set flag_trapping_math to 0.
9667
9668 2002-03-28 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9669
9670 * parse.y (resolve_package): Initialize "decl".
9671 (lookup_package_type): Remove unused function.
9672
9673 2002-03-28 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9674
9675 Fix for PR java/5993:
9676 * parse.y (resolve_package): Return the decl if resolution was
9677 successful. Don't special case "java.lang" and "java.lang.reflect"
9678 packages. Set type_name to the merged identifier.
9679 (resolved_qualified_expression_name): Print error using "name" if
9680 resolve_package returns NULL_TREE.
9681
9682 2002-03-27 Tom Tromey <tromey@redhat.com>
9683
9684 * expr.c (expand_invoke): Don't generate null pointer check if
9685 we're calling <init>.
9686
9687 2002-03-27 Neil Booth <neil@daikokuya.demon.co.uk>
9688
9689 * expr.c (java_lang_expand_expr): Rename java_expand_expr,
9690 fix prototype.
9691 * java-tree.h (java_lang_expand_expr): Similarly.
9692 * lang.c (LANG_HOOKS_EXPAND_EXPR): Redefine.
9693 (java_init): Don't set hook.
9694
9695 2002-03-27 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9696
9697 Fix for PR java/5850:
9698 * parse.y (lookup_field_wrapper): Call itself recursively for enclosing
9699 context if field was not found in the current scope.
9700 * expr.c (lookup_field): Don't look in enclosing contexts.
9701
9702 2002-03-26 Tom Tromey <tromey@redhat.com>
9703
9704 Fix for PR java/5942:
9705 * parse.y (init_src_parse): Added sanity check.
9706 * parse.h (struct parser_ctxt) [modifier_ctx]: Array has 12
9707 elements, not 11.
9708
9709 2002-03-26 Neil Booth <neil@daikokuya.demon.co.uk>
9710
9711 * decl.c (lang_mark_tree): Rename java_mark_tree.
9712 * java-tree.h (java_mark_tree): New.
9713 * java-lang.c (LANG_HOOKS_MARK_TREE): Redefine.
9714
9715 2002-03-25 Zack Weinberg <zack@codesourcery.com>
9716
9717 * lex.c: Change java_perform_atof to take normal parameters
9718 instead of a pointer to a parameter block. Call it directly
9719 from java_lex.
9720
9721 2002-03-22 Mark Wielaard <mark@klomp.org>
9722
9723 Fix for PR java/5368:
9724 * parse.y (resolve_qualified_expression_name): Use decl not field_decl
9725 when printing error message.
9726
9727 2002-03-25 Neil Booth <neil@daikokuya.demon.co.uk>
9728
9729 * decl.c (maybe_build_cleanup): Remove.
9730
9731 2002-03-22 Tom Tromey <tromey@redhat.com>
9732
9733 Andrew Haley <aph@cambridge.redhat.com>
9734
9735 * expr.c (build_field_ref): Don't build a check if the field is a
9736 member of `this'.
9737
9738 2002-03-21 Eric Blake <ebb9@email.byu.edu>
9739
9740 Fix for PR java/6026:
9741 * lex.c (java_lex): Fix parsing of consecutive floats.
9742
9743 2002-03-21 Tom Tromey <tromey@redhat.com>
9744
9745 * parse.y (build_access_to_thisn): Stop when FROM is not an inner
9746 class.
9747
9748 2002-03-21 Neil Booth <neil@daikokuya.demon.co.uk>
9749
9750 * cp-tree.h (pushdecl, pushlevel, poplevel, set_block,
9751 insert_block, getdecls, kept_level_p, global_bindings_p): New.
9752
9753 2002-03-20 Nic Ferrier <nferrier@tapsellferrier.co.uk>
9754
9755 * gcj.texi: @code{gcj} becomes @command{gcj}.
9756 @code{gcc} becomes @command{gcc}.
9757 GcjRaw changed to gnu.gcc.RawData.
9758
9759 2002-03-20 Neil Booth <neil@daikokuya.demon.co.uk>
9760
9761 * decl.c (start_java_method): Use new hook.
9762 * lang.c (LANG_HOOKS_DECL_PRINTABLE_NAME): Redefine.
9763 (java_init): Remove old hook.
9764
9765 2002-03-18 Alexandre Petit-Bianco <apbianco@redhat.com>
9766
9767 * builtins.c (define_builtin): Do nothing if `type' is null.
9768 Fixes PR java/5876.
9769
9770 2002-03-18 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9771
9772 * parse.y (parser_check_super_interface): Fix error message
9773 grammar/order.
9774
9775 2002-03-17 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
9776
9777 * jcf-parse.c (get_constant): Delete unused variables.
9778
9779 2002-03-17 Neil Booth <neil@daikokuya.demon.co.uk>
9780
9781 * java-tree.h (java_parse_file): New.
9782 * jcf-parse.c (yyparse): Rename java_parse_file.
9783 * lang.c (LANG_HOOKS_PARSE_FILE): Redefine.
9784
9785 2002-03-16 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9786
9787 * parse.y (craft_constructor): Return the constructor decl.
9788 (java_expand_classes): Update comments.
9789 (lookup_method_invoke): Call fix_constructors immediately for
9790 anonymous class. Fixes PR java/5935.
9791
9792 2002-03-15 Anthony Green <green@redhat.com>
9793
9794 * jcf-parse.c (yyparse): Don't emit class registration
9795 constructor when compiling resource files.
9796
9797 2002-03-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
9798
9799 * lang.c (java_tree_code_type, java_tree_code_length,
9800 tree_code_name): Delete.
9801 (tree_code_type, tree_code_length, tree_code_name): Define.
9802 (java_init): Don't try to copy into the various tree_code
9803 arrays.
9804
9805 2002-03-12 Tom Tromey <tromey@redhat.com>
9806
9807 * jcf-parse.c (get_constant) [CONSTANT_String]: String values are
9808 UTF-8, not UCS-2. Fixes PR java/5923.
9809
9810 * parse.y (qualify_ambiguous_name): Handle case where QUAL_WFL is
9811 a call_expr wrapped in a convert. Fixes PR java/5848.
9812
9813 2002-03-12 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9814
9815 * jcf-write.c (write_classfile): Improve error strings.
9816
9817 2002-03-11 Eric Blake <ebb9@email.byu.edu>
9818
9819 * lex.c: Adjust comments to GNU standards.
9820
9821 2002-03-11 Eric Blake <ebb9@email.byu.edu>
9822
9823 Fix for PR java/5902:
9824 * lex.c (java_lex): Fix parsing of literals.
9825
9826 2002-03-11 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9827
9828 * parse.y (patch_assignment): Wrap the right-hand-side with a save_expr
9829 to prevent it getting evaluated twice in the store checking case.
9830 * expr.c (build_java_arraystore_check): Unwrap SAVE_EXPR's when
9831 examining OBJECT.
9832
9833 2002-03-09 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9834
9835 * decl.c (java_init_decl_processing): Make sure class_type_node
9836 alignment is not less than 64 bits if hash synchronization is enabled.
9837
9838 2002-03-08 Per Bothner <per@bothner.com>
9839
9840 * parse.y (java_complete_lhs): Check if patch_assignment
9841 returned an error-mark.
9842
9843 * parse.y (try_builtin_assignconv): Don't special-case zero.
9844
9845 2002-03-08 Per Bothner <per@bothner.com>
9846
9847 Fix for PR java/5812.
9848 * expr.c (build_java_jsr): Take pc arguments, and do lookup_label
9849 here instead of in JSR macro. Likewise with load_type_state call.
9850 Do the latter on if the return_pc has been verified (the jsr returns).
9851 (JSR): Now just call build_java_jsr.
9852
9853 2002-03-07 Jeff Sturm <jsturm@one-point.com>
9854
9855 * java/Make-lang.in (JAVA_TARGET_INSTALL_NAME): Define.
9856 (java.install-common): Link native driver to
9857 JAVA_TARGET_INSTALL_NAME.
9858
9859 2002-03-05 David Billinghurst <David.Billinghurst@riotinto.com>
9860
9861 * builtins.c(cos_builtin): method_return_type ATTRIBUTE_UNUSED
9862 * builtins.c(sin_builtin): Likewise
9863 * builtins.c(sqrt_builtin): Likewise
9864
9865 2002-03-03 Zack Weinberg <zack@codesourcery.com>
9866
9867 * java/expr.c, java/jcf-parse.c, java/lex.c:
9868 Remove all #ifndef REAL_ARITHMETIC blocks, make all #ifdef
9869 REAL_ARITHMETIC blocks unconditional. Delete some further
9870 #ifdef blocks predicated on REAL_ARITHMETIC.
9871
9872 2002-03-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
9873
9874 * class.c (init_class_processing): Use ARRAY_SIZE in lieu of
9875 explicit sizeof/sizeof.
9876 * decl.c (java_init_decl_processing): Likewise.
9877 * jcf-parse.c (init_jcf_parse): Likewise.
9878 * parse.y (init_src_parse): Likewise.
9879
9880 2002-03-02 Per Bothner <per@bothner.com>
9881
9882 Make --CLASSPATH by a synonym for --classpath and -classpath.
9883 Implement --bootclasspath.
9884 * jcf-path.c (classpath_u): Rename static variable to classpath_user.
9885 (classpath_l): Remove.
9886 (jcf_path_CLASSPATH_arg): Remove.
9887 (jcf_path_bootclasspath_arg): New function.
9888 (jcf_path_seal): Simplify accordingly.
9889
9890 * jcf.h (jcf_path_bootclasspath_arg): New declarations.
9891 (jcf_path_CLASSPATH): Remove declaration.
9892 * jvspec.c (jvgenmain_spec): Also accept -fbootclasspath*.
9893 (lang_specific_driver): Translate -bootclasspath.
9894 * lang-options.h: Add --bootclasspath. Update --CLASSPATH.
9895 * lang.c (decode_lang_options): Do jcf_path_init first.
9896 Handle -fCLASSPATH same as -fclasspath. Also process -fbootclasspath.
9897 * gjavah.c: Also handle --bootclasspath.
9898 Handle --CLASSPATH as a synonum for --classpath.
9899 * jcf-dump.c: Likewise.
9900
9901 "." is not part of system path, but is the default for --classpath.
9902 * jcf-path.c (jcf_path_init): Don't add "." to sys_dirs.
9903 (jcf_path_seal): Add "." if no CLASSPATH specified.
9904
9905 * gcj.texi: Document changes.
9906
9907 2002-03-01 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9908
9909 * expr.c (build_java_arraystore_check): Fix formatting.
9910
9911 2002-02-28 Alexandre Petit-Bianco <apbianco@redhat.com>
9912
9913 Fix for PR java/5758, java/5632:
9914 * jcf-parse.c (load_class): Renamed local variable, consider `.' an
9915 inner-class separator too.
9916 * parse.y (do_resolve_class): New local `decl_result.'
9917 Progressively build a name for what can have been loaded.
9918
9919 2002-02-28 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
9920
9921 * expr.c (java_array_data_offset): Removed function.
9922 (JAVA_ARRAY_LENGTH_OFFSET): Removed macro.
9923 (build_java_array_length_access): Obtain "length" value using a
9924 COMPONENT_REF, instead of INDIRECT_REF and arithmetic.
9925 (build_java_arrayaccess): Correct comment. Access "data" using a
9926 COMPONENT_REF, and return an ARRAY_REF instead of an INDIRECT_REF.
9927 (build_java_arraystore_check): New function.
9928 (expand_java_arraystore): Use build_java_arraystore_check.
9929 * parse.y (patch_assignment): Simplify code to insert a store check
9930 when lvalue is an ARRAY_REF. Use build_java_arraystore_check.
9931 * check-init.c (check_init): Update to reflect that an array length
9932 access is now a COMPONENT_REF.
9933 * gcj.texi (Code Generation): Improve documentation of
9934 -fno-bounds-check. Add documentation for -fno-store-check.
9935 * java-tree.h (flag_store_check): Declare.
9936 (build_java_arraystore_check): Declare.
9937 * lang.c (flag_store_check): Initialize to 1.
9938 (lang_f_options): Add store-check option.
9939 * jvspec.c: Don't pass store-check option to jvgenmain.
9940 * lang-options.h: Add help string for -fno-store-check.
9941
9942 2002-02-28 Neil Booth <neil@daikokuya.demon.co.uk>
9943
9944 * decl.c (copy_lang_decl): Rename java_dup_lang_specific_decl.
9945 * java-tree.h (java_dup_lang_specific_decl): New.
9946 * lang.c (LANG_HOOKS_DUP_LANG_SPECIFIC_DECL): Redefine.
9947
9948 2002-02-27 Zack Weinberg <zack@codesourcery.com>
9949
9950 * builtins.c, decl.c: Delete traditional-mode-related code
9951 copied from the C front end but not used, or used only to
9952 permit the compiler to link.
9953
9954 2002-02-22 Tom Tromey <tromey@redhat.com>
9955
9956 Fix for PR java/2369:
9957 * jvspec.c (verify_class_name): New function.
9958 (lang_specific_driver): Call it.
9959 (JAVA_START_CHAR_P): New macro.
9960 (JAVA_PART_CHAR_P): Likewise.
9961
9962 2002-02-22 Per Bothner <per@bothner.com>
9963
9964 * class.c: Change vtable to be more compatible with g++ v3 abi.
9965 (get_dispatch_table): Prepend offset-to-top (always 0) and
9966 type_info pointer (currently unimplemented hence NULL) to vtable.
9967 Specifically, prepend offset-to-top and typeinfo ptr (currently null).
9968 (make_class_data): Variable dtable_start_offset is sizeof 2 pointers.
9969 Adjust vtable pointers by dtable_start_offse - i.e. skip new words.
9970 (build_dtable_decl): Add declarations for new fields.
9971
9972 2002-02-20 Per Bothner <per@bothner.com>
9973
9974 * parse.y (patch_method_invocation): Set CAN_COMPLETE_NORMALLY on call
9975 to finit$ (otherwise generate_bytecode_insns drops it). However, we
9976 don't need to set it on the COMPOUND_EXPR - the caller does that.
9977
9978 2002-02-20 Nic Ferrier <nferrier@tapsellferrier.co.uk>
9979
9980 * gcj.texi: Option `--classpath' becomes `--CLASSPATH.'Option
9981 `--CLASSPATH' becomes `--classpath.'
9982 * gjavah.c: Likewise.
9983 * jcf-dump.c: Likewise.
9984 * lang-options.h: Likewise.
9985 * lang.c: Likewise.
9986 * jcf-path.c: Updated comment.
9987 (jcf_path_classpath_arg): Renamed `jcf_path_CLASSPATH_arg.'
9988 (jcf_path_CLASSPATH_arg): Renamed `jcf_path_classpath_arg.'
9989 * jcf.h (jcf_path_CLASSPATH_arg): Ditto.
9990 (jcf_path_CLASSPATH_arg): Ditto.
9991 (classpath_u): Updated leading comment.
9992
9993 2002-02-20 Per Bothner <per@bothner.com>
9994
9995 * builtins.c (check_for_builtin): New function.
9996 (build_call_or_builtin): Remove.
9997 * java-tree.h: Update accordingly.
9998 * expr.c (expand_invoke): Use build + check_for_builtin instead
9999 of build_call_or_builtin.
10000 * parse.y (patch_invoke): Likewise. This avoids needlessly creating
10001 a new CALL_EXPR node, which means we don't lose the CALL_USING_SUPER
10002 flag (which had caused jcf-write to incorrectly emit invokevirtual).
10003
10004 2002-02-17 Tom Tromey <tromey@redhat.com>
10005
10006 * java-tree.h (TYPE_STRICTFP): New macro.
10007 (struct lang_type) [strictfp]: New field.
10008 (CLASS_STRICTFP): New macro.
10009 (METHOD_STRICTFP): New macro.
10010 (struct lang_decl) [strictfp]: New field.
10011 * parse.y (method_header): Disallow strictfp constructor or
10012 abstract method.
10013 (STRICT_TK): Move before MODIFIER_TK.
10014 * parse.h (CLASS_MODIFIERS): Added ACC_STRICT.
10015 (METHOD_MODIFIERS): Likewise.
10016 (INTERFACE_MODIFIERS): Likewise.
10017 * jcf-write.c (get_access_flags): Likewise.
10018 * class.c (set_class_decl_access_flags): Recognize ACC_STRICT.
10019 (add_method_1): Likewise.
10020 (get_access_flags_from_decl): Likewise.
10021 * jcf-dump.c (print_access_flags): Print in standard order. Also,
10022 recognize strictfp flag.
10023 * jcf.h (ACC_STRICT): New define.
10024
10025 2002-02-12 David Billinghurst <Davod.Billinghurst@riotinto.com>
10026
10027 * class.c(build_utf8_ref): Move declaration of decl_size
10028
10029 2002-02-07 Tom Tromey <tromey@redhat.com>
10030
10031 * gcj.texi (Input Options): --CLASSPATH does not suppress system
10032 path.
10033
10034 2002-02-04 Anthony Green <green@redhat.com>
10035
10036 * class.c (build_utf8_ref): Put UTF-8 constants into merged
10037 sections if available.
10038
10039 2002-02-04 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10040
10041 * parse.y (java_expand_classes): Fix typo in static field loop.
10042
10043 2002-02-02 Richard Henderson <rth@redhat.com>
10044
10045 * class.c (add_field): Mark static fields external.
10046 (build_class_ref): Remove redundant set.
10047 * parse.y (java_expand_classes): Mark static fields of classes
10048 to be compiled as local.
10049 * jcf-parse.c (parse_class_file): Likewise.
10050
10051 2002-02-02 Nic Ferrier <nferrier@tapsellferrier.co.uk>
10052
10053 * gcj.texi (About CNI): New node.
10054
10055 2002-02-01 Craig Rodrigues <rodrigc@gcc.gnu.org>
10056
10057 PR java/5080
10058 * jcf-parse.c : Check for HAVE_LOCALE_H before using
10059 setlocale() with LC_CTYPE as a parameter.
10060 * jv-scan.c: Same.
10061
10062 2002-01-31 Joseph S. Myers <jsm28@cam.ac.uk>
10063
10064 * gjavah.c (version), jcf-dump.c (version), jv-scan.c (version):
10065 Follow GNU Coding Standards for --version.
10066
10067 2002-01-28 Tom Tromey <tromey@redhat.com>
10068
10069 * expr.c (build_jni_stub): Ensure storage for `meth' is
10070 generated.
10071 * parse.y (java_complete_expand_methods): Set
10072 current_function_decl before building JNI stub.
10073
10074 2002-01-26 Andreas Tobler <a.tobler@schweiz.ch>
10075
10076 * gcc/java/builtins.c (sqrt_builtin): Use BUILT_IN_SQRT, not
10077 BUILT_IN_SQRTF.
10078
10079 2002-01-22 Tom Tromey <tromey@redhat.com>
10080
10081 * decl.c (java_init_decl_processing): Use add_predefined_file.
10082 Predefine RawData.java.
10083 (predef_filenames): Removed.
10084 (java_init_decl_processing): Don't register predef_filenames.
10085 * jcf-parse.c (add_predefined_file): New function.
10086 (predefined_filename_p): Rewrote.
10087 (predefined_filename_p): No longer static.
10088 * decl.c (java_init_decl_processing): Call initialize_builtins.
10089 * Make-lang.in (JAVA_OBJS): Added builtins.o.
10090 (java/builtins.o): New target.
10091 * builtins.c: New file.
10092 * parse.y (patch_invoke): Use build_call_or_builtin.
10093 * java-tree.h (build_call_or_builtin): Declare.
10094 (initialize_builtins): Declare.
10095 (java_set_exception_lang_code): Removed unused declaration.
10096 (PREDEF_FILENAMES_SIZE): Removed.
10097 (java_tree_index): Added JTI_PREDEF_FILENAMES.
10098 (predef_filenames): New define.
10099 (add_predefined_file): Declare.
10100 (predefined_filename_p): Declare.
10101 * expr.c (expand_invoke): Use build_call_or_builtin.
10102
10103 2002-01-22 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10104
10105 * parse.y (patch_switch_statement): Fix format specifier.
10106
10107 2002-01-16 Tom Tromey <tromey@redhat.com>
10108
10109 More for PR java/5365:
10110 * gjavah.c (print_stub_or_jni): Cause exception to be thrown by
10111 default.
10112 (process_file): Generate include for
10113 java.lang.UnsupportedOperationExceptions.
10114
10115 2002-01-15 Andreas Jaeger <aj@suse.de>
10116
10117 * .cvsignore: Add man pages.
10118
10119 2002-01-15 Tom Tromey <tromey@redhat.com>
10120
10121 Fix for PR java/5365:
10122 * gjavah.c (process_file): Turn class name into a file name.
10123
10124 2002-01-14 Matthias Klose <doko@debian.org>
10125
10126 * gcj.texi: Fix whitespace and formatting errors in the
10127 synopsis of the man pages. Update copyright.
10128
10129 2002-01-14 Tom Tromey <tromey@redhat.com>
10130
10131 For PR libgcj/5303:
10132 * Make-lang.in (java.install-man): Handle jv-convert man page.
10133 (java.generated-manpages): Added jv-convert.1.
10134 (java.uninstall): Remove jv-convert.1.
10135 (java.maintainer-clean): Likewise.
10136 ($(srcdir)/java/jv-convert.1): New target.
10137 * gcj.texi (Top): Link to jv-convert node.
10138 (Individual utilities): Likewise.
10139 (Invoking jv-convert): New node.
10140
10141 2001-01-10 Jeff Sturm <jsturm@one-point.com>
10142 Martin Kahlert <martin.kahlert@infineon.com>
10143
10144 * jcf-parse.c (get_constant): Don't swap lo/hi for big
10145 endian targets when HOST_BITS_PER_WIDE_INT >= 64.
10146
10147 2002-01-03 Graham Stott <grahams@redhat.com>
10148
10149 * class.c (compile_resource_file): Update copyright date.
10150 Constify filename parameter.
10151 (java-tree.h): Update copyright date.
10152 (compile_resource_file): Constify filename parameter.
10153
10154 2002-01-03 Graham Stott <grahams@redhat.com>
10155
10156 * gcc/jcf-parse.c: Update copyright date.
10157 (yyparse): Constify resource_filename.
10158
10159 2002-01-02 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10160
10161 * parse.y (src_parse_roots): Don't needlessly zero init.
10162
10163 2001-12-31 Tom Tromey <tromey@redhat.com>
10164
10165 * parse.y (dump_java_tree): New function.
10166 (source_end_java_method): Call it.
10167 (end_class_declaration): Likewise.
10168 * lang.c (java_decode_option): Call dump_switch_p.
10169
10170 2001-12-28 Tom Tromey <tromey@redhat.com>
10171
10172 * gen-table.pl: Don't process characters after \uffff. Added
10173 comment pointing to input file.
10174
10175 2001-12-28 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10176
10177 * gen-table.pl: Const-ify output. Document the location of a
10178 suitable unicode input file.
10179
10180 * chartables.h: Regenerate.
10181
10182 2001-12-26 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10183
10184 * chartables.h: Const-ify.
10185 * gjavah.c (options): Likewise.
10186 * jcf-dump.c (options): Likewise.
10187 * jv-scan.c (options): Likewise.
10188 * lex.c (java_start_char_p, java_part_char_p): Likewise.
10189 * parse.y (binop_lookup): Likewise.
10190
10191 2001-12-23 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10192
10193 * Make-lang.in (keyword.h): Pass -C to gperf to const-ify
10194 the static arrays that are output.
10195 * jvspec.c (jvgenmain_spec): Make static.
10196 * keyword.gperf (struct java_keyword, java_keyword): Const-ify.
10197 * keyword.h: Regenerate.
10198 * lang.c (string_option, process_option_with_no, lang_f_options,
10199 lang_W_options): Const-ify.
10200 * lex.c (java_lex): Likewise.
10201
10202 2001-12-21 Richard Henderson <rth@redhat.com>
10203
10204 * boehm.c (PROCEDURE_OBJECT_DESCRIPTOR): Merge into ..
10205 (get_boehm_type_descriptor): ... here. Arrange for the
10206 TREE_TYPE to get set properly.
10207
10208 2001-12-21 Richard Henderson <rth@redhat.com>
10209
10210 * class.c (compile_resource_file): Set TREE_PUBLIC on the constructor
10211 only if the target requires collect2.
10212
10213 * class.c (build_class_ref): Mark _Jv_fooClass DECL_EXTERNAL.
10214
10215 2001-12-20 Tom Tromey <tromey@redhat.com>
10216
10217 For PR java/4509:
10218 * parse.y (java_complete_lhs) [COMPOUND_EXPR]: Correctly compute
10219 CAN_COMPLETE_NORMALLY for the node.
10220 * jcf-write.c (generate_bytecode_insns) [COMPOUND_EXPR]: Don't
10221 generate code for second branch if first branch can't complete
10222 normally.
10223 (generate_bytecode_insns) [LOOP_EXPR]: Don't generate `goto' to
10224 the loop head if the loop body can't complete normally.
10225
10226 2001-12-20 Tom Tromey <tromey@redhat.com>
10227
10228 For PR java/4766:
10229 * jcf-write.c (generate_bytecode_insns) [TRY_FINALLY_EXPR]: Handle
10230 case where `finally' clause can't complete normally.
10231
10232 2001-12-20 Tom Tromey <tromey@redhat.com>
10233
10234 Fixes PR java/5057:
10235 * parse.y (analyze_clinit_body): Added this_class parameter.
10236 Check for more cases where we must keep <clinit>.
10237 (maybe_yank_clinit): Cleaned up flow control.
10238
10239 2001-12-20 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10240
10241 * decl.c (java_init_decl_processing): Don't initialize
10242 finit_leg_identifier_node.
10243 * java-tree.h (java_tree_index): Remove JTI_FINIT_LEG_IDENTIFIER_NODE.
10244 (finit_leg_identifier_node): Remove.
10245 (ID_FINIT_P): Don't check for JTI_FINIT_LEG_IDENTIFIER_NODE.
10246
10247 2001-12-20 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10248
10249 * mangle.c (mangle_member_name): Don't special-case for
10250 NO_DOLLAR_IN_LABEL.
10251 * mangle_name.c (unicode_mangling_length): Likewise.
10252 (append_unicode_mangled_name): Likewise.
10253 * parse.y (make_nested_class_name): Remove dead NO_DOLLAR_IN_LABEL
10254 code.
10255
10256 2001-12-20 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10257
10258 * expr.c (build_java_array_length_access): Don't force null pointer
10259 check unless flag_check_references is set.
10260
10261 2001-12-20 Tom Tromey <tromey@redhat.com>
10262
10263 Fix for PR java/3417:
10264 * parse.y (patch_assignment): Added special processing for
10265 `return'.
10266 (patch_return): Don't convert booleans to integers, and don't
10267 special-case `null'.
10268
10269 2001-12-20 Joseph S. Myers <jsm28@cam.ac.uk>
10270
10271 * config-lang.in (diff_excludes): Remove.
10272
10273 2001-12-17 Joseph S. Myers <jsm28@cam.ac.uk>
10274
10275 * gcj.texi: Update link to GCC manual.
10276
10277 2001-12-17 Tom Tromey <tromey@redhat.com>
10278
10279 * parse.y (link_nested_class_to_enclosing): Removed useless
10280 statement.
10281
10282 2001-12-16 Tom Tromey <tromey@redhat.com>
10283
10284 * mangle.c (mangle_method_decl): Never emit `C2' constructor.
10285 Fixes PR java/5088.
10286
10287 2001-12-16 Joseph S. Myers <jsm28@cam.ac.uk>
10288
10289 * ChangeLog, Make-lang.in, class.c, expr.c, gcj.texi, java-tree.h,
10290 jcf-parse.c, jcf-write.c, lex.c, parse.h, parse.y, verify.c: Fix
10291 spelling errors.
10292
10293 2001-12-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10294
10295 * lex.c (java_read_unicode, java_lex): Use hex_p/hex_value.
10296
10297 2001-12-16 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10298
10299 * decl.c (java_init_decl_processing): Build otable_type correctly.
10300 otable_decl is an otable_type.
10301
10302 2001-12-15 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10303
10304 * java-tree.h (otable_methods, otable_decl, otable_syms_decl,
10305 otable_type, otable_ptr_type, method_symbol_type,
10306 method_symbols_array_type, method_symbols_array_ptr_type): New
10307 field/global tree definitions.
10308 (flag_indirect_dispatch): New flag.
10309 * decl.c (java_init_decl_processing): Initialize new otable and
10310 otable_syms type nodes and decls. Add new field "index" to
10311 method_type_node.
10312 * class.c (build_method_symbols_entry): New function.
10313 (make_method_value): Set "index" to to method's vtable index for
10314 virtual methods when indirect-dispatch is not used.
10315 (make_class_data): For indirect-dispatch, don't emit the dtable_decl,
10316 and set vtable_method_count to -1. Set otable and otable_syms field
10317 if indirect-dispatch is used and there was something to put in them.
10318 (build_method_symbols_entry): New function.
10319 (emit_offset_symbol_table): New function.
10320 * expr.c (get_offset_table_index): New function.
10321 (build_invokevirtual): Build array reference to otable at the index
10322 returned by get_offset_table_index, and use the result as the vtable
10323 offset.
10324 (build_invokeinterface): Similar.
10325 * jcf-parse.c (yyparse): If indirect-dispatch, call
10326 emit_offset_symbol_table at the end of compilation, after all classes
10327 have been generated.
10328 * jvspec.c: Don't pass findirect-dispatch to jvgenmain.
10329 * lang.c (flag_indirect_dispatch): Define.
10330 (lang_f_options): Add indirect-dispatch flag.
10331
10332 2001-12-14 Matthias Klose <doko@debian.org>
10333
10334 * gcj.texi: Markup for man page generation. Document missing
10335 options printed by <tool> --help.
10336 Terminate description of gij's -ms option with a dot.
10337 * Make-lang.in ($(srcdir)/java/*.1): New targets.
10338 (java.generated-manpages java.install-man, java.uninstall,
10339 java-maintainer-clean) Updated.
10340
10341 2001-12-14 Hans Boehm <Hans_Boehm@hp.com>
10342
10343 * class.c (get_dispatch_table): Fix java vtable layout
10344 for TARGET_VTABLE_USES_DESCRIPTORS.
10345 * decl.c (java_init_decl_processing): Initialize
10346 alloc_no_finalizer_node, finalize_identifier_node.
10347 * expr.c (class_has_finalize_method): New function.
10348 (expand_java_NEW): Generate calls for finalizer-free allocation.
10349 (build_invokevirtual): Fix java vtable layout for
10350 TARGET_VTABLE_USES_DESCRIPTORS.
10351 * java-tree.h (enum java_tree_index): New entries:
10352 JTI_ALLOC_NO_FINALIZER_NODE, JTI_FINALIZE_IDENTIFIER_NODE.
10353 (alloc_no_finalizer_node, finalize_deintifier_node): New macros.
10354 (class_has_finalize_method): declare.
10355 (HAS_FINALIZER_P): New macro.
10356 * parse.y (patch_invoke): Generate calls for finalizer-free
10357 allocation.
10358
10359 2001-12-12 Matthias Klose <doko@debian.org>
10360
10361 * Make-lang.in: JAVA_INSTALL_NAME, JAVA_CROSS_NAME: Remove
10362 whitespace at end of line.
10363
10364 2001-12-11 Tom Tromey <tromey@redhat.com>
10365
10366 * lex.c (java_init_lex): Define wfl_to_string as
10367 gnu.gcj.runtime.StringBuffer unless generating bytecode.
10368
10369 2001-12-11 Jeff Sturm <jsturm@one-point.com>
10370
10371 * class.c (make_method_value): Use null_pointer_node to
10372 represent empty exception table.
10373
10374 2001-12-10 Tom Tromey <tromey@redhat.com>
10375
10376 * check-init.c (check_init) [SWITCH_EXPR]: Use SWITCH_HAS_DEFAULT.
10377
10378 2001-12-10 Douglas B. Rupp <rupp@gnat.com>
10379
10380 * Make-lang.in (jvspec.o): Add $(OUTPUT_OPTION).
10381
10382 2001-12-09 Per Bothner <per@bothner.com>
10383
10384 * check-init.c (current_switch_has_default): New static field.
10385 (check_init): Case DEFAULT_EXPR: Set current_switch_has_default.
10386 Case SWITCH_EXPR: Save/restore current_switch_has_default. If no
10387 DEFAULT_EXPR seen, simulate a default alternative that copies state.
10388
10389 2001-12-09 Tom Tromey <tromey@redhat.com>
10390
10391 * check-init.c (check_init): Don't allow pre- or post- increment
10392 or decrement of final variable.
10393 (final_assign_error): Minor error message rewording.
10394
10395 2001-12-08 Tom Tromey <tromey@redhat.com>
10396
10397 * java-tree.h: Fixed typo.
10398
10399 * gjavah.c (decompile_method): Don't decompile to `return this'
10400 for static methods.
10401
10402 * gjavah.c (cxx_keywords): Re-sorted.
10403 * lex.c (cxx_keywords): Re-sorted.
10404
10405 * gjavah.c (HANDLE_METHOD): Set `decompiled' before doing anything
10406 else.
10407
10408 * gjavah.c (print_namelet): Clear subnamelets.
10409 (HANDLE_METHOD): Set `method_printed' earlier.
10410
10411 2001-12-07 Tom Tromey <tromey@redhat.com>
10412
10413 * lang.c (lang_f_options): Added
10414 optimize-static-class-initialization.
10415 (java_decode_option): Removed special case.
10416
10417 2001-12-07 Per Bothner <per@bothner.com>
10418
10419 * check-init.c (check_init): Fix typo freeing memory twice.
10420
10421 2001-12-05 Per Bothner <per@bothner.com>
10422
10423 Restore support for static class initialization optimization.
10424 * java-tree.h (STATIC_CLASS_INIT_OPT_P): Re-enable.
10425 * check-init.c (check_int): At end of BLOCK handle initialization
10426 blocks, which used to be done in java_complete_expand_method but did
10427 not handle the case where check_for_initialization might allocate
10428 more than a word of bits.
10429 * decl.c (lang_make_tree): The smic field is now a tree.
10430 * expr.c (build_class_init): Set DECL_FUNCTION_INIT_TEST_CLASS field.
10431 * java-tree.h (DECL_FUNCTION_INIT_TEST_TABLE): New macro.
10432
10433 * parse.y (emit_test_initialization): Combine hash_lookup calls.
10434
10435 * java-tree.h (DECL_FUNCTION_STATIC_METHOD_INVOCATION_COMPOUND):
10436 Change from a hash table to a list.
10437 (struct_lang_decl): Change field 'smic' to match.
10438 * class.c (add_method_1): Initialize
10439 DECL_FUNCTION_STATIC_METHOD_INVOCATION_COMPOUND to null list.
10440 * parse.y (adjust_init_test_initialization): Removed - inlined into -
10441 (java_expand_method_bodies): -here, since 'smic' is now a list.
10442 (patch_invoke): Add to 'smic' list, instead of hash_lookup.
10443
10444 * check-init.c (WORD_SIZE): Use BITS_PER_UNIT.
10445
10446 * class.c (java_hash_compare_tree_node): Fix casts.
10447
10448 2001-12-04 Per Bothner <per@bothner.com>
10449
10450 * check-init.c: Handle definite unassignment to finals in addition
10451 to definite assignment.
10452 (loop_current_locals): New field.
10453 (num_current_locals, int start_current_locals, num_current_words):
10454 Make static.
10455 (SET_P, CLEAR_P, SET_BIT): Add needed but missing parentheses.
10456 (ASSIGNED_P, UNASSIGNED_P, SET_ASSIGNED, SET_UNASSIGNED,
10457 CLEAR_ASSIGNED, CLEAR_UNASSIGNED): New macros.
10458 (get_variable_decl, check_final_reassigned): New functions.
10459 (check_init, check_bool_init): Modify as needed for checking finals.
10460 (check_for_initialization): Take extra parameter and return void.
10461 Do extra start-up logic to check final fields for assignment.
10462 * parse.y (check_static_final_variable_assignment_flag,
10463 reset_static_final_variable_assignment_flag, check_final_assignment,
10464 check_final_variable_local_assignment_flag,
10465 reset_final_variable_indirect_assignment_flag,
10466 reset_final_variable_global_assignment_flag): Remove functions.
10467 (java_complete_expand_methods, outer_field_access_fix,
10468 patch_assignment): Remove no-longer used logic.
10469 * java-tree.h (DECL_FIELD_FINAL_IUD): Change usage and comments.
10470 * parse.y (register_fields, java_complete_tree): Update accordingly.
10471
10472 * check-init.c (ALLOC_WORDS/FREE_WORDS): Use xmalloc/free, not alloca.
10473 (DECLARE_BUFFERS, RELEASE_BUFFERS, ALLOC_BUFFER, FREE_BUFFER): New.
10474 (check_cond_init, check_bool2_init): Use DECLARE_BUFFERS.
10475
10476 * java-tree.h (STATIC_CLASS_INIT_OPT_P): Temporarily turn off.
10477
10478 * java-tree.h (DECL FINAL): New bit-field.
10479 (METHOD_FINAL, FIELD_FINAL, CLASS_FINAL): Define as DECL_FINAL.
10480 (LOCAL_FINAL_P): Use DECL_FINAL rather than old LOCAL_FINAL.
10481 (DECL_INIT_CALLS_THIS): New macro.
10482 (struct lang_decl): New bit-field init_calls_this.
10483 (DECL_FUNCTION_ALL_FINAL_INITIALIZED, DECL_FIELD_FINAL_LIIC,
10484 DECL_FIELD_FINAL_IERR, LOCAL_FINAL, TYPE_HAS_FINAL_VARIABLE
10485 (DECL_BIT_INDEX): Change to use pointer_alias_set since we now
10486 use it for both local variables and final fields.
10487 (struct lang_decl_var): Remove bit-fields final_liic, final_ierr,
10488 and local_final.
10489 (struct lang_type): Remove hfv bit-field.
10490 (check_for_initialization): Change to return void.
10491
10492 * java-tree.h (IS_ARRAY_LENGTH_ACCESS): New macros.
10493 * expr.c (build_java_array_length_access): Set IS_ARRAY_LENGTH_ACCESS.
10494 * check-init.c (final_assign_error): New helper function.
10495 (check_final_reassigned, check_init): Use it.
10496 (check_init): Also check IS_ARRAY_LENGTH_ACCESS for ARRAY.length.
10497
10498 * java-tree.h (struct lang_decl, struct lang_decl_var): Change all
10499 bit-fields to unsigned.
10500
10501 2001-12-03 Per Bothner <per@bothner.com>
10502
10503 * parse.y (patch_binop): Minor constant folding.
10504
10505 * parse.y (build_current_thisn): Shorter 'buffer'.
10506
10507 2001-12-03 Per Bothner <per@bothner.com>
10508
10509 * decl.c (complete_start_java_method): Now generate TRY_FINALLY_EXPR
10510 instead of CLEANUP_POINT_EXPR and WITH_CLEANUP_EXPR.
10511 * jcf-write.c (generate_bytecode_insns): Remove support for
10512 CLEANUP_POINT_EXPR and WITH_CLEANUP_EXPR as they are no longer used.
10513 * check-init.c (check_init): Likewise.
10514
10515 2001-12-03 Per Bothner <per@bothner.com>
10516
10517 * verify.c (subroutine_nesting): New function.
10518 (verify_jvm_instructions): Use it to fix logic for checking that
10519 we're done with the current subroutine.
10520
10521 * verify.c (verify_jvm_instruction): For OPCODE_checkcast and
10522 OPCODE_instanceof use POP_TYPE macro for better diagnostics.
10523
10524 2001-12-03 Per Bothner <per@bothner.com>
10525
10526 * jcf.h: Fix obvious typo in comment.
10527 * typeck.c (build_null_signature): Add comment.
10528
10529 2001-12-03 Neil Booth <neil@daikokuya.demon.co.uk>
10530
10531 * expr.c: Remove leading capital from diagnostic messages, as
10532 per GNU coding standards.
10533 * jcf-io.c: Similarly.
10534 * jcf-parse.c: Similarly.
10535 * jv-scan.c: Similarly.
10536 * jvspec.c: Similarly.
10537 * mangle.c: Similarly.
10538
10539 2001-12-02 Tang Ching-Hui <nicholas@cs.nthu.edu.tw>
10540 Alexandre Petit-Bianco <apbianco@redhat.com>
10541
10542 * expr.c (build_java_arrayaccess): Call save_expr on array for
10543 correct evaluation order, modified comment, fixed indentation.
10544 * parse.y: (patch_assignment): Correctly extract the array base
10545 from the tree generate by build_java_arrayaccess, added comments.
10546 (patch_array_ref): Remove SAVE_EXPR on ARRAY_REF.
10547 Fixes PR java/3096, PR java/3803, PR java/3965.
10548
10549 2001-12-01 Neil Booth <neil@daikokuya.demon.co.uk>
10550
10551 * expr.c (expand_byte_code): Remove trailing periods from messages.
10552 * jcf-parse.c (load_class, jcf_parse): Similarly.
10553 * jcf-write.c (generate_classfile): Similarly.
10554 * lex.c (java_lex): Similarly.
10555
10556 2001-11-30 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10557
10558 * class.c (add_interface_do): Set BINFO_VPTR_FIELD.
10559
10560 2001-11-29 Joseph S. Myers <jsm28@cam.ac.uk>
10561
10562 * Make-lang.in (java.generated-manpages): New dummy target.
10563
10564 2001-11-27 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
10565
10566 * jvspec.c (jvgenmain_spec): Cannot use %umain, breaks
10567 ASM_FINAL_SPEC.
10568 (lang_specific_pre_link): Use set_input to set input_filename.
10569 Append `main' here.
10570 * jvgenmain.c (usage): Append literal `main' to CLASSNAME.
10571 (main): Fix definition.
10572 Strip `main' from classname.
10573 Fixes PR java/227.
10574
10575 2001-11-18 Roger Sayle <roger@eyesopen.com>
10576
10577 * parse.h (java_expand_switch): Remove old prototype.
10578
10579 2001-11-18 Tom Tromey <tromey@redhat.com>
10580
10581 Fix for PR java/1401:
10582 * jcf-write.c (generate_bytecode_insns) [binop]: Handle case where
10583 arg0 is null.
10584 (generate_bytecode_insns) [MODIFY_EXPR]: Handle `OP=' case
10585 correctly.
10586
10587 2001-11-18 Neil Booth <neil@daikokuya.demon.co.uk>
10588
10589 * lang.c (finish_parse): Rename to java_finish.
10590 (LANG_HOOKS_FINISH, java_finish): New.
10591
10592 2001-11-15 Neil Booth <neil@daikokuya.demon.co.uk>
10593
10594 * decl.c (init_decl_processing): Rename java_init_decl_processing.
10595 * java-tree.h: New prototype.
10596 * lang.c (java_init): Update prototype. Combine with old init_parse.
10597
10598 2001-11-13 Tom Tromey <tromey@redhat.com>
10599
10600 * gjavah.c (method_signature): New global.
10601 (HANDLE_METHOD): Set it.
10602 (decompile_return_statement): New function.
10603 (decompile_method): Use it.
10604 (print_method_info): Removed `synth' argument.
10605
10606 2001-11-09 Neil Booth <neil@daikokuya.demon.co.uk>
10607
10608 * java-tree.h (java_set_yydebug): New.
10609 * jcf-parse.c (set_yydebug): Rename java_set_yydebug.
10610 * lang.c (LANG_HOOKS_SET_YYDEBUG): Override.
10611 (print_lang_decl, print_lang_type, print_lang_identifier,
10612 print_lang_statistics, lang_print_xnode): Remove.
10613
10614 2001-11-09 Neil Booth <neil@daikokuya.demon.co.uk>
10615
10616 * jcf-parse.c (init_lex): Remove.
10617 * lang.c (language_string, lang_identify): Remove.
10618 (struct lang_hooks): Constify.
10619 (LANG_HOOKS_NAME): Override.
10620 (init_parse): Update.
10621
10622 2001-11-08 Andreas Franck <afranck@gmx.de>
10623
10624 * Make-lang.in (JAVA_INSTALL_NAME, JAVA_CROSS_NAME): Handle
10625 program_transform_name the way suggested by autoconf.
10626 (java.install-common): Also transform auxiliary program names with
10627 program_transform_name.
10628
10629 2001-11-08 Tom Tromey <tromey@cygnus.com>
10630
10631 * parse.y (trap_overflow_corner_case): New rule.
10632 (unary_expression): Use it.
10633 * lex.c (java_init_lex): Don't set minus_seen.
10634 (yylex): Don't use minus_seen. Communicate overflow to parser for
10635 it to handle.
10636 (error_if_numeric_overflow): New function.
10637 * parse.h (minus_seen): Removed field.
10638 (JAVA_RADIX10_FLAG): New define.
10639
10640 2001-11-07 Tom Tromey <tromey@redhat.com>
10641
10642 Patch for PR java/1414:
10643 * parse.y (case_label_list): New global.
10644 (goal): Register case_label_list with GC.
10645 (java_complete_lhs): Save new case on case_label_list.
10646 (patch_switch_statement): Check for duplicate case labels.
10647
10648 2001-11-07 Alexandre Petit-Bianco <apbianco@redhat.com>
10649
10650 * parse.y (patch_assignment): Removed unused third argument.
10651 (java_complete_lhs): Removed unused third argument to patch_assignment.
10652
10653 2001-11-06 Neil Booth <neil@cat.daikokuya.demon.co.uk>
10654
10655 * lang.c: Include langhooks-def.h.
10656 * Make-lang.in: Update.
10657
10658 2001-10-31 Zack Weinberg <zack@codesourcery.com>
10659
10660 * Make-lang.in: Replace $(INTL_TARGETS) with po-generated.
10661
10662 2001-10-29 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10663
10664 * mangle.c (find_compression_record_match): Don't match compression
10665 records for package name elements unless they occur at the start of
10666 the name. Fix for PR java/4717.
10667
10668 2001-10-25 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10669
10670 * expr.c (expand_java_field_op): Don't special-case references to
10671 java.lang.PRIMTYPE.TYPE.
10672 (build_primtype_type_ref): Removed.
10673 * java-tree.h (build_primtype_type_ref): Remove prototype.
10674 * parse.y (maybe_build_primttype_type_ref): Removed.
10675 (complete_function_arguments): Don't special-case references to
10676 java.lang.PRIMTYPE.TYPE.
10677 (patch_assignment): Likewise.
10678 (array_constructor_check_entry): Likewise.
10679
10680 2001-10-24 Alexandre Petit-Bianco <apbianco@redhat.com>
10681
10682 * mangle.c (static tree compression_table): Fixed leading comment.
10683 * parse.h (struct parser_ctxt): Fixed field comment.
10684 * parse.y (check_pkg_class_access): New prototype, fixed leading
10685 comment, new parameter used to emit error only if passed as true.
10686 (parse_check_super): Pass extra argument to check_pkg_class_access.
10687 (do_resolve_class): Likewise.
10688 (process_imports): Likewise.
10689 (read_import_dir): Fixed indentation.
10690 (find_in_imports_on_demand): New local class_type_name. Local
10691 node_to_use deleted. while loop changed into for loop. Report
10692 multiple definition only for accessible classes. Improved error
10693 message.
10694 (start_complete_expand_method): Local `ptr' removed. DECL_ARGUMENTS
10695 assigned to parameter list, fixed indentation. while loop changed
10696 into for loop, restore TREE_CHAIN on local `tem' before the next
10697 iteration.
10698
10699 2001-10-23 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
10700
10701 * lang.c (lang_get_alias_set): Deleted.
10702
10703 2001-10-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10704
10705 * gjavah.c (jni_print_char): Fix thinko in last change.
10706
10707 * gjavah.c (jni_print_char, decode_signature_piece): Use
10708 safe-ctype macros and/or fold extra calls into fewer ones.
10709 * lex.c (java_read_unicode, java_lex): Likewise.
10710 * lex.h (JAVA_START_CHAR_P, JAVA_PART_CHAR_P, JAVA_ASCII_DIGIT,
10711 JAVA_ASCII_HEXDIGIT, JAVA_ASCII_LETTER): Likewise.
10712 * mangle_name.c (append_unicode_mangled_name,
10713 unicode_mangling_length): Likewise.
10714
10715 2001-10-17 Richard Henderson <rth@redhat.com>
10716
10717 * Make-lang.in (java/lang.o): Depend on langhooks.h.
10718
10719 2001-10-15 Alexandre Petit-Bianco <apbianco@redhat.com>
10720
10721 * lang.c (langhooks.h): Included.
10722 (LANG_HOOKS_INIT): Redefined.
10723 (LANG_HOOKS_INIT_OPTIONS): Likewise.
10724 (LANG_HOOKS_DECODE_OPTION): Likewise.
10725 (struct lang_hooks lang_hooks): New initialization.
10726
10727 2001-10-11 Per Bothner <per@bothner.com>
10728
10729 * parse.y (patch_synchronized_statement): Use a TRY_FINALLY_EXPR
10730 rather than a CLEANUP_POINT_EXPR/WITH_CLEANUP_EXPR pair.
10731 The former is simpler, and jcf-write.c handles it better.
10732 (java_complete_lhs): No longer need to handle CLEANUP_POINT_EXPR
10733 or WITH_CLEANUP_EXPR.
10734 * jcf-write.c: Revert Alex's change from 2000-10-18. It is no
10735 longer needed, as we already handle empty TRY_FINALLY_EXPR bodies fine.
10736
10737 * parse.y (patch_if_else_statement): If the condition is constant,
10738 optimize away the test.
10739
10740 2001-10-09 Alexandre Petit-Bianco <apbianco@redhat.com>
10741
10742 * parse.y (patch_cast): Call patch_string on the first operand of
10743 the incoming node, update it if necessary. Fixes PR java/4510.
10744
10745 2001-10-09 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
10746
10747 * parse.y (find_as_inner_class): Don't disregard the enclosing scope
10748 when name qualifier matches a package name.
10749
10750 2001-10-08 Tom Tromey <tromey@redhat.com>
10751
10752 Fix for PR java/4489:
10753 * jcf-write.c (generate_bytecode_insns) [SWITCH_EXPR]: Always
10754 force a new label when computing `body_block'.
10755
10756 2001-10-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10757
10758 * jcf-io.c (format_uint): Const-ify.
10759 * lang.c (java_tree_code_type, java_tree_code_length): Likewise.
10760 * lex.c (java_get_line_col): Likewise.
10761 * parse.y (build_incdec): Likewise.
10762
10763 2001-10-05 Alexandre Petit-Bianco <apbianco@redhat.com>
10764
10765 * parse.y (register_incomplete_type): Set JDEP_SUPER to be given
10766 a NULL enclosing context if appropriate. Fixes PR java/4466.
10767
10768 2001-10-03 Alexandre Petit-Bianco <apbianco@redhat.com>
10769
10770 * parse.y (patch_assignment): Use lvalue's original TYPE when
10771 building the final COMPOUND_EXPR.
10772 (try_reference_assignconv): Fixed leading comment.
10773
10774 2001-09-26 Alexandre Petit-Bianco <apbianco@redhat.com>
10775
10776 * parse.y (check_final_variable_indirect_assignment): For
10777 COMPOUND_EXPR, return only if finals were found initialized
10778 properly, if not, keep on checking.
10779 (check_final_variable_global_assignment_flag): New local
10780 error_found, set when appropriate and used to decide whether to
10781 report uninitialized finals. Fixed typo in comment.
10782
10783 2001-09-22 Alexandre Petit-Bianco <apbianco@redhat.com>
10784
10785 * decl.c (init_decl_processing): Fixed typo in predef_filenames
10786 last three initializations. Fixes PR java/4360.
10787
10788 2001-09-21 Richard Henderson <rth@redhat.com>
10789
10790 * class.c (get_dispatch_table): Handle function descriptors.
10791 (build_dtable_decl): Likewise.
10792 * expr.c (build_invokevirtual): Likewise.
10793
10794 2001-09-20 Alexandre Petit-Bianco <apbianco@redhat.com>
10795
10796 * parse.y (patch_method_invocation): Build class initialization
10797 when static finals are used to qualify method invocation.
10798 Fixes PR java/4366.
10799
10800 2001-09-19 Alexandre Petit-Bianco <apbianco@redhat.com>
10801
10802 * parse.h: (WFL_STRIP_BRACKET): Re-written using
10803 build_type_name_from_array_name.
10804 (STRING_STRIP_BRACKETS): New macro.
10805 * parse.y (build_type_name_from_array_name): New function.
10806 (array_creation_expression:): Accumulate []s instead of [s.
10807 (cast_expression:): Accumulate []s instead of [s after cast type
10808 name.
10809 (build_array_from_name): Local string deleted, use
10810 build_type_name_from_array_name.
10811 (build_unresolved_array_type): Accumulate []s instead of [s after
10812 type name.
10813 (register_fields): Fixed comment.
10814 (resolve_class): Local name, base deleted, new locals tname and
10815 array_dims. Use build_type_name_from_array_name. Use array_dims to
10816 build array type.
10817 (purify_type_name): Use STRING_STRIP_BRACKETS.
10818
10819 2001-09-18 Andreas Jaeger <aj@suse.de>
10820
10821 * parse.y: Use VA_OPEN/VA_CLOSE/VA_FIXEDARG throughout.
10822 * jv-scan.c: Likewise.
10823
10824 2001-09-17 Alexandre Petit-Bianco <apbianco@redhat.com>
10825
10826 * parse.y (patch_method_invocation): Inner class creation context
10827 check not enforced within constructors. Fixes PR java/1873.
10828
10829 2001-09-16 Tom Tromey <tromey@redhat.com>
10830
10831 * jcf-write.c (generate_bytecode_insns) [SWITCH_EXPR]: Call
10832 NOTE_PUSH for single-case push. Fixes PR java/4189.
10833
10834 2001-09-13 Alexandre Petit-Bianco <apbianco@redhat.com>
10835
10836 * java-tree.h (TYPE_IMPORT_LIST): New macro.
10837 (TYPE_IMPORT_DEMAND_LIST): Likewise.
10838 (struct lang_type): New fields import_list and import_demand_list.
10839 * parse.y (java_complete_class): Initialize TYPE_IMPORT_LIST and
10840 TYPE_IMPORT_DEMAND_LIST with ctxp counterparts.
10841 (do_resolve_class): New local saved_enclosing_type, initialized,
10842 passed as parameter to find_in_imports and find_in_imports_on_demand.
10843 (find_in_imports): Added paramater enclosing_type, use its
10844 TYPE_IMPORT_LIST when applicable.
10845 (find_in_imports_on_demand): Added parameter enclosing_type, use
10846 its TYPE_IMPORT_DEMAND_LIST when applicable. Reorganized locals
10847 declaration and initialization.
10848 (fold_constant_for_init): Switch/restore current_class to the
10849 appropriate context.
10850
10851 2001-09-13 Mark Mitchell <mark@codesourcery.com>
10852
10853 * verify.c (verify_jvm_instructions): Fix typo.
10854
10855 2001-09-13 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10856
10857 * expr.c (expand_invoke): Const-ification.
10858 * parse.y (patch_method_invocation): Likewise.
10859
10860 2001-09-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10861
10862 * gjavah.c (cxx_keywords): Const-ification.
10863 * keyword.gperf (java_keyword): Likewise.
10864 * lang.c (java_tree_code_name): Likewise.
10865 * lex.c (cxx_keywords): Likewise.
10866 * parse.y (java_parser_context_suspend, merge_string_cste): Likewise.
10867
10868 2001-09-11 Richard Henderson <rth@redhat.com>
10869
10870 * parse.h (ctxp_for_generation): Mark extern.
10871
10872 2001-09-10 Richard Henderson <rth@redhat.com>
10873
10874 * class.c (build_class_ref): Set DECL_EXTERNAL before make_decl_rtl.
10875
10876 2001-09-07 Matt Kraai <kraai@alumni.carnegiemellon.edu>
10877
10878 * typeck.c (java_array_type_length, build_prim_array_type):
10879 Represent empty arrays by NULL index.
10880
10881 2001-09-06 Alexandre Petit-Bianco <apbianco@redhat.com>
10882
10883 * java-tree.h (compile_resource_file): Grouped with other prototypes.
10884 * jvspec.c (lang_specific_driver): Removed unused local `ptr.'
10885
10886 2001-09-06 Anthony Green <green@redhat.com>
10887
10888 * class.c (O_BINARY): Define if necessary.
10889 (registerResource_libfunc): Declare.
10890 (init_class_processing): Initilize registerResource_libfunc.
10891 (compile_resource_file): New function.
10892 * java-tree.h (resource_name): Declare.
10893 (compile_resource_file): Declare.
10894 * jcf-parse.c (yyparse): Handle compiling java resource files.
10895 * lang.c (java_decode_option): Handle -fcompile-resource option.
10896 * jvspec.c (lang_specific_driver): Handle -R flag for compiling
10897 resource files.
10898 * gcj.texi (Code Generation): Add documentation for -R flag.
10899
10900 2001-09-05 Alexandre Petit-Bianco <apbianco@redhat.com>
10901
10902 * jcf-write.c (generate_classfile): Issue an error in case of
10903 field/initial value mismatch.
10904 * parse.y (analyze_clinit_body): Keep <clinit> if an array is
10905 being initialized and we're generating bytecode.
10906 (java_complete_lhs): In MODIFY_EXPR section: added comments,
10907 set DECL_INITIAL properly when appropriate.
10908 Fixes PR java/4230
10909 Fixes PR java/4204
10910
10911 2001-09-01 Per Bothner <per@bothner.com>
10912
10913 * parse.y (maybe_yank_clinit): A field without an initializer is not
10914 relevant. All initializers except static final and constant require
10915 <clinit>, regardless of flag_emit_class_files.
10916
10917 2001-08-31 Per Bothner <per@bothner.com>
10918
10919 * class.c (set_constant_value): When not emitting class files, then a
10920 String ConstantValue is a utf8const_ptr_type.
10921
10922 2001-08-30 Per Bothner <per@bothner.com>
10923
10924 * jcf-write.c (generate_classfile): Check that field is primitive
10925 or string before emitting ConstantValue attribute.
10926
10927 2001-08-30 Per Bothner <per@bothner.com>
10928
10929 * parse.y (resolve_qualified_expression_name): If creating a
10930 COMPOUND_EXPR, set it's type correctly.
10931
10932 2001-08-30 Per Bothner <per@bothner.com>
10933
10934 * jcf-io.c (open_class): Set filename field.
10935
10936 * jcf-parse,c (parse_class_file): Set current_function_decl
10937 for better error message when Code attribute is missing.
10938
10939 * lang.c (put_decl_node, lang_print_error): Re-arrange for
10940 better diagnostics, especially for constructors.
10941
10942 2001-08-30 Per Bothner <per@bothner.com>
10943
10944 * jcf-write.c (generate_classfile): Don't write ConstantValue
10945 attribute if field is not final, for compatibility with jdk.
10946
10947 * jcf-write.c (generate_classfile): Convert ConstantValue values
10948 to correct type. Work-around for front-end bug.
10949 * class.c (set_constant_value): Error if constant has wrong type.
10950
10951 2001-08-30 Per Bothner <per@bothner.com>
10952
10953 * jcf-dump.c (print_constant): Fix fencepost error so "Float" and
10954 "Double" are printed at verbosity 1.
10955
10956 * jcf-dump.c (main): Disable flag_print_attributes if --javap.
10957
10958 * jcf-dump.c (SPECIAL_IINC): Remove unneeded casts to long.
10959
10960 2001-08-30 Alexandre Petit-Bianco <apbianco@redhat.com>
10961
10962 * parse.y (patch_assignment): Don't verify final re-assignment here.
10963 (java_complete_lhs): Verify assignments to finals calling
10964 patch_assignment. Verify re-assignments to finals before calling
10965 patch_assignment.
10966
10967 2001-08-29 Alexandre Petit-Bianco <apbianco@redhat.com>
10968
10969 * parse.y (java_complete_lhs): Allow final locals in CASE_EXPRs.
10970 Fixes PR java/1413
10971
10972 2001-08-28 Alexandre Petit-Bianco <apbianco@redhat.com>
10973
10974 * lex.c (java_lex): new local found_hex_digits. Set and then used
10975 in test to reject invalid hexadecimal numbers.
10976 * parse.y (java_complete_tree): Prevent unwanted cast with
10977 initialized floating point finals.
10978 (patch_binop): Emit a warning when detecting a division by zero,
10979 mark result not constant, don't simplify non integer division.
10980
10981 2001-08-28 Per Bothner <per@bothner.com>
10982
10983 * jcf-write.c (generate_bytecode_insns): For increments and
10984 decrements just recurse to push constant. Improvement on Mark's patch.
10985
10986 2001-08-28 Mark Mitchell <mark@codesourcery.com>
10987
10988 * jcf-write.c (generate_bytecode_insns): Generate an integer to
10989 real conversion for increments and decrements of reals.
10990
10991 2001-08-27 Alexandre Petit-Bianco <apbianco@redhat.com>
10992
10993 * parse.y (resolve_qualified_expression_name): Handle unresolved
10994 qualified expressions, prevent numerical qualifiers, fixed typo.
10995 Fixes PR java/4141
10996
10997 2001-08-24 Alexandre Petit-Bianco <apbianco@redhat.com>
10998
10999 * parse.y (check_deprecation): Handle TYPE_DECL in a special case,
11000 don't report anything but deprecated class when marked so. Handle
11001 VAR_DECL.
11002 (patch_method_invocation): Check deprecation on methods and types.
11003 (patch_binop): code becomes an enum tree_code, added default: to
11004 switch to handle that. Detect division by zero, try to fold and
11005 return before using a subroutine.
11006
11007 2001-08-23 Alexandre Petit-Bianco <apbianco@redhat.com>
11008
11009 * jcf-parse.c (yyparse): Set magic to 0, don't issue error for a
11010 file smaller than 4 bytes.
11011 * parse.y (check_inner_circular_reference): New function.
11012 (check_circular_reference): Likewise.
11013 (array_initializer:): Accept {,}.
11014 (java_check_circular_reference): Rewritten using
11015 check_circular_reference and check_inner_circular_reference.
11016 (java_complete_expand_method): Unconditionally save and restore
11017 the unpurged exception list.
11018 (build_dot_class_method_invocation): Unmangle signature parameter.
11019
11020 2001-08-21 Tom Tromey <tromey@redhat.com>
11021
11022 * decl.c (init_decl_processing): Add `throws' field to method
11023 descriptor.
11024 * class.c (make_method_value): Compute `throws' field for method.
11025
11026 2001-08-22 Alexandre Petit-Bianco <apbianco@redhat.com>
11027
11028 * parse.y (resolve_inner_class): Keep local_enclosing to NULL if
11029 circularity is detected.
11030 (ctors_unchecked_throws_clause_p): Fixed leading comment.
11031
11032 2001-08-17 Richard Henderson <rth@redhat.com>
11033
11034 * class.c (emit_register_classes): Add align parameter to
11035 call to assemble_integer.
11036
11037 2001-08-16 Alexandre Petit-Bianco <apbianco@redhat.com>
11038
11039 * jcf-parse.c (load_class): New locals saved and class_loaded. If
11040 loading a class_or_name fails, try considering an innerclass name
11041 and load the enclosing context.
11042 * parse.y (resolve_inner_class): New function.
11043 (find_as_inner_class): Added leading comment.
11044 (register_incomplete_type): Keep the current context as enclosing
11045 context for JDEP_FIELD dependencies.
11046 (do_resolve_class): Locals new_class_decl and super initialized to
11047 NULL. Call resolve_inner_class, explore the enclosing context
11048 superclass if necessary.
11049 Fixes PR java/4007
11050
11051 2001-08-16 Tom Tromey <tromey@redhat.com>
11052
11053 * jcf-dump.c (main): Updated for change to jcf_path_seal.
11054 * gjavah.c (main): Updated for change to jcf_path_seal.
11055 * lang.c (version_flag): New global.
11056 (java_decode_option): Recognize `-version'.
11057 (java_init): Update for change to jcf_path_seal.
11058 * jcf.h (jcf_path_seal): Added `print' argument.
11059 * jcf-path.c (jcf_path_seal): Added `print' argument.
11060
11061 2001-08-13 Zack Weinberg <zackw@panix.com>
11062
11063 * Make-lang.in (java/decl.o): Update dependencies.
11064 * decl.c: Include libfuncs.h, don't include toplev.h.
11065
11066 2001-08-12 Alexandre Petit-Bianco <apbianco@redhat.com>
11067
11068 * decl.c (init_decl_processing): exception_type_node,
11069 class_not_found_type_node, and no_class_def_found_type_node
11070 initialized. predef_filenames augmented accordingly.
11071 instinit_identifier_node initialized.
11072 * java-tree.def (INSTANCE_INITIALIZERS_EXPR): Entry removed.
11073 * java-tree.h (enum java_tree_index): New entries
11074 JTI_EXCEPTION_TYPE_NODE, JTI_CLASS_NOT_FOUND_TYPE_NODE,
11075 JTI_NO_CLASS_DEF_FOUND_TYPE_NODE, JTI_INSTINIT_IDENTIFIER_NODE.
11076 (exception_type_node): New macro.
11077 (class_not_found_type_node): Likewise.
11078 (no_class_def_found_type_node): Likewise.
11079 (instinit_identifier_node): Likewise.
11080 (PREDEF_FILENAMES_SIZE): Adjusted.
11081 (TYPE_HAS_FINAL_VARIABLE): Fixed typo.
11082 (struct lang_type): Fixed typo in bitfield name.
11083 (DECL_INSTINIT_P): New macro.
11084 (ID_INSTINIT_P): Likewise.
11085 * jcf-write.c (generate_classfile): instinit$ bears the Synthetic
11086 attribute.
11087 * parse.y (encapsulate_with_try_catch): New function.
11088 (generate_instinit): Likewise.
11089 (build_instinit_invocation): Likewise.
11090 (ctors_unchecked_throws_clause_p): Likewise.
11091 (add_instance_initializer): Deleted.
11092 (build_instance_initializer): Likewise.
11093 (in_instance_initializer): Likewise.
11094 (check_method_redefinition): instinit$ not to be verified.
11095 (java_complete_expand_methods): Generate instinit$, simplified code.
11096 (build_dot_class_method): Eliminated unnecessary locals. Use
11097 encapsulate_with_try_catch, removed unnecessary code.
11098 (fix_constructors): New local iii. Use build_instinit_invocation.
11099 (patch_method_invocation): Added comment.
11100 (maybe_use_access_method): Don't consider instinit$.
11101 (find_applicable_accessible_methods_list): Shorten the search for
11102 instinit$ too.
11103 (java_complete_lhs): case INSTANCE_INITIALIZERS_EXPR removed.
11104 (patch_return): Use DECL_INSTINIT_P instead of in_instance_initializer.
11105 (patch_throw_statement): Likewise. Fixed typo.
11106
11107 2001-08-12 David Edelsohn <edelsohn@gnu.org>
11108
11109 Revert:
11110 2001-08-02 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
11111 * jvspec.c (jvgenmain_spec): Cannot use %umain, breaks
11112 ASM_FINAL_SPEC.
11113 (lang_specific_pre_link): Use set_input to set input_filename.
11114 Append `main' here.
11115 * jvgenmain.c (usage): Append literal `main' to CLASSNAME.
11116 (main): Fix definition.
11117 Strip `main' from classname.
11118 Fixes PR java/227.
11119
11120 2001-08-11 Zack Weinberg <zackw@panix.com>
11121
11122 * lex.h: Don't include setjmp.h. Don't define
11123 SET_FLOAT_HANDLER or prototype set_float_handler.
11124
11125 2001-08-09 Alexandre Petit-Bianco <apbianco@redhat.com>
11126
11127 * expr.c (java_lang_expand_expr): Call `expand_end_bindings' and
11128 `poplevel' in the right order.
11129
11130 2001-08-09 Richard Henderson <rth@redhat.com>
11131
11132 * Make-lang.in (class.o): Depend on TARGET_H.
11133 * class.c (emit_register_classes): Use target hooks instead of
11134 assemble_constructor and assemble_destructor.
11135
11136 2001-08-08 Alexandre Petit-Bianco <apbianco@redhat.com>
11137
11138 * check-init.c (flags.h): Include
11139 (check_init): Don't report uninitialized static class
11140 initialization flags, don't free bit index when doing static class
11141 initialization optimization.
11142 (check_for_initialization): Return type changed to `unsigned int.'
11143 (attach_initialized_static_class): New function.
11144 * class.c (add_method_1): Create the initialized static class
11145 table if necessary.
11146 (finish_class): Always emit deferred inline methods.
11147 * decl.c (emit_init_test_initialization): Moved to expr.c
11148 (complete_start_java_method): Don't traverse
11149 DECL_FUNCTION_INIT_TEST_TABLE.
11150 (lang_mark_tree): Mark hash tables in function decls.
11151 * expr.c (emit_init_test_initialization): Moved from decl.c.
11152 (build_class_init): Create LAG_DECL_SPECIFIC for the static class
11153 initialization flag, set DECL_CONTEXT and
11154 LOCAL_CLASS_INITIALIZATION_FLAG.
11155 (java_lang_expand_expr): Emit initialization code for static class
11156 initialized flags when entering block, if necessary.
11157 * gcj.texi (-fno-optimize-static-class-initialization): Documented.
11158 * java-tree.h (flag_optimize_sci): New global variable declaration.
11159 (DECL_FUNCTION_INITIALIZED_CLASS_TABLE): New macro.
11160 (DECL_FUNCTION_STATIC_METHOD_INVOCATION_COMPOUND): Likewise.
11161 (LOCAL_FINAL_P): Fixed typo in comment.
11162 (FINAL_VARIABLE_P): Likewise.
11163 (LOCAL_CLASS_INITIALIZATIO_FLAG): New macro.
11164 (LOCAL_CLASS_INITIALIZATIO_FLAG_P): Likewise.
11165 (struct lang_decl): New fields `ict', `smic' and `cif.'
11166 (check_for_initialization): New returned value for global.
11167 (attach_initialized_static_class): New global function.
11168 (STATIC_CLASS_INIT_OPT_P): New macro.
11169 * lang-options.h (-fno-optimize-static-class-initialization): New flag.
11170 * lang.c (java_decode_option): Handle
11171 `-fno-optimize-static-class-initialization'
11172 * parse.y (start_complete_expand_method): New function.
11173 (java_expand_method_bodies): Likewise.
11174 (attach_init_test_initialization_flags): Likewise.
11175 (adjust_init_test_initialization): Likewise.
11176 (emit_test_initialization): Likewise.
11177 (java_complete_expand_methods): Nullify abstract and native method
11178 bodies.
11179 (java_complete_expand_method): New locals `fbody', `block_body'
11180 and `exception_copy.' Reorganized: directly return on empty method
11181 bodies, call `start_complete_expand_method', remember definitely
11182 initialized static class in function, don't expand method bodies.
11183 (java_expand_classes): Call `java_expand_method_bodies' before
11184 `finish_class' when compiling to native.
11185 (resolve_expression_name): Use `orig' after building outer class
11186 field access.
11187 (patch_invoke): Remember static method invocations.
11188
11189 2001-08-06 Richard Henderson <rth@redhat.com>
11190
11191 * class.c (emit_register_classes): Pass a symbol_ref and priority
11192 to assemble_constructor.
11193
11194 2001-08-02 Alexandre Petit-Bianco <apbianco@redhat.com>
11195
11196 * java-tree.h (all_class_filename): New macro.
11197 (enum java_tree_index): New enum `JTI_ALL_CLASS_FILENAME.'
11198 (BUILD_FILENAME_IDENTIFIER_NODE): Fixed leading comment. Link
11199 newly created IDENTIFIER_NODE to `all_class_filename.'
11200
11201 2001-08-01 Jeff Sturm <jsturm@one-point.com>
11202
11203 * java-tree.h (BUILD_FILENAME_IDENTIFIER_NODE):
11204 Use ggc_add_tree_root to register roots.
11205
11206 2001-07-31 Alexandre Petit-Bianco <apbianco@redhat.com>
11207
11208 * check-init.c (check_init): WITH_CLEANUP_EXPR node to use its
11209 second operand calling check_init.
11210 * decl.c (complete_start_java_method): Swaped second and third
11211 arguments while creating WITH_CLEANUP_EXPR node.
11212 * jcf-write.c (generate_bytecode_insns): Use second operand
11213 instead of third when handling WITH_CLEANUP_EXPR.
11214 * parse.y (java_complete_lhs): Expand second operand of
11215 WITH_CLEANUP_EXPR nodes.
11216 (patch_synchronized_statement): Swaped second and third arguments
11217 while creating WITH_CLEANUP_EXPR node.
11218
11219 2001-07-18 Alexandre Petit-Bianco <apbianco@redhat.com>
11220
11221 * parse.y (create_interface): Avoid cyclic inheritance report when
11222 syntax error encountered during class definition.
11223 Fixes PR java/2956
11224
11225 2001-08-02 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
11226
11227 * jvspec.c (jvgenmain_spec): Cannot use %umain, breaks
11228 ASM_FINAL_SPEC.
11229 (lang_specific_pre_link): Use set_input to set input_filename.
11230 Append `main' here.
11231 * jvgenmain.c (usage): Append literal `main' to CLASSNAME.
11232 (main): Fix definition.
11233 Strip `main' from classname.
11234 Fixes PR java/227.
11235
11236 2001-07-18 Tom Tromey <tromey@redhat.com>
11237
11238 For PR java/2812:
11239 * lex.h: Use HAVE_ICONV, not HAVE_ICONV_H.
11240 * lex.c (java_new_lexer): Use ICONV_CONST.
11241 (java_read_char): Likewise.
11242 * Make-lang.in (jc1$(exeext)): Link against LIBICONV.
11243 (jv-scan$(exeext)): Likewise.
11244
11245 2001-07-17 Alexandre Petit-Bianco <apbianco@redhat.com>
11246
11247 * parse.h (INTERFACE_INNER_MODIFIERS): Disallow `private.'
11248 * parse.y (check_class_interface_creation): Allow `private' if the
11249 enclosing is not an interface.
11250 (create_interface): Interface tagged public if the enclosing
11251 context is an interface.
11252 (create_class): Class tagged public if the enclosing context
11253 is an interface.
11254 Fixes PR java/2959
11255
11256 2001-07-17 Alexandre Petit-Bianco <apbianco@redhat.com>
11257
11258 * class.c (push_class): Set DECL_SIZE to `integer_zero_node.'
11259 Fixes PR java/2665
11260
11261 2001-07-14 Tim Josling <tej@melbpc.org.au>
11262
11263 * check-init.c (check_init): Remove references to EXPON_EXPR.
11264
11265 2001-07-13 Alexandre Petit-Bianco <apbianco@redhat.com>
11266
11267 * parse.y (java_complete_lsh): Set CAN_COMPLETE_NORMALLY and unset
11268 TREE_CONSTANT_OVERFLOW of CASE_EXPR value.
11269 Fixes PR java/3602
11270
11271 2001-07-13 Tom Tromey <tromey@redhat.com>
11272
11273 * jvspec.c (jvgenmain_spec): Remove -ffilelist-file from cc1
11274 invocation.
11275
11276 2001-07-12 Alexandre Petit-Bianco <apbianco@redhat.com>
11277
11278 * parse.y (patch_method_invocation): Don't override primary if one
11279 is already provided, but let this$<n> be built. Fixed comment.
11280
11281 2001-07-12 Alexandre Petit-Bianco <apbianco@redhat.com>
11282
11283 * parse.y (empty_statement:): Report empty statement error only
11284 when found at class declaration level.
11285 Fixes PR java/3635
11286
11287 2001-07-12 Tom Tromey <tromey@redhat.com>
11288
11289 * expr.c (expand_load_internal): New function.
11290 (LOAD_INTERNAL): Use it.
11291
11292 2001-07-11 Alexandre Petit-Bianco <apbianco@redhat.com>
11293
11294 * parse.y (verify_constructor_super): Compare anonymous class ctor
11295 args with `valid_method_invocation_conversion_p.'
11296 Fixes PR java/3285
11297
11298 2001-07-10 Alexandre Petit-Bianco <apbianco@redhat.com>
11299
11300 * lang-specs.h: Forbit the use if `-femit-class-file{s}' without
11301 `-fsyntax-only.' Fixes PR java/3248
11302
11303 2001-07-10 Alexandre Petit-Bianco <apbianco@redhat.com>
11304
11305 * jcf-io.c (find_class): Clarified error message. Fixes PR java/2603
11306
11307 2001-07-10 Alexandre Petit-Bianco <apbianco@redhat.com>
11308
11309 * parse.h (INNER_ENCLOSING_SCOPE_CHECK): No `this' is fine if the
11310 current function is static. Fixes PR java/1970
11311
11312 2001-07-09 Alexandre Petit-Bianco <apbianco@redhat.com>
11313
11314 * parse.y (patch_method_invocation): Add enclosing context to ctor
11315 calls if necessary. Fixes PR java/2953
11316
11317 2001-07-09 Alexandre Petit-Bianco <apbianco@redhat.com>
11318
11319 * parse.y (resolve_package): Abort if qualified expression member
11320 isn't right.
11321 (qualify_ambiguous_name): Don't qualify as type if `this' in use.
11322 Fixes PR java/1391
11323
11324 2001-07-07 Zack Weinberg <zackw@stanford.edu>
11325
11326 * verify.c: Don't use // comments.
11327
11328 2001-07-05 Tom Tromey <tromey@redhat.com>
11329
11330 * lang.c (flag_assume_compiled): Removed.
11331 * java-tree.h (flag_assume_compiled): Removed.
11332 * lang-options.h: Removed -ffile-list-file, -fuse-boehm-gc,
11333 -fhash-synchronization, -fuse-divide-subroutine,
11334 -fcheck-references, -femit-class-file, -femit-class-files,
11335 -fassume-compiled. Updated --encoding information. Changed
11336 -foutput-class-dir to `-d'.
11337
11338 2001-07-04 Daniel Berlin <dan@cgsoftware.com>
11339
11340 * jcf-parse.c (parse_class_file): Add lineno parameter to
11341 debug_start_source_file call.
11342
11343 2001-07-04 Joseph S. Myers <jsm28@cam.ac.uk>
11344
11345 * gcj.texi: Use gpl.texi.
11346 * Make-lang.in ($(srcdir)/java/gcj.info, java/gcj.dvi): Update
11347 dependencies and use doc/include in search path.
11348
11349 2001-07-03 Jeff Sturm <jsturm@one-point.com>
11350
11351 * parse.y (fix_constructors): Test if a CALL_EXPR invokes
11352 `this'. If so, don't build instance initializers.
11353
11354 2001-07-03 Alexandre Petit-Bianco <apbianco@redhat.com>
11355
11356 * parse.y (resolve_expression_name): Improved error message for
11357 inner class cases. Fixes PR java/1958
11358
11359 2001-06-28 Gabriel Dos Reis <gdr@codesourcery.com>
11360
11361 * lang.c: #include diagnostic.h
11362 (lang_print_error): Add a `diagnostic_context *' parameter.
11363 (java_dummy_print): Likewise.
11364 * Make-lang.in (JAVA_LEX_C): Depend on diagnostic.h
11365
11366 2001-06-27 Alexandre Petit-Bianco <apbianco@redhat.com>
11367
11368 * jcf-parse.c (gcc_mark_jcf): Test for a finished JCF.
11369 * jcf.h (typedef struct JCF): New bitfield `finished.'
11370 (JCF_FINISH): Set `finished.'
11371 (JCF_ZERO): Reset `finished.'
11372 Fixes PR java/2633
11373
11374 2001-06-27 Alexandre Petit-Bianco <apbianco@redhat.com>
11375
11376 * parse.y (class_body_declaration:): Don't install empty instance
11377 initializers.
11378 Fixes PR java/1314
11379
11380 2001-06-27 Alexandre Petit-Bianco <apbianco@redhat.com>
11381
11382 * class.c (set_super_info): Call `set_class_decl_access_flags.'
11383 (set_class_decl_access_flags): New function.
11384 * java-tree.h (set_class_decl_access_flags): New prototype.
11385 * jcf-parse.c (handle_innerclass_attribute): Read and set access flags.
11386 (parse_class_file): New local `decl_max_locals.' Take wide types
11387 into account to compute DECL_MAX_LOCALS.
11388 * parse.y (type_import_on_demand_declaration:): Ignore duplicate
11389 imports on demand.
11390
11391 2001-06-22 Jan van Male <jan.vanmale@fenk.wau.nl>
11392
11393 * zipfile.h: Use GCC_JCF_H instead of JCF_H.
11394
11395 2001-06-20 Alexandre Petit-Bianco <apbianco@redhat.com>
11396
11397 * class.c (java_hash_tree_node): Fixed indentation in leading comment.
11398 * parse.y (do_resolve_class): Moved comments out to leading comment
11399 section. Removed local `start', New local `_ht' and
11400 `circularity_hash.' Record `enclosing' in hash table and search
11401 it to detect circularity. Use `enclosing' as an argument to
11402 `lookup_cl.' Free the hash table when done.
11403
11404 2001-06-19 Tom Tromey <tromey@redhat.com>
11405
11406 * lex.c (java_read_char): Disallow invalid and overlong
11407 sequences. Fixes PR java/2319.
11408
11409 2001-06-05 Jeff Sturm <jsturm@one-point.com>
11410
11411 * decl.c (create_primitive_vtable): Don't call make_decl_rtl.
11412
11413 2001-06-04 Alexandre Petit-Bianco <apbianco@redhat.com>
11414
11415 * expr.c (force_evaluation_order): Match wrapped ctor calls, locate
11416 arguments accordingly.
11417
11418 2001-06-02 Joseph S. Myers <jsm28@cam.ac.uk>
11419
11420 * gcj.texi: Move contents to just after title page.
11421
11422 2001-06-01 Alexandre Petit-Bianco <apbianco@redhat.com>
11423
11424 * parse.y (type_literals:): Use `build_incomplete_class_ref' with
11425 builtin type.
11426 (patch_incomplete_class_ref): Build the class ref, build the class
11427 init if necessary, complete the tree.
11428 Fixes PR java/2605
11429
11430 2001-05-31 Alexandre Petit-Bianco <apbianco@redhat.com>
11431
11432 * parse.y (lookup_field_wrapper): Test `name' code.
11433 (resolve_qualified_expression_name): Test `qual_wfl' code.
11434 (qualify_ambiguous_name): Handle `CONVERT_EXPR', fixe indentation,
11435 handle `qual_wfl' by code.
11436 (maybe_build_primttype_type_ref): Test `wfl' code.
11437
11438 2001-05-23 Theodore Papadopoulo <Theodore.Papadopoulo@sophia.inria.fr>
11439
11440 * Make-lang.in ($(srcdir)/java/gcj.info): Added dependencies on
11441 fdl.texi.
11442 (java/gcj.dvi): Use TEXI2DVI instead of custom tex calls. Create
11443 the dvi file in the java directory.
11444
11445 2001-05-25 Sam TH <sam@uchicago.edu>
11446
11447 * gen-table.pl javaop.h jcf.h lex.h,
11448 parse.h: Fix header include guards.
11449
11450 2001-05-23 Joseph S. Myers <jsm28@cam.ac.uk>
11451
11452 * jv-scan.c (version): Update copyright year.
11453
11454 2001-05-21 Per Bothner <per@bothner.com>
11455
11456 * jcf-parse.c (read_class): If class is from .class or .zip file
11457 and it's already been read, don't push/pop parser context.
11458
11459 2001-05-18 Per Bothner <per@bothner.com>
11460
11461 * jvspec.c (lang_specific_pre_link): Re-arrange the linker
11462 command line so the jvgenmain-generated main program comes first.
11463
11464 2001-05-15 Tom Tromey <tromey@redhat.com>
11465
11466 * class.c (build_utf8_ref): Don't generate identifier based on
11467 utf8const contents.
11468
11469 2001-05-12 Richard Henderson <rth@redhat.com>
11470
11471 * java-tree.def (JAVA_EXC_OBJ_EXPR): New.
11472 * expr.c (java_lang_expand_expr): Expand it.
11473 (process_jvm_instruction): Build JAVA_EXC_OBJ_EXPR instead of
11474 calling build_exception_object_ref.
11475 * parse.y (catch_clause_parameter): Likewise.
11476 (build_dot_class_method): Likewise.
11477 (try_reference_assignconv): Likewise.
11478 * check-init.c (check_init): Check JAVA_EXC_OBJ_EXPR not EXC_PTR_EXPR.
11479 * jcf-write.c (generate_bytecode_insns): Likewise.
11480
11481 2001-05-07 Alexandre Petit-Bianco <apbianco@redhat.com>
11482
11483 * parse.y (build_unresolved_array_type): Set
11484 EXPR_WFL_QUALIFICATION on the newly created wfl.
11485 Fixes PR java/2538. Fixes PR java/2535.
11486
11487 2001-05-07 Alexandre Petit-Bianco <apbianco@redhat.com>
11488
11489 * parse.y (fix_constructors): Removed unnecessary assignment to
11490 local. Moved assignment to `this$<n>', fixed comments and
11491 indentation.
11492 (build_wfl_wrap): Fixed indentation.
11493 Fixes PR java/2598, java/2579 and java/2658.
11494
11495 2001-05-03 Mo DeJong <mdejong@redhat.com>
11496
11497 * lex.c (java_new_lexer): Call iconv_close on temp handle used to
11498 check for byte swap.
11499
11500 2000-05-02 Jeff Sturm <jsturm@one-point.com>
11501
11502 * expr.c (build_class_init): Move MODIFY_EXPR
11503 outside of COND_EXPR. Remove variable `call'.
11504
11505 2001-05-02 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11506
11507 * decl.c: NULL_PTR -> NULL.
11508 * jcf-write.c: Likewise.
11509
11510 2001-05-01 Tom Tromey <tromey@redhat.com>
11511
11512 * Make-lang.in ($(srcdir)/java/gcj.info): Added `-I..'.
11513 (java/gcj.dvi): Added $(srcdir) to TEXINPUTS.
11514 * gcj.texi: Updated copyright text. Include fdl.texi.
11515 (Top): Link to new node.
11516
11517 2001-05-01 Per Bothner <per@bothner.com>
11518
11519 * parse.h (REGISTER_IMPORT): Use tree_cons instead of chainon.
11520
11521 2001-05-01 Per Bothner <per@bothner.com>
11522
11523 * parse.y (java_pop_parser_context): The TREE_VALUE of a link in the
11524 import_list contains the name, not the TREE_PURPOSE.
11525
11526 2001-04-29 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11527
11528 * jcf-io.c (read_zip_member): Cast to long in comparison with
11529 signed value.
11530
11531 * jvspec.c (lang_specific_driver): Initialize variables.
11532
11533 * mangle.c (find_compression_record_match): Likewise.
11534
11535 * typeck.c (build_null_signature): Provide static prototype. Mark
11536 parameter with ATTRIBUTE_UNUSED.
11537
11538 * verify.c (verify_jvm_instructions): Initialize variable.
11539
11540 2001-04-27 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
11541
11542 * parse.y (do_resolve_class): Check for cyclic inheritance during
11543 inner class resolution.
11544
11545 2001-04-27 Per Bothner <per@bothner.com>
11546
11547 * parse.y (java_expand_classes): Don't change ctxp_for_generation
11548 while iterating, since that could cause gc to lose stuff.
11549
11550 2001-04-26 Per Bothner <per@bothner.com>
11551
11552 Fix method search wrt scope of inner classes to match JLS2.
11553 * typeck.c (build_null_signature): New static function.
11554 (has_method): New function. Uses build_null_signature and lookup_do.
11555 * java-tree.h (has_method): New declaration.
11556 * parse.y (find_applicable_accessible_methods_list): Do not search
11557 context of inner classes here.
11558 (patch_method_invocation): Search scope, ie. current and outer clases,
11559 for method matching simple name, to find class.
11560
11561 2001-04-26 Per Bothner <per@bothner.com>
11562
11563 * jcf-write.c (generate_bytecode_insns case SWITCH_EXPR):
11564 Fix thinko: If a single case, use if_icmpeq, not ifeq.
11565
11566 * constants.c (find_methodref_with_class_index): New function.
11567 (find_methodref_index): Use find_methodref_with_class_index.
11568 * java-tree.h (find_methodref_with_class_index): New declaration.
11569 * jcf-write.c (generate_bytecode_insns case CALL_EXPR): Don't change
11570 DECL_CONTEXT, instead use new find_methodref_with_class_index function.
11571 If context changed from interface to class, don't use invokeinterface.
11572
11573 2001-04-25 Per Bothner <per@bothner.com>
11574
11575 * verify.c (verify_jvm_instructions): For field instructions,
11576 check that field index is valid. For invoke instructions, check that
11577 method index is valid.
11578
11579 2001-04-25 Alexandre Oliva <aoliva@redhat.com>
11580
11581 * config-lang.in (target_libs): Copy from $libgcj_saved.
11582
11583 2001-04-25 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
11584
11585 * decl.c (init_decl_processing): Add new class "protectionDomain"
11586 field.
11587 * class.c (make_class_data): Set initial value for "protectionDomain".
11588
11589 2001-04-22 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11590
11591 * jvspec.c (lang_specific_driver): Fix memory allocation
11592 deficit, by using concat in lieu of xmalloc/sprintf.
11593
11594 2001-04-20 Per Bothner <per@bothner.com>
11595
11596 Fixes to compile multiple .class files at once.
11597 * decl.c (init_decl_processing): Don't set CLASS_LOADED_P.
11598 * java-tree.h (CLASS_PARSED_P): New macro.
11599 (CLASS_LOADED_P): Re-define to use TYPE_SIZE and CLASS_PARSED_P.
11600 * jcf-parse.c (jcf_parse_source): Inline into read_class.
11601 (read_class): Avoid some code duplication.
11602 Don't call JCF_FINISH for a .class file - might be needed later.
11603 (jcf_parse): Don't call layout_class here. Check/set CLASS_PARSED_P
11604 rather than CLASS_LOADED_P, since latter implies class laid out.
11605 (yyparse): Do layout_class and JCF_FINISh here instead, in pass 2.
11606 * parse.y: Don't need to set CLASS_LOADED_P for array types.
11607
11608 2001-04-11 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11609
11610 * Make-lang.in (java/boehm.o): Depend on toplev.h.
11611
11612 * boehm.c: Include toplev.h.
11613
11614 2001-04-06 Tom Tromey <tromey@redhat.com>
11615 Alexandre Petit-Bianco <apbianco@redhat.com>
11616
11617 Fix for PR gcj/1404 and PR gcj/2332:
11618 * parse.y (build_array_from_name): If we use the type_wfl then
11619 accumulate dimensions from the original type as well.
11620 (build_unresolved_array_type): Don't modify TYPE_OR_WFL in place.
11621
11622 2001-04-06 Tom Tromey <tromey@redhat.com>
11623
11624 * parse.y (analyze_clinit_body): Return true if the second operand
11625 of a METHOD_EXPR is nonzero.
11626
11627 2001-04-06 Tom Tromey <tromey@redhat.com>
11628
11629 * Make-lang.in ($(srcdir)/java/parse-scan.c): Run bison from build
11630 directory.
11631 ($(srcdir)/java/parse.c): Likewise.
11632
11633 2001-04-05 Alexandre Petit-Bianco <apbianco@redhat.com>
11634
11635 * gcj.texi: Use `which-gcj' instead of `which-g77.'
11636 (version-gcc): Initialized.
11637 (which-gcj): Likewise.
11638
11639 2001-04-04 Alexandre Petit-Bianco <apbianco@redhat.com>
11640
11641 * java-tree.h (struct lang_decl): New macro
11642 `DECL_FIXED_CONSTRUCTOR_P.' New field `fixed_ctor.'
11643 * parse.y (build_instance_initializer): New function.
11644 (add_instance_initializer): Use it.
11645 (java_fix_constructors): Set `current_class' before fix pass.
11646 (fix_constructors): Just return if already fixed. Move `super()'
11647 invocation ahead. Use `build_instance_initializer.'
11648 Fixes PR java/1315.
11649
11650 2001-04-04 Alexandre Petit-Bianco <apbianco@redhat.com>
11651
11652 * parse.y (resolve_qualified_expression_name): Pass field's
11653 DECL_CONTEXT to `not_accessible_p.'
11654 (not_accessible_p): Changed parameters order in `inherits_from_p'
11655 invocation.
11656
11657 2001-03-27 Andrew Haley <aph@cambridge.redhat.com>
11658
11659 * lang-options.h: Add flag_check_references.
11660
11661 2001-04-04 Per Bothner <per@bothner.com>
11662
11663 * java-tree.h (CONSTANT_VALUE_P): New macro.
11664 * jcf-write.c (generate_classfile): Use CONSTANT_VALUE_P.
11665 * parse.y (maybe_build_class_init_for_field): New static function.
11666 (resolve_expression_name, resolve_field_access): Use
11667 maybe_build_class_init_for_field instead of build_class_init
11668 This does not do the init if the field is compile-time-constant.
11669 (resolve_field_access): Simplify.
11670
11671 * parse.y (fold_constant_for_init): Merge test into switch.
11672
11673 2001-04-03 Zack Weinberg <zackw@stanford.edu>
11674
11675 * Make-lang.in (buffer.o, check-init.o, class.o): Don't depend
11676 on gansidecl.h.
11677 * buffer.c, jvgenmain.c: Don't include gansidecl.h.
11678
11679 2001-04-02 Zack Weinberg <zackw@stanford.edu>
11680
11681 * expr.c (pop_type_0): Save the result of the first
11682 lang_printable_name call in a scratch buffer, so it
11683 won't be clobbered by the second call.
11684
11685 2001-03-30 Alexandre Petit-Bianco <apbianco@redhat.com>
11686
11687 * parse-scan.y (array_type:): Rewritten.
11688 (type_declaration:): `empty_statement' replaces `SC_TK.'
11689 (class_member_declaration:): `empty statement' added.
11690 (method_body:): Simplified.
11691 (static_initializer:): Likewise.
11692 (primary_no_new_array:): Use `type_literals.'
11693 (type_literals:): New rule.
11694 (dims:): Set and update `bracket_count.'
11695 Fixes PR java/1074. Fixes PR java/2412.
11696
11697 2001-03-28 Hans Boehm <boehm@acm.org>
11698
11699 * boehm.c (PROCEDURE_OBJECT_DESCRIPTOR): Set to use `build_int_2.'
11700 (get_boehm_type_descriptor): Set type on returned value to be a
11701 pointer length integer.
11702
11703 2001-03-28 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11704
11705 * expr.c (pop_type_0): Call `concat' rather than building the
11706 string manually.
11707 (pop_type): Add format specifier in call to `error'.
11708
11709 * parse.y (patch_method_invocation): Avoid casting away
11710 const-ness.
11711
11712 2001-03-28 Jeffrey Oldham <oldham@codesourcery.com>
11713
11714 * jvgenmain.c (do_mangle_classname): End string constant with '\0'.
11715
11716 2001-03-28 Richard Henderson <rth@redhat.com>
11717
11718 IA-64 ABI Exception Handling:
11719 * Make-lang.in (except.o): Don't depend on eh-common.h.
11720 * check-init.c (check_init): Handle EXC_PTR_EXPR.
11721 * decl.c (init_decl_processing) [throw_node]: No _Jv_Sjlj_Throw.
11722 [soft_exceptioninfo_call_node]: Remove.
11723 [eh_personality_libfunc, lang_eh_runtime_type]: New.
11724 (end_java_method): No emit_handlers.
11725 * except.c (java_set_exception_lang_code): Remove.
11726 (method_init_exceptions): Don't call it.
11727 (prepare_eh_table_type): No CATCH_ALL_TYPE.
11728 (build_exception_object_ref): New.
11729 (expand_end_java_handler): Update for except.h name changes.
11730 (emit_handlers, expand_resume_after_catch): Remove.
11731 * expr.c (java_lang_expand_expr): Update for except.h name changes.
11732 (process_jvm_instruction): Use build_exception_object_ref.
11733 * java-tree.h (JTI_SOFT_EXCEPTIONINFO_CALL_NODE): Remove.
11734 (soft_exceptioninfo_call_node): Remove.
11735 (build_exception_object_ref): Declare.
11736 * jcf-write.c (generate_bytecode_insns) [CALL_EXPR]: No
11737 soft_exceptioninfo_call_node. Move processing ...
11738 [EXC_PTR_EXPR]: ... here.
11739 * parse.h (BUILD_ASSIGN_EXCEPTION_INFO): Remove dead code.
11740 * parse.y (catch_clause_parameter): Use build_exception_object_ref.
11741 (source_end_java_method): No java_set_exception_lang_code or
11742 emit_handlers.
11743 (build_dot_class_method): Use build_exception_object_ref.
11744 (try_reference_assignconv): Check EXC_PTR_EXPR not
11745 soft_exceptioninfo_call_node.
11746
11747 2001-03-28 Richard Henderson <rth@redhat.com>
11748
11749 * java-tree.h (throw_node): Define as a single member of
11750 java_global_trees instead of a separate array.
11751 (JTI_THROW_NODE): New.
11752 * decl.c (throw_node): Don't declare.
11753 (init_decl_processing): Init a scalar throw_node.
11754 Don't register it for gc.
11755 * check-init.c (check_init): Reference scalar throw_node.
11756 * expr.c (build_java_athrow): Likewise.
11757 * jcf-write.c (generate_bytecode_insns): Likewise.
11758 * parse.h (BUILD_THROW): Likewise.
11759
11760 2001-03-28 Richard Henderson <rth@redhat.com>
11761
11762 * decl.c (end_java_method): Do not save and restore
11763 flag_non_call_exceptions.
11764 * parse.y (source_end_java_method): Likewise.
11765 * lang.c (flag_exceptions): Don't declare.
11766 (java_init_options): Set flag_non_call_exceptions. Set
11767 flag_exceptions here ...
11768 (java_init): ... not here.
11769
11770 2001-03-27 Richard Henderson <rth@redhat.com>
11771
11772 * expr.c, parse.h: Use USING_SJLJ_EXCEPTIONS instead of
11773 exceptions_via_longjmp.
11774
11775 * lang.c (flag_new_exceptions): Don't declare it.
11776 (java_init_options): Or set it.
11777
11778 2001-03-27 Richard Henderson <rth@redhat.com>
11779
11780 * decl.c (end_java_method): Rename asynchronous_exceptions to
11781 flag_non_call_exceptions.
11782 * parse.y (source_end_java_method): Likewise.
11783
11784 2001-03-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11785
11786 * Make-lang.in: Depend on $(SYSTEM_H), not system.h.
11787
11788 2001-03-26 Mark Mitchell <mark@codesourcery.com>
11789
11790 * parse.h (DECL_END_SOURCE_LINE): Don't rely on DECL_FRAME_SIZE.
11791
11792 2001-03-26 Alexandre Petit-Bianco <apbianco@redhat.com>
11793
11794 * parse.y (find_as_inner_class): Follow current package
11795 indications not to mistakingly load an unrelated class.
11796
11797 2001-03-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11798
11799 * constants.c (PUTN): Use memcpy, not bcopy.
11800
11801 * lex.c (java_read_char): Use memmove, not bcopy.
11802
11803 * parse.y (java_parser_context_resume): Use memcpy, not bcopy.
11804
11805 2001-03-23 Per Bothner <per@bothner.com>
11806
11807 * verify.c (verify_jvm_instructions): Replace 3 pop_type by POP_TYPE
11808 macro for better error pin-pointing.
11809 * java-tree.h: Fix typo in comment.
11810
11811 * jcf-write.c (generate_bytecode_insns): Changes to TRY_FINALLY_EXPR.
11812 Don't include jsr/goto in exception range.
11813 Check if start and end of exception range are the same (also TRY_EXPR).
11814 Don't emit jsr after try_block if CAN_COMPLETE_NORMALLY is false.
11815 However, do emit the following goto even if try_block is empty.
11816 Defer freeing exception_decl until after the finalizer, to make
11817 sure the local isn't reused in the finalizer. Fixes PR java/1208.
11818
11819 * parse.y (java_complete_lhs): If the try-clause is empty, just
11820 return the finally-clause and vice versa.
11821
11822 2001-03-23 Alexandre Petit-Bianco <apbianco@redhat.com>
11823
11824 * gcj.texi (Input Options): documented the check for attribute
11825 `gnu.gcc.gccj-compiled' and the `-fforce-classes-archive-check' flag.
11826 * java-tree.h (flag_force_classes_archive_check): Declared extern.
11827 * jcf-parse.c (HANDLE_GCJCOMPILED_ATTRIBUTE): New macro.
11828 (jcf_parse): Check for the right classes archive if necessary.
11829 * jcf-reader.c (get_attribute): Define `MATCH_ATTRIBUTE' and use it.
11830 (jcf_parse_fields): Fixed indentation.
11831 * jcf-write.c (append_gcj_attribute): New function.
11832 (generate_classfile): Compute the attribute count, invoke
11833 `append_gcj_attribute'.
11834 * jcf.h (typedef struct JCF): `seen_in_zip' and `java_source'
11835 turned into bit-fields. New bit-field `right_zip.'
11836 (JCF_ZERO): Set `right_zip' to zero.
11837 * lang-options.h (-fforce-classes-archive-check): Added flag.
11838 * lang.c (flag_force_classes_archive_check): New flag.
11839 (lang_f_options): New entry `force-classes-archive-check.'
11840 Fixes PR java/1213.
11841
11842 2001-02-07 Andrew Haley <aph@redhat.com>
11843
11844 * gcj.texi (Configure-time Options): Add -fcheck-references.
11845 * expr.c (build_java_indirect_ref): New function.
11846 (java_check_reference): New function.
11847 (build_java_array_length_access): Use build_java_indirect_ref to
11848 check for null references.
11849 (build_java_arrayaccess): Likewise.
11850 (build_get_class): Likewise.
11851 (build_field_ref): Likewise.
11852 (invoke_build_dtable): Likewise.
11853 (build_invokeinterface): Likewise.
11854 * lang.c (lang_f_options): Add flag_check_references.
11855 * jvspec.c (jvgenmain_spec): Add flag_check_references.
11856 * java-tree.h (flag_check_references): New variable.
11857 * lang.c (flag_check_references): Likewise.
11858 * parse.y (patch_invoke): Use java_check_reference.
11859 (patch_assignment): Allow for extra nesting in
11860 _Jv_CheckArrayStore.
11861
11862 2001-03-23 Bryce McKinlay <bryce@albatross.co.nz>
11863
11864 * gjavah.c (cxx_keywords): Update from the definitive list in cp/lex.c.
11865 * lex.c (cxx_keywords): Likewise.
11866
11867 2001-03-21 Alexandre Petit-Bianco <apbianco@redhat.com>
11868
11869 * parse.y (qualify_ambiguous_name): Broaden `length'
11870 recognition. Help MODIFY_EXPR be resolved as expression names.
11871 Fixes PR java/2066. Fixes PR java/2400.
11872
11873 2001-03-21 Bryce McKinlay <bryce@albatross.co.nz>
11874
11875 * gjavah.c (process_file): Mark interface definitions with
11876 "__attribute__ ((java_interface))".
11877
11878 2001-03-21 Alexandre Petit-Bianco <apbianco@redhat.com>
11879
11880 * class.c (layout_class): Fixed push_super_field's second
11881 argument. Fixes PR java/2333.
11882 (jdep_resolve_class): Reset TYPE_SIZE if `error_mark_node', it's
11883 too early to lay innerclasses out.
11884
11885 2001-03-20 Tom Tromey <tromey@redhat.com>
11886 Alexandre Petit-Bianco <apbianco@redhat.com>
11887
11888 * parse.y (patch_assignment): Handle the case of a SAVE_EXPR
11889 inside an array reference. Insertion of the array store check
11890 rewritten. Fixes PR java/2299.
11891
11892 2001-03-20 Tom Tromey <tromey@redhat.com>
11893
11894 * lex.c (java_read_unicode): Only accept leading `u's.
11895
11896 2001-03-20 Tom Tromey <tromey@redhat.com>
11897
11898 * jcf-parse.c (read_class): Initialize `class'.
11899
11900 2001-03-20 Matt Kraai <kraai@alumni.carnegiemellon.edu>
11901
11902 * jcf_parse.c (jcf_parse): Eliminate unused variable.
11903
11904 2001-03-19 Mark Mitchell <mark@codesourcery.com>
11905
11906 * class.c (build_class_ref): Use SET_DECL_ASSEMBLER_NAME.
11907 (layout_class): Likewise.
11908 (layout_class_method): Likewise.
11909 (emit_register_classes): Likewise.
11910 * decl.c (builtin_function): Likewise.
11911 (give_name_to_locals): Likewise.
11912
11913 2001-03-19 Per Bothner <per@bothner.com>
11914
11915 * jcf-parse.c (load_inner_classes): Check CLASS_LOADED_P
11916 before trying to load an inner class.
11917
11918 Fixes to process to command-line .class files in two passes.
11919 * java-tree.h (JAVA_FILE_P, CLASS_FILE_P, ZIP_FILE_P): New flags.
11920 (CLASS_FROM_CURRENTLY_COMPILED_SOURCE_P): Rename to ..
11921 (CLASS_FROM_CURRENTLY_COMPILED_P): ... because it is more general now.
11922 * class.c (is_compiled_class): Fix for renamed flag.
11923 * parse.y (maybe_create_class_interface_decl): Likewise.
11924 * jcf-parse.c (yyparse): Also set if compiling .class files.
11925 * jcf-parse.c (read_class); Read current_class.
11926 (jcf_parse): Make static.
11927 (load_inner_classes): New function, with code moved from jcf_parse,
11928 because we need to inner classes after the command-line files are read.
11929 (yyparse): Set finput to NULL when it doesn't need to be closed.
11930 Reduce use of main_jcf (basically only for archive) and
11931 use finput instead of main_jcf->read_state.
11932 Inline jcf_figure_file_type into yyparse.
11933 Set JAVA_FILE_P, CLASS_FILE_P, or ZIP_FILE_P on filename list name.
11934 Defer load_inner_classes and parse_class_file to a second pass,
11935 after we've correctly mapped command-line .clas fiels to classes.
11936 (jcf_figure_file_type): Removed.
11937 * jcf.h (JCF_ZIP, JCF_CLASS, JCF_SOURCE): Removed flags.
11938 (JCF_ZERO): Also clear zipd field.
11939 * zipfile.h: Conditionalize on JCF_H insread of JCF_ZIP.
11940
11941 2001-03-18 Matt Kraai <kraai@alumni.carnegiemellon.edu>
11942
11943 * jcf-parse.c (yyparse): Change ch from char * to char.
11944
11945 2001-03-19 Per Bothner <per@bothner.com>
11946
11947 * jvspec.c (lang_specific_driver): Check for .zip and .jar files.
11948 Add constructed filelist-file at end, following -xjava. Thus any .o
11949 and library files are not affected by the -xjava. Also wrap
11950 explicit @FILE with -xjava and -xnone.
11951
11952 2001-03-19 Andrew Haley <aph@cambridge.redhat.com>
11953
11954 * class.c (build_static_field_ref): Call make_decl_rtl() after
11955 setting the DECL_EXTERNAL flag.
11956
11957 2001-03-17 Per Bothner <per@bothner.com>
11958
11959 * decl.c (clear_binding_level): Fix initializer (broke 03-15).
11960
11961 * jcf-write.c (generate_bytecode_insns): Handle emitting iinc
11962 when result is is needed (target is STACK_TARGET).
11963
11964 * parse.h (JDEP_SOLV): Removed.
11965 * parse.y (register_incomplete_type): Use JDEP_TO_RESOLVE instead.
11966
11967 * parse.y (incomplete_class_list): Removed.
11968 (obtain_incomplete_type): Don't use or set incomplete_class_list.
11969 It doesn't work if resolve_class changes the name of an array type
11970 that is on the list and then someone else looks for the modified name.
11971 Also, seems liable to break when compiling multiple source files at
11972 once. So the simplest is to just remove incomplete_class_list -
11973 it is only a minor space win and it is not even clear it saves time.
11974
11975 * parse.y (resolve_class): Remove unneeded promote_type.
11976
11977 2001-03-15 Per Bothner <per@bothner.com>
11978
11979 * java-tree.h (BLOCK_IS_IMPLICIT): New flag.
11980 * parse.h (BLOCK_EXPR_ORIGIN): Removed macro.
11981 * parse.y (declare_local_variables, maybe_absorb_scoping_blocks):
11982 Use BLOCK_IS_IMPLICIT rather than BLOCK_EXPR_ORIGIN.
11983
11984 * jcf-parse.c (yyparse): Set/reset input_filename for source file.
11985 * parse.y (java_expand_classes): Likewise.
11986
11987 * parse.y (expand_start_java_method): Was only called once and had a
11988 misleading name, so inline in caller java_complete_expand_method.
11989 (enter_a_block): Likewise inline in enter_block and remove.
11990
11991 Remove junk from when gcc/java was created (by copying from C/C++).
11992 * decl.c (keep_next_level_flag, keep_next_if_subblocks): Remove.
11993 (struct binding_level): Remove fields keep, keep_if_subblocks,
11994 more_cleanups_ok, have_cleanups (which have never been used).
11995 (pushlevel, poplevel): Remove related useless code.
11996
11997 * class.c (make_class_data): The class_dtable_decl (i.e. the
11998 vtable for Class) should be external, except when compiling Class.
11999
12000 * jvspec.c (lang_specific_driver): Fix -C handling.
12001 Check -save-temps to see if temp @FILE should be deleted.
12002 Follow-up to/fix for February 16 patch.
12003
12004 * verify.c (verify_jvm_instructions): Better error msgs for dup.
12005 (type_stack_dup): Remove no-longer neded error check.
12006
12007 2001-03-15 Bryce McKinlay <bryce@albatross.co.nz>
12008
12009 * mangle.c (mangle_record_type): Rename 'from_pointer' argument
12010 to 'for_pointer'. If this type is for a pointer (argument) mangling,
12011 don't surround the element with 'N..E' if the type name is
12012 unqualified.
12013
12014 2001-03-14 Mark Mitchell <mark@codesourcery.com>
12015
12016 * class.c (build_static_field_ref): Use COPY_DECL_RTL,
12017 DECL_RTL_SET_P, etc.
12018 (make_method_value): Likewise.
12019 (get_dispatch_table): Likewise.
12020
12021 * decl.c (push_jvm_slot): Use COPY_DECL_RTL, DECL_RTL_SET_P, etc.
12022
12023 2001-03-07 Tom Tromey <tromey@redhat.com>
12024
12025 * config-lang.in (lang_requires): Define.
12026
12027 2001-03-07 Brad Lucier <lucier@math.purdue.edu>
12028
12029 * typeck.c (convert): Check flag_unsafe_math_optimizations,
12030 not flag_fast_math.
12031
12032 2001-03-05 Per Bothner <per@bothner.com>
12033
12034 Fix a problem where rest_of_decl_compilation applied to
12035 class_dtable_decl causes problems because it was done too early,
12036 before output file was opened.
12037 * decl.c (init_decl_processing): Remove init of class_dtable_decl.
12038 * class.c (class_dtable_decl): Add macro - element of class_roots.
12039 (make_class_data): Define class_dtable_decl.
12040 * java-tree.h (JTI_CLASS_DTABLE_DECL, class_dtable_decl): Removed.
12041
12042 2001-03-01 Zack Weinberg <zackw@stanford.edu>
12043
12044 * java/class.c, java/decl.c, java/java-tree.h: Replace all
12045 uses of 'boolean' with 'bool'.
12046
12047 2001-03-01 Zack Weinberg <zackw@stanford.edu>
12048
12049 * lang-specs.h: Add zero initializer for cpp_spec field to all
12050 array elements.
12051
12052 2001-02-16 Per Bothner <per@bothner.com>
12053
12054 Handle compiling multiple input files at once, and @FILE syntax.
12055 * gcj.texi: Updated documentation to match.
12056 * java-tree.h (flag_filelist_file, init_src_parse): New declarations.
12057 * jcf-parse.c (parse_source_file): Split into ...
12058 (parse_source_file_1): New function - and:
12059 (parse_source_file_2): New function.
12060 (yyparse): On -ffilelist-file, open and scan named file.
12061 On first pass over files, only do parse_source_file_1.
12062 A new second pass calls parse_source_file_2 for each file to compile.
12063 (init_jcf_parse): Call init_src_parse.
12064 * jvspec.c (INDIRECT_FILE_ARG): New flag.
12065 (lang_specific_driver): Support @FILELIST-FILE syntax, as well
12066 as multiple input file combined in one compilation.
12067 * lang-options.h: Add -ffilelist-file
12068 * lang.c (flag_filelist_file): New flag variable.
12069 (lang_f_options): Handle -ffilelist-file.
12070 * lex.c (java_init_lex): Don't clear ctxp->incomplete_class.
12071 * parse.h (struct parse_ctxt): Remove fields incomplete_class and
12072 gclass_list - use global fields of src_parse_roots instead.
12073 * parse.y (src_parse_roots): New array.
12074 (incomplete_class_list, gclass_list): New macros.
12075 (push_parser_context, java_pop_parser_context,
12076 java_parser_context_resume): Don't fiddle with deleted fields.
12077 (various): Use incomplete_class gclass_list and global macros
12078 instead of parse_ctxt fields - the lists are global.
12079 (init_src_parse): New function.
12080
12081 2001-02-23 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
12082
12083 * decl.c (set_block): Set NAMES and BLOCKS from BLOCK.
12084
12085 2001-02-20 Alexandre Petit-Bianco <apbianco@redhat.com>
12086
12087 * parse.y (check_inner_class_access): Moved declaration of local
12088 `enclosing_decl_type' to the right location.
12089
12090 2001-02-19 Bryce McKinlay <bryce@albatross.co.nz>
12091
12092 * parse.y (parser_check_super_interface): Don't call
12093 check_pkg_class_access for an inner interface.
12094 (parser_check_super): Don't call check_pkg_class_access for inner
12095 class.
12096 (do_resolve_class): Simplify enclosing type loop. Don't call
12097 check_pkg_class_access if CL and DECL are not set.
12098 (find_in_imports_on_demand): Set DECL if class_type needed to be
12099 loaded. Don't call check_pkg_class_access for an inner class.
12100 (check_inner_class_access): Rewritten to implement member access
12101 rules as per spec 6.6.1.
12102 (check_pkg_class_access): Handle the empty package correctly.
12103 (in_same_package): New function. Determine if two classes are in the
12104 same package.
12105
12106 2001-02-18 Bryce McKinlay <bryce@albatross.co.nz>
12107
12108 * typeck.c (build_java_array_type): Don't try to poke a public `clone'
12109 method into array types.
12110 * parse.y (patch_method_invocation): Bypass access check on clone call
12111 to array instance.
12112
12113 2001-02-15 Alexandre Petit-Bianco <apbianco@redhat.com>
12114
12115 * expr.c (build_instanceof): Check for arrays when trying fold to
12116 false.
12117
12118 2001-02-15 Jim Meyering <meyering@lucent.com>
12119
12120 * Make-lang.in (java.install-common): Depend on `installdirs'.
12121 (java.install-info): Likewise.
12122
12123 2001-02-15 Bryce McKinlay <bryce@albatross.co.nz>
12124
12125 * Make-lang.in (jvspec.o): Modify rule to match that of cp/g++spec.o.
12126
12127 2001-02-14 Tom Tromey <tromey@redhat.com>
12128 Alexandre Petit-Bianco <apbianco@cygnus.com>
12129
12130 Fix for PR java/1261.
12131 * typeck.c (build_java_array_type): Add public `clone' method to
12132 arrays.
12133 * parse.y (resolve_qualified_expression_name): Use current_class
12134 when checking for inaccessibility.
12135 (patch_method_invocation): Fixed error message when accessibility
12136 denied. Added `from_super' argument.
12137
12138 2001-02-14 Alexandre Petit-Bianco <apbianco@redhat.com>
12139
12140 * parse.y (resolve_class): Don't build a fake decl. Use the one
12141 already built.
12142 * typeck.c (build_java_array_type): Build and assign decl to array
12143 type.
12144
12145 2001-02-14 Alexandre Petit-Bianco <apbianco@redhat.com>
12146
12147 * parse.y (not_accessible_p): Changed leading comment. Added extra
12148 `where' argument. Use it to enforce protected access rules.
12149 (resolve_qualified_expression_name): Added extra argument to
12150 not_accessible_p.
12151 (patch_method_invocation): Use argument `primary' to provide
12152 not_accessible_p with an extra argument.
12153 (lookup_method_invoke): Added extra argument to not_accessible_p.
12154 (search_applicable_method_list): Likewise.
12155
12156 2001-02-13 Alexandre Petit-Bianco <apbianco@redhat.com>
12157
12158 * parse.y (resolve_qualified_expression_name): Try to resolve as
12159 an inner class access only if `decl' is a TYPE_DECL.
12160
12161 2001-02-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
12162
12163 * decl.c (classdollar_identifier_node): Initialize.
12164 * java-tree.h (enum java_tree_index): New entry
12165 `JTI_CLASSDOLLAR_IDENTIFIER_NODE.'
12166 (classdollar_identifier_node): New macro.
12167 (ID_CLASSDOLLAR_P): Likewise.
12168 * parse.y (build_dot_class_method): Use `classdollar_identifier_node.'
12169 (build_dot_class_method_invocation): Likewise.
12170 (find_applicable_accessible_methods_list): `class$' can't be
12171 inherited.
12172
12173 2001-02-09 Raja R Harinath <harinath@cs.umn.edu>
12174
12175 * Make-lang.in (java/mangle_name.o): Add 'make' prereqs.
12176
12177 2001-02-09 Alexandre Petit-Bianco <apbianco@redhat.com>
12178
12179 * Manke-lang.in (JVGENMAIN_OBJS): Added `errors.o'
12180 * jvgenmain.c (error): Reversed 2001-02-09 patch. `error' is now
12181 gone.
12182
12183 2001-02-09 Alexandre Petit-Bianco <apbianco@redhat.com>
12184
12185 * mangle_name (append_unicode_mangled_name): Emit `_' or `U'
12186 outside of the `__U' sequence too.
12187 (unicode_mangling_length): Count `_' or `U' outside of the `__U'
12188 sequence too.
12189
12190 2001-02-09 Alexandre Petit-Bianco <apbianco@redhat.com>
12191
12192 * jvgenmain.c (error): Reversed 2001-02-01 deletion.
12193
12194 2001-02-08 Alexandre Petit-Bianco <apbianco@cygnus.com>
12195
12196 * Make-lang.in (JAVA_OBJS): Added java/mangle_name.o
12197 (JVGENMAIN_OBJS): Likewise.
12198 * java-tree.h (append_gpp_mangled_name): New prototype.
12199 * jcf-parse.c (ggc_mark_jcf): Argument now `void *.'
12200 Removed cast calling `gcc_add_root.'
12201 * jvgenmain.c (mangle_obstack): New global, initialized.
12202 (main): Use it.
12203 (do_mangle_class): Constify local `ptr.'
12204 Removed macro `MANGLE_NAME.' Removed cast in `for.' Call
12205 append_gpp_mangle_name and update `count' if necessary.
12206 Use `mangle_obstack.'
12207 * mangle.c (append_unicode_mangled_name): Removed.
12208 (append_gpp_mangled_name): Likewise.
12209 (unicode_mangling_length): Likewise.
12210 (mangle_member_name): Return type set to `void.'
12211 (mangle_field_decl): Don't append `U' in escaped names.
12212 (mangle_method_decl): Likewise.
12213 (mangle_member_name): Just use `append_gpp_mangled_name.'
12214 * mangle_name.c: New file.
12215
12216 2001-02-07 Per Bothner <per@bothner.com>
12217
12218 * check-init.c (check_init): Fix TRY_FINALLY_EXPR logic.
12219
12220 * check-init.c (check_init): Don't call done_alternative after
12221 processing loop code, as a LOOP_EXPR never terminates normally.
12222
12223 2001-02-08 Joseph S. Myers <jsm28@cam.ac.uk>
12224
12225 * gcj.texi: Change sources.redhat.com reference to gcc.gnu.org.
12226
12227 2001-02-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
12228
12229 * jcf-parse.c (HANDLE_SYNTHETIC_ATTRIBUTE): Don't handle field
12230 DECLs.
12231
12232 2001-02-06 Tom Tromey <tromey@redhat.com>
12233
12234 * lex.c (java_new_lexer): Longer error message.
12235
12236 2001-02-05 Jeff Sturm <jeff.sturm@commerceone.com>
12237 Alexandre Petit-Bianco <apbianco@cygnus.com>
12238
12239 * typeck.c (build_prim_array_type): Added leading comment.
12240 (build_java_array_type): Moved locals out of
12241 block. Always create the `data' field, fixed alignment to match
12242 C++.
12243
12244 2001-02-04 Tom Tromey <tromey@redhat.com>
12245
12246 * expr.c (java_lang_expand_expr): Don't bother recomputing
12247 `length'. Use rest_of_decl_compilation, not make_decl_rtl.
12248 Fixes PR java/1866.
12249
12250 2001-02-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
12251
12252 * parse.y (process_imports): Save the original name of the import
12253 for better error report.
12254
12255 2001-02-04 Bryce McKinlay <bryce@albatross.co.nz>
12256
12257 * Make-lang.in (jvspec.o): Add DRIVER_DEFINES to the list
12258 of macros used when compiling jvspec.c.
12259 * jvspec.c (lang_specific_driver): Link with the shared
12260 libgcc by default.
12261
12262 2001-02-04 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
12263
12264 * check-init.c (check_init): Call internal_error instead of fatal.
12265 * expr.c (java_lang_expand_expr): Likewise.
12266 * jcf-parse.c (get_constant): Likewise.
12267 * mangle.c (java_mangle_decl): Likewise.
12268 * parse.y (make_nested_class_name, java_complete_lhs): Likewise.
12269 (operator_string): Likewise.
12270 * check-init.c (check_init): Call abort instead of fatal.
12271 * class.c (build_class_ref): Likewise.
12272 * constants.c (write_constant_pool): Likewise.
12273 * decl.c (start_java_method): Likewise.
12274 * expr.c (push_type, java_stack_pop, java_stack_swap): Likewise.
12275 (java_stack_dup, encode_newarray_type): Likewise.
12276 (build_java_array_length_access): Likewise.
12277 (build_java_check_indexed_type, expand_java_pushc): Likewise.
12278 (build_java_soft_divmod, build_invokeinterface): Likewise.
12279 * java-tree.h (INNER_CLASS_P): Likewise.
12280 * jcf-parse.c (parse_signature, get_name_constant): Likewise.
12281 (give_name_to_class, get_class_constant): Likewise.
12282 * jcf-write.c (CHECK_PUT, CHECK_OP, get_access_flags): Likewise.
12283 (find_constant_index, generate_bytecode_conditional): Likewise.
12284 (generate_bytecode_insns, perform_relocations): Likewise.
12285 * lex.c (java_unget_unicode, java_lex): Likewise.
12286 * mangle.c (mangle_type, mangle_record_type): Likewise.
12287 (mangle_pointer_type, mangle_array_type, init_mangling): Likewise.
12288 (finish_mangling): Likewise.
12289 * parse.h (MARK_FINAL_PARMS): Likewise.
12290 * parse.y (pop_current_osb, unreachable_stmt_error): Likewise.
12291 (obtain_incomplete_type, java_complete_class): Likewise.
12292 (java_check_regular_methods, java_complete_expand_method): Likewise.
12293 (cut_identifier_in_qualified, check_deprecation): Likewise.
12294 (patch_invoke, find_applicable_accessible_methods_list): Likewise.
12295 (java_complete_lhs, lookup_name_in_blocks): Likewise.
12296 (check_final_variable_indirect_assignment, build_unaryop): Likewise.
12297 * typeck.c (set_local_type, parse_signature_type): Likewise.
12298 (parse_signature_string, build_java_signature): Likewise;
12299 (set_java_signature): Likewise.
12300 * verify.c (type_stack_dup, CHECK_PC_IN_RANGE): Likewise.
12301 * class.c (add_method): Call fatal_error instead of fatal.
12302 (build_static_field_ref): Likewise.
12303 * expr.c (build_known_method_ref, expand_invoke): Likewise.
12304 * jcf-parse.c (get_constant, jcf_parse): Likewise.
12305 * lex.c (java_new_new_lexer): Likewise.
12306 * jv-scan.c (main): Likewise.
12307 (fatal_error): Renamed from fatal.
12308 * jcf-parse.c (yyparse): Call fatal_io_error instead of
12309 pfatal_with_name.
12310 * jcf-parse.c (jcf_parse_source): Call fatal_io_error, not fatal.
12311 (yyparse): Likewise.
12312 * jcf-write.c (make_class_file_name, write_classfile): Likewise.
12313 * lex.c (java_get_line_col): Likewise.
12314 * jcf-parse.c (load_class): Make errors non-fatal.
12315 * lex.c (byteswap_init, need_byteswap): Only #ifdef HAVE_ICONV.
12316
12317 2001-02-01 Bryce McKinlay <bryce@albatross.co.nz>
12318
12319 * jvgenmain.c (class_mangling_suffix): Remove unused string.
12320 (error): Remove unused function.
12321 (main): Don't use "__attribute__ alias" on generated class symbol.
12322
12323 2001-01-30 Alexandre Petit-Bianco <apbianco@cygnus.com>
12324
12325 * jcf-parse.c (init_jcf_parse): Added cast to ggc_add_root's last
12326 argument.
12327 * parse.y (finish_method_declaration): Code accounting for WFLed
12328 method DECL_NAMEs deleted.
12329 (check_abstract_method_definitions): Likewise.
12330 (resolve_type_during_patch): Layout resolved type.
12331 * typeck.c (lookup_do): Removed unused local.
12332
12333 2001-01-30 Bryce McKinlay <bryce@albatross.co.nz>
12334
12335 * java-tree.h: Remove JTI_INTEGER_NEGATIVE_ONE_NODE.
12336 * decl.c (init_decl_processing): Use integer_minus_one_node, not
12337 integer_negative_one_node.
12338 * expr.c (build_java_binop): Likewise.
12339
12340 2001-01-24 Jeff Sturm <jeff.sturm@commerceone.com>
12341
12342 * zextract.c (read_zip_archive): Read file_offset before writing
12343 zipd and consequently clobbering the header contents.
12344
12345 2001-01-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
12346
12347 * Make-lang.in: Remove all dependencies on defaults.h.
12348 * decl.c: Don't include defaults.h.
12349 * expr.c: Likewise.
12350 * parse.y: Likewise.
12351
12352 2001-01-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
12353
12354 * ChangeLog (2001-01-21): Fixed typo.
12355 * class.c (layout_class_method): Code accounting for WFLed
12356 method DECL_NAMEs deleted.
12357 * constant.c (find_methodref_index): Likewise.
12358 * decl.c (lang_mark_tree): Mark `wfl' field in struct lang_decl.
12359 * java-tree.h (DECL_FUNCTION_WFL): New macro.
12360 (struct lang_decl): New field `wfl'.
12361 (java_get_real_method_name): Prototype deleted.
12362 * mangle.c (mangle_method_decl): Code accounting for WFLed
12363 method DECL_NAMEs deleted.
12364 * parse.h (GET_METHOD_NAME): Macro deleted.
12365 * parse.y (reset_method_name): Deleted.
12366 (method_header): Set DECL_FUNCTION_WFL.
12367 (check_abstract_method_header): Code accounting for WFLed method
12368 DECL_NAMEs deleted.
12369 (java_get_real_method_name): Deleted.
12370 (check_method_redefinition): Code accounting for WFLed method
12371 DECL_NAMEs deleted. Use DECL_FUNCTION_WFL.
12372 (java_check_regular_methods): Likewise.
12373 (java_check_abstract_methods): Likewise.
12374 (java_expand_classes): Don't call `reset_method_name.'
12375 (search_applicable_method_list): Use DECL_NAMEs instead of
12376 GET_METHOD_NAME.
12377 * typeck.c (lookup_do): Code accounting for WFLed method
12378 DECL_NAMEs deleted.
12379
12380 2001-01-25 Richard Earnshaw <rearnsha@arm.com>
12381
12382 * lex.c (java_read_char): Check for EOF from getc first.
12383
12384 2001-01-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
12385
12386 * class.c (layout_class): Don't lay the superclass out if it's
12387 already being laid out.
12388 * jcf-parse.c (handle_innerclass_attribute): New function.
12389 (HANDLE_INNERCLASSES_ATTRIBUTE): Invoke
12390 handle_innerclasses_attribute.
12391 (jcf_parse): Don't load an innerclasses if it's already being
12392 laid out.
12393 * jcf-write.c (append_innerclass_attribute_entry): Static
12394 `anonymous_name' and its initialization deleted. `ocii' and `ini'
12395 to be zero for anonymous classes.
12396
12397 2001-01-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
12398
12399 * class.c (set_constant_value): Set DECL_FIELD_FINAL_IUD if
12400 necessary.
12401 * jcf-parse.c (set_source_filename): Use
12402 MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC if necessary.
12403
12404 2001-01-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
12405
12406 * expr.c (build_jni_stub): Set DECL_CONTEXT on `meth_var' so it
12407 gets a unique asm name.
12408
12409 2001-01-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
12410
12411 * jcf-parse.c (HANDLE_END_METHODS): Nullify current_method.
12412 (HANDLE_START_FIELD): Invoke MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC
12413 if necessary.
12414 (HANDLE_SYNTHETIC_ATTRIBUTE): New macro.
12415 * jcf-reader.c (get_attribute): Handle `Synthetic' attribute.
12416 * parse.y (lookup_package_type_and_set_next): Deleted.
12417 (resolve_package): Removed unnecessary code.
12418 (find_applicable_accessible_methods_list): `finit$' can't be
12419 inherited.
12420 * verify.c (pop_argument_types): Added missing prototype.
12421
12422 2001-01-23 Bryce McKinlay <bryce@albatross.co.nz>
12423
12424 * config-lang.in: Disable java by default.
12425
12426 2001-01-23 Tom Tromey <tromey@redhat.com>
12427
12428 * gcj.texi (Copying): New node.
12429 Added copyright information.
12430
12431 2001-01-21 Per Bothner <per@bothner.com>
12432
12433 Various fixes to allow compiling a compressed .jar/.zip archive.
12434 * zipfile.h (struct ZipFileCache): Replace by struct ZipFile.
12435 (struct ZipFile): Add fields name and next (from ZipFileCache).
12436 (struct ZipDirectory): New field zipf points to owning ZipFile.
12437 * jcf.h (struct ZipDirectory): Add forward declaration.
12438 (struct JCF): Declare zipd field to have type struct ZipDirectory.
12439 Remove seen_in_zip and zip_offset fields.
12440 (JCF_SEEN_IN_ZIP): New macro.
12441 * zextract.c (read_zip_archive): Set ZipDirectory's zipf field.
12442 * jcf-io.c: Change all ZipFileCache to ZipFile.
12443 (read_zip_member): New function.
12444 (open_in_zip): Call read_zip_member.
12445 * jcf-parse.c (find_in_current_zip): Remove function.
12446 (read_class): Merge in find_in_current_zip functionality.
12447 Call read_zip_member if needed.
12448 (parse_zip_file_entries): Use read_zip_member.
12449 (process_zip_dir): Update for removed and added JCF fields.
12450 (jcf_figure_file_type): Re-use, don't copy initial ZipFile struct.
12451
12452 2001-01-21 Per Bothner <per@bothner.com>
12453
12454 Minor optimization of static ggc roots.
12455 * jcf-parse.c (parse_roots): New static field.
12456 (current_field, current_method, current_file_list): Replace by macros
12457 naming fields of parse_roots.
12458 (init_jcf_parse): Combine 3 ggc_add_tree_root calls to 1.
12459 * class.c (class_roots): New static field.
12460 (registered_class, fields_ident, info_ident, class_list):
12461 New macros naming fields of parse_roots.
12462 (build_static_field_ref): Don't register roots here.
12463 (layout_class): Static field list replaced by macro class_list.
12464 (init_class_processing): Call ggc_add_tree_root for 4 roots.
12465 Initialize fields_ident and info_ident here.
12466
12467 2001-01-21 Per Bothner <per@bothner.com>
12468
12469 * jcf-parse.c (ggc_mark_jcf): New function.
12470 (init_jcf_parse): Register current_jcf as ggc root.
12471
12472 2001-01-21 Per Bothner <per@bothner.com>
12473
12474 * lang.c (put_decl_node): Print method's name.
12475
12476 2001-01-21 Per Bothner <per@bothner.com>
12477
12478 * verify.c (VERIFICATION_ERROR_WITH_INDEX): New macro.
12479 (verify_jvm_instructions): Use it, for better error messages on loads.
12480
12481 2001-01-21 Per Bothner <per@bothner.com>
12482
12483 * verify.c (merge_type_state): Still may have to merge even if
12484 LABEL_VERIFIED (label).
12485
12486 2001-01-21 Per Bothner <per@bothner.com>
12487
12488 * parse.y (method_header): Don't set the DECL_NAME of a FUNCTION_DECL
12489 to a EXPR_WITH_FILE_LOCATION - that is just too fragile and wrong.
12490
12491 2001-01-19 Per Bothner <per@bothner.com>
12492
12493 * expr.c (pop_type_0): Only return object_ptr_type_node on mismatch
12494 if expeting an interface type. Refines Tom's change of 2000-09-12.
12495
12496 2001-01-18 Per Bothner <per@bothner.com>
12497
12498 * gcj.texi (Input Options): Mention .java files.
12499
12500 2001-01-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
12501
12502 * lang-options.h (-Wunsupported-jdk11): Removed.
12503 * lang.c (flag_not_overriding): Deleted.
12504 (flag_static_local_jdk1_1): Likewise.
12505 (lang_W_options): Removed "unsupported-jdk11" entry.
12506 * parse.y (java_check_methods): Removed dead code.
12507
12508 2001-01-17 Tom Tromey <tromey@redhat.com>
12509
12510 Changes suggested by Per Bothner:
12511 * gcj.texi (Input Options): Don't mention input files.
12512 (Code Generation): Updated --main information.
12513 (Invoking jcf-dump): Mention that --javap is incomplete.
12514 From Alexandre Petit-Bianco:
12515 (Warnings): Don't mention -Wunsupported-jdk11.
12516 My stuff:
12517 (Compatibility): Mention JDK 1.2-ness of libraries.
12518 (Resources): Mention resources used when writing gcj.
12519
12520 2001-01-17 Tom Tromey <tromey@redhat.com>
12521
12522 * gcj.texi: New file.
12523 * Make-lang.in ($(srcdir)/java/gcj.info): New target.
12524 (java.info): Depend on gcj.info.
12525 (java/gcj.dvi): New target.
12526 (java.dvi): Depend on gcj.dvi.
12527 (java.install-info): Wrote.
12528
12529 2001-01-16 Jeff Sturm <jeff.sturm@appnet.com>
12530
12531 * expr.c (java_lang_expand_expr): Use TREE_SYMBOL_REFERENCED after
12532 having called make_decl_rtl.
12533
12534 2001-01-14 Per Bothner <per@bothner.com>
12535
12536 Various patches to emit better messages on verification errors.
12537 * expr.c (push_type_0): Return error indication on stack overflow,
12538 instead of callinfg fatal.
12539 (push_type): Now just call push_type_0 (nd fatal on overflow).
12540 (pop_type_0): Return detailed error message (in a char** argument).
12541 (pop_type): If pop_type_0 fails, print error message.
12542 (pop_argument_types): Moved to verify.c.
12543 * verify.c (pop_argument_types): Moved from expr.c.
12544 Return a (possible) error message, rather than void.
12545 (POP_TYPE, POP_TYPE_CONV, PUSH_TYPE, PUSH_PENDING): New macros.
12546 (verify_jvm_instruction): Use new macros, improving error messages.
12547 For case OPCODE_astore use object_ptr_type_node.
12548 * java-tree.h (TYPE_UNDERFLOW, TYPE_UNEXPECTED): New macros.
12549 (pop_type_0, push_type_0, pop_argument_types): Update accordingly.
12550
12551 * parse.y (java_complete_lhs case EXPR_WITH_FILE_LOCATION): If body is
12552 constant, return body without wrapper. (Improves constant folding.)
12553 * lex.c (build_wfl_node): Clear TREE_TYPE from returned node.
12554
12555 2001-01-13 Per Bothner <per@bothner.com>
12556
12557 * expr.c (expand_java_field_op): Assigning to a final field outside
12558 an initializer does not violate JVM spec, so should be warning, not
12559 error. (Sun's verifier does not complain - though MicroSoft's does.)
12560
12561 2001-01-12 Joseph S. Myers <jsm28@cam.ac.uk>
12562
12563 * gjavah.c (version), jcf-dump.c (version): Update copyright year
12564 to 2001.
12565
12566 2001-01-11 Bryce McKinlay <bryce@albatross.co.nz>
12567
12568 * parse.y (resolve_expression_name): Permit instance variables from
12569 enclosing context in super constructor call.
12570 (resolve_qualified_expression_name): Permit enclosing class's qualified
12571 "this" in super constructor call.
12572
12573 2001-01-10 Mark Mitchell <mark@codesourcery.com>
12574
12575 * class.c (build_utf8_ref): Remove last argument in call to
12576 make_decl_rtl; use make_function_rtl instead of make_decl_rtl.
12577 (build_class_ref): Likewise.
12578 (build_static_field_ref): Likewise.
12579 (get_dispatch_table): Likewise.
12580 (layout_class_method): Likewise.
12581 (emit_register_classes): Likewise.
12582 * constants.c (build_constant_data_ref): Likewise.
12583 * decl.c (builtin_function): Likewise.
12584 (create_primitive_vtable): Likewise.
12585 * expr.c (build_known_method_def): Likewise.
12586 (build_jni_stub): Likewise.
12587 (java_lang_expand_expr): Likewise.
12588
12589 2001-01-10 Tom Tromey <tromey@redhat.com>
12590
12591 * jvspec.c (jvgenmain_spec): Omit -fencoding from cc1 invocation.
12592
12593 2001-01-08 Alexandre Petit-Bianco <apbianco@cygnus.com>
12594
12595 * java-tree.h (lang_printable_name_wls): New prototype.
12596 * lang.c (put_decl_name): Removed dead code. Use DECL_CONTEXT
12597 rather than `current_class' to print type name. Don't prepend type
12598 names when printing constructor names.
12599 (lang_printable_name_wls): New function.
12600 * jcf-parse.c (jcf_parse_source): Pass NULL `file' argument to
12601 `build_expr_wfl', alway set EXPR_WFL_FILENAME_NODE.
12602 * parse.y (patch_method_invocation): Message tuned for constructors.
12603 (not_accessible_p): Grant `private' access from within
12604 enclosing contexts.
12605
12606 2001-01-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
12607
12608 All files with updated copyright when applicable.
12609 * Make-lang.in (JVGENMAIN_OBS): Removed java/mangle.o.
12610 * class.c (mangle_class_field): Function removed.
12611 (append_gpp_mangled_type, mangle_static_field, mangle_field): Likewise.
12612 (utf8_cmp, cxx_keyword_p): Moved to lex.c.
12613 (build_class_ref): Call `java_mangle_class_field' instead of
12614 `mangle_class_field.'
12615 (build_dtable_decl): Rewritten to call `java_mangle_vtable.'
12616 (layout_class): Call `java_mangle_decl' instead of
12617 `mangle_static_field.'
12618 (cxx_keywords): Initialized static array moved to `lex.c.'
12619 (layout_class_method): Changed leading comment. Simplified to
12620 call `java_mangle_decl.' Local `ptr' moved in for loop body.
12621 * decl.c (lang_mark_tree): Mark field `package_list.'
12622 * java-tree.h (TYPE_PACKAGE_LIST): New macro.
12623 (struct lang_type): New field `package_list.'
12624 (unicode_mangling_length): Prototype removed.
12625 (append_gpp_mangled_name, append_gpp_mangled_classtype,
12626 emit_unicode_mangled_name): Likewise.
12627 (cxx_keyword_p): New prototype.
12628 (java_mangle_decl, java_mangle_class_field,
12629 java_mangle_class_field_from_string, java_mangle_vtable): Likewise.
12630 * jcf-parse.c (jcf_parse_source): Constify `file' argument to
12631 `build_expr_wfl.'
12632 * jvgenmain.c (main_method_prefix): Global variable removed.
12633 (main_method_suffix): Likewise.
12634 (do_mangle_classname): New function.
12635 (main): Call it. Format changed to accommodate new mangling scheme.
12636 * lex.c: (utf8_cmp): Conditionally prototyped.
12637 (cxx_keywords): Moved from class.c, conditionally defined.
12638 (utf8_cmp, cxx_keyword_p): Likewise.
12639 * mangle.c (obstack.h, ggc.h): Included.
12640 (mangle_field_decl): New function.
12641 (mangle_method_decl, mangle_type, mangle_pointer_type,
12642 mangle_array_type, mangle_record_type,
12643 find_compression_pointer_match, find_compression_array_match,
12644 find_compression_record_match,
12645 find_compression_array_template_match, set_type_package_list,
12646 entry_match_pointer_p, emit_compression_string, init_mangling,
12647 finish_mangling, compression_table_add, mangle_member_name): Likewise.
12648 (mangle_obstack): New global.
12649 (MANGLE_RAW_STRING): New macro.
12650 (unicode_mangling_length): Turned static.
12651 (append_unicode_mangled_name): Renamed from
12652 `emit_unicode_mangled_name.' Turned static. `mangle_obstack'
12653 replaces `obstack', removed from the parameter list.
12654 (append_gpp_mangled_name): Turned static. `mangle_obstack'
12655 replaces parameter `obstack', removed from the parameter list. Call
12656 `append_unicode_mangled_name' instead of `emit_unicode_mangled_name.
12657 (append_gpp_mangled_classtype): Removed.
12658 (compression_table, compression_next): New static variables.
12659 * parse.y (temporary_obstack): Extern declaration removed.
12660
12661 2001-01-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
12662
12663 * parse.y (patch_binop): Compute missing type in error situations.
12664
12665 2001-01-05 Bryce McKinlay <bryce@albatross.co.nz>
12666
12667 * class.c (make_class_data): Push initial value for "arrayclass".
12668 * decl.c (init_decl_processing): Add new class field "arrayclass".
12669
12670 2001-01-05 Bryce McKinlay <bryce@albatross.co.nz>
12671
12672 From patha@softlab.ericsson.se:
12673 * parse.y (switch_label): Use build, not build1, to construct
12674 DEFAULT_EXPR.
12675
12676 2001-01-04 Neil Booth <neil@daikokuya.demon.co.uk>
12677
12678 * lang.c (lang_decode_option): Change -MA to -MP.
12679 * jcf-depend.c (jcf_dependency_add_target, jcf_dependency_set_target):
12680 Update to new prototype; do quote targets.
12681 (jcf_dependency_write): Update.
12682
12683 2000-12-22 Bryce McKinlay <bryce@albatross.co.nz>
12684
12685 Shorten primitive array allocation path:
12686 * decl.c (init_decl_processing): Use _Jv_NewPrimArray not _Jv_NewArray
12687 to create new primitive arrays.
12688 * expr.c (build_newarray): If generating native code, call
12689 soft_newarray_node with a reference to the primitive TYPE identifier
12690 instead of type_value.
12691
12692 2000-12-17 Bryce McKinlay <bryce@albatross.co.nz>
12693
12694 Fix for PRs gcj/312 and gcj/253:
12695 * parse.y (valid_ref_assignconv_cast_p): Load classes for source and
12696 dest if they arn't already.
12697 * class.c (layout_class): Call maybe_layout_super_class on
12698 superinterfaces also, but only if compiling from bytecode.
12699
12700 Fix for PR gcj/373:
12701 * parse.y (create_class): Set ACC_STATIC if class is declared in an
12702 interface.
12703
12704 2000-12-15 Tom Tromey <tromey@redhat.com>
12705
12706 * jcf-parse.c (jcf_parse_source): Set wfl_operator if not already
12707 set.
12708
12709 2000-12-14 Andrew Haley <aph@redhat.com>
12710
12711 * boehm.c (mark_reference_fields): Change test to correctly detect
12712 bitmap overflow.
12713
12714 2000-12-15 Andreas Jaeger <aj@suse.de>
12715
12716 * config-lang.in (lang_dirs): Added.
12717
12718 2000-12-15 Alexandre Petit-Bianco <apbianco@cygnus.com>
12719
12720 * parse.y (end_artificial_method_body): Fixed undefined behavior.
12721 Credits go to rth for finding it.
12722
12723 2000-12-13 Mike Stump <mrs@wrs.com>
12724
12725 * parse.y (check_static_final_variable_assignment_flag): Fix spelling.
12726
12727 2000-11-07 Tom Tromey <tromey@cygnus.com>
12728
12729 * Make-lang.in (JAVA_LEX_C): Added chartables.h.
12730 * lex.c (java_ignorable_control_p): Removed.
12731 (java_letter_or_digit_p): Removed.
12732 (java_start_char_p): New function.
12733 (java_read_char): Return `int', not `unicode_t'. Changed
12734 callers.
12735 (java_read_unicode): Likewise.
12736 (java_read_unicode_collapsing_terminators): Likewise.
12737 (java_get_unicode): Likewise.
12738 (java_new_lexer): Initialize hit_eof.
12739 (java_parse_end_comment): Take `int' argument.
12740 (java_parse_doc_section): Likewise.
12741 (java_parse_escape_sequence): Don't allow backlash-newline.
12742 Return `int'.
12743 * lex.h (JAVA_DIGIT_P): Removed.
12744 (_JAVA_LETTER_OR_DIGIT_P): Removed.
12745 (_JAVA_IDENTIFIER_IGNORABLE): Removed.
12746 (JAVA_START_CHAR_P): Renamed from JAVA_ID_CHAR_P.
12747 (JAVA_PART_CHAR_P): New macro.
12748 (UEOF): Now -1.
12749 (JAVA_CHAR_ERROR): Now -2.
12750 (java_lexer): New field `hit_eof'.
12751 * chartables.h: New file.
12752 * gen-table.pl: new file.
12753
12754 2000-11-20 Tom Tromey <tromey@cygnus.com>
12755 Alexandre Petit-Bianco <apbianco@cygnus.com>
12756
12757 * parse.y (java_complete_lhs): Only allow compound assignment of
12758 reference type if type is String.
12759
12760 2000-12-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
12761
12762 * Make-lang.in (java/jcf-path.o:): libgcj.jar replaces libgcj.zip.
12763 jcf-path.c: Likewise.
12764
12765 2000-12-09 Anthony Green <green@redhat.com>
12766
12767 * zipfile.h (ZipDirectory): Declare size, uncompressed_size,
12768 filestart and filename_length as int values.
12769
12770 2000-12-07 Mo DeJong <mdejong@redhat.com>
12771
12772 * jcf-io.c (find_class): Correct the logic that tests to see if a
12773 .java file is newer than its .class file. The compiler was
12774 incorrectly printing a warning when file mod times were equal.
12775
12776 2000-12-07 Zack Weinberg <zack@wolery.stanford.edu>
12777
12778 * jvgenmain.c: Use ISPRINT not isascii.
12779
12780 2000-12-06 Alexandre Petit-Bianco <apbianco@cygnus.com>
12781
12782 * parse.y (end_artificial_method_body): Fixed typo.
12783
12784 2000-12-04 Alexandre Petit-Bianco <apbianco@cygnus.com>
12785
12786 * parse.y (patch_method_invocation): Pick the correct enclosing
12787 context when creating inner class instances.
12788 Fixes gcj/332.
12789
12790 2000-11-26 Joseph S. Myers <jsm28@cam.ac.uk>
12791
12792 * gjavah.c (version), jcf-dump.c (version), jv-scan.c (version):
12793 Update copyright year to 2000.
12794
12795 2000-11-23 Anthony Green <green@redhat.com>
12796
12797 * jcf-parse.c (init_jcf_parse): Register current_file_list root.
12798 Move current_file_list out of yyparse and make it static.
12799
12800 * expr.c: Declare quick_stack and tree_list_free_list as static
12801 (init_expr_processing): Register quick_stack and
12802 tree_list_free_list roots.
12803
12804 2000-11-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
12805
12806 * parse.y (build_outer_field_access): New local `decl_ctx', use
12807 it. Check for field's context and current class immediate outer
12808 context inheritance.
12809 (outer_field_access_p): Consider fields inherited from the last
12810 enclosing context.
12811 (build_access_to_thisn): Stop at the last enclosing context if
12812 necessary.
12813 Fixes gcj/367.
12814
12815 2000-11-23 J"orn Rennecke <amylaar@redhat.com>
12816
12817 * Make-lang.in (jvspec.o): Depend on $(CONFIG_H).
12818
12819 2000-11-22 Bryce McKinlay <bryce@albatross.co.nz>
12820
12821 * jcf-parse.c (get_constant): Call UT8_CHAR_LENGTH on `utf8', not the
12822 scratch buffer.
12823
12824 2000-11-20 Tom Tromey <tromey@cygnus.com>
12825
12826 * jv-scan.c (help): Document --complexity.
12827 (options): Added --complexity.
12828 (flag_complexity): New global.
12829 (main): Call `report'.
12830 * parse-scan.y (complexity): New global.
12831 (if_then_statement, if_then_else_statement,
12832 if_then_else_statement_nsi, switch_block_statement_group,
12833 while_expression, do_statement, for_begin, continue_statement,
12834 throw_statement, catch_clause, finally, method_invocation,
12835 conditional_and_expression, conditional_or_expression,
12836 conditional_expression): Update complexity.
12837 (reset_report): Reset complexity.
12838 (report): New function.
12839
12840 2000-11-20 Tom Tromey <tromey@cygnus.com>
12841
12842 * lex.c (yylex): Added STRICT_TK case.
12843 * parse.y (STRICT_TK): Added.
12844 * parse-scan.y (STRICT_TK): Added.
12845 * Make-lang.in ($(srcdir)/java/keyword.h): Added missing `\' and
12846 `;'. Use 4, not 3, with -k option. Correctly rename resulting
12847 file.
12848 * keyword.h: Rebuilt.
12849 * keyword.gperf (strictfp): Added.
12850
12851 2000-11-20 Tom Tromey <tromey@cygnus.com>
12852
12853 * lex.c (yylex): Recognize floating point constants with leading
12854 0.
12855
12856 2000-11-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
12857
12858 * java-tree.h (cyclic_inheritance_report): Constify.
12859 * parse.y (cyclic_inheritance_report): Likewise.
12860
12861 2000-11-17 Zack Weinberg <zack@wolery.stanford.edu>
12862
12863 * parse.y (goal): Remove call to ggc_add_string_root.
12864
12865 2000-11-16 Zack Weinberg <zack@wolery.stanford.edu>
12866
12867 * jcf-parse.c (get_constant), parse.y (do_merge_string_cste):
12868 Create string in scratch buffer, then pass to build_string.
12869
12870 2000-11-13 Joseph S. Myers <jsm28@cam.ac.uk>
12871
12872 * parse.y (issue_warning_error_from_context): Add
12873 ATTRIBUTE_PRINTF.
12874
12875 2000-11-11 Anthony Green <green@redhat.com>
12876
12877 * jcf-parse.c (process_zip_dir): Add finput parameter.
12878 (jcf_figure_file_type): Call process_zip_dir with appropriate
12879 argument.
12880
12881 2000-11-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
12882
12883 * decl.c (copy_lang_decl): Use memcpy, not bcopy.
12884 * jcf-parse.c (jcf_figure_file_type): Likewise.
12885
12886 2000-11-09 Joseph S. Myers <jsm28@cam.ac.uk>
12887
12888 * parse.y (create_new_parser_context): Use memset () instead of
12889 bzero ().
12890
12891 2000-11-08 Tom Tromey <tromey@cygnus.com>
12892
12893 * gjavah.c (process_file): Only include gcj/cni.h when generating
12894 CNI stubs.
12895
12896 2000-11-07 Joseph S. Myers <jsm28@cam.ac.uk>
12897
12898 * expr.c (note_instructions), jcf-io.c (find_class), jcf-parse.c
12899 (init_outgoing_cpool), lex.c (java_init_lex): Use memset ()
12900 instead of bzero ().
12901
12902 2000-11-05 Tom Tromey <tromey@cygnus.com>
12903
12904 * lex.h (JAVA_FLOAT_RANGE_ERROR): Typo fix.
12905 * lex.c (IS_ZERO): New define.
12906 (java_perform_atof): Error on floating point underflow.
12907
12908 2000-11-04 Tom Tromey <tromey@cygnus.com>
12909
12910 * lex.c (java_parse_escape_sequence): Only read two octal
12911 characters if the first one is greater than 3. Don't allow
12912 "octal" numbers to include the digits 8 or 9.
12913
12914 2000-11-05 Joseph S. Myers <jsm28@cam.ac.uk>
12915
12916 * Make-lang.in (java.distdir): Remove.
12917
12918 2000-11-03 Tom Tromey <tromey@cygnus.com>
12919
12920 * Make-lang.in (java.dvi): New target.
12921 Partial fix for PR other/567.
12922
12923 * lang-options.h: Mention -Wout-of-date.
12924 * jcf-dump.c (flag_newer): New global.
12925 * gjavah.c (flag_newer): New global.
12926 * jcf-io.c (find_class): Only warn when flag_newer set.
12927 * lang.c (flag_newer): New global.
12928 (struct string_option): New declaration.
12929 (lang_W_options): New global.
12930 (process_option_with_no): New function.
12931 (lang_decode_option): Use it.
12932
12933 * class.c (cxx_keyword_p): Accept keywords with trailing `$'s.
12934 * gjavah.c (cxx_keyword_subst): Handle any number of trailing
12935 `$'.
12936
12937 * lex.h (_JAVA_IDENTIFIER_IGNORABLE): New macro.
12938 (JAVA_ID_CHAR_P): Also try java_ignorable_control_p.
12939 * lex.c (java_read_unicode): Removed `term_context' argument.
12940 Recognize any number of `u' in `\u'.
12941 (java_read_unicode_collapsing_terminators): New function.
12942 (java_get_unicode): Use it.
12943 (java_lineterminator): Removed.
12944 (yylex): Produce error if character literal is newline or single
12945 quote. Return if eof found in middle of `//' comment. EOF in
12946 `//' comment is only an error if pedantic.
12947 (java_ignorable_control_p): New function.
12948 (java_parse_end_comment): Return if eof found in middle of
12949 comment.
12950 Include flags.h.
12951 * jv-scan.c (pedantic): New global.
12952
12953 2000-10-31 Alexandre Petit-Bianco <apbianco@cygnus.com>
12954
12955 * parse.y (outer_field_access_p): Inherited fields aren't
12956 consider outer fields.
12957 (maybe_build_thisn_access_method): Use
12958 PURE_INNER_CLASS_TYPE_P instead of INNER_CLASS_TYPE_P.
12959 (resolve_expression_name): Trigger an error if a static field
12960 is being accessed as an outer field.
12961
12962 2000-10-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
12963
12964 * Make-lang.in (LIBGCJ_ZIP_FILE): Define with `$(prefix)'.
12965 Fixes gcj/365.
12966
12967 2000-10-27 Zack Weinberg <zack@wolery.stanford.edu>
12968
12969 * Make-lang.in: Move all build rules here from Makefile.in,
12970 adapt to new context. Wrap all rules that change the current
12971 directory in parentheses. Expunge all references to $(P).
12972 When one command depends on another and they're run all at
12973 once, use && to separate them, not ;. Add OUTPUT_OPTION to
12974 all object-file generation rules. Delete obsolete variables.
12975
12976 * Makefile.in: Delete.
12977 * config-lang.in: Delete outputs= line.
12978
12979 2000-10-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
12980
12981 * parse.y (patch_method_invocation): NULLify this_arg when already
12982 inserted.
12983 (maybe_use_access_method): Handle call to methods unrelated to the
12984 current class. Fixed comment.
12985 Fixes gcj/361.
12986
12987 2000-10-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
12988
12989 * parse.h (INNER_ENCLOSING_SCOPE_CHECK): Check inherited type in
12990 scope.
12991
12992 2000-10-24 Tom Tromey <tromey@cygnus.com>
12993
12994 * lex.c (java_new_lexer): Initialize new fields. Work around
12995 broken iconv() implementations.
12996 (java_read_char): Swap bytes if required. Use fallback decoder if
12997 required.
12998 (byteswap_init, need_byteswap): New globals.
12999 (java_destroy_lexer): Only close iconv handle if it is in use.
13000 * lex.h (java_lexer): New fields read_anything, byte_swap,
13001 use_fallback.
13002 Made out_buffer unsigned.
13003
13004 2000-10-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
13005
13006 * parse.y (register_incomplete_type): Include JDEP_FIELD as a case
13007 where an enclosing context can be set on the jdep.
13008 (do_resolve_class): Fixed identation.
13009
13010 2000-10-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
13011
13012 * gjavah.c (NEED_PEEK_ATTRIBUTE, NEED_SKIP_ATTRIBUTE): Define
13013
13014 * jcf-reader.c (peek_attribute, skip_attribute): Only define
13015 when requested.
13016
13017 * parse.h (yyerror): If JC1_LITE, mark with ATTRIBUTE_NORETURN.
13018
13019 * verify.c (CHECK_PC_IN_RANGE): Cast result of stmt-expr to void.
13020
13021 2000-10-18 Alexandre Petit-Bianco <apbianco@cygnus.com>
13022
13023 * jcf-write.c (OP1): Update `last_bc'.
13024 (struct jcf_block): Fixed indentation and typo in comments. New
13025 field `last_bc'.
13026 (generate_bytecode_insns): Insert `nop' if `jsr' immediately
13027 follows `monitorenter'.
13028 * parse.y (patch_synchronized_statement): New local `tmp'. Call
13029 `patch_string'.
13030 Fixes gcj/232.
13031
13032 2000-10-16 Tom Tromey <tromey@cygnus.com>
13033
13034 * jvspec.c (lang_specific_driver): Recognize -MF and -MT.
13035 * lang-specs.h: Added %{MA}, %{MF*}, %{MT*}.
13036 * lang-options.h: Added -MA, -MT, -MF..
13037 * lang.c (lang_decode_option): Recognize -MA, -MT, -MF.
13038 (DEPEND_TARGET_SET): New macro.
13039 (DEPEND_FILE_ALREADY_SET): Likewise.
13040 (init_parse): Handle new flags.
13041 * jcf.h (jcf_dependency_print_dummies): Declare.
13042 * Make-lang.in (s-java): Added mkdeps.o.
13043 * Makefile.in (BACKEND): Added mkdeps.o.
13044 (../gcjh$(exeext)): Added mkdeps.o.
13045 (../jcf-dump$(exeext)): Added mkdeps.o.
13046 * jcf-depend.c: Include mkdeps.h.
13047 (struct entry, dependencies, targets, MAX_OUTPUT_COLUMNS,
13048 add_entry): Removed.
13049 (jcf_dependency_reset): Rewrote.
13050 (dependencies): New global.
13051 (jcf_dependency_set_target): Rewrote.
13052 (jcf_dependency_add_target): Likewise.
13053 (jcf_dependency_add_file): Likewise.
13054 (munge): Removed.
13055 (print_ents): Removed.
13056 (jcf_dependency_write): Rewrote.
13057 (print_dummies): New global.
13058 (jcf_dependency_print_dummies): New function
13059 (jcf_dependency_write): Call deps_dummy_targets if required.
13060
13061 2000-10-18 Alexandre Petit-Bianco <apbianco@cygnus.com>
13062
13063 * gjavah.c (add_class_decl): Removed unused variables `tname',
13064 `tlen' and `name_index'.
13065 * java-tree.h (BUILD_FILENAME_IDENTIFIER_NODE): New macro.
13066 * jcf-parse.c (jcf_parse_source): Use it and set EXPR_WFL_FILENAME
13067 in `wfl_operator' with value.
13068 (yyparse): Use BUILD_FILENAME_IDENTIFIER_NODE.
13069 (jcf_figure_file_type): Fixed identation.
13070 * lex.c (java_get_line_col): Use EOF. Tuned `^' placement.
13071 * parse.y (analyze_clinit_body): New function.
13072 (static_initializer:): Reset `current_static_block'.
13073 (java_parser_context_restore_global): Set EXPR_WFL_FIILENAME_NODE in
13074 `wfl_operator' with new value.
13075 (lookup_cl): Use EXPR_WFL_FILENAME.
13076 (maybe_yank_clinit): Handle bogus <clinit> bodies, call
13077 analyze_clinit_body.
13078 (build_outer_field_access): Access to this$<n> built from
13079 current_class, not its outer context.
13080 (build_access_to_thisn): Fixed leading comment. Tidied things up.
13081 (resolve_qualified_expression_name): Handle `T.this' and `T.this.f()'.
13082 (patch_method_invocation): Use `is_static_flag' when already
13083 initialized.
13084 (patch_newarray): Removed assignment in ternary operator.
13085
13086 2000-10-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
13087
13088 * except.c (free_eh_ranges): Don't free `whole_range'.
13089
13090 2000-10-15 Anthony Green <green@redhat.com>
13091
13092 * decl.c (init_decl_processing): Call init_class_processing before
13093 anything else.
13094
13095 2000-10-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
13096
13097 * check-init.c (check_init): Fixed leading comment. Use
13098 LOCAL_FINAL_P.
13099 * decl.c (push_jvm_slot): Use MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC.
13100 (give_name_to_locals): Likewise.
13101 (lang_mark_tree): Handle FIELD_DECL. Register `am' and `wfl'
13102 fields in lang_decl_var.
13103 * java-tree.h (DECL_FUNCTION_SYNTHETIC_CTOR,
13104 DECL_FUNCTION_ALL_FINAL_INITIALIZED): New macros.
13105 (FIELD_INNER_ACCESS): Removed ugly cast, macro rewritten.
13106 (FIELD_INNER_ACCESS_P, DECL_FIELD_FINAL_IUD, DECL_FIELD_FINAL_LIIC,
13107 DECL_FIELD_FINAL_IERR, DECL_FIELD_FINAL_WFL): New macros.
13108 (LOCAL_FINAL): Rewritten.
13109 (LOCAL_FINAL_P, FINAL_VARIABLE_P, CLASS_FINAL_VARIABLE_P
13110 MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC): New macros.
13111 (struct lang_decl): Fixed comments. Added `synthetic_ctor' and
13112 `init_final' fields.
13113 (struct lang_decl_var): Fixed leading comment. Added `am', `wfl',
13114 `final_uid', `final_liic', `final_ierr' and `local_final' fields.
13115 (TYPE_HAS_FINAL_VARIABLE): New macro.
13116 (struct lang_type): Added `afv' field.
13117 * parse.y (check_static_final_variable_assignment_flag): New function.
13118 (reset_static_final_variable_assignment_flag): Likewise.
13119 (check_final_variable_local_assignment_flag): Likewise.
13120 (reset_final_variable_local_assignment_flag): Likewise.
13121 (check_final_variable_indirect_assignment): Likewise.
13122 (check_final_variable_global_assignment_flag): Likewise.
13123 (add_inner_class_fields): Use LOCAL_FINAL_P.
13124 (register_fields): Handle local finals and final variables.
13125 (craft_constructor): Set DECL_FUNCTION_SYNTHETIC_CTOR.
13126 (declare_local_variables): Call MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC.
13127 (source_start_java_method): Call MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC
13128 on local finals.
13129 (java_complete_expand_methods): Loop to set
13130 TYPE_HAS_FINAL_VARIABLE. Call
13131 `reset_final_variable_local_assignment_flag' and
13132 `check_final_variable_local_assignment_flag' accordingly before
13133 and after constructor expansion. Call
13134 `reset_static_final_variable_assignment_flag'
13135 before expanding <clinit> and after call
13136 `check_static_final_variable_assignment_flag' if the
13137 current_class isn't an interface. After all methods have been
13138 expanded, call `check_final_variable_global_assignment_flag' and
13139 `check_static_final_variable_assignment_flag' if the current class
13140 is an interface.
13141 (maybe_yank_clinit): Fixed typo in comment.
13142 (build_outer_field_access_methods): Removed old sanity check. Use
13143 FIELD_INNER_ACCESS_P. Call MAYBE_CREATE_VAR_LANG_DECL_SPECIFIC.
13144 Don't create access methods for finals.
13145 (resolve_field_access): Use `CLASS_FINAL_VARIABLE_P'.
13146 (java_complete_tree): Likewise. Reset DECL_FIELD_FINAL_IUD if
13147 existing DECL_INIT has been processed.
13148 (java_complete_lhs): Likewise.
13149 (check_final_assignment): Filter input on `lvalue''s TREE_CODE.
13150 Test for COMPONENT_REF to get to the FIELD_DECL. Implemented new
13151 logic.
13152 (patch_assignment): Use LOCAL_FINAL_P.
13153 (fold_constant_for_init): Reset DECL_FIELD_FINAL_IUD if
13154 DECL_INITIAL is nullified.
13155 Fixes gcj/163.
13156
13157 2000-10-13 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
13158
13159 * Make-lang.in (parse.c, parse-scan.c): Create atomically.
13160
13161 * Makefile.in (parse.c, parse-scan.c): Likewise.
13162
13163 2000-10-12 Mark Mitchell <mark@codesourcery.com>
13164
13165 * class.c (temporary_obstack): Remove.
13166 (make_class): Don't mess with obstascks.
13167 (push_class): Likewise.
13168 (set_super_info): Likewise.
13169 (add_method_1): Likewise.
13170 (add_method): Likewise.
13171 (add_field): Likewise.
13172 (build_utf8_ref): Likewise.
13173 (build_class_ref): Likewise.
13174 (build_static_field_ref): Likewise.
13175 (finish_class): Likewise.
13176 (push_super_field): Likewise.
13177 (layout_class): Likewise.
13178 (layout_class_methods): Likewise.
13179 (init_class_processing): Likewise.
13180 * constants.c (get_tag_node): Likewise.
13181 (build_constant_data_ref): Likewise.
13182 * decl.c (ggc_p): Remove.
13183 (copy_lang_decl): Use ggc_alloc.
13184 (complete_start_java_method): Don't mess with obstacks.
13185 (start_java_method): Likewise.
13186 (end_java_method): Likewise.
13187 * except.c (link_handler): Use xmalloc.
13188 (free_eh_ranges): New function.
13189 (method_init_exceptions): Use it.
13190 (add_handler): Use xmalloc.
13191 (expand_start_java_handler): Don't mess with obstacks.
13192 (prepare_eh_table_type): Likewise.
13193 (expand_end_java_handler): Likewise.
13194 * expr.c (push_value): Likewise.
13195 (create_label_decl): Likewise.
13196 (build_jni_stub): Likewise.
13197 (java_lang_expand_expr): Likewise.
13198 (note_instructions): Use xrealloc.
13199 (java_push_constant_from_pool): Don't mess with obstacks.
13200 (process_jvm_instruction): Likewise.
13201 * java-tree.h (cyclic_inheritance_report): Remove duplicate
13202 declaration.
13203 * jcf-parse.c (get_constant): Don't mess with obstacks.
13204 (read_class): Likewise.
13205 (jcf_parse): Likewise.
13206 * lex.c (expression_obstack): Remove.
13207 (java_lex): Don't use obstack_free.
13208 * parse.h (exit_java_complete_class): Don't mess with obstacks.
13209 (MANGLE_OUTER_LOCAL_VARIABLE_NAME): Adjust.
13210 (MANGLE_ALIAS_INITIALIZER_PARAMETER_NAME_ID): Likewise.
13211 (MANGLE_ALIAS_INITIALIZER_PARAMETER_NAME_STRING): Likewise.
13212 * parse.y (gaol): Add more GC roots.
13213 (add_inner_class_fields): Adjust calls to MANGLE_* macros.
13214 (lookup_field_wrapper): Likewise.
13215 (obtain_incomplete_type): Don't mess with obstacks.
13216 (build_alias_initializer_parameter_list): Adjust calls to MANGLE_*
13217 macros.
13218 (craft_constructor): Don't mess with obstacks.
13219 (safe_layout_class): Likewise.
13220 (java_complete_class): Likewise.
13221 (source_end_java_method): Likewise.
13222 (build_outer_field_access_methods): Likewise.
13223 (build_outer_method_access_method): Likewise.
13224 (maybe_build_thisn_access_method): Likewise.
13225 (build_dot_class_method_invocation): Likewise.
13226 (java_complete_tree): Likewise.
13227 (java_complete_lhs): Likewise.
13228 (do_merge_string_cste): Likewise.
13229 (patch_string_cst): Likewise.
13230 (array_constructor_check_entry): Likewise.
13231 * typeck.c (build_java_array_type): Likewise.
13232 (parse_signature_string): Likewise.
13233 (build_java_signature): Likewise.
13234
13235 2000-10-12 Tom Tromey <tromey@cygnus.com>
13236
13237 Fix for PR gcj/356:
13238 * gjavah.c (add_class_decl): Don't special-case inner classes.
13239 (add_namelet): Likewise.
13240
13241 2000-10-11 Rodney Brown <RodneyBrown@mynd.com>
13242
13243 * java-tree.h: Constify current_encoding.
13244 * lang.c: Constify current_encoding.
13245
13246 2000-10-10 Jeff Sturm <jeff.sturm@appnet.com>
13247
13248 * jvgenmain.c (class_mangling_suffix): Omit `.'.
13249 (main): Use `$' when NO_DOLLAR_IN_LABEL is not set, otherwise `.'.
13250
13251 2000-10-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
13252
13253 * expr.c (java_lang_expand_expr): Reinstall 1999-08-14 Anthony's
13254 patch. Fixes gcj/340.
13255
13256 2000-10-10 Tom Tromey <tromey@cygnus.com>
13257
13258 * lex.c (java_new_lexer): Initialize out_first and out_last
13259 fields.
13260 * lex.h (java_lexer): Added out_buffer, out_first, out_last.
13261
13262 2000-10-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
13263
13264 * parse.y (pop_current_osb): New function.
13265 (array_type:): Use `dims:', changed actions
13266 accordingly. Suggested by Anthony Green.
13267 (array_creation_expression:): Used pop_current_osb.
13268 (cast_expression:): Likewise.
13269 (search_applicable_method_list): Fixed indentation.
13270
13271 2000-10-08 Anthony Green <green@redhat.com>
13272
13273 * parse.y (array_type_literal): Remove production.
13274 (type_literals): Refer to array_type, not array_type_literal.
13275
13276 2000-10-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
13277
13278 Patch contributed by Corey Minyard.
13279 * decl.c (check_local_named_variable): New function.
13280 (tree check_local_unnamed_variable): Likewise.
13281 (find_local_variable): Splitted. Call check_local_{un}named_variable.
13282
13283 2000-10-07 Anthony Green <green@redhat.com>
13284
13285 * class.c (layout_class): Handle case where superclass can't be
13286 layed out yet.
13287
13288 2000-10-07 Joseph S. Myers <jsm28@cam.ac.uk>
13289
13290 * Makefile.in (keyword.h): Refer to GNU FTP site for updated
13291 gperf.
13292
13293 2000-10-05 Tom Tromey <tromey@cygnus.com>
13294
13295 * jvspec.c (jvgenmain_spec): Added `-fdollars-in-identifiers'.
13296 * jvgenmain.c (class_mangling_prefix): Removed.
13297 (class_mangling_suffix): New global.
13298 (main): Use it.
13299 * gjavah.c (cxx_keyword_subst): Mangle C++ keywords by appending
13300 `$'.
13301 (print_method_info): Handle overrides for static and final
13302 methods.
13303 (process_file): Generate declaration for class object field.
13304 * class.c (cxx_keywords): New array.
13305 (utf8_cmp): New function.
13306 (cxx_keyword_p): New function.
13307 (layout_class_method): Mangle C++ keywords by appending `$'.
13308 (mangle_field): New function.
13309 (mangle_class_field): Use mangle_field. Mangle class name as
13310 `class$'.
13311 (mangle_static_field): Use mangle_field.
13312
13313 2000-10-03 Alexandre Petit-Bianco <apbianco@cygnus.com>
13314
13315 * decl.c (find_local_variable): Removed uncessary type check and
13316 fixed range check typo. From Corey Minyard.
13317
13318 2000-09-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
13319
13320 * decl.c (give_name_to_locals): New local `code_offset'. Call
13321 `maybe_adjust_start_pc'.
13322 * expr.c (note_instructions): New function.
13323 (expand_byte_code): Don't collect insn starts here.
13324 (peek_opcode_at_pc): New function.
13325 (maybe_adjust_start_pc): Likewise.
13326 * java-tree.h (maybe_adjust_start_pc): Declare.
13327 (note_instructions): Likewise.
13328 * jcf-parse.c (parse_class_file): Call `note_instructions'.
13329
13330 2000-09-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
13331
13332 * parse.y (field_access:): Fixed indentation.
13333 (qualify_ambiguous_name): Properly qualify `this.a[b].c'.
13334
13335 2000-09-07 Tom Tromey <tromey@cygnus.com>
13336
13337 Fix for PR gcj/307:
13338 * parse.y (patch_binop): Use JNUMERIC_TYPE_P, not
13339 JPRIMITIVE_TYPE_P, for arithmetic operators.
13340 (patch_method_invocation): Indentation fix.
13341 (try_builtin_assignconv): Handle boolean specially. Fixed typo.
13342 (valid_builtin_assignconv_identity_widening_p): Handle boolean.
13343 (do_unary_numeric_promotion): Cleaned up code.
13344 (valid_cast_to_p): Handle boolean correctly.
13345
13346 2000-09-27 Tom Tromey <tromey@cygnus.com>
13347
13348 * lex.c (java_read_unicode): Reset bs_count when finished with
13349 `\u' sequence.
13350
13351 2000-10-01 Mark Mitchell <mark@codesourcery.com>
13352
13353 Convert to GC.
13354 * Make-lang.in (s-java): Don't depend on ggc-callbacks.o.
13355 * Makefile.in (BACKEND): Don't include ggc-callbacks.o.
13356 (typeck.o): Depend on ggc.h.
13357 * class.c (add_method_1): Use GC functions for allocation.
13358 (init_class_processing): Register roots.
13359 * decl.c (ggc_p): Set to 1.
13360 (pending_local_decls): Make it static.
13361 (push_jvm_slot): Use GC functions for allocation.
13362 (init_decl_processing): Register roots.
13363 (give_name_to_locals): Use GC functions for allocation.
13364 (lang_mark_tree): New function.
13365 * java-tree.h (MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC): Use GC
13366 functions for allocation.
13367 * jcf-parse.c (jcf_parse_source): Use ggc_strdup.
13368 * lex.c (java_lex): Use build_string, rather than replicating it
13369 inline.
13370 * parse.y (goal): Add more roots.
13371 (mark_parser_ctxt): New function.
13372 * typeck.c: Include ggc.h.
13373
13374 2000-09-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
13375
13376 * parse.y (maybe_yank_clinit): Also keep <clinit> if its body
13377 contains something else than MODIFY_EXPR.
13378
13379 2000-09-23 Mark Mitchell <mark@codesourcery.com>
13380
13381 * Make-lang.in (JAVA_SRCS): Include java-tree.h.
13382 * Makefile.in (parse.o): Depend on ggc.h.
13383 (class.o): Likewise.
13384 (constants.o): Likewise.
13385 (decl.o): Likewise.
13386 (expr.o): Likewise.
13387 (jcf-parse.o): Likewise.
13388 (jcf-write.o): Likewise.
13389 (mangle.o): Likewise.
13390 * class.c: Include ggc.h.
13391 (build_static_field_ref): Register GC roots.
13392 (layout_class): Likewise.
13393 (init_class_processing): Likewise.
13394 * constants.c: Include ggc.h.
13395 (current_constant_pool_data_ref): Remove.
13396 (tag_nodes): Move it to ...
13397 (get_tag_node): ... here. Register GC roots.
13398 * decl.c: Include ggc.h. Remove many global tree definitions.
13399 (throw_node): Define.
13400 (java_global_trees): Likewise.
13401 (predef_filenames): Make the size a constant.
13402 (init_decl_processing): Adjust accordingly.
13403 (init_decl_processing): Call init_jcf_parse. Register GC roots.
13404 * expr.c: Include ggc.h.
13405 (init_expr_processing): Register GC roots.
13406 (build_invokeinterface): Likewise.
13407 * java-tree.h: Replace extern tree declarations with macros.
13408 (java_global_trees): New variable.
13409 (java_tree_index): New enumeration.
13410 (init_jcf_parse): Declare.
13411 * jcf-parse.c: Include ggc.h.
13412 (current_class): Remove declaration.
13413 (main_class): Likewise.
13414 (all_class_list): Likewise.
13415 (predefined_filename_p): Adjust for constant size of
13416 predef_filenames.
13417 (init_jcf_parse): New function.
13418 * jcf-write.c: Include ggc.h.
13419 (generate_classfile): Register GC roots.
13420 (append_synthetic_attribute): Likewise.
13421 (append_innerclass_attribute_entry): Likewise.
13422 * lang.c: Include ggc.h.
13423 (lang_print_error): Register GC roots.
13424 * parse.h (struct parser_ctxt): Rename fields to avoid conflicts
13425 with macros.
13426 * parse.y: Include ggc.h.
13427 (wfl_operator): Remove.
13428 (goal): Register GC roots.
13429 (java_pop_parser_context): Adjust for new field names.
13430 (java_parser_context_save_global): Likewse.
13431 (java_parser_context_restore_global): Likewise.
13432 (java_parser_context_suspend): Likewise.
13433 (java_parser_context_resume): Likewise.
13434 (verify_constructor_circularity): Register GC roots.
13435 (lookup_cl): Likewise.
13436 (java_reorder_fields): Likewise.
13437 (build_current_this): Likewise.
13438 (class_in_current_package): Likewise.
13439 (argument_types_convertible): Likewise.
13440 (patch_cast): Rename wfl_op parameter to avoid macro conflicts.
13441
13442 2000-09-14 Tom Tromey <tromey@cygnus.com>
13443
13444 * lex.h: Use HAVE_ICONV_H, not HAVE_ICONV.
13445
13446 2000-09-13 Tom Tromey <tromey@cygnus.com>
13447
13448 * jcf-parse.c: Include <locale.h>.
13449 * jv-scan.c: Include <locale.h>.
13450
13451 2000-09-12 Tom Tromey <tromey@cygnus.com>
13452
13453 * expr.c (pop_type_0): Return `Object' if trying to merge two
13454 interface types.
13455 * verify.c (merge_types): Don't return `TYPE_UNKNOWN' for
13456 interface types; `Object' is always a valid supertype.
13457
13458 2000-09-12 Tom Tromey <tromey@cygnus.com>
13459
13460 Fix for PR gcj/33:
13461 * jv-scan.c (help): Document --encoding.
13462 (options): Added `encoding' entry.
13463 (OPT_ENCODING): New define.
13464 (main): Handle --encoding.
13465 Include <langinfo.h> if nl_langinfo exists.
13466 * lang-options.h: Document --classpath, --CLASSPATH, --main, and
13467 --encoding.
13468 * jcf-parse.c Include <langinfo.h> if we have nl_langinfo.
13469 (parse_source_file): Correctly call java_init_lex. Added `finput'
13470 argument. Use nl_langinfo to determine default encoding.
13471 * java-tree.h (current_encoding): Declare.
13472 * parse.y (java_parser_context_restore_global): Don't restore
13473 `finput'.
13474 (java_parser_context_save_global): Don't set `finput' field.
13475 (java_pop_parser_context): Don't restore `finput'. Free old lexer
13476 if required.
13477 * lang.c (current_encoding): New global.
13478 (lang_decode_option): Recognize `-fencoding='.
13479 (finish_parse): Don't close finput.
13480 * parse.h (struct parser_ctxt): Removed `finput' and
13481 `unget_utf8_value' fields. Added `lexer' field.
13482 (java_init_lex): Fixed declaration.
13483 * lex.c (java_new_lexer): New function.
13484 (java_destroy_lexer): Likewise.
13485 (java_read_char): Added `lex' argument. Handle iconv case.
13486 (java_read_unicode): Added `lex' argument. Count backslashes in
13487 lexer structure.
13488 (java_init_lex): Added `finput' and `encoding' arguments. Set
13489 `lexer' field in ctxp.
13490 (BAD_UTF8_VALUE): Removed.
13491 (java_lex): Handle seeing UEOF in the middle of a string literal.
13492 * lex.h: Include <iconv.h> if HAVE_ICONV defined.
13493 (java_lexer): New structure.
13494 (UNGETC): Removed.
13495 (GETC): Removed.
13496 (DEFAULT_ENCODING): New define.
13497 (java_destroy_lexer): Declare.
13498
13499 2000-09-12 Tom Tromey <tromey@cygnus.com>
13500
13501 Fix for PR gcj/343:
13502 * lex.c (java_init_lex): Initialize java_io_serializable.
13503 * parse.y (java_io_serializable): New global.
13504 (valid_ref_assignconv_cast_p): An array can be cast to
13505 serializable.
13506
13507 2000-09-10 Zack Weinberg <zack@wolery.cumb.org>
13508
13509 * decl.c, expr.c: Include defaults.h if not already included.
13510 Don't define the *_TYPE_SIZE macros.
13511
13512 2000-09-09 Geoffrey Keating <geoffk@cygnus.com>
13513
13514 * typeck.c (build_java_array_type): Correct first parameter
13515 in ADJUST_FIELD_ALIGN invocation.
13516
13517 2000-09-06 Tom Tromey <tromey@cygnus.com>
13518
13519 * lang-specs.h: Also recognize `-femit-class-files'.
13520
13521 2000-09-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
13522
13523 * verify.c (merge_types): Load the types to merge if necessary.
13524
13525 2000-09-02 Anthony Green <green@redhat.com>
13526
13527 * jcf-io.c: Include zlib.h.
13528 (open_in_zip): Read compressed class file archives.
13529 * zipfile.h (ZipDirectory): Add uncompressed_size and
13530 compression_method fields.
13531 * zextract.c (read_zip_archive): Collect file compression info.
13532
13533 2000-08-15 Bryce McKinlay <bryce@albatross.co.nz>
13534
13535 * parse.y (do_resolve_class): Also explore superclasses of
13536 intermediate enclosing contexts when searching for inner classes.
13537
13538 2000-08-11 Alexandre Petit-Bianco <apbianco@cygnus.com>
13539
13540 * parse.y (variable_declarator_id:): Better error message.
13541 (expression_statement:): Use YYNOT_TWICE.
13542 (cast_expression:): Likewise.
13543 (assignment:): Likewise.
13544
13545 2000-08-11 Alexandre Petit-Bianco <apbianco@cygnus.com>
13546
13547 * parse.y (do_merge_string_cste): New locals. Create new
13548 STRING_CSTs each time, use memcpy. Fixes gcj/311.
13549
13550 2000-08-07 Hans Boehm <boehm@acm.org>
13551
13552 * boehm.c (mark_reference_fields): Set marking bits for all words in
13553 a multiple-word record.
13554 (get_boehm_type_descriptor): Use the procedure marking descriptor for
13555 java.lang.Class.
13556
13557 2000-08-31 Mike Stump <mrs@wrs.com>
13558
13559 * Make-lang.in (jc1$(exeext), gcjh$(exeext), jv-scan$(exeext),
13560 jcf-dump$(exeext)): Make parallel safe.
13561
13562 2000-08-29 Zack Weinberg <zack@wolery.cumb.org>
13563
13564 * jcf-parse.c (set_source_filename): Constify a char *.
13565 * jcf-write.c (append_innerclasses_attribute,
13566 make_class_file_name): Constify a char *. Don't recycle a
13567 variable for an unrelated purpose.
13568 * parse.y: (build_alias_initializer_parameter_list): Constify a char *.
13569 (breakdown_qualified): Do not modify IDENTIFIER_POINTER strings.
13570
13571 2000-08-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
13572
13573 * expr.c (can_widen_reference_to): Fixed indentation.
13574 * java-tree.h (CLASS_METHOD_CHECKED_P): Added leading comment.
13575 * parse.y: `finit$' replaces `$finit$' in comments.
13576 (try_builtin_assignconv): Fixed leading comment.
13577
13578 2000-08-25 Greg McGary <greg@mcgary.org>
13579
13580 * gjavah.c (cxx_keyword_subst): Use ARRAY_SIZE.
13581
13582 2000-08-24 Greg McGary <greg@mcgary.org>
13583
13584 * lang.c (lang_decode_option): Use ARRAY_SIZE.
13585 * parse.y (BINOP_LOOKUP): Likewise.
13586
13587 2000-08-22 Andrew Haley <aph@cygnus.com>
13588
13589 * javaop.h (WORD_TO_INT): Mask lower 32 bits of a jword before
13590 sign extending. Fixes gcj/321.
13591 * jcf-parse.c (get_constant): Mask lower 32 bits of a jint before
13592 combining to make a jlong. Fixes gcj/321.
13593
13594 2000-08-21 Nix <nix@esperi.demon.co.uk>
13595
13596 * lang-specs.h: Do not process -o or run the assembler if
13597 -fsyntax-only.
13598
13599 2000-08-16 Andrew Haley <aph@cygnus.com>
13600
13601 * typeck.c (build_java_array_type): Rewrite code to do array
13602 alignment. Take into account back-end macros when aligning array
13603 data. Remove setting of TYPE_USER_ALIGN; Java doesn't allow the
13604 user to set alignment. Fixes gcj/252 and 160.
13605
13606 2000-08-09 Tom Tromey <tromey@cygnus.com>
13607
13608 * parse.y (check_abstract_method_definitions): Now return `int'.
13609 Check implemented interfaces. Fixes PR gcj/305.
13610
13611 * parse.y (patch_switch_statement): Disallow `long' in switch
13612 expressions. Fixes PR gcj/310.
13613
13614 2000-08-15 Alexandre Petit-Bianco <apbianco@cygnus.com>
13615
13616 * decl.c (finit_leg_identifier_node): New global.
13617 (init_decl_processing): Use `finit$' to initialize
13618 finit_identifier_node. Use `$finit$' to initialize
13619 finit_leg_identifier_node.
13620 * expr.c (expand_java_field_op): Use ID_FINIT_P.
13621 * java-tree.h (finit_identifier_node): Changed attached comment.
13622 (finit_leg_identifier_node): New declaration.
13623 (ID_FINIT_P): Take finit_identifier_node and
13624 finit_leg_identifier_node into account. This is a backward
13625 compatibility hack.
13626
13627 2000-08-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
13628
13629 * jcf-write.c (generate_bytecode_conditional): Re-installed lost
13630 Jan 6 2000 patch.
13631 (generate_bytecode_insns): Check `nargs' before emitting it.
13632 * verify.c (merge_type_state): Fixed typo.
13633 * ChangeLog: Fixed typo in some jcf-write.c entries mentioning
13634 generate_bytecode_{conditional,insns}.
13635
13636 2000-08-13 Anthony Green <green@redhat.com>
13637
13638 * check-init.c (check_init): Add case for BIT_FIELD_REF (required
13639 for -pg builds).
13640
13641 2000-08-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
13642
13643 * class.c (maybe_layout_super_class): Fixed indentation.
13644 * java-tree.h (CLASS_METHOD_CHECKED_P): New macro.
13645 (java_check_methods): New function declaration.
13646 * jcf-parse.c (get_constant): Let `char_len' go up to 3. Use `str'
13647 instead of `str_ptr'.
13648 * jcf-write.c (generate_bytecode_insns): Emit number the of args
13649 of a `invokeinterface' at the right time.
13650 * parse.h (WFL_STRIP_BRACKET): New macro.
13651 (SET_TYPE_FOR_RESOLUTION): Use it.
13652 * parse.y (build_unresolved_array_type): Reuse `type_or_wfl'.
13653 (check_class_interface_creation): Don't check for cross package
13654 innerclass name clashes.
13655 (method_header): Behave properly if MDECL is `error_mark_node'.
13656 (method_declarator): Return `error_mark_node' if bogus current
13657 class.
13658 (resolve_class): Apply WFL_STRIP_BRACKET on `cl' if necessary.
13659 (resolve_and_layout): New local `decl_type', set and used. Call
13660 java_check_methods.
13661 (java_check_methods): New method.
13662 (java_layout_classes): Use it.
13663 (resolve_qualified_expression_name): No EH check necessary in
13664 access$<n>.
13665 (java_complete_lhs): Use VAR_DECL's DECL_INITIAL when evaluating
13666 `case' statement.
13667 (patch_assignment): Set DECL_INITIAL on integral final local.
13668
13669 2000-08-08 Alexandre Petit-Bianco <apbianco@cygnus.com>
13670
13671 * java-tree.h (flag_extraneous_semicolon): New extern.
13672 * lang-options.h: (-Wextraneous-semicolon): New option.
13673 * lang.c (flag_redundant): Fixed typo in leading comment.
13674 (flag_extraneous_semicolon): New global.
13675 (lang_decode_option): Set `flag_extraneous_semicolon' when
13676 -Wall. Decode `-Wextraneous-semicolon'.
13677 * parse.y (type_declaration:): Removed `SC_TK' hack, added
13678 `empty_statement' rule.
13679 (class_body_declaration): Likewise.
13680 (method_body:): Accept `;' as a method body.
13681 (static_initializer:): Removed `SC_TK' hack.
13682 (constructor_block_end:): Likewise.
13683 (empty_statement:): Report deprecated empty declaration. Fixes
13684 gcj/295
13685
13686 2000-08-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
13687
13688 * parse.y (build_dot_class_method_invocation): Changed parameter
13689 name to `type'. Build signature from `type' and convert it to a
13690 STRING_CST if it's an array.
13691 (patch_incomplete_class_ref): `build_dot_class_method_invocation'
13692 to use `ref_type' directly.
13693
13694 2000-08-06 Ovidiu Predescu <ovidiu@cup.hp.com>
13695
13696 * lang-options.h: Added a comma after the last element to avoid
13697 syntax errors when other languages define additional options.
13698
13699 2000-08-04 Zack Weinberg <zack@wolery.cumb.org>
13700
13701 * Make-lang.in (jc1, jv-scan): Depend on $(BACKEND), not stamp-objlist.
13702 * Makefile.in: Add BACKEND; delete OBJS, OBJDEPS.
13703 (jc1): Link with $(BACKEND).
13704 (jv-scan): Depend on version.o, not all of $(OBJS) or $(BACKEND).
13705
13706 2000-08-02 Zack Weinberg <zack@wolery.cumb.org>
13707
13708 * jvspec.c: Adjust type of second argument to
13709 lang_specific_driver, and update code as necessary.
13710
13711 * class.c (build_dtable_decl): Initialize dummy.
13712
13713 2000-08-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
13714
13715 * parse.y (maybe_yank_clinit): When generating bytecode: non empty
13716 method bodies not to rule out discarding `<clinit>'; don't use
13717 <clinit> to initialize static fields with constant initializers.
13718
13719 2000-08-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
13720
13721 * gjavah.c (print_method_info): Added `synth' parameter. Skip
13722 synthetic methods.
13723 (method_synthetic): New global.
13724 (HANDLE_METHOD): Recognize synthetic method and tell
13725 `print_method_info' about it.
13726 (HANDLE_END_METHOD): Do not issue an additional `;\n' if we're
13727 processing a synthetic method.
13728 * jcf-reader.c (skip_attribute): New function.
13729 ( skip_attribute): Likewise.
13730
13731 2000-08-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
13732
13733 * parse.y (build_outer_field_access): Fixed comments.
13734 (fix_constructors): Emit the initialization of this$<n> before
13735 calling $finit$.
13736 (resolve_qualified_expression_name): Build an access to `decl' if
13737 necessary.
13738
13739 2000-07-31 Alexandre Petit-Bianco <apbianco@cygnus.com>
13740
13741 * parse-scan.y (curent_class): Non longer const.
13742 (inner_qualifier, inner_qualifier_length): Deleted.
13743 (current_class_length): New global.
13744 (bracket_count): Fixed typo in leading comment.
13745 (anonymous_count): New global.
13746 (class_instance_creation_expression:): Handle anonymous classes.
13747 (anonymous_class_creation:): New rule.
13748 (push_class_context): Rewritten.
13749 (pop_class_context): Likewise.
13750 (INNER_QUALIFIER): Macro deleted.
13751 (report_class_declaration): call `push_class_context' when
13752 entering the function. `fprintf' format modified not to use
13753 INNER_QUALIFIER.
13754 (report_class_declaration): Assign `package_name' and
13755 `current_class' to NULL separately.
13756
13757 2000-07-31 Alexandre Petit-Bianco <apbianco@cygnus.com>
13758
13759 * expr.c (build_invokeinterface): Call layout_class_methods on
13760 target interface.
13761
13762 2000-07-27 Tom Tromey <tromey@cygnus.com>
13763 Anthony Green <green@cygnus.com>
13764 Alexandre Petit-Bianco <apbianco@cygnus.com>
13765
13766 * class.c (make_class_data): Create vtable for abstract classes.
13767 (get_dispatch_table): Changed to cope with abstract classes.
13768
13769 2000-07-27 Tom Tromey <tromey@cygnus.com>
13770
13771 * parse.y (patch_method_invocation): Don't reverse the argument
13772 list when dealing with anonymous class constructors. Fixed typo in
13773 comment.
13774
13775 2000-07-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
13776
13777 * parse.y (build_alias_initializer_parameter_list): Reverse
13778 crafted list when building aliases for anonymous class
13779 constructors.
13780
13781 2000-07-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
13782
13783 * parse.y (jdep_resolve_class): Don't bother checking potential
13784 innerclass access if `decl' is NULL.
13785 (find_in_imports_on_demand): TREE_PURPOSE of `import' contains the
13786 WFL.
13787
13788 2000-07-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
13789
13790 * parse.c: Remove (again.)
13791
13792 2000-07-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
13793
13794 * parse.y (find_as_inner_class): Removed 2000-07-19 patches.
13795 * jcf-parse.c (HANDLE_INNERCLASSES_ATTRIBUTE): Local `decl' moved
13796 outside the `if' statement, alias to innerclass removed, `decl'
13797 used to mark the class complete.
13798
13799 2000-07-21 Alexandre Petit-Bianco <apbianco@cygnus.com>
13800
13801 * parse.y (simple_name:): Fixed typo in error message.
13802
13803 2000-07-21 Alexandre Petit-Bianco <apbianco@cygnus.com>
13804
13805 * parse.y (java_complete_lhs): LOOP_EXPR:, SWITCH_EXPR: the node
13806 or its first operand can be error marks.
13807
13808 2000-07-20 Alexandre Petit-Bianco <apbianco@cygnus.com>
13809
13810 * parse.h (SET_TYPE_FOR_RESOLUTION): Use GET_CPC.
13811 * parse.y (method_header): Likewise.
13812
13813 2000-07-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
13814
13815 * parse.y (process_imports): Consider that one might be trying to
13816 import an innerclass. Fixes gcj/254
13817
13818 2000-07-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
13819
13820 * parse.y (find_as_inner_class): Handle the case where the
13821 enclosing context of an innerclass has been loaded as bytecode.
13822
13823 2000-07-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
13824
13825 * parse.y (simple_name:): Reject `$' in type names.
13826 (resolve_type_during_patch): Use `type' as a second
13827 argument to resolve_no_layout. Fixes gcj/257.
13828
13829 2000-07-18 Bryce McKinlay <bryce@albatross.co.nz>
13830
13831 * parse.y (find_most_specific_methods_list): Select the only
13832 non-abstract method even if max has been set.
13833 Fixes gcj/285, gcj/298.
13834
13835 2000-07-18 Jeff Sturm <jeff.sturm@appnet.com>
13836
13837 * lang-specs.h: Added %(jc1) to java compiler options.
13838
13839 2000-07-14 Zack Weinberg <zack@wolery.cumb.org>
13840
13841 * .cvsignore: New file.
13842
13843 2000-07-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
13844
13845 * parse.y (not_accessible_p): Access granted to innerclasses
13846 (indirectly) extending the reference type. Fixes gcj/249.
13847
13848 2000-07-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
13849
13850 * parse.y (patch_method_invocation): Fixed comment.
13851 (maybe_use_access_method): Build this$<n>s to the context of the
13852 target method, or a type that extends it. Fixes gcj/242.
13853
13854 2000-07-13 Mark Mitchell <mark@codesourcery.com>
13855
13856 * parse.c: Remove.
13857
13858 2000-07-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
13859
13860 * parse.y (fold_constant_for_init): Avoid bullish conversion.
13861
13862 2000-07-13 Tom Tromey <tromey@cygnus.com>
13863
13864 * lang-specs.h: Added %{I*}.
13865
13866 2000-07-13 Zack Weinberg <zack@wolery.cumb.org>
13867
13868 * lang-specs.h: Use the new named specs. Remove unnecessary braces.
13869
13870 2000-07-12 Mark Mitchell <mark@codesourcery.com>
13871
13872 * parse-scan.c: Remove.
13873
13874 2000-07-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
13875
13876 * class.c (set_super_info): Handled protected inner classes.
13877 (common_enclosing_context_p): Bail early if arguments aren't both
13878 inner classes.
13879 (get_access_flags_from_decl): Handle private and protected inner
13880 classes.
13881 * java-tree.h (TYPE_PROTECTED_INNER_CLASS): New macro.
13882 (CLASS_PROTECTED): Likewise.
13883 (struct lang_type): New bitfield `poic'.
13884 * parse.y (jdep_resolve_class): Call check_inner_class_access on
13885 inner classes only.
13886 (check_inner_class_access): Renamed arguments, added
13887 comments. Handles protected inner classes (fixes gcj/225)
13888 (not_accessible_p): Fixed comments. Avoid handling inner classes.
13889
13890 2000-07-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
13891
13892 * parse.y (resolve_qualified_expression_name): Verify qualified
13893 access to `this'. Fixes gcj/239.
13894
13895 2000-07-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
13896
13897 * jcf-write.c (generate_classfile): Don't install ConstantValue
13898 for null pointers.
13899
13900 2000-07-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
13901
13902 * parse.y (resolve_qualified_expression_name): Handle inner class
13903 access. Fixes gcj/256.
13904
13905 2000-07-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
13906
13907 * jcf-write.c (generate_classfile): Properly install the
13908 ConstantValue attribute and the initial value constant pool index
13909 on string constants.
13910 * parse.y (java_complete_lhs): Keep DECL_INITIAL when emitting
13911 class files.
13912
13913 2000-07-06 Alexandre Petit-Bianco <apbianco@cygnus.com>
13914
13915 * parse.h (BUILD_PTR_FROM_NAME): Surround with a do/while
13916 construct.
13917 * parse.y (find_as_inner_class): Fixed typo.
13918 (do_resolve_class): Explore enclosing contexts when searching for
13919 innerclasses. Removed curly brackets around BUILD_PTR_FROM_NAME.
13920 (check_inner_class_access): Check `decl' which can be null in case
13921 of previous errors.
13922
13923 2000-07-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
13924
13925 * java-tree.h (java_debug_context): Declared `extern'.
13926 (safe_layout_class): Likewise.
13927 * parse.y (resolve_field_access): Field must be `static' in order
13928 to be replaced by its initial value. Added comments.
13929 (find_applicable_accessible_methods_list): Fixed typo.
13930 (find_most_specific_methods_list): Methods found in innerclasses
13931 take over methods founds in the enclosing contexts.
13932 (java_complete_tree): Loosen restrictions on the type of DECLs
13933 that can be replaced by their initialization values.
13934 (valid_ref_assignconv_cast_p): Removed call to `enclosing_context_p'.
13935
13936 2000-07-05 Tom Tromey <tromey@cygnus.com>
13937
13938 * Make-lang.in (PARSE_DIR): New macro.
13939 (PARSE_RELDIR): Likewise.
13940 (PARSE_C): Likewise.
13941 (PARSE_SCAN_C): Likewise.
13942 ($(PARSE_C)): New target.
13943 ($(PARSE_SCAN_C)): Likewise.
13944 (SET_BISON): New macro.
13945 (BISONFLAGS): Likewise.
13946 (JAVABISONFLAGS): Likewise.
13947
13948 2000-07-02 Bryce McKinlay <bryce@albatross.co.nz>
13949
13950 * gjavah.c (HANDLE_METHOD): Call print_method_info with a NULL stream
13951 argument on the first pass for CNI as well as JNI.
13952 (print_method_info): Set up method name on the first pass only.
13953
13954 2000-07-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
13955
13956 * parse.y (parser_qualified_classname): Removed parameter
13957 `is_static'.
13958 (create_interface): Removed first passed parameter to
13959 parser_qualified_classname.
13960 (create_class): Likewise. Don't install alias on static
13961 innerclasses. Fixes gcj/275.
13962
13963 2000-07-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
13964
13965 * parse.y (maybe_generate_pre_expand_clinit): Don't build a
13966 debugable statement with empty_stmt_node. Fixes gcj/272
13967
13968 2000-07-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
13969
13970 * expr.c (build_instanceof): Layout type after it's loaded. Fixes
13971 gcj/271.
13972
13973 2000-06-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
13974
13975 * jcf-write.c (push_long_const): Appropriately cast short negative
13976 constant to jword.
13977
13978 2000-06-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
13979
13980 * parse.y (verify_constructor_super): Use loop variable
13981 `m_arg_type' initialized with `mdecl_arg_type'.
13982
13983 2000-06-29 Tom Tromey <tromey@cygnus.com>
13984
13985 * parse.y (resolve_field_access): Handle case where `type_found'
13986 is NULL.
13987
13988 2000-06-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
13989
13990 * expr.c (lookup_field): The same field can be found through two
13991 different interface. Don't declare it ambiguous in that case.
13992
13993 2000-06-27 Tom Tromey <tromey@cygnus.com>
13994
13995 * lex.c (java_lineterminator): Don't recognize \r after \n. If \r
13996 follows \r, then unget it at a lower level.
13997
13998 2000-06-26 Tom Tromey <tromey@cygnus.com>
13999
14000 * parse.y (resolve_field_access): Pass decl, not DECL_INITIAL, to
14001 java_complete_tree.
14002
14003 2000-06-25 Tom Tromey <tromey@cygnus.com>
14004
14005 * parse.y (for_statement): Wrap expression in a WFL if it is a
14006 constant. For PR gcj/268.
14007
14008 2000-06-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
14009
14010 * parse.y (do_resolve_class): Minor optimiztion in the package
14011 list search. Removed unnecessary test and return statement.
14012 (valid_ref_assignconv_cast_p): Order of arguments to
14013 enclosing_context_p fixed.
14014
14015 2000-06-24 Tom Tromey <tromey@cygnus.com>
14016
14017 * expr.c (lookup_field): Print error and return error_mark_node if
14018 field reference is ambiguous.
14019
14020 * parse.y (check_abstract_method_definitions): Also check if
14021 `other_method' is abstract.
14022
14023 2000-06-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
14024
14025 * class.c (set_super_info): Handle ACC_PRIVATE for (inner)
14026 classes.
14027 * java-tree.h (TYPE_PRIVATE_INNER_CLASS): New macro.
14028 (struct lang_type): New field `pic'.
14029 (CLASS_PRIVATE): New macro.
14030 * parse.y (check_inner_class_access): New function.
14031 (jdep_resolve_class): Call it.
14032
14033 2000-06-23 Tom Tromey <tromey@cygnus.com>
14034
14035 * parse.y (patch_incomplete_class_ref): Initialize the returned
14036 class. For PR gcj/260.
14037
14038 2000-06-21 Alexandre Petit-Bianco <apbianco@cygnus.com>
14039
14040 * except.c (prepare_eh_table_type): Use `CATCH_ALL_TYPE'.
14041
14042 2000-06-20 Alexandre Petit-Bianco <apbianco@cygnus.com>
14043
14044 * check-init.c (ENABLE_JC1_CHECKING): Replaces ENABLE_CHECKING for
14045 Java specific checks.
14046 * expr.c (build_instanceof): CLASS_INTERFACE and CLASS_FINAL usage
14047 screened by DECL_P.
14048 * java-tree.def (CASE_EXPR): Marked 'e'.
14049 (DEFAULT_EXPR): Likewise.
14050 * jcf-parse.c (set_source_filename): CLASS_COMPLETE_P usage
14051 screened by DECL_P.
14052 * jcf-write.c (ENABLE_JC1_CHECKING): Replaces ENABLE_CHECKING for
14053 Java specific checks.
14054 (generate_bytecode_insns): Test try_block for BLOCK before using
14055 BLOCK_EXPR_BODY.
14056 * parse.y (build_wfl_wrap): Added `location' argument. Set
14057 EXPR_WFL_LINECOL accordingly.
14058 (dim_expr:): Wrap constants with WFLs.
14059 (method_declarator): Use TREE_TYPE not TYPE_NAME on GET_CPC.
14060 (resolve_package): Check for `stmt' not being a BLOCK before
14061 building a debuggable statement with it.
14062 (make_qualified_primary): Added extra parameter to build_wfl_wrap
14063 invocation.
14064 (resolve_field_access): Make sure `decl' is a DECL before treating
14065 it as such.
14066 (maybe_build_primttype_type_ref): Make sure `wfl''s node is an
14067 IDENTIFIER_NODE before treating it as such.
14068 (patch_new_array_init): Make sure `elt' is a TREE_LIST before
14069 treating it as such.
14070 (find_applicable_accessible_methods_list): CLASS_INTERFACE macro
14071 to be applied only on non array types.
14072
14073 2000-06-16 Per Bothner <per@bothner.com>
14074
14075 * java-tree.h (LABEL_RETURN_LABELS, LABEL_PENDING_CHAIN): Don't
14076 define in terms of DECL_RESULT, as that fails when --enable-checking.
14077
14078 2000-06-15 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
14079
14080 * jcf-write.c (CHECK_PUT): Add static prototype. Make pointer
14081 types the same in comparison.
14082 (CHECK_OP): Add static prototype.
14083
14084 2000-06-13 Jakub Jelinek <jakub@redhat.com>
14085
14086 * typeck.c (build_java_array_type): Set TYPE_USER_ALIGN.
14087 * parse.y (java_complete_class): Set DECL_USER_ALIGN.
14088 * parse.c: Rebuilt.
14089
14090 2000-06-11 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
14091
14092 * decl.c (create_primitive_vtable): Prototype.
14093
14094 * jcf-write.c (generate_bytecode_insns): Initialize variable
14095 `saved_context'.
14096
14097 * lang.c (lang_get_alias_set): Mark parameter with ATTRIBUTE_UNUSED.
14098
14099 2000-06-09 Bryce McKinlay <bryce@albatross.co.nz>
14100
14101 * parse.y (find_applicable_accessible_methods_list): Use a hashtable
14102 to track searched classes, and do not search the same class more than
14103 once. Call find_applicable_accessible_methods_list on immediate
14104 superclass, instead of search_applicable_method_list on all ancestors.
14105 Fix for PR gcj/238.
14106
14107 2000-06-09 Bryce McKinlay <bryce@albatross.co.nz>
14108
14109 * parse.y (register_fields): Permit static fields in inner classes
14110 if they are final. Fix for PR gcj/255.
14111
14112 2000-06-06 Alexandre Petit-Bianco <apbianco@cygnus.com>
14113
14114 * parse.h (REGISTER_IMPORT): Use `chainon' to link new entries.
14115 * parse.y (find_in_imports): Returned type changed to void,
14116 leading comment fixed.
14117 (register_package): New function.
14118 (qualify_and_find): Likewise.
14119 (package_declaration:): Use `register_package'.
14120 (single_type_import_declaration:): Removed local variable
14121 `node'. Added missing `;' for consistency.
14122 (type_import_on_demand_declaration:): Use `chainon' to link new
14123 entries.
14124 (lookup_field_wrapper): Lookup local variables defined in outer
14125 contexts first.
14126 (java_complete_class): Don't reverse the list of imported on demand.
14127 (do_resolve_class): Reorganized. Removed local variable
14128 `original_name'. Call `qualify_and_find' with the current package
14129 name, invoke `find_in_imports_on_demand' right after. Call
14130 `qualify_and_find' with the packages we've seen so far. Fixed
14131 operations numbering in comments.
14132 (java_expand_class): Don't reverse `package_list'.
14133 (find_most_specific_methods_list): New local variables `abstract'
14134 and `candidates'. Use them to pick the right method.
14135
14136 2000-06-06 Tom Tromey <tromey@ferrule.cygnus.com>
14137
14138 * parse.y (check_modifiers_consistency): Don't subtract out
14139 `PUBLIC_TK' from argument to THIS_MODIFIER_ONLY.
14140
14141 2000-06-04 Philipp Thomas <pthomas@suse.de>
14142
14143 * Makefile.in (INTLLIBS): New.
14144 (LIBS): Add above.
14145 (DEPLIBS): Ditto.
14146
14147 2000-06-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
14148
14149 * class.c (get_dispatch_table): Build the vtable dummy entry list
14150 element with a null purpose. Fixed leading comment.
14151 (build_dtable_decl): Build an accurate dtable type when appropriate
14152 and use it.
14153
14154 2000-06-02 Richard Henderson <rth@cygnus.com>
14155
14156 * lang.c (lang_get_alias_set): New.
14157
14158 2000-05-31 Alexandre Petit-Bianco <apbianco@cygnus.com>
14159
14160 * parse.y (resolve_field_access): Complete the DECL_INITIAL tree
14161 before using it as the accessed field.
14162
14163 2000-05-31 Tom Tromey <tromey@cygnus.com>
14164
14165 * java-tree.h (boolean_array_vtable, byte_array_vtable,
14166 char_array_vtable, short_array_vtable, int_array_vtable,
14167 long_array_vtable, float_array_vtable, double_array_vtable):
14168 Declare.
14169 * expr.c (get_primitive_array_vtable): New function.
14170 (create_primitive_vtable): New function.
14171 (java_lang_expand_expr): Enable code to statically generate
14172 arrays.
14173 * decl.c (init_decl_processing): Create primitive vtables.
14174 (boolean_array_vtable, byte_array_vtable, char_array_vtable,
14175 short_array_vtable, int_array_vtable, long_array_vtable,
14176 float_array_vtable, double_array_vtable): Define.
14177
14178 2000-05-26 Zack Weinberg <zack@wolery.cumb.org>
14179
14180 * java/parse.y (find_applicable_accessible_methods_list):
14181 Don't add an uninitialized value to the list.
14182
14183 2000-05-25 Tom Tromey <tromey@cygnus.com>
14184
14185 * parse.y (resolve_field_access): Don't check DECL_LANG_SPECIFIC
14186 when trying to see if field's class should be initialized. Always
14187 initialize field's declaring class, not qualified class.
14188 For PR gcj/162.
14189
14190 * parse.y (array_constructor_check_entry): Pass `wfl_value', not
14191 `wfl_operator', to maybe_build_primttype_type_ref.
14192 Fixes PR gcj/235.
14193
14194 2000-05-23 Bryce McKinlay <bryce@albatross.co.nz>
14195
14196 * parse.y (patch_method_invocation): Don't try to lookup methods
14197 in primitive types.
14198
14199 2000-05-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
14200
14201 * parse.y (resolve_field_access): Call the appropriate <clinit>
14202 before accessing the length of a static array. Craft a decl for
14203 the field while its time. Fixes PR gcj/129.
14204
14205 2000-05-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
14206
14207 * parse.y (resolve_package): Correctly set `*next' (was off by
14208 one.)
14209 (resolve_qualified_expression_name): Fixed comment.
14210
14211 2000-04-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
14212
14213 * jcf-parse.c (jcf_parse_source): Reset current_class and
14214 current_function_decl to NULL before parsing a new file.
14215
14216 2000-04-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
14217
14218 * parse.y (block_end:): If the collected block doesn't feature a
14219 statement, insert an empty statement.
14220
14221 2000-04-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
14222
14223 * parse.y (maybe_yank_clinit): New function.
14224 (maybe_generate_pre_expand_clinit): Always link <clinit> at the
14225 end of the list of methods belonging to a class.
14226 (java_complete_expand_method): Check whether <clinit> is really
14227 necessary and expand it accordingly.
14228
14229 2000-04-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
14230
14231 * parse.y (fold_constant_for_init): Let VAR_DECL and FIELD_DECL be
14232 processed by the method's switch statement.
14233
14234 2000-05-19 Tom Tromey <tromey@cygnus.com>
14235
14236 * java-tree.h: Added init state enum.
14237 * decl.c (emit_init_test_initialization): Initialize class
14238 initialization check variable by looking at class' state.
14239
14240 2000-05-19 Tom Tromey <tromey@cygnus.com>
14241
14242 * java-tree.h (build_instanceof): Declare.
14243 (build_get_class): Declare.
14244 * parse.y (patch_binop): Use build_instanceof.
14245 * expr.c (build_instanceof): New function. If class is final,
14246 don't make a function call.
14247 (expand_java_INSTANCEOF): Use it.
14248 (build_get_class): New function.
14249
14250 2000-05-18 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
14251
14252 * jcf-write.c (generate_classfile): Scan the source_file for
14253 slashes with the right pointer variable.
14254
14255 2000-05-17 Andrew Cagney <cagney@b1.cygnus.com>
14256
14257 * lang.c (lang_decode_option): Update -Wunused flags by calling
14258 set_Wunused.
14259 * decl.c (poplevel): Replace warn_unused with warn_unused_label.
14260
14261 2000-05-09 Zack Weinberg <zack@wolery.cumb.org>
14262
14263 * check_init.c (check_init): Constify local char *.
14264 * class.c (push_class): Constify local char *.
14265 * java_tree.h: Update prototypes.
14266 * jcf-io.c (open_class): Constify filename parameter and
14267 return value.
14268 (find_class): Remove redundant string copy. Cast return from
14269 open_class.
14270 * jcf-parse.c (read_class, parse_class_file, yyparse):
14271 Constify local char *.
14272 * jcf-write.c (generate_bytecode_insns, generate_classfile):
14273 Constify local char *.
14274 * jcf.h (JCF): Constify filename and classname.
14275 (JCF_FINISH): Cast args to FREE to char * when appropriate.
14276 * lang.c (init_parse): Constify parameter and return value.
14277 * lex.c (java_get_line_col): Constify filename parameter.
14278 * parse.h: Constify parser_ctxt.filename. Update prototypes.
14279 * parse.y (java_parser_context_suspend,
14280 issue_warning_error_from_context, safe_layout_class): Constify
14281 local char *.
14282 * parse.c: Regenerate.
14283
14284 2000-05-08 Tom Tromey <tromey@cygnus.com>
14285
14286 * expr.c (build_jni_stub): Cache the result of
14287 _Jv_LookupJNIMethod.
14288
14289 2000-05-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
14290
14291 * decl.c (predef_filenames_size): Now 7.
14292 (predef_filenames): New seventh entry.
14293
14294 2000-05-04 Tom Tromey <tromey@cygnus.com>
14295
14296 * boehm.c (mark_reference_fields): Don't mark RawData fields.
14297 Keep track of when we've seen a reference field after a
14298 non-reference field.
14299 (get_boehm_type_descriptor): Handle case where we see
14300 non-reference fields but no trailing reference field.
14301 * decl.c (rawdata_ptr_type_node): Define.
14302 (init_decl_processing): Initialize rawdata_ptr_type_node.
14303 * java-tree.h (rawdata_ptr_type_node): Declare.
14304
14305 2000-05-04 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
14306
14307 * jcf-dump.c (SPECIAL_IINC): Ensure arguments match format
14308 specifiers in calls to fprintf.
14309
14310 2000-05-03 Andrew Haley <aph@cygnus.com>
14311
14312 * expr.c (build_java_jsr): Use emit_jump, not expand_goto.
14313
14314 * javaop.h (WORD_TO_INT): New function.
14315 (IMMEDIATE_s4): Use WORD_TO_INT.
14316 * jcf.h (JPOOL_INT): Ditto.
14317
14318 * gjavah.c (decode_signature_piece): Don't treat `$' as namespace
14319 separator.
14320
14321 2000-04-19 Tom Tromey <tromey@cygnus.com>
14322
14323 * class.c (add_method_1): Set both DECL_EXTERNAL and METHOD_NATIVE
14324 on native function.
14325 * jcf-parse.c (parse_class_file): Call build_jni_stub for native
14326 JNI methods.
14327 * expr.c (build_jni_stub): New function.
14328 * lang-specs.h: -fjni and -femit-class-file are incompatible.
14329 * parse.c: Rebuilt.
14330 * parse.y (java_complete_expand_methods): Expand a native method
14331 and call build_jni_stub if -fjni given.
14332 * lang-options.h: Document -fjni.
14333 * lang.c (flag_jni): New global.
14334 (lang_f_options): Added `jni' entry.
14335 * java-tree.h (soft_lookupjnimethod_node,
14336 soft_getjnienvnewframe_node, soft_jnipopsystemframe_node):
14337 Declare.
14338 (flag_jni): Declare.
14339 (build_jni_stub): Declare.
14340 (struct lang_decl): Added `native' flag.
14341 (METHOD_NATIVE): Redefined to use `native' field of lang specific
14342 structure.
14343 * decl.c (soft_lookupjnimethod_node, soft_getjnienvnewframe_node,
14344 soft_jnipopsystemframe_node): New globals.
14345 (init_decl_processing): Set them. _Jv_InitClass only takes one
14346 argument.
14347
14348 * java-tree.def: Put into `C' mode.
14349
14350 2000-04-27 Tom Tromey <tromey@cygnus.com>
14351
14352 Fix for PR gcj/2:
14353 * expr.c (expand_invoke): Generate check to see if object pointer
14354 is null in nonvirtual invocation case.
14355 * java-tree.h (soft_nullpointer_node): Declare.
14356 * decl.c (soft_nullpointer_node): New global.
14357 (init_decl_processing): Initialize soft_nullpointer_node.
14358 * parse.y (invocation_mode): Return INVOKE_NONVIRTUAL for `final'
14359 or `private' methods.
14360 (patch_invoke): Handle INVOKE_NONVIRTUAL case.
14361
14362 2000-04-26 Alexandre Petit-Bianco <apbianco@cygnus.com>
14363
14364 * decl.c (complete_start_java_method): Don't call _Jv_InitClass
14365 from <clinit>
14366
14367 2000-04-26 Tom Tromey <tromey@cygnus.com>
14368
14369 * zextract.c (find_zip_file_start): New function.
14370 (read_zip_archive): Use it.
14371
14372 2000-04-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
14373
14374 * parse.y (register_incomplete_type): Handle JDEP_ANONYMOUS.
14375
14376 2000-04-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
14377
14378 * class.c (common_enclosing_context_p): New function.
14379 * java-tree.h (common_enclosing_context_p): Added prototype.
14380 * parse.h (INNER_ENCLOSING_SCOPE_CHECK): Relaxed test to allow
14381 classes sharing an outer context with the current instance.
14382 * parse.y (build_access_to_thisn): Fixed leading comment.
14383 (verify_constructor_super): New local `supper_inner'. Skip
14384 enclosing context argument in the case of inner class constructors.
14385 (patch_method_invocation): Insert proper context as second
14386 parameter to pure inner class constructor super invocations.
14387
14388 2000-04-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
14389
14390 * parse.y (end_class_declaration): Reset the interface number
14391 counter.
14392
14393 2000-04-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
14394
14395 * parse.y (source_start_java_method): Deleted unnecessary code.
14396 (patch_method_invocation): Fixed comment.
14397
14398 2000-04-24 Robert Lipe <robertlipe@usa.net>
14399
14400 * parse.h (_jdep): Member `kind' now ENUM_BITFIELD.
14401
14402 2000-04-23 Tom Tromey <tromey@cygnus.com>
14403
14404 * boehm.c (mark_reference_fields): Use int_byte_position.
14405
14406 2000-04-22 Tom Tromey <tromey@cygnus.com>
14407
14408 * boehm.c (mark_reference_fields): Only call byte_position on
14409 non-static fields.
14410
14411 2000-04-22 Tom Tromey <tromey@cygnus.com>
14412
14413 * boehm.c (mark_reference_fields): Added `last_view_index'
14414 argument. Use DECL_FIELD_OFFSET to determine field's offset.
14415
14416 2000-04-20 Mo DeJong <mdejong@cygnus.com>
14417
14418 * parse.h (INTERFACE_INNER_MODIFIERS): New macro.
14419 * parse.y (check_class_interface_creation): Fixed comments. Select
14420 permitted modifiers for (inner) interfaces. Changed error message
14421 to report rejected modifiers used with local classes.
14422
14423 2000-04-20 Alexandre Petit-Bianco <apbianco@cygnus.com>
14424
14425 * parse.h (INNER_ENCLOSING_SCOPE_CHECK): Immediate inner classes
14426 of directly inherited type considered in scope.
14427 * parse.y (do_resolve_class): Search inherited classes for inner
14428 classes.
14429
14430 2000-04-20 Tom Tromey <tromey@cygnus.com>
14431
14432 * parse.y (not_accessible_p): Use member's class, not current
14433 class, when doing inheritance check for protected reference.
14434 Fixes PR gcj/124.
14435
14436 2000-04-20 Jason Schroeder <shrode@subnature.com>
14437
14438 * jcf-dump.c (SPECIAL_IINC): Fixed typo printing iinc instruction.
14439
14440 2000-04-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
14441
14442 * parse.y (lookup_field_wrapper): Search for final local aliases.
14443 (resolve_expression_name): Let lookup_field_wrapper search for
14444 final local aliases. Force the value of `name' if one is found.
14445 (qualify_ambiguous_name): CONVERT_EXPR is enough to now we have
14446 an expression name. Fixed comments.
14447
14448 2000-04-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
14449
14450 * parse.y (yyerror): `msg' can be null, don't use it in that case.
14451
14452 2000-04-19 Tom Tromey <tromey@cygnus.com>
14453
14454 * gjavah.c (cxx_keyword_subst): Avoid potential infinite loop.
14455
14456 2000-04-18 Alexandre Petit-Bianco <apbianco@cygnus.com>
14457
14458 * parse.y (maybe_make_nested_class_name): Use `obstack_grow0'.
14459
14460 2000-04-18 Tom Tromey <tromey@cygnus.com>
14461
14462 PR gcj/211:
14463 * gjavah.c (utf8_cmp): Changed return value.
14464 (cxx_keyword_subst): Handle all C++ keywords. Allocate new return
14465 result.
14466 (cxx_keywords): New global.
14467 (get_field_name): Handle new result of cxx_keyword_subst.
14468 (print_method_info): Likewise.
14469
14470 2000-04-17 Bryce McKinlay <bryce@albatross.co.nz>
14471
14472 * gjavah.c (print_name_for_stub_or_jni): Don't prefix method names
14473 with a newline, for CNI.
14474 (print_stub_or_jni): Print a space or newline before method name for
14475 CNI as well as JNI.
14476 (print_cxx_classname): Don't write leading "::" in CNI stub method.
14477 (process_file): Include gcj/cni.h if generating CNI stubs.
14478
14479 2000-04-16 Tom Tromey <tromey@cygnus.com>
14480
14481 * gjavah.c (decompile_method): Use print_field_name.
14482 Fixes PR gcj/205.
14483
14484 2000-04-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
14485
14486 * parse.y (java_expand_classes): Reverse the package list once.
14487 (java_complete_lhs): PLUS_EXPR: don't try rhs and lhs at string
14488 reduction.
14489 (patch_binop): New temp `cn'. Call patch_string on LHS/RHS of
14490 the `==' and `!=' operators.
14491
14492 2000-04-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
14493
14494 * jcf-write.c (generate_bytecode_insns): At invocation time,
14495 always relate an interface method to the type of its selector.
14496
14497 2000-04-05 Tom Tromey <tromey@cygnus.com>
14498
14499 Fix for PR gcj/2:
14500 * expr.c (expand_invoke): Generate check to see if object pointer
14501 is null in nonvirtual invocation case.
14502 * java-tree.h (soft_nullpointer_node): Declare.
14503 * decl.c (soft_nullpointer_node): New global.
14504 (init_decl_processing): Initialize soft_nullpointer_node.
14505 * parse.y (invocation_mode): Return INVOKE_NONVIRTUAL for `final'
14506 or `private' methods.
14507 (patch_invoke): Handle INVOKE_NONVIRTUAL case.
14508
14509 2000-04-05 Tom Tromey <tromey@cygnus.com>
14510
14511 Fix for PR gcj/140:
14512 * parse.y (check_final_assignment): Recognize assignments to the
14513 `length' field of an array when generating class files.
14514
14515 2000-04-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
14516
14517 * class.c (decl_hash): Prototype removed.
14518 (decl_compare): Likewise.
14519
14520 2000-04-05 Tom Tromey <tromey@cygnus.com>
14521
14522 * parse.h (THIS_MODIFIER_ONLY): Changed meaning of `v' parameter.
14523 * parse.y (check_modifiers_consistency): Check for final/volatile
14524 clash. Fixes PR gcj/164.
14525
14526 2000-04-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
14527
14528 * class.c: (java_hash_hash_tree_node): Renamed from `decl_hash',
14529 made global.
14530 (java_hash_compare_tree_node): Renamed from `decl_compare, made
14531 global.
14532 (add_method_1): Use `java_hash_hash_tree_node' and
14533 `java_hash_compare_tree_node'.
14534 * java-tree.h: (java_hash_hash_tree_node): Prototyped.
14535 (java_hash_compare_tree_node): Likewise.
14536 * parse.y (find_applicable_accessible_methods_list): Create,
14537 delete and use a hash table to remember already searched interfaces.
14538
14539 2000-04-03 Matt Welsh <mdw@cs.berkeley.edu>
14540
14541 * jcf-depend.c (add_entry): Fixed bug where list was always replaced
14542 with latest entry.
14543
14544 2000-04-04 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
14545
14546 * boehm.c (mark_reference_fields, set_bit): Prototype.
14547 (set_bit): Un-ANSI-fy definition.
14548
14549 * class.c (init_test_hash_newfunc, decl_hash, decl_compare):
14550 Prototype.
14551
14552 * decl.c (emit_init_test_initialization): Likewise.
14553
14554 * gjavah.c (jni_print_char): Likewise.
14555
14556 * parse.y (create_new_parser_context): Likewise.
14557
14558 2000-03-30 Alexandre Petit-Bianco <apbianco@cygnus.com>
14559
14560 * expr.c (java_lang_expand_expr): Added Anthony's Thu Jan 6 2000
14561 patch missing hunk. Fixed indentation.
14562
14563 2000-03-30 Tom Tromey <tromey@cygnus.com>
14564
14565 * gjavah.c (D_NAN_MASK): Only define as word-reversed when
14566 HOST_FLOAT_WORDS_BIG_ENDIAN and HOST_WORDS_BIG_ENDIAN disagree.
14567
14568 2000-03-28 Alexandre Petit-Bianco <apbianco@cygnus.com>
14569
14570 * parse-scan.y (pop_class_context): Reset `inner_qualifier_length'
14571 when negative *before* using it as an array index.
14572 * ChangeLog: Fixed typo.
14573
14574 2000-03-28 Alexandre Petit-Bianco <apbianco@cygnus.com>
14575
14576 * parse-scan.y (pop_class_context): Reset `inner_qualifier_length'
14577 to 0 when it reaches -1.
14578
14579 2000-03-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
14580
14581 * jcf-parse.c (get_constant): Properly cast `num' during the
14582 invocation of `add_double'.
14583 * jcf-write.c (push_long_const): Properly cast `lo' before
14584 comparing it to short bounds.
14585 * parse-scan.y (interface_declaration:): Rule re-arrange so that
14586 `interface_body:' is reduced after the current interface is
14587 pushed.
14588
14589 2000-03-26 Tom Tromey <tromey@cygnus.com>
14590
14591 * jvspec.c (jvgenmain_spec): Add `%{<...}' construct for each
14592 Java-specific `-f' option.
14593
14594 2000-03-26 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
14595
14596 * decl.c (init_decl_processing): Only call initialize_sizetypes once.
14597 Adjust order of making types.
14598 Make bitsize_*_node values.
14599
14600 2000-03-25 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
14601
14602 * class.c (make_field_value): Use byte_position.
14603 * expr.c (JAVA_ARRAY_LENGTH_OFFSET): Use byte_position.
14604 (java_array_data_offset): Likewise.
14605 * java-tree.h (MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC): Add case to
14606 bzero call.
14607
14608 2000-03-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
14609
14610 * parse.y (check_abstract_method_definitions): New local
14611 `end_type_reached'. Make sure we also consider `end_type'.
14612 (java_check_abstract_method_definitions): Make sure we eventually
14613 consider `java.lang.Object'.
14614 (maybe_use_access_method): Don't use access method if not in the
14615 context of a pure inner class or if the method's context is right.
14616 (find_applicable_accessible_methods_list): New static flag
14617 `object_done'. Don't search abstract classes as interfaces. Fixed
14618 indentation. Fixed the `java.lang.Object' only search. Search
14619 class interface(s) first, then fully search enclosing contexts.
14620 (find_most_specific_methods_list): Pick the closest candidate when
14621 they're all abstract.
14622
14623 2000-03-20 Alexandre Petit-Bianco <apbianco@cygnus.com>
14624
14625 * jcf-write.c (generate_bytecode_insns): TRY_FINALLY_EXPR:
14626 properly initialize `finished_label'. Don't emit gotos for empty
14627 try statements.
14628
14629 2000-03-19 Martin v. Löwis <loewis@informatik.hu-berlin.de>
14630
14631 * except.c (emit_handlers): Clear catch_clauses_last.
14632
14633 2000-03-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
14634
14635 * parse.y (check_method_types_complete): New function.
14636 (create_class): Reset anonymous class counter only when seeing an
14637 non inner classe.
14638 (java_complete_class): JDEP_METHOD: Don't recompute signature
14639 if incomplete.
14640
14641 2000-03-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
14642
14643 * class.c (build_static_ref): Fixed indentation in comment.
14644 * java-tree.def (TRY_EXPR): Fixed typo in name.
14645 (CLASS_LITERAL): Likewise.
14646 * java-tree.h: (TYPE_DOT_CLASS): New macro.
14647 (struct lang_type): New field `dot_class'.
14648 * jcf-write.c (generate_bytecode_insns): Fixed error message.
14649 (generate_classfile): Method `class$' is synthetic.
14650 * parse.y (build_do_class_method): New function.
14651 (build_dot_class_method_invocation): Likewise.
14652 (java_complete_expand_methods): Expand TYPE_DOT_CLASS if necessary.
14653 (resolve_qualified_expression_name): Handle CLASS_LITERAL.
14654 (qualify_ambiguous_name): Likewise.
14655 (patch_incomplete_class_ref): Invoke synthetic method if necessary.
14656 (build_try_statement): Fixed leading comment.
14657
14658 2000-03-17 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
14659
14660 * class.c (make_field_value): Properly handle sizes.
14661 (get_dispatch_vector): Use tree_low_cst and host_integerp.
14662 (layout_class_method): Count using trees.
14663 * decl.c (push_promoted_type): Set TYPE_{MIN,MAX}_VALUE with copy_node.
14664 * expr.c (java_array_data_offset): Use int_bit_position.
14665 (build_newarray, build_anewarray): Use host_integerp and tree_low_cst.
14666 (build_invokevirtual): Use tree_low_cst and do computations with trees.
14667
14668 2000-03-16 Tom Tromey <tromey@cygnus.com>
14669
14670 * lang.c (flag_hash_synchronization): New global.
14671 (lang_f_options): Added `hash-synchronization'.
14672 * lang-options.h: Mention -fhash-synchronization.
14673 * java-tree.h (flag_hash_synchronization): Declare.
14674 * expr.c (java_lang_expand_expr): Only push `sync_info' value when
14675 hash table synchronization is disabled.
14676 * decl.c (init_decl_processing): Only push `sync_info' value when
14677 hash table synchronization is disabled.
14678 * class.c (make_class_data): Only push `sync_info' field when hash
14679 table synchronization is disabled. Removed dead code.
14680
14681 2000-03-16 Tom Tromey <tromey@cygnus.com>
14682
14683 * lang.c (lang_decode_option): Enable -Wunused when -Wall given.
14684
14685 2000-03-15 Alexandre Petit-Bianco <apbianco@cygnus.com>
14686
14687 * parse.h (INNER_ENCLOSING_SCOPE_CHECK): Disregard anonymous
14688 classes.
14689 * parse.y (patch_method_invocation): Handle anonymous classes
14690 creation in static context.
14691
14692 2000-03-15 Alexandre Petit-Bianco <apbianco@cygnus.com>
14693
14694 * parse.h (INNER_ENCLOSING_SCOPE_CHECK): New macro.
14695 * parse.y (resolve_qualified_expression_name): Use it.
14696 (patch_method_invocation): Likewise.
14697
14698 2000-03-15 Alexandre Petit-Bianco <apbianco@cygnus.com>
14699
14700 * parse.y (register_incomplete_type): JDEP_ENCLOSING set
14701 depending on the type of dependency which dictates what the
14702 current class is.
14703 (unresolved_type_p): Resolved types limited to the current class.
14704
14705 2000-03-15 Tom Tromey <tromey@cygnus.com>
14706
14707 * decl.c (init_decl_processing): Set type of `sync_info' to be
14708 pointer to Object.
14709
14710 * boehm.c (get_boehm_type_descriptor): Correctly compute `bits'.
14711 Correctly compute bit number for current slot. Zero `high' and
14712 `low' in DS_LENGTH case. Don't skip inherited fields. Use
14713 mark_reference_fields.
14714 (mark_reference_fields): New function.
14715
14716 2000-03-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
14717
14718 * parse.y (register_incomplete_type): Fixed initialization of
14719 JDEP_ENCLOSING.
14720
14721 2000-02-28 Alexandre Petit-Bianco <apbianco@cygnus.com>
14722
14723 * parse-scan.y (inner_qualifier, inner_qualifier_length): New
14724 static globals.
14725 (push_class_context, pop_class_context): New function.
14726 (class_body:): Call pop_class_context.
14727 (interface_body:): Likewise.
14728 (INNER_QUALIFIER): New macro.
14729 (report_class_declaration): Changed output format and use
14730 INNER_QUALIFIER. Call push_class_context.
14731
14732 2000-02-14 Andrew Haley <aph@cygnus.com>
14733
14734 * check-init.c (check_init): Add new cases for unary and binary
14735 tree nodes.
14736
14737 2000-03-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
14738
14739 * parse.y (resolve_package): Set `next' once a type name has been
14740 progressively discovered.
14741 (resolve_qualified_expression_name): Propagate resolution only if
14742 there are remaining qualifiers. Take into account `q' might have
14743 been cleared after re-qualification.
14744 * parse.y (patch_method_invocation): New local `resolved'.
14745 Section dealing with qualified expression rewritten to use
14746 resolve_field_access.
14747
14748 2000-03-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
14749
14750 * parse.h (PUSH_CPC): Fixed indentation.
14751 (DEBUG_CPC): New macro.
14752 (SET_CPC_INITIALIZER_STMT, SET_CPC_STATIC_INITIALIZER_STMT,
14753 SET_CPC_INSTANCE_INITIALIZER_STMT): New macros.
14754 * parse.y (class_body_declaration:): Use
14755 SET_CPC_INSTANCE_INITIALIZER_STMT.
14756 (method_declaration:): Check for null current_function_decl.
14757 (static_initializer:): Use SET_CPC_STATIC_INITIALIZER_STMT.
14758 (java_parser_context_pop_initialized_field): Better handling of
14759 empty lists.
14760 (maybe_make_nested_class_name): Mark nested class name as
14761 qualified when necessary.
14762 (end_class_declaration): Don't call java_parse_context_resume when
14763 one or more error occurred.
14764 (add_inner_class_fields): Use SET_CPC_INITIALIZER_STMT.
14765 (register_fields): Use SET_CPC_STATIC_INITIALIZER_STMT and
14766 SET_CPC_INITIALIZER_STMT.
14767 (method_header): Check for inner classes declaring static methods.
14768 (resolve_qualified_expression_name): Handle situation where `this'
14769 is implied.
14770
14771 2000-03-13 Hans Boehm <boehm@acm.org>
14772
14773 * typeck.c (build_prim_array_type): Correctly set the high word too.
14774
14775 2000-03-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
14776
14777 * parse.y (java_complete_expand_methods): Leave <clinit> out of
14778 ordinary methods.
14779 (maybe_generate_pre_expand_clinit): Put <clinit> at the end of the
14780 list of methods for interfaces.
14781
14782 2000-03-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
14783
14784 * parse.y (qualify_ambiguous_name): Properly handle expressions
14785 using `null'.
14786
14787 2000-03-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
14788
14789 * parse.y (check_final_assignment): Extended to process
14790 COMPOUND_EXPR.
14791 (patch_assignment): Have check_final_assignment called only once.
14792
14793 2000-03-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
14794
14795 * java-tree.h (IS_INIT_CHECKED): New flag.
14796 * check-init.c (check_init): Test and set IS_INIT_CHECKED.
14797 * parse.y (patch_string): Call force_evaluation_order on the
14798 completed string concatenation tree.
14799 * expr.c (force_evaluation_order): Call force_evaluation_order on
14800 function's arguments too.
14801
14802 2000-03-06 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
14803
14804 * decl.c (emit_init_test_initialization): Mark KEY as unused.
14805 * expr.c (build_newarray): Cast TREE_INT_CST_LOW to HOST_WIDE_INT.
14806 (build_anewarray): Likewise.
14807 * parse.y (patch_newarray): Likewise.
14808 * parse.c: Regenerated.
14809
14810 2000-03-06 Bryce McKinlay <bryce@albatross.co.nz>
14811
14812 * decl.c (init_decl_processing): Added new class fields `depth',
14813 `ancestors', and `idt' to class_type_node. Use
14814 _Jv_LookupInterfaceMethodIdx for soft_lookupinterfacemthod_node.
14815 * class.c (make_class_data): Push initial values for new fields.
14816 * java-tree.h: Updated prototype for `build_invokeinterface'.
14817 * expr.c (build_invokeinterface): Changed parameters to accept
14818 `method' tree. Calculate index of `method' in its declaring
14819 interface. Build call to _Jv_LookupInterfaceMethodIdx.
14820 (expand_invoke): Call `build_invokeinterface' with new parameters.
14821 * parse.y (patch_invoke): Call `build_invokeinterface' with new
14822 parameters.
14823
14824 2000-03-06 Bryce McKinlay <bryce@albatross.co.nz>
14825
14826 * typeck.c (lookup_do): Search superinterfaces first
14827 when looking up an interface method. From Godmar Back
14828 <gback@cs.utah.edu>
14829
14830 2000-03-06 Tom Tromey <tromey@cygnus.com>
14831
14832 * Make-lang.in (JAVA_SRCS): Added boehm.c, lex.c.
14833
14834 2000-03-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
14835
14836 * java-tree.h (lookup_argument_method2): Declared.
14837 (safe_layout_class): Prototype moved from parse.h.
14838 * parse.h (safe_layout_class): Prototype moved to java-tree.h.
14839 * parse.y (java_check_regular_methods): Local `super_class' gone.
14840 Call lookup_argument_method2 instead of lookup_argument_method.
14841 Perform modifier match for methods found declared in implemented
14842 interfaces. Fixed indentation problem. Overriding/hiding error
14843 report to take place only for methods found in classes.
14844 * typeck.c (lookup_argument_method): Changed leading
14845 comment. Re-written by calling lookup_do.
14846 (lookup_argument_method2): New function.
14847 (lookup_java_method): Re-written by calling lookup_do.
14848 (lookup_do): New function.
14849
14850 2000-03-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
14851
14852 * check-init.c (check_init): Removed dead code. Handle (blank)
14853 final variables.
14854 * parse.y (declare_local_variables): New local `final_p', set it
14855 and use it to initialize LOCAL_FINAL.
14856 (check_final_assignment): Only check FIELD_DECLs.
14857
14858 2000-02-17 Tom Tromey <tromey@cygnus.com>
14859
14860 * Makefile.in (JAVA_OBJS): Added boehm.o.
14861 (boehm.o): New target.
14862 * Make-lang.in (JAVA_SRCS): Added boehm.c.
14863 * java-tree.h (flag_use_boehm_gc): Declare.
14864 (get_boehm_type_descriptor): Declare.
14865 * lang.c (lang_f_options): Added `use-boehm-gc'.
14866 (flag_use_boehm_gc): New global.
14867 * lang-options.h: Added -fuse-boehm-gc.
14868 * boehm.c: New file.
14869 * class.c (get_dispatch_table): If class uses a Boehm type
14870 descriptor, put it in the vtable.
14871 (make_class_data): Removed dead code.
14872
14873 2000-03-03 Per Bothner <per@bothner.com>
14874
14875 * decl.c (init_decl_processing): Initialize sizetype properly.
14876
14877 2000-03-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
14878
14879 * java-tree.h (LOCAL_CLASS_P): New flag usage and macro.
14880 (PURE_INNER_CLASS_DECL_P, PURE_INNER_CLASS_TYPE_P): New macros.
14881 * jcf-dump.c (HANDLE_INNERCLASSES_ATTRIBUTE): New macro.
14882 * jcf-parse.c (HANDLE_INNERCLASSES_ATTRIBUTE): Likewise.
14883 (jcf_parse): New local `current'. Load innerclasses seen in outer
14884 context being processed.
14885 * jcf-reader.c (HANDLE_INNERCLASSES_ATTRIBUTE): New macro.
14886 * jcf-write.c (append_innerclasses_attribute): New function.
14887 (append_innerclasses_attribute_entry): Likewise.
14888 (get_access_flags): Handle static classes. Set anonymous and local
14889 classes to be private.
14890 (generate_classfile): Attribute count adjusted. Call
14891 append_innerclasses_attribute.
14892 * parse.h (SKIP_THIS_AND_ARTIFICIAL_PARMS): Use
14893 PURE_INNER_CLASS_TYPE_P.
14894 * parse.y (parser_qualified_classname): New parameter `is_static',
14895 produce non qualified name accordingly.
14896 (block_statement:): Set LOCAL_CLASS_P when declaring local class.
14897 (create_interface): Added argument to parser_qualified_classname.
14898 (create_class): Added argument to parser_qualified_classname. Setup
14899 alias for top level classes. Use PURE_INNER_CLASS_DECP_P.
14900 (add_inner_class_fields): Fixed indentation.
14901 (method_declarator): Use PURE_INNER_CLASS_DECP_P.
14902 (method_declarator): Fixed typo in comment.
14903 (craft_constructor): Use PURE_INNER_CLASS_DECP_P.
14904 (build_current_thisn): Likewise.
14905 (patch_method_invocation): Likewise.
14906
14907 2000-03-01 Martin von Löwis <loewis@informatik.hu-berlin.de>
14908
14909 * decl.c (current_function_decl): Move to toplev.c.
14910
14911 2000-02-28 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
14912
14913 * java-tree.h (LABEL_PC): Relect name changes in ../tree.h.
14914 (DECL_BIT_INDEX): Use underlying representation.
14915 * parse.h (DECL_INHERITED_SOURCE_LINE): Likewise.
14916
14917 2000-02-27 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
14918
14919 * expr.c (build_java_ret): Pass proper type to size_binop.
14920
14921 2000-02-25 Anthony Green <green@cygnus.com>
14922
14923 * expr.c (build_class_init): Mark the decl to be ignored by
14924 check_init.
14925 * java-tree.h (DECL_BIT_INDEX): Move definition from check-init.c
14926 * check-init.c: Move DECL_BIT_INDEX to java-tree.h
14927 * class.c (init_test_hash_newfunc): New function.
14928 (decl_hash): New function.
14929 (decl_compare): New function.
14930 * decl.c (emit_init_test_initialization): New function.
14931 (complete_start_java_method): Traverse the init test hashtable,
14932 calling emit_init_test_initialization.
14933 (always_initialize_class_p): Define.
14934 * expr.c (build_class_init): Use initialization tests when
14935 emitting class initialization code.
14936 (always_initialize_class_p): Declare.
14937 * jcf-parse.c (parse_class_file): Set always_initialize_class_p to
14938 1.
14939 * java-tree.h: Include hash.h.
14940 (DECL_FUNCTION_INIT_TEST_TABLE): Define.
14941 (struct lang_decl): Add init_test_table field.
14942 (init_test_hash_entry): Define.
14943
14944 2000-02-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
14945
14946 * gjavah.c (main): Avoid using `argi' to report unimplemented
14947 options.
14948
14949 2000-02-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
14950
14951 * jcf-write.c (generate_bytecode_insns): TRY_FINALLY_EXPR:
14952 initialize locals to avoid warnings. Local `exception_type' moved
14953 into if statement.
14954
14955 2000-02-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
14956
14957 * parse.y (resolve_expression_name): Use `orig' as a second
14958 argument to resolve_field_access.
14959 (resolve_field_access): Removed unnecessary code when dealing with
14960 static fields.
14961
14962 2000-02-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
14963
14964 * class.c (push_super_field): Don't push the field twice.
14965 * jcf-parse.c (parse_source_file): Call java_reorder_fields.
14966 * parse.h (java_reorder_fields): Prototyped.
14967 * parse.y (java_reorder_fields): New function.
14968 (java_layout_class): Simplified not to worry about re-ordering.
14969
14970 2000-02-23 Tom Tromey <tromey@cygnus.com>
14971
14972 * gjavah.c (print_name): In JNI case, correctly quote string.
14973 (print_method_info): Don't handle overrides in JNI mode.
14974
14975 2000-02-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
14976
14977 * parse.y (init_decl_processing): `_Jv_IsInstanceOf' returned
14978 value type set to `boolean_type_node'.
14979
14980 2000-01-18 Joerg Brunsmann <joerg.brunsmann@fernuni-hagen.de>
14981
14982 * jcf-dump.c (main): Test for correct condition after
14983 output file creation.
14984
14985 2000-02-19 Anthony Green <green@cygnus.com>
14986
14987 * jcf-depend.c (add_entry): Fix test for first list entry.
14988
14989 2000-02-19 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
14990
14991 * class.c (build_class_ref, push_super_field): Set DECL_SIZE_UNIT.
14992 * constants.c (build_constants_constructor): Likewise.
14993
14994 2000-02-19 Anthony Green <green@cygnus.com>
14995
14996 * jcf-depend.c (add_entry): Add entries to the end of the list.
14997
14998 1999-11-03 Pekka Nikander <pekka.nikander@hut.fi>
14999
15000 * decl.c (INT_TYPE_SIZE): Define if necessary.
15001 (expand_java_return): Handle the case of a native integer smaller
15002 than a JVM integer.
15003
15004 2000-02-18 Martin von Löwis <loewis@informatik.hu-berlin.de>
15005
15006 * gjavah.c (help): Use GCCBUGURL.
15007 * jv-scan.c (help): Likewise.
15008 * jcf-dump.c (help): Likewise.
15009
15010 2000-02-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
15011
15012 * jcf-write.c (generate_bytecode_insns): Don't generate empty
15013 `finally' clauses.
15014
15015 2000-02-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
15016
15017 * jcf-parse.c (load_class): Call `fatal' if no file containing
15018 the target class are found.
15019
15020 2000-02-16 Zack Weinberg <zack@wolery.cumb.org>
15021
15022 * Makefile.in (PARSE_C, PARSE_SCAN_C): Move dependencies on
15023 lex.c, lex.h, and PARSE_H to...
15024 (parse.o, parse-scan.o): ...here, respectively.
15025
15026 * lex.c: Split out code that may trigger SIGFPE from yylex()
15027 to its own function.
15028 * lex.h (JAVA_FLOAT_RANGE_ERROR): Don't set value.
15029
15030 2000-02-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15031
15032 * Make-lang.in (jvspec.o): Depend on $(GCC_H), not gcc.h.
15033
15034 2000-02-15 Alexandre Petit-Bianco <apbianco@cygnus.com>
15035
15036 * parse.y (outer_field_access_p): Stop in time when outer contexts
15037 are exhausted.
15038 (resolve_qualified_expression_name): Properly qualify *everything*
15039 after a package.type to be resoled as expression names.
15040 (find_applicable_accessible_methods_list): Save/restore `class' to
15041 isolate it from a possible outer context search.
15042
15043 2000-02-15 Tom Tromey <tromey@cygnus.com>
15044
15045 * gjavah.c (jni_print_char): New function.
15046 (print_full_cxx_name): Use it.
15047 (decode_signature_piece): Likewise.
15048 (print_cxx_classname): Likewise.
15049
15050 2000-02-15 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15051
15052 * Makefile.in (jv-scan, jcf-dump, gcjh): Depend on and link with
15053 version.o.
15054 (jcf-dump.o, gjavah.o, jv-scan.o): Depend on version.h.
15055
15056 * gjavah.c: Include version.h.
15057
15058 * jcf-dump.c: Likewise.
15059
15060 * jv-scan.c: Likewise.
15061
15062 2000-02-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
15063
15064 * parse.y (outer_field_access_fix): First parameter now a tree
15065 node. Check for assignment to final. First argument to
15066 build_outer_field_access_fix modified to accommodate prototype.
15067 (build_outer_field_access): Don't check for assignment to final
15068 here.
15069 (java_complete_lhs): MODIFY_EXPR case: Check for `error_mark_node'
15070 possibly returned by outer_field_access_fix. Changed
15071 outer_field_access_fix's first argument.
15072 (check_final_assignment): $finit$'s context is OK.
15073 (patch_unaryop): Use node instead of its line/column value when
15074 calling outer_field_access_fix.
15075
15076 2000-02-11 Alexandre Petit-Bianco <apbianco@cygnus.com>
15077
15078 * parse.y (interface_declaration:): No longer tagged
15079 <node>. Re-installed default action.
15080 (class_member_declaration:): Handle inner interfaces.
15081 (interface_member_declaration): Handle inner interfaces and
15082 classes.
15083 (create_interface): Push error if one seen. Suspend parsing
15084 context when processing an inner interface.
15085 (register_fields): Inner class static field limitations not to
15086 apply to inner interfaces.
15087
15088 2000-02-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
15089
15090 * jcf-parse.c (load_class): Update `java_error_count' when a
15091 class' file can't be found.
15092 (parse.y): Avoid (byte)code generation when errors seen.
15093
15094 2000-02-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
15095
15096 * parse.y (java_complete_lhs): Handle TRUNC_DIV_EXPR. Ensure `fatal'
15097 decodes a valid node.
15098 (patch_binop): Handle TRUNC_DIV_EXPR.
15099
15100 2000-02-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
15101
15102 * parse.y (resolve_package): New local `acc'. Try to progressively
15103 build and guess a package and type name.
15104
15105 2000-02-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
15106
15107 * parse.y (find_applicable_accessible_methods_list): Load and
15108 layout the search class if necessary.
15109 (java_complete_tree): Keep to original type of the folded initial
15110 value.
15111
15112 2000-02-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
15113
15114 * class.c (layout_class): Set and test CLASS_BEING_LAIDOUT.
15115 Generate error message if circularity is detected. New static
15116 local `list'.
15117 * java-tree.h (CLASS_BEING_LAIDOUT): New flag usage, new macro. *
15118 * jcf-write.c (generate_bytecode_insns): Very simply handle
15119 SAVE_EXPR.
15120 * parse.y (java_check_circular_reference): Use
15121 `cyclic_inheritance_report' during report, if necessary.
15122 (java_complete_lhs): fixed comment with `THROW_EXPR:' case. Avoid
15123 walking NEW_ARRAY_INIT twice.
15124
15125 2000-02-09 Tom Tromey <tromey@cygnus.com>
15126
15127 * parse.y (check_class_interface_creation): Allow inner classes to
15128 be `private' or `protected', check modifiers' consistency. Prevent
15129 block local classes from bearing any modifiers.
15130
15131 2000-02-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15132
15133 * except.c (check_start_handlers): Re-add prototype lost in last
15134 patch.
15135 (maybe_start_try): Remove excess argument to `check_start_handlers'.
15136
15137 2000-02-09 Andrew Haley <aph@cygnus.com>
15138
15139 * decl.c (clear_binding_level): Remove excess initializer.
15140 (maybe_poplevels): Remove unused variable.
15141 (force_poplevels): Ditto.
15142 (struct binding_level): Add comment.
15143
15144 2000-02-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
15145
15146 * jcf-write.c (generate_classfile): Don't consider
15147 pre-initialization with reference value (use <clinit> instead.)
15148 * parse.y (java_fix_constructors): No generated constructor for
15149 interfaces.
15150 (build_outer_field_access): Removed debug message.
15151 (outer_field_expanded_access_p): Adapted to bytecode generation.
15152 (build_outer_field_access_method): Use fix_method_argument_names.
15153 (build_outer_method_access_method): Fixed indentation. Added
15154 comment. Handle access method generation for static and also void
15155 methods.
15156 (build_access_to_thisn): Inserted debug message.
15157 (maybe_build_thisn_access_method): Use fix_method_argument_names.
15158 (resolve_qualified_expression_name): Fixed comment.
15159 (not_accessible_p): Adapted to bytecode generation. Added comment.
15160 (patch_method_invocation): Added comment.
15161 (maybe_use_access_method): Fixed leading comment. Handle static
15162 methods.
15163 (java_complete_lhs): Don't shortcut handling of initialized upon
15164 declaration String type static fields when generating bytecode.
15165 (patch_unaryop): Handle outer field access when generating
15166 bytecode.
15167
15168 2000-02-03 Alexandre Petit-Bianco <apbianco@cygnus.com>
15169
15170 * java-tree.h (FIELD_THISN): New macro.
15171 * jcf-write.c (append_synthetic_attribute): New function.
15172 (generate_classfile): Set "Synthetic" attribute on this$<n>,
15173 val$<name> fields, access$<n> and $finit$ methods. Fixed indentation.
15174 * parse.y (add_inner_class_fields): Set FIELD_THISN for created
15175 this$<n> fields.
15176 (build_outer_field_access): Turned on access functions usage and
15177 generation when compiling to bytecode.
15178 (maybe_use_access_method): Likewise.
15179
15180 2000-01-25 Andrew Haley <aph@cygnus.com>
15181
15182 * java-except.h (struct eh_range): Add `expanded' field.
15183 (maybe_start_try): Add end_pc arg.
15184 (maybe_end_try): Ditto.
15185 * java-tree.h (force_poplevels): new function.
15186 * expr.c (expand_byte_code): Don't call maybe_start_try or
15187 maybe_end_try.
15188 * except.c (add_handler): Reset expanded.
15189 (expand_start_java_handler): Set expanded.
15190 (check_start_handlers): Don't expand a start handler that's
15191 already been expanded.
15192 (maybe_start_try): Add end_pc arg. Only expand a handler which
15193 ends after end_pc.
15194 (expand_end_java_handler): call force_poplevels.
15195 (force_poplevels): new function.
15196 * decl.c (binding_level): Add start_pc of binding level.
15197 (maybe_pushlevels): Call maybe_start_try when pushing binding
15198 levels.
15199 (maybe_poplevels): Call maybe_end_try when popping binding levels.
15200 (LARGEST_PC): Define.
15201 (clear_binding_level): Use LARGEST_PC.
15202
15203 * java-tree.h (DEBUG_JAVA_BINDING_LEVELS): new define.
15204 * decl.c (DEBUG_JAVA_BINDING_LEVELS): new define.
15205 (binding_depth, is_class_level, current_pc): new variables.
15206 (struct binding_level): ditto.
15207 (indent): new function.
15208 (push_jvm_slot): add debugging info.
15209 (maybe_pushlevels): ditto.
15210 (maybe_poplevels): ditto.
15211 (pushlevel): ditto.
15212 (poplevel): ditto.
15213 (start_java_method): ditto.
15214 (give_name_to_locals): comment only.
15215 * except.c (binding_depth, is_class_level, current_pc):
15216 new variables.
15217 (expand_start_java_handler): add debugging info.
15218 (expand_end_java_handler): ditto.
15219
15220 2000-02-05 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15221
15222 * gjavah.c (overloaded_jni_method_exists_p): Add prototype.
15223 (print_name_for_stub_or_jni, process_file): Constify a char*.
15224
15225 2000-02-03 Tom Tromey <tromey@cygnus.com>
15226
15227 * jcf-io.c (jcf_print_utf8_replace): Handle UTF-8 input.
15228
15229 2000-01-31 Scott Bambrough <scottb@netwinder.org>
15230
15231 * gcc/java/javaop.h (WORDS_TO_DOUBLE): Allow WORDS_TO_DOUBLE to
15232 assemble doubles correctly when HOST_FLOAT_WORDS_BIG_ENDIAN is
15233 defined to be 1.
15234
15235 2000-02-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
15236
15237 * java-tree.def (INSTANCE_INITIALIZERS_EXPR): New tree code.
15238 * java-tree.h (TYPE_II_STMT_LIST): New macro.
15239 (struct lang_type): New field `ii_block'.
15240 * lex.c (java_init_lex): Use CPC_INITIALIZER_LIST,
15241 CPC_STATIC_INITIALIZER_LIST and CPC_INSTANCE_INITIALIZER_LIST.
15242 * parse.h (struct parser_ctxt): New field `instance_initializers'.
15243 (CPC_INITIALIZER_LIST, CPC_STATIC_INITIALIZER_LIST,
15244 CPC_INSTANCE_INITIALIZER_LIST, CPC_INITIALIZER_STMT,
15245 CPC_STATIC_INITIALIZER_STMT, CPC_INSTANCE_INITIALIZER_STMT): New
15246 macros.
15247 * parse.y (add_instance_initializer): New function.
15248 (in_instance_initializer): New static global.
15249 (class_body_declaration:): Link instance initializer block.
15250 (static_initializer:): Use CPC_STATIC_INITIALIZER_STMT.
15251 (array_creation_expression:): Remove unused local.
15252 (java_parser_context_push_initialized_field): Fixed leading
15253 comment. Use CPC_STATIC_INITIALIZER_LIST, CPC_INITIALIZER_LIST and
15254 CPC_INSTANCE_INITIALIZER_LIST.
15255 (java_parser_context_pop_initialized_field): Likewise.
15256 (add_inner_class_fields): Use CPC_INITIALIZER_STMT.
15257 (register_fields): Use CPC_STATIC_INITIALIZER_STMT and
15258 CPC_INITIALIZER_STMT.
15259 (fix_constructors): New local `class_type'. Use it. Call
15260 add_instance_initializer.
15261 (java_complete_lhs): New case INSTANCE_INITIALIZERS_EXPR.
15262 (patch_return): Forbid return in instance initializers.
15263 (patch_throw_statement): Enforce exception handling in the context
15264 of instance initializers.
15265
15266 2000-02-03 Tom Tromey <tromey@cygnus.com>
15267
15268 * Make-lang.in (java.mostlyclean): Remove executables in
15269 `mostlyclean'.
15270
15271 2000-01-31 Scott Bambrough <scottb@netwinder.org>
15272
15273 * gcc/java/gjavah.c (D_NAN_MASK): Alternate definition required when
15274 HOST_FLOAT_WORDS_BIG_ENDIAN is defined to be 1.
15275 (java_float_finite): Convert to use union Word from javaop.h.
15276 (java_double_finite): Convert to use union DWord from javaop.h.
15277
15278 2000-02-02 Tom Tromey <tromey@cygnus.com>
15279
15280 * gjavah.c (options): Added `jni' entry.
15281 (help): Document -jni.
15282 (flag_jni): New global.
15283 (process_file): Handle JNI output. Don't print text from
15284 -prepend, -add, etc, when generating stubs. Only remove `.class'
15285 suffix if it actually exists.
15286 (main): Create a `.c' file when run with `--jni --stubs'. Create
15287 correct output file name with `--jni'.
15288 (print_include): Mangle header name differently in JNI case.
15289 (HANDLE_METHOD): In JNI mode, call print_method_info to generate
15290 method list.
15291 (print_method_info): Handle JNI case. Put signature info into
15292 method name. Handle case when STREAM is NULL.
15293 (print_name_for_stub_or_jni): New function.
15294 (print_stub_or_jni): Renamed from `print_stub'. Handle JNI.
15295 (print_cxx_classname): Handle JNI.
15296 (print_full_cxx_name): Likewise.
15297 (decode_signature_piece): Likewise.
15298 (overloaded_jni_method_exists_p): New function.
15299 (struct method_name): Added `signature' and `sig_length' fields.
15300 (HANDLE_END_FIELD): Do nothing in JNI mode.
15301
15302 2000-02-02 Tom Tromey <tromey@cygnus.com>
15303
15304 * jv-scan.c: Include version.c, <getopt.h>.
15305 (LONG_OPT, OPT_HELP, OPT_VERSION): New macros.
15306 (options): New array.
15307 (usage): New function.
15308 (version): New function.
15309 (main): Use getopt_long to parse command line.
15310 * jcf-dump.c: Include version.c, <getopt.h>.
15311 (LONG_OPT, OPT_classpath, OPT_CLASSPATH, OPT_HELP, OPT_VERSION,
15312 OPT_JAVAP): New macros.
15313 (options): New array.
15314 (usage): Return `void'. Changed message.
15315 (help): New function.
15316 (version): New function.
15317 (main): Use getopt_long_only to parse command line.
15318 * gjavah.c: Include <getopt.h>.
15319 (LONG_OPT, OPT_classpath, OPT_CLASSPATH, OPT_HELP, OPT_TEMP,
15320 OPT_VERSION, OPT_PREPEND, OPT_FRIEND, OPT_ADD, OPT_APPEND, OPT_M,
15321 OPT_MM, OPT_MG, OPT_MD, OPT_MMD): New macros.
15322 (options): New array.
15323 (java_no_argument): Removed.
15324 (help): Updated with missing options.
15325 (main): Use getopt_long_only to parse command line.
15326 (usage): Changed message.
15327
15328 2000-02-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
15329
15330 * java-tree.def (NEW_ANONYMOUS_ARRAY_EXPR): New tree code.
15331 * parse.h (ANONYMOUS_ARRAY_BASE_TYPE, ANONYMOUS_ARRAY_DIMS_SIG,
15332 ANONYMOUS_ARRAY_INITIALIZER): New access macros.
15333 * parse.y (array_creation_expression:): Handle anonymous arrays.
15334 (build_array_from_name): Don't set `ret_name' if null.
15335 (resolve_qualified_expression_name): New case NEW_ANONYMOUS_ARRAY_EXPR.
15336 (qualify_ambiguous_name): Likewise.
15337 (java_complete_expand_class): Likewise.
15338
15339 2000-02-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
15340
15341 * java-tree.def (SYNCHRONIZED_EXPR): Fixed typo.
15342 * parse.h (MANGLE_ALIAS_INITIALIZER_PARAMETER_NAME_ID): New macro.
15343 (MANGLE_ALIAS_INITIALIZER_PARAMETER_NAME_STR): Likewise.
15344 (SKIP_THIS_AND_ARTIFICIAL_PARMS): Use DECL_FINIT_P.
15345 (AIPL_FUNCTION_FINIT_INVOCATION): Replaces
15346 AIPL_FUNCTION_COMPLETED_INVOCATION.
15347 (AIPL_FUNCTION_CTOR_INVOCATION): Replaces
15348 AIPL_FUNCTION_INVOCATION_READY.
15349 (AIPL_FUNCTION_DECLARATION): New enum entry.
15350 * parse.y (reorder_static_initialized): New function.
15351 (java_parser_context_pop_initialized_field): Use it.
15352 (add_inner_class_fields): Use
15353 MANGLE_ALIAS_INITIALIZER_PARAMETER_NAME_ID. Comment
15354 augmented. Install marker after last alias initializer, if any.
15355 (generate_finit): Fixed typo. Don't try to retain only the used
15356 fields.
15357 (method_header): Compute and set DECL_FUNCTION_NAP.
15358 (method_declarator): Fixed comment. Insert alias initializer in
15359 parameter list.
15360 (build_alias_initializer_parameter_list): Fixed leading
15361 comment. New case for AIPL_FUNCTION_DECLARATION. Old enum value
15362 replaced by new ones. Use MANGLE_ALIAS_INITIALIZER_PARAMETER_NAME_ID.
15363 (java_complete_expand_class): Code to retain only used aliases
15364 removed.
15365 (java_complete_expand_methods): New local `first_decl'. Generate
15366 $finit$ first, then expand the constructors, regular methods and
15367 <clinit>.
15368 (java_complete_expand_method): Don't report error on missing
15369 return statement if previously detected bogus.
15370 (fix_constructors): Don't patch constructor parameters list.
15371 (patch_method_invocation): Use new AIPL enum values. Reverse
15372 alias initializer list for anonymous classes.
15373
15374 2000-01-30 Anthony Green <green@redhat.com>
15375
15376 * jcf-write.c (generate_bytecode_insns): Use TYPE_IS_WIDE to
15377 determine how many stack slots to pop.
15378
15379 2000-01-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
15380
15381 * parse.y (formal_parameter:): Set `$$' to NULL_TREE for better
15382 error handling/recovery.
15383 * java-tree.h (SYNCHRONIZED_EXPR): Fixed typo in comment.
15384
15385 2000-01-28 Alexandre Petit-Bianco <apbianco@cygnus.com>
15386
15387 * java-tree.h (ARG_FINAL_P, FIELD_LOCAL_ALIAS,
15388 FIELD_LOCAL_ALIAS_USED): New macros.
15389 (DECL_FUNCTION_NAP): New macro.
15390 (struct lang_decl): New field `nap'.
15391 (TYPE_FINIT_STMT_LIST, TYPE_CLINIT_STMT_LIST): New macros.
15392 (struct lang_type): New fields `finit_stmt_list' and
15393 `clinit_stmt_list'.
15394 (CLASS_HAS_FINIT_P): Defined using TYPE_FINIT_STMT_LIST.
15395 * parse.h (MANGLE_OUTER_LOCAL_VARIABLE_NAME): New macro.
15396 (SKIP_THIS_AND_ARTIFICIAL_PARMS, MARK_FINAL_PARMS,
15397 UNMARK_FINAL_PARMS, CRAFTED_PARAM_LIST_FIXUP): New macros.
15398 (AIPL_FUNCTION_CREATION, AIPL_FUNCTION_COMPLETED_INVOCATION,
15399 AIPL_FUNCTION_INVOCATION_READY): New enum fields.
15400 (BUILD_THROW): Macro line separator re-indented.
15401 * parse.y (end_class_declaration): New function.
15402 (maybe_generate_pre_expand_clinit): New name for
15403 java_pre_expand_clinit. Create <clinit> off TYPE_CLINIT_STMT_LIST,
15404 pre-expand static fields.
15405 (maybe_generate_clinit): Function deleted.
15406 (check_for_static_method_reference): Prototype's parameter list
15407 indented.
15408 (generate_finit): New name for maybe_generate_finit. Changed
15409 leading comment. Function rewritten to use
15410 TYPE_FINIT_STMT_LIST. Call build_alias_initializer_parameter_list.
15411 (build_alias_initializer_parameter_list): New function.
15412 (java_parser_context_pop_initialized_field): Likewise.
15413 (add_inner_class_fields): Likewise.
15414 (type_declaration:): Call end_class_declaration.
15415 (class_member_declaration:): Likewise.
15416 (formal_parameter_list:): Fixed typos.
15417 (formal_parameter:): Use ARG_FINAL_P to mark created tree list
15418 element. Improved error handling.
15419 (block_statement:): Call end_class_declaration.
15420 (anonymous_class_creation:): Likewise.
15421 (create_anonymous_class): Fixed comments.
15422 (create_class): Call add_inner_class_fields.
15423 (register_fields): Set FIELD_LOCAL_ALIAS according to ARG_FINAL_P.
15424 (method_header): Use MARK_FINAL_PARMS.
15425 (finish_method_declaration): Use UNMARK_FINAL_PARMS.
15426 (method_declarator): Propagate final argument flag.
15427 (craft_constructor): New local `artificial'. Call
15428 build_alias_initializer_parameter_list. Use
15429 CRAFTED_PARAM_LIST_FIXUP, assign DECL_FUNCTION_NAP.
15430 (source_start_java_method): Mark parm decls with LOCAL_FINAL if
15431 necessary.
15432 (complete_expand_class): Get rid of unused outer context local
15433 alias fields.
15434 (java_complete_expand_methods): Fixed leading
15435 comment. Generate/pre-expand <clinit> first. Changed method
15436 expansion order to regular, $finit$, constructors, <clinit>.
15437 (java_complete_expand_method): Set current_function_decl.
15438 (fix_constructors): Fix constructor parameter list to account for
15439 outer context local alias initializers.
15440 (verify_constructor_super): Use SKIP_THIS_AND_ARTIFICIAL_PARMS.
15441 (resolve_expression_name): Lookup outer context local aliases. New
15442 local `access', use it.
15443 (patch_method_invocation): Patch inner class ctor invocation with
15444 outer context local aliases initialization values. $finit$
15445 invocation patching now includes things generated with
15446 build_alias_initializer_parameter_list.
15447 (argument_types_convertible): Use SKIP_THIS_AND_ARTIFICIAL_PARMS.
15448 (build_super_invocation): Likewise.
15449 (patch_assignment): Changed comment.
15450
15451 2000-01-27 Andrew Haley <aph@cygnus.com>
15452
15453 * jcf-write.c (emit_goto): RESERVE 3 bytes for insn.
15454 (emit_if): Ditto.
15455 (emit_jsr): Ditto.
15456
15457 2000-01-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15458
15459 * parse.h (OBSOLETE_MODIFIER_WARNING): Don't use ANSI string
15460 concatenation.
15461 (OBSOLETE_MODIFIER_WARNING2): New macro allowing two args.
15462
15463 * parse.y (register_fields): Don't pass a format specifier to
15464 OBSOLETE_MODIFIER_WARNING.
15465 (check_abstract_method_header): Use OBSOLETE_MODIFIER_WARNING2
15466 instead of OBSOLETE_MODIFIER_WARNING, and don't pass a format
15467 specifier.
15468 (check_modifiers): Change function into a macro.
15469 (check_class_interface_creation): Pass a literal format string.
15470
15471 2000-01-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15472
15473 * buffer.h: PROTO -> PARAMS.
15474 * check-init.c: Likewise.
15475 * class.c: Likewise.
15476 * constants.c: Likewise.
15477 * convert.h: Likewise.
15478 * decl.c: Likewise.
15479 * except.c: Likewise.
15480 * expr.c: Likewise.
15481 * gjavah.c: Likewise.
15482 * java-except.h: Likewise.
15483 * java-tree.h: Likewise.
15484 * jcf-depend.c: Likewise.
15485 * jcf-dump.c: Likewise.
15486 * jcf-parse.c: Likewise.
15487 * jcf-path.c: Likewise.
15488 * jcf-reader.c: Likewise.
15489 * jcf-write.c: Likewise.
15490 * jcf.h: Likewise.
15491 * jv-scan.c: Likewise.
15492 * jvgenmain.c: Likewise.
15493 * jvspec.c: Likewise.
15494 * lang.c: Likewise.
15495 * lex.c: Likewise.
15496 * lex.h: Likewise.
15497 * parse-scan.y: Likewise.
15498 * parse.h: Likewise.
15499 * parse.y: Likewise.
15500 * typeck.c: Likewise.
15501 * verify.c: Likewise.
15502 * xref.c: Likewise.
15503 * xref.h: Likewise.
15504 * zextract.c: Likewise.
15505 * zipfile.h: Likewise.
15506
15507 2000-01-18 Alexandre Petit-Bianco <apbianco@cygnus.com>
15508
15509 * class.c (make_class): Use MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC.
15510 (is_compiled_class): Remove test on TYPE_LANG_SPECIFIC, use TYPE_JCF.
15511 * constants.c (build_constant_data_ref): Check for cached
15512 current_constant_pool_data_ref. Cache current_constant_pool_data_ref
15513 in TYPE_CPOOL_DATE_REF.
15514 * java-tree.h (TYPE_JCF, TYPE_CPOOL, TYPE_CPOOL_DATA_REF,
15515 MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC:) New macros.
15516 (struct lang_type): New fields `cpool' and `cpool_data_ref'.
15517 (LOCAL_FINAL): New macro.
15518 * jcf-parse.c (init_outgoing_cpool): Always allocate new outgoing
15519 constant pool -- don't try to reuse.
15520 (parse_zip_file_entries): Use TYPE_JCF, don't lazily allocate
15521 TYPE_LANG_SPECIFIC.
15522 (find_in_current_zip): Use TYPE_JCF.
15523 * parse.h (java_check_final): Prototype removed.
15524 * parse.y (create_class): Reversed Jan 12, 2000 extra argument patch.
15525 (maybe_create_class_interface_decl,
15526 check_class_interface_creation): Likewise.
15527 (java_expand_finals): Function removed.
15528 (class_declaration:): Reversed Jan 12, 2000 extra argument patch.
15529 (block_statement:): Fixed comment.
15530 (anonymous_class_creation:): Likewise.
15531 (check_class_interface_creation): Reversed Jan 12, 2000 extra
15532 argument patch.
15533 (check_class_interface_creation): Loosened error report on (inner)
15534 public class declarations. CPC_INNER_P replaces GET_CPC_LIST.
15535 (link_nested_class_to_enclosing): Reversed Jan 12, 2000 patch.
15536 (maybe_create_class_interface_decl): Reversed Jan 12, 2000 extra
15537 argument patch.
15538 (create_interface): Likewise.
15539 (anonymous_class_counter): New static global.
15540 (create_anonymous_class): Reversed Jan 12, 2000 extra argument
15541 patch. Fixed comments.
15542 (create_class): Reversed Jan 12, 2000 extra argument patch. Reset
15543 anonymous_class_counter when declaring a toplevel class.
15544 (craft_constructor): Fixed constructor name when handling
15545 anonymous classes. Anonymous class constructors to feature hidden
15546 this$<n> parameter.
15547 (java_fix_constructors): Added comment.
15548 (java_check_final): Function removed.
15549 (java_complete_expand_methods): Fixed comment. Don't generate
15550 class data, save its outgoing constant pool instead.
15551 (verify_constructor_super): Skip anonymous class constructor
15552 hidden this$<n> parameter.
15553 (java_expand_classes): New local `saved_ctxp'. Removed call to
15554 java_expand_finals and java_check_final. Expand anonymous class
15555 constructors. Generate class data.
15556 (build_super_invocation): Skip anonymous class hidden this$<n>
15557 parameter.
15558 * typeck.c (build_java_signature): Use TYPE_SIGNATURE and
15559 MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC.
15560 (set_java_signature): Likewise.
15561
15562 2000-01-18 Joerg Brunsmann <joerg.brunsmann@fernuni-hagen.de>
15563
15564 * gjavah.c: Delete ACC_VISIBILITY define.
15565 * jcf.h: Add ACC_VISIBILITY define.
15566 * parse.y: final: rule tagged <value>.
15567 (java_check_regular_methods): Use ACC_VISIBILITY define for
15568 default package access check.
15569 (local_variable_declaration_statement): Use final: rule.
15570
15571 2000-01-17 Joerg Brunsmann <joerg.brunsmann@fernuni-hagen.de>
15572
15573 * parse.y (format_parameter:): Use final: rule instead of modifiers:.
15574 (final:): New rule.
15575
15576 2000-01-17 Tom Tromey <tromey@cygnus.com>
15577
15578 * gjavah.c (print_field_info): Allow non-static final fields.
15579
15580 2000-01-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
15581
15582 * parse.h (enum jdep_code): New entry `JDEP_ANONYMOUS'.
15583 * parse.y (patch_anonymous_class): New function.
15584 (create_anonymous_class): Register incomplete type when the
15585 class/interface to extends/implement isn't known yet.
15586 (parser_check_super_interface): Simplify argument to CLASS_INTERFACE.
15587 (verify_constructor_super): Tuned error message.
15588
15589 2000-01-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
15590
15591 * java-tree.h (FOR_LOOP_P): Replaces IS_FOR_LOOP_P.
15592 (ANONYMOUS_CLASS_P): New macro.
15593 (TYPE_SIGNATURE, TYPE_JCF): New macros.
15594 (INNER_CLASS_TYPE_P): Fixed typo in leading comment.
15595 * parse.y (create_class): Added leading argument.
15596 (maybe_create_class_interface_decl,
15597 check_class_interface_creation): Likewise.
15598 (craft_constructor): New function.
15599 (verify_constructor_super): Added argument in prototype.
15600 (class_declaration:): Inserted leading argument.
15601 (for_begin:): Use FOR_LOOP_P.
15602 (anonymous_class_creation): Create WFL of the anonymous class to
15603 instantiate. Call build_new_invocation. Added comments.
15604 (check_class_interface_creation): Handle parameter `anonymous' in
15605 verbose mode class creation announce.
15606 (link_nested_class_to_enclosing): Exclude anonymous classes.
15607 (maybe_create_class_interface_decl): Don't set DECL_CONTEXT on
15608 anonymous class, even though they appear to have an enclosing
15609 context.
15610 (create_interface): Pass extra argument to
15611 check_class_interface_creation.
15612 (create_anonymous_class): Set ANONYMOUS_CLASS_P to 1.
15613 (create_class): Call check_class_interface_creation and
15614 maybe_create_class_interface_decl with extra new argument. Don't
15615 add private this$<n> to anonymous classes.
15616 (method_declarator): Insert hidden this$<n> to anonymous class
15617 constructors.
15618 (java_fix_constructors): Deleted code creating default
15619 constructor. Call craft_constructor instead.
15620 (java_check_regular_methods): Set `saw_constructor' to 1 for
15621 anonymous classes.
15622 (fix_constructors): Pass extra argument to verify_constructor_super.
15623 (verify_constructor_super): New local `sdecl', use it. Search for
15624 matching constructor (possibly featuring arguments) in super
15625 class.
15626 (lookup_method_invoke): Craft constructor according to arguments
15627 list when dealing with anonymous class constructors.
15628 (build_super_invocation): Pass arguments to anonymous class super
15629 constructors.
15630 (search_loop): Use FOR_LOOP_P.
15631 (labeled_block_contains_loop_p): Likewise.
15632
15633 2000-01-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
15634
15635 * class.c (set_super_info): Set CLASS_STATIC when appropriate.
15636 (enclosing_context_p): New function.
15637 (get_access_flags_from_decl): Handle CLASS_STATIC.
15638 (maybe_layout_super_class): Extra first argument passed to
15639 do_resolve_class.
15640 (layout_class_method): Use ID_FINIT_P, DECL_CLINIT_P and
15641 ID_INIT_P.
15642 * decl.c (access0_identifier_node): New global.
15643 (init_decl_processing): access0_identifier_node initialized.
15644 (pushdecl): Set DECL_CONTEXT only on non type decls.
15645 * expr.c (lookup_field): Lookup inner class fields in enclosing
15646 contexts.
15647 (expand_invoke): Use ID_INIT_P.
15648 (expand_java_field_op): Use DECL_CLINIT_P.
15649 * java-tree.def (CLASS_LITERAL): New tree code.
15650 * java-tree.h (DECL_FUNCTION_ACCESS_DECL,
15651 DECL_FUNCTION_INNER_ACCESS, FIELD_INNER_ACCESS): New macros.
15652 (struct lang_decl): New field `inner_access'.
15653 (enclosing_context_p): Prototyped.
15654 (DECL_INIT_P, DECL_FINIT_P, DECL_CLINIT_P, ID_INIT_P, ID_FINIT_P,
15655 ID_CLINIT_P): New macros.
15656 (CLASS_STATIC): New macro.
15657 (CLASS_ACCESS0_GENERATED_P): New macro.
15658 (OUTER_FIELD_ACCESS_IDENTIFIER_P, INNER_CLASS_DECL_P,
15659 TOPLEVEL_CLASS_DECL_P, INNER_CLASS_TYPE_P, TOPLEVEL_CLASS_TYPE_P,
15660 INNER_CLASS_P): New macros.
15661 (DECL_INNER_CLASS_LIST): New macro.
15662 * jcf-parse.c (yyparse): Avoid the use of ANSI string
15663 concatenation.
15664 * jcf-write.c (generate_bytecode_insns): binop: Change the type of
15665 the shift value to int. Fixed typo in comment.
15666 * lex.c (inst_id, wpv_id): Initialize.
15667 * mangle.c (unicode_mangling_length): Take `$' into account.
15668 * parse.h (DRECOVER, RECOVER): Terminate properly.
15669 (IDENTIFIER_INNER_CLASS_OUTER_FIELD_ACCESS): New macro.
15670 (typedef struct _jdep): New field `enclosing'.
15671 (JDEP_ENCLOSING): New macro.
15672 (IS_CLINIT): Deleted (DECL_CLINIT_P replaces it.)
15673 (struct parser_ctxt): New fields `marker_beginning', `marked_end'.
15674 (GET_CPC_LIST, CPC_INNER_P, GET_CPC, GET_CPC_UN, GET_CPC_UN_MODE,
15675 GET_CPC_DECL_NODE, GET_ENCLOSING_CPC, GET_NEXT_ENCLOSING_CPC,
15676 GET_ENCLOSING_CPC_CONTEXT): New macros.
15677 (PUSH_CPC, PUSH_ERROR, POP_CPC): New macros.
15678 (do_resolve_class): Added extra argument in prototype.
15679 * parse.y (resolve_class): Added extra argument in prototype.
15680 (maybe_create_class_interface_decl): Likewise.
15681 (maybe_use_access_method, build_wfl_wrap): New functions.
15682 (java_complete_expand_classes, java_complete_expand_class):
15683 Likewise.
15684 (java_parser_context_push_initialized_field,
15685 java_parser_context_suspend, java_parser_context_resume):
15686 Likewise.
15687 (maybe_make_nested_class_name, make_nested_class_name,
15688 set_nested_class_simple_name_value,
15689 link_nested_class_to_enclosing, find_as_inner_class,
15690 find_as_inner_class_do, check_inner_class_redefinition,
15691 build_thisn_assign, build_current_thisn, build_access_to_thisn,
15692 maybe_build_thisn_access_method, build_outer_field_access,
15693 build_outer_field_access_methods, build_outer_field_access_expr,
15694 build_outer_method_access_method, build_new_access_id,
15695 build_outer_field_access_method, outer_field_access_p,
15696 outer_field_expanded_access_p, outer_field_access_fix,
15697 build_incomplete_class_ref, patch_incomplete_class_ref,
15698 create_anonymous_class): Likewise.
15699 (inst_id, wpv_id): New static global variables.
15700 (synchronized:): New rule, tagged <node>.
15701 (type_declaration:): No longer tagged <node>. Call POP_CPC in sub
15702 rules.
15703 (anonymous_class_creation:): New rule, tagged <node>.
15704 (NEW_TK): Tagged <node>.
15705 (type_literals, array_type_literal): New rules, tagged <node>.
15706 (class_declaration:): Removed action when reducing by class_body:
15707 (class_body:): Set DECL_END_SOURCE_LINE and rule's returned value
15708 using GET_CPC in sub-rules.
15709 (class_member_declaration): Handle inner classes.
15710 (method_declaration): When reducing method_header:, reset
15711 current_function_decl when appropriate.
15712 (method_declarator:): Set the number of formal parameter to 0 for
15713 method declared without arguments.
15714 (constructor_declarator:): Likewise.
15715 (static_initializer:): List of elements kept in a list.
15716 (static:): Rule modifiers: replaces MODIFIER_TK. Enforce correct
15717 use of the keyword `static' for type declarations.
15718 (block_statement:): Handle inner class declarations.
15719 (primary_no_new_array:): Use type_literals:. Fixed comment. Handle
15720 type qualified `this'.
15721 (class_instance_creation_expression): Use anonymous_class_creation:
15722 to handle inner class instances creation. Handle qualified `new'.
15723 (something_dot_new): Added appropriate actions.
15724 (create_new_parser_context): New function.
15725 (java_push_parser_context, java_parser_context_save_global,
15726 java_parser_context_suspend): Use create_new_parser_context.
15727 (check_modifiers): Changed leading comment.
15728 (check_class_interface_creation): Handle interclasses.
15729 (add_superinterfaces): Fixed comment.
15730 (create_interface): Build qualified name from the raw_name instead
15731 of its matching WFL. Push the initialized fields list. raw_name added
15732 as an extra argument to maybe_create_class_interface_decl.
15733 (create_class): Build qualified name from the raw_name instead of
15734 its matching WFL. Removed assignment to current_parsed_class_un.
15735 Call PUSH_ERROR before returning an error. Suspend the current
15736 parser context when processing an inner class. Push the
15737 initialized fields list. raw_name added as an extra argument to
15738 maybe_create_class_interface_decl. Add the private this$<n>
15739 field.
15740 (duplicate_declaration_error_p): Use GET_CPC when calling find_field.
15741 (register_fields): Get the class type from GET_CPC and handle
15742 previous errors. Added code to handle the creation of static
15743 fields in inner classes. Initialized fields initialization
15744 statements kept in a list of lists.
15745 (maybe_generate_finit): Initialized fields initialization
15746 statements kept in a list of lists. Use GET_CPC.
15747 (maybe_generate_clinit): Likewise.
15748 (method_header): Use GET_CPC and GET_CPC_UN.
15749 (parser_qualified_classname): Handle inner classes.
15750 (register_incomplete_type): Set JDEP_ENCLOSING using GET_CPC.
15751 (java_fix_constructors): Hide pointer to enclosing context
15752 instance in constructor list when dealing with inner classes.
15753 (jdep_resolve_class): Call resolve_class with extra first argument
15754 JDEP_ENCLOSING.
15755 (resolve_class): Add enclosing context as a first extra argument
15756 to do_resolve_class.
15757 (do_resolve_class): Call find_as_inner_class. Handle WFLs
15758 properly.
15759 (resolve_no_layout): Extra argument added to resolve_class
15760 invocation.
15761 (reset_method_name): Use DECL_CLINIT_P, DECL_FINIT_P.
15762 (java_get_real_method_name): Use GET_CPC_UN.
15763 (check_abstract_method_definitions): Use DECL_CLINIT_P.
15764 (java_check_abstract_methods): Handle static method declared in
15765 inner classes by an error.
15766 (java_check_regular_methods): Use DECL_CLINIT_P.
15767 (source_start_java_method): Also set DECL_MAX_LOCALS.
15768 (create_artificial_method): Call java_parser_context_save_global
15769 and java_parser_context_restore_global instead of saving/restoring
15770 the context by hand.
15771 (expand_start_java_method): Improved verbose mode message.
15772 (java_complete_expand_methods): Fixed leading comment. Use
15773 DECL_CLINIT_P.
15774 (fix_constructors): Added assignment to this$<n> if necessary.
15775 (java_expand_classes): Call java_complete_expand_classes instead
15776 of java_complete_expand_methods.
15777 (make_qualified_primary): Simplified.
15778 (merge_qualified_name): Optimized for missing left or right parts.
15779 (resolve_expression_name): Handle access to outer class fields from
15780 interclasses.
15781 (resolve_qualified_expression_name): New macro
15782 RESTORE_THIS_AND_CURRENT_CLASS, used. Handle creation of inner
15783 classes. Report error on non appropriate qualification of
15784 `new'. Handle qualified `this'.
15785 (not_accessible_p): Allow access to outer class private fields from
15786 inner classes.
15787 (patch_method_invocation): Handle method invocations through
15788 access methods and inner class constructor invocations.
15789 (find_applicable_accessible_methods_list): Search enclosing
15790 contexts of an inner class.
15791 (search_applicable_methods_list): Fixed typo.
15792 (argument_types_convertible): Handle inner class constructors'
15793 hidden outer context reference argument.
15794 (qualify_ambiguous_name): Handle qualified `this'.
15795 (java_complete_lhs): Handle use of field accessed through
15796 artificial access methods in various cases of assignments. Handle
15797 CLASS_LITERAL node.
15798 (check_final_assignment): Use DECL_CLINIT_P.
15799 (valid_ref_assignconv_cast_p): Handle the destination being an
15800 enclosing context of the source.
15801 (patch_unaryop): Handle use of field accessed through artificial
15802 access methods.
15803 (patch_return): Use DECL_CLINIT_P.
15804 (patch_throw_statement): Use DECL_CLINIT_P.
15805 (check_thrown_exceptions): Use DECL_FINIT_P and DECL_INIT_P.
15806 * verify.c (verify_jvm_instructions): Use ID_CLINIT_P and
15807 ID_INIT_P.
15808
15809 2000-01-16 Anthony Green <green@cygnus.com>
15810
15811 * parse.y (build_string_concatenation): Only use
15812 StringBuffer(String) shortcut if String arg is constant.
15813
15814 2000-01-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
15815
15816 * jcf-write.c (generate_bytecode_insns): binop: Change the type of
15817 the shift value to int. Fixed typo in comment.
15818
15819 2000-01-11 Mumit Khan <khan@xraylith.wisc.edu>
15820
15821 * jcf-path.c: Delete PATH_SEPARATOR and DIR_SEPARATOR macros.
15822 * jcf-write.c: Likewise.
15823 * parse.y: Likewise.
15824 * parse.c: Regenerate.
15825
15826 2000-01-09 Anthony Green <green@cygnus.com>
15827
15828 * jcf-write.c (generate_bytecode_insns): Emit invokeinterface
15829 bytecodes in the correct order.
15830
15831 2000-01-09 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15832
15833 * Makefile.in (jcf-dump, gcjh): Move ../errors.o before $(LIBS).
15834
15835 2000-01-06 Anthony Green <green@cygnus.com>
15836
15837 * expr.c (java_lang_expand_expr): Switch to permanent obstack
15838 before building constant array decl.
15839
15840 2000-01-06 Alexandre Petit-Bianco <apbianco@cygnus.com>
15841
15842 * jcf-write.c (generate_bytecode_conditional): Fixed indentation in
15843 method invocation and typo in conditional expression.
15844 (generate_bytecode_insns): COND_EXPR can be part of a binop. Issue
15845 the appropriate NOTE_POP.
15846 * parse.y (patch_binop): Shift value mask to feature the right
15847 type.
15848
15849 1999-12-30 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15850
15851 * class.c (assume_compiled, assume_compiled_node): Add static
15852 prototype.
15853 (add_assume_compiled): Use xmalloc/xstrdup, not malloc/strdup.
15854
15855 * jcf-dump.c (ARRAY_NEW_NUM): Cast long to int in switch.
15856
15857 * jvgenmain.c (usage): Add static prototype with ATTRIBUTE_NORETURN.
15858
15859 * parse.h (OBSOLETE_MODIFIER_WARNING): Rename parameter `modifier'
15860 to `__modifier' to avoid stringifying it.
15861
15862 * parse.y (verify_constructor_circularity): Don't call a variadic
15863 function with a non-literal format string.
15864 (java_check_abstract_methods): Move unreachable code inside
15865 `continue' statement.
15866 (lookup_method_invoke): Call xstrdup, not strdup.
15867
15868 * expr.c (expand_java_field_op): Avoid the use of ANSI string
15869 concatenation.
15870
15871 * jcf-parse.c (yyparse): Likewise.
15872
15873 * jv-scan.c (main): Likewise.
15874
15875 1999-12-30 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15876
15877 * parse.h (ABSTRACT_CHECK, JCONSTRUCTOR_CHECK,
15878 ERROR_CANT_CONVERT_TO_BOOLEAN, ERROR_CANT_CONVERT_TO_NUMERIC,
15879 ERROR_CAST_NEEDED_TO_INTEGRAL): Avoid the use of ANSI string
15880 concatenation.
15881
15882 * parse.y (synchronized, variable_redefinition_error,
15883 check_class_interface_creation, create_interface, create_class,
15884 method_header, finish_method_declaration,
15885 check_modifiers_consistency, method_declarator,
15886 complete_class_report_errors, check_abstract_method_definitions,
15887 java_check_regular_methods, check_throws_clauses,
15888 java_check_abstract_methods, read_import_dir,
15889 check_pkg_class_access, declare_local_variables, fix_constructors,
15890 cut_identifier_in_qualified, resolve_expression_name,
15891 resolve_qualified_expression_name, patch_method_invocation,
15892 java_complete_lhs, patch_assignment, try_builtin_assignconv,
15893 patch_binop, patch_array_ref, patch_newarray, build_labeled_block,
15894 patch_exit_expr, patch_exit_expr, patch_switch_statement,
15895 patch_try_statement, patch_synchronized_statement,
15896 patch_throw_statement, check_thrown_exceptions,
15897 patch_conditional_expr): Likewise.
15898
15899 1999-12-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
15900
15901 * Makefile.in (LIBDEPS): Added gcc's errors.o
15902 (../jcf-dump$(exeext):): Link with gcc's errors.o
15903 (../gcjh$(exeext):): Likewise.
15904 * expr.c (expand_java_NEW): Layout the entire target type instead of
15905 laying out its methods only.
15906 (lookup_field): Layout the class after having loaded it.
15907 * java-tree.h (java_debug_context): Declared.
15908 * jcf-io.c (toplev.h): Included.
15909 (find_class): Removed assignment to jcf's outofsynch
15910 field. Force source file to be read if newer than its matching
15911 class file. Tweaked debug messages.
15912 * jcf-parse.c (jcf_out_of_synch): Deleted.
15913 (read_class): Call to jcf_out_of_synch removed.
15914 * jcf.h (typedef struct JCF): Field `outofsynch' deleted.
15915 (jcf_out_of_synch): Prototype deleted.
15916 * parse.h (struct parser_ctxt): `minus_seen', `java_error_flag',
15917 `deprecated' and `class_err': integer turned into bit-fields.
15918 New bit-fields `saved_data_ctx' and `saved_data'. Fixed comments.
15919 * parse.y (package_list): New global.
15920 (package_declaration:): Record newly parsed package name.
15921 (extra_ctxp_pushed_p): Static global deleted.
15922 (java_parser_context_save_global): Create buffer context for the
15923 purpose of saving globals, if necessary.
15924 (java_parser_context_restore_global): Pop context pushed for the
15925 purpose of saving globals, if necessary.
15926 (java_debug_context_do): New prototype and function.
15927 (java_debug_context): Likewise.
15928 (do_resolve_class): Use already parsed package names to qualify
15929 and lookup class candidate.
15930 (java_pre_expand_clinit): Removed unnecessary local variable.
15931
15932 1999-12-17 Tom Tromey <tromey@cygnus.com>
15933
15934 * gjavah.c (decode_signature_piece): Print "::" in JArray<>. This
15935 fixes PR gcj/119.
15936 (process_file): Use `\n\' at end of each line in string.
15937
15938 1999-12-16 Alexandre Petit-Bianco <apbianco@cygnus.com>
15939
15940 * expr.c (expand_invoke): Layout the loaded class before
15941 attempting to use it.
15942 (expand_java_field_op): Allow final field assignments to take
15943 place in $finit$.
15944 * typeck.c (convert): Return error_mark_node if expr is null.
15945
15946 1999-12-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
15947
15948 * class.c (class_depth): Return -1 if the class doesn't load
15949 properly.
15950 * expr.c (can_widen_reference_to): Check for errors during depth
15951 computation and return 0 accordingly.
15952 * jcf-parse.c (parse_source_file): Call java_fix_constructors to
15953 create default constructors and add an other error check.
15954 * parse.h (java_fix_constructors): Prototyped.
15955 * parse.y (java_pre_expand_clinit): Likewise.
15956 (build_super_invocation): Re-prototyped to feature one argument.
15957 (java_check_circular_reference): Directly use `current'.
15958 (java_fix_constructors): New function.
15959 (java_check_regular_methods): Don't create default constructors
15960 here, but abort if none were found.
15961 (java_complete_expand_methods): Pre-process <clinit> calling
15962 java_pre_expand_clinit.
15963 (java_pre_expand_clinit): New function.
15964 (fix_constructors): build_super_invocation invoked with the
15965 current method declaration as an argument.
15966 (build_super_invocation): Use the context of the processed method
15967 decl argument instead of current_class.
15968 * typeck.c (lookup_java_method): Take WFLs in method names into
15969 account.
15970
15971 1999-12-14 Per Bothner <per@bothner.com>
15972
15973 * class.c (make_class_data): flag_keep_inline_functions to keep
15974 private methods in the method array.
15975
15976 1999-12-15 Anthony Green <green@cygnus.com>
15977
15978 * check-init.c (check_init): Take into account both types of
15979 `throw's when checking for uninitialized variables.
15980
15981 1999-12-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
15982
15983 * parse.y (java_complete_lhs): Force conversion of array
15984 dimensions to int_type_node, that's what runtime's ABI expects.
15985
15986 1999-12-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
15987
15988 * parse.h (EXPR_WFL_QUALIFICATION): Temporary uses the third
15989 operand of a WFL, until the Java front-end gets fixed with regard
15990 to Mark Mitchell's gcc/tree.h patch (1999-12-04.)
15991
15992 1999-12-10 Andrew Haley <aph@cygnus.com>
15993
15994 * parse.h (BUILD_THROW): Add support for sjlj-exceptions.
15995 decl.c (init_decl_processing): Add _Jv_Sjlj_Throw.
15996 expr.c (build_java_athrow): Add support for sjlj-exceptions.
15997 java-tree.h: Ditto.
15998 jcf-write.c: Ditto.
15999
16000 1999-12-08 Alexandre Petit-Bianco <apbianco@cygnus.com>
16001
16002 * expr.c (java_lang_expand_expr): Switch to permanent obstack
16003 before calling expand_eh_region_start and expand_start_all_catch.
16004 * except.c (expand_start_java_handler): Switch to permanent
16005 obstack before calling expand_eh_region_start.
16006 (expand_end_java_handler): Switch to permanent obstack before
16007 calling expand_start_all_catch.
16008
16009 1999-12-5 Anthony Green <green@cygnus.com>
16010
16011 * decl.c (init_decl_processing): Mark throw_node as a noreturn
16012 function with side effects.
16013 (init_decl_processing): Mark all memory allocating DECLs with
16014 DECL_IS_MALLOC.
16015
16016 1999-12-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
16017
16018 * except.c (expand_end_java_handler): Call
16019 expand_resume_after_catch and end_catch_handler.
16020
16021 1999-11-30 Anthony Green <green@cygnus.com>
16022
16023 * verify.c (verify_jvm_instructions): Create new return label
16024 chain if non existent (don't rely on the verified state of the jsr
16025 target.)
16026
16027 1999-11-30 Alexandre Petit-Bianco <apbianco@cygnus.com>
16028
16029 * jcf-write.c (generate_bytecode_insns): Fixed indentation for
16030 COMPOUND_EXPR and FIX_TRUNC_EXPR cases.
16031
16032 * parse.y (patch_assignment): Removed bogus final class test on
16033 lhs when checking on whether to emit an ArrayStoreException runtime
16034 check.
16035 * expr.c (expand_java_arraystore): Likewise.
16036
16037 1999-11-28 Anthony Green <green@cygnus.com>
16038
16039 * decl.c (find_local_variable): Reuse single slot decls when
16040 appropriate.
16041
16042 1999-11-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
16043
16044 * jcf-parse.c (saw_java_source): Global variable removed.
16045 (read_class): Don't use `saw_java_source'. Added extra braces.
16046 (yyparse): Code setting `saw_java_source' removed.
16047
16048 1999-11-24 Mark Mitchell <mark@codesourcery.com>
16049
16050 * except.c (emit_handlers): Zero catch_clauses after emitting them.
16051
16052 1999-11-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
16053
16054 * verify.c (merge_type_state): Non verified subroutines being
16055 considered more than once to trigger passive type merge.
16056
16057 1999-11-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
16058
16059 * parse.y (catch_clause_parameter:): Still set `$$' to NULL_TREE
16060 in case of error. Error message tuned.
16061
16062 1999-11-21 Anthony Green <green@cygnus.com>
16063
16064 * constants.c (find_methodref_index): Unwrap method names before
16065 inserting them in the constant pool.
16066
16067 * jcf-parse.c (jcf_parse): Display `interface' when appropriate.
16068
16069 * class.c (assume_compiled_node): New typedef.
16070 (assume_compiled_tree): New static data.
16071 (find_assume_compiled_node): New function.
16072 (add_assume_compiled): New function.
16073 (assume_compiled): New function.
16074 * class.c (make_class_data): Use assume_compiled.
16075 (is_compiled_class): Use assume_compiled.
16076
16077 * java-tree.h (add_assume_compiled): Declare.
16078
16079 * lang.c (lang_decode_option): Parse new options.
16080
16081 1999-11-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
16082
16083 * class.c (layout_class): Always convert TYPE_SIZE_UNIT to
16084 int_type_node: that's what `_Jv_AllocObject' expects.
16085
16086 1999-11-11 Alexandre Petit-Bianco <apbianco@cygnus.com>
16087
16088 * parse.y (lookup_method_invoke): Use lang_printable_name to
16089 reliably build the type name during error report. Fixes PR gcj/97.
16090
16091 1999-11-09 Tom Tromey <tromey@cygnus.com>
16092
16093 * jcf-path.c: Include <sys/stat.h>.
16094 (jcf_path_init): Search for libjava.zip. Fixes PR gcj/84.
16095 (DIR_UP): New macro.
16096
16097 1999-11-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
16098
16099 * parse.y (source_end_java_method): Resume permanent allocation,
16100 reversing Apr 27 1998 patch.
16101 (patch_string_cst): Pop obstacks after having pushed the permanent
16102 ones.
16103
16104 1999-11-05 Tom Tromey <tromey@cygnus.com>
16105
16106 * class.c (finish_class): Emit inlined methods if any native
16107 methods exist in the class. Fixes PR gcj/85.
16108
16109 1999-11-04 Alexandre Petit-Bianco <apbianco@cygnus.com>
16110
16111 * parse.y (resolve_qualified_expression_name): Handle PLUS_EXPR.
16112 (qualify_ambiguous_name): Likewise.
16113
16114 1999-11-03 Godmar Back <gback@cs.utah.edu>
16115
16116 * typeck.c: (lookup_java_method): search all inherited
16117 interfaces when looking up interface method.
16118
16119 1999-11-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
16120
16121 * parse.y (method_header:): Issue error message for rule `type
16122 error'.
16123 (synchronized:): Error report when not using synchronized.
16124
16125 1999-11-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
16126
16127 * parse.y (resolve_qualified_expression_name): Prevent `this' from
16128 being used before the superclass constructor has been called.
16129 (complete_function_arguments): Use CALL_EXPLICIT_CONSTRUCTOR_P
16130 instead of `CALL_THIS_CONSTRUCTOR_P'.
16131
16132 1999-10-30 Todd T. Fries <todd@lighthouse.fries.net>
16133
16134 * check-init.c: Fix typo in comment.
16135
16136 1999-10-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
16137
16138 * class.c (add_method_1): Set DECL_INLINE to 1 for private, static
16139 and final method.
16140
16141 1999-10-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
16142
16143 * parse.y (expression_statement:): Call function to report
16144 improper invocation of a constructor.
16145 (parse_ctor_invocation_error): New function.
16146
16147 1999-10-26 Mark Mitchell <mark@codesourcery.com>
16148
16149 * decl.c (poplevel): Don't set BLOCK_TYPE_TAGS or call
16150 remember_end_note.
16151
16152 1999-10-21 Tom Tromey <tromey@cygnus.com>
16153
16154 * jvgenmain.c (main): _Jv_Compiler_Properties now an extern; set
16155 in generated `main'.
16156
16157 1999-10-21 Alexandre Petit-Bianco <apbianco@cygnus.com>
16158
16159 * parse.y (resolve_qualified_expression_name): Handle MODIFY_EXPR.
16160 (qualify_ambiguous_name): Likewise.
16161
16162 1999-10-20 Alexandre Petit-Bianco <apbianco@cygnus.com>
16163
16164 * parse.y (java_complete_tree): fold_constant_for_init to work on
16165 permanent_obstack.
16166 (java_complete_lhs): Likewise.
16167 (array_constructor_check_entry): Complete an initializer element
16168 on permanent_obstack.
16169
16170 1999-10-19 Tom Tromey <tromey@cygnus.com>
16171
16172 * jcf-parse.c (parse_source_file): Call jcf_dependency_add_file.
16173 From Mike Moreton <mike@pillim.demon.co.uk>.
16174
16175 1999-10-15 Greg McGary <gkm@gnu.org>
16176
16177 * java-tree.h (flag_bounds_check): Remove extern decl.
16178 * lang.c (flag_bounds_check): Remove global variable.
16179 (lang_f_options): Remove "bounds-check" entry.
16180 (lang_init_options): Default flag_bounds_check to "on".
16181
16182 1999-10-14 Tom Tromey <tromey@cygnus.com>
16183
16184 * jvgenmain.c (usage): New function.
16185 (main): Use it. Also, handle `-D' options.
16186 * jvspec.c (lang_specific_driver): Recognize -D.
16187 (jvgenmain_spec): Added `%{D*}' to jvgenmain invocation.
16188
16189 * jvspec.c (jvgenmain_spec): Use `%umain', not just `%u'.
16190
16191 1999-10-14 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16192
16193 * jcf-dump.c (print_constant, disassemble_method): Don't call a
16194 variadic function with a non-literal format string.
16195
16196 * parse-scan.y (report_main_declaration): Likewise.
16197
16198 * parse.h (ERROR_CAST_NEEDED_TO_INTEGRAL): Likewise.
16199
16200 * parse.y (read_import_dir, patch_assignment, patch_binop,
16201 patch_array_ref): Likewise.
16202
16203 * typeck.c (build_java_array_type): Likewise.
16204
16205 * verify.c (verify_jvm_instructions): Likewise.
16206
16207 1999-10-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
16208
16209 * jcf-write.c (RELOCATION_VALUE_1): Fixed integer value from 0 to 1.
16210
16211 1999-10-07 Anthony Green <green@cygnus.com>
16212
16213 * jcf-write.c (generate_classfile): Use UNSAFE_PUTx in cases
16214 where CHECK_PUT may fail for valid reasons.
16215
16216 * jcf-write.c (UNSAFE_PUT1, UNSAFE_PUT2, UNSAFE_PUT3,
16217 UNSAFE_PUTN): New macros.
16218
16219 1999-10-04 Tom Tromey <tromey@cygnus.com>
16220
16221 * lex.h (BUILD_OPERATOR2): Return ASSIGN_ANY_TK in `lite' case as
16222 well. Fixes Java PR gcj/59.
16223 * parse-scan.y (yyerror): Report errors.
16224
16225 1999-09-24 Glenn Chambers <GChambers@provsol.com>
16226
16227 * decl.c (insert_block): Remove unconditional `abort'.
16228
16229 1999-09-24 Bernd Schmidt <bernds@cygnus.co.uk>
16230
16231 * decl.c (builtin_function): No longer static. New arg CLASS. Arg
16232 FUNCTION_CODE now of type int. All callers changed.
16233 Set the builtin's DECL_BUILT_IN_CLASS.
16234
16235 1999-09-23 Tom Tromey <tromey@cygnus.com>
16236
16237 * jvspec.c (lang_specific_driver): Don't read spec file if
16238 -fsyntax-only given.
16239
16240 1999-09-22 Tom Tromey <tromey@cygnus.com>
16241
16242 * lang-specs.h: Added `%(jc1)' to the jc1 spec.
16243
16244 * javaop.h (WORD_TO_FLOAT): Use `inline' unconditionally.
16245 (WORDS_TO_LONG): Likewise.
16246 (WORDS_TO_DOUBLE): Likewise.
16247
16248 1999-09-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
16249
16250 * jcf-write.c (RELOCATION_VALUE_0): New macro.
16251 (RELOCATION_VALUE_1): Likewise.
16252 (emit_iinc, emit_reloc, push_constant1, push_constant2,
16253 push_in_const, push_long_const): Prototyped.
16254 (push_constant1): Argument `index' is of type HOST_WIDE_INT.
16255 (push_constant2): Likewise.
16256 (push_int_const): Cast find_constant1's integer arguments to `jword'.
16257 (find_constant_wide): Cast find_constant2's integer arguments to
16258 `jword'.
16259 (find_constant_index): Cast find_constant2's and find_constant2's
16260 integer arguments to `jword'.
16261 (emit_pop): Argument `value' is of type HOST_WIDE_INT.
16262 (emit_switch_reloc): Use RELOCATION_VALUE_0.
16263 (emit_if): Use RELOCATION_VALUE_1.
16264 (emit_goto): Likewise.
16265 (emit_jsr): Likewise.
16266 (generate_bytecode_insns): Use RELOCATION_VALUE_0. Cast second
16267 argument to push_long_const to HOST_WIDE_INT.
16268
16269 1999-09-15 Andreas Schwab <schwab@suse.de>
16270
16271 * Makefile.in (parse.o): Depend on $(JAVA_TREE_H).
16272
16273 1999-09-20 Nick Clifton <nickc@cygnus.com>
16274
16275 * lang.c (lang_decode_option): Extend comment.
16276
16277 1999-09-16 Alexandre Petit-Bianco <apbianco@cygnus.com>
16278
16279 * parse.y (java_method_add_stmt): Test against GET_CURRENT_BLOCK
16280 instead of fndecl.
16281
16282 1999-09-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16283
16284 * gjavah.c (get_field_name, print_method_info, print_include,
16285 add_namelet): Use xmalloc, not malloc.
16286
16287 * jcf-depend.c (add_entry): Likewise. Use xstrdup, not strdup.
16288 (munge): Use xrealloc, not realloc, trust xrealloc to handle a
16289 NULL pointer.
16290
16291 * jcf-io.c (open_in_zip, find_class): Use xstrdup, not strdup.
16292
16293 * jcf-parse.c (jcf_out_of_synch, yyparse): Likewise.
16294
16295 * jcf-path.c (add_entry): Likewise.
16296
16297 * jcf.h (ALLOC, REALLOC): Use xmalloc/xrealloc, not malloc/realloc.
16298
16299 * jv-scan.c (xmalloc): Remove definition.
16300
16301 * jvgenmain.c (xmalloc): Likewise.
16302
16303 * jvspec.c (lang_specific_driver): Use xcalloc, not xmalloc/bzero.
16304
16305 * lex.c (java_store_unicode): Use xrealloc, not realloc.
16306
16307 * parse-scan.y: Use concat, not of xmalloc/assign/strcpy. Use
16308 concat, not xmalloc/sprintf.
16309 (java_push_parser_context): Use xcalloc, not xmalloc/bzero.
16310 (xstrdup): Remove definition.
16311
16312 * parse.y (duplicate_declaration_error_p,
16313 constructor_circularity_msg, verify_constructor_circularity,
16314 check_abstract_method_definitions, java_check_regular_methods,
16315 java_check_abstract_methods, patch_method_invocation,
16316 check_for_static_method_reference, patch_assignment, patch_binop,
16317 patch_cast, array_constructor_check_entry, patch_return,
16318 patch_conditional_expr): Use xstrdup, not strdup.
16319
16320 * zextract.c (ALLOC): Use xmalloc, not malloc.
16321
16322 1999-09-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16323
16324 * Make-lang.in (jvspec.o): Depend on system.h and gcc.h.
16325
16326 * jvspec.c: Include gcc.h. Don't include gansidecl.h.
16327 (do_spec, lang_specific_pre_link, lang_specific_driver,
16328 input_filename, input_filename_length): Don't declare.
16329 (main_class_name, jvgenmain_spec, lang_specific_driver):
16330 Constify a char*.
16331 (lang_specific_driver): All calls to the function pointer
16332 parameter now explicitly call `fatal'.
16333
16334 1999-09-11 Alexandre Petit-Bianco <apbianco@cygnus.com>
16335
16336 * parse.y (find_applicable_accessible_methods_list): Search
16337 abstract classes as interfaces.
16338
16339 1999-09-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
16340
16341 * class.c (finish_class): We're now outside a valid method
16342 declaration. Tell the rest of gcc so.
16343
16344 1999-09-08 Bruce Korb autogen@linuxbox.com
16345
16346 * Makefile.in: Give the gperf user a hint about why "gperf -F" fails.
16347
16348 1999-09-07 Tom Tromey <tromey@cygnus.com>
16349
16350 * gjavah.c (add_class_decl): Generate include for gcj/array.h, not
16351 java-array.h.
16352 (decode_signature_piece): Don't emit "::" in JArray<>.
16353 (print_namelet): Only print trailing `;' when printing a class.
16354
16355 1999-09-10 Bernd Schmidt <bernds@cygnus.co.uk>
16356
16357 * java-tree.h: Delete declarations for all tree nodes now moved to
16358 global_trees.
16359 * decl.c: Delete their definitions.
16360
16361 1999-09-04 Mark Mitchell <mark@codesourcery.com>
16362
16363 * Make-lang.in (jc1): Depend on ggc-callbacks.o.
16364 * Makefile.in (OBJS): Add ggc-callbacks.o.
16365 (OBJDEPS): Likewise.
16366
16367 1999-09-03 Tom Tromey <tromey@cygnus.com>
16368
16369 * parse.y (strip_out_static_field_access_decl): Return operand if
16370 it satisfies JDECL_P.
16371
16372 1999-09-02 Tom Tromey <tromey@cygnus.com>
16373
16374 * gjavah.c (decode_signature_piece): Emit "::" in JArray<>.
16375 Handle nested arrays, like `[[I'.
16376
16377 1999-09-02 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16378
16379 * class.c (finish_class): Remove unused parameter, all callers
16380 changed.
16381
16382 * expr.c (build_java_athrow): Change return type to void.
16383 (java_lang_expand_expr): Make sure each case in switch returns a
16384 value.
16385
16386 * java-tree.h (finish_class): Fix prototype to take void args.
16387
16388 * jcf-dump.c (usage): Mark with ATTRIBUTE_NORETURN.
16389 (main): Issue return from main, not exit.
16390
16391 * jcf-parse.c (parse_class_file): Fix call to `finish_class'.
16392
16393 * jcf.h (jcf_unexpected_eof): Mark with ATTRIBUTE_NORETURN.
16394
16395 * jv-scan.c (main): Issue return from main, not exit.
16396
16397 * parse.y (check_abstract_method_definitions,
16398 java_check_abstract_method_definitions): Add static prototypes.
16399 (java_complete_expand_methods): Fix call to `finish_class'.
16400
16401 * verify.c (verify_jvm_instructions): Initialize variables `oldpc'
16402 and `prevpc'.
16403
16404 1999-08-30 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16405
16406 * lang.c (language_string): Constify.
16407
16408 1999-08-30 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16409
16410 * Makefile.in (LIBS): Fix definition so we link with $(CLIB).
16411 Remove hacks for stuff which comes from libiberty.
16412
16413 * Make-lang.in: Likewise.
16414
16415 1999-08-30 Hans-Peter Nilsson <hp@axis.se>
16416
16417 * Makefile.in (xref.o): Depend on xref.c explicitly.
16418
16419 1999-08-29 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16420
16421 * java-tree.h (lang_printable_name): Constify a char*.
16422
16423 * lang.c (lang_printable_name): Likewise.
16424
16425 1999-08-27 Jeffrey A Law (law@cygnus.com)
16426
16427 * gjavah.c, jcf-write.c, verify.c: Do not use C++ style
16428 comments in C code.
16429
16430 1999-08-26 Tom Tromey <tromey@cygnus.com>
16431
16432 * gjavah.c (print_cxx_classname): Print "::" before qualified
16433 name.
16434
16435 1999-08-26 Alexandre Petit-Bianco <apbianco@cygnus.com>
16436
16437 * parse.y (lookup_cl): Changed leading comment. Now does its best
16438 to set the column number.
16439 (qualify_ambiguous_name): Take WFL wrappers into account.
16440
16441 1999-08-25 Gregg Townsend <gmt@cs.arizona.edu>
16442
16443 * verify.c (verify_jvm_instructions): Don't check instruction
16444 validity beyond end of method.
16445
16446 1999-08-25 Tom Tromey <tromey@cygnus.com>
16447
16448 * jvspec.c (lang_specific_driver): Correctly handle --help again.
16449
16450 1999-08-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16451
16452 * gjavah.c (print_name, print_base_classname, utf8_cmp,
16453 cxx_keyword_subst, generate_access, name_is_method_p,
16454 get_field_name, print_field_name, super_class_name, print_include,
16455 decode_signature_piece, print_class_decls, usage, help,
16456 java_no_argument, version, add_namelet, print_namelet): Add static
16457 prototype.
16458 (print_base_classname, utf8_cmp, cxx_keyword_subst,
16459 name_is_method_p): Constify a char*.
16460 (get_field_name): Likewise. Prefer xstrdup over malloc/strcpy.
16461 Provide a final else clause in an if-else-if.
16462 (print_field_info): Add missing final arg in function call to
16463 `print_field_name'.
16464 (print_method_info, decompile_method, decode_signature_piece,
16465 print_c_decl, print_full_cxx_name, print_stub,
16466 print_mangled_classname, super_class_name, print_include,
16467 add_namelet, add_class_decl, print_class_decls, process_file,
16468 help): Constify a char*.
16469
16470 * jcf-write.c (jcf_handler, push_constant1, push_constant2,
16471 push_int_const, find_constant_wide, find_constant_index,
16472 push_long_const, field_op, maybe_wide, emit_dup, emit_pop,
16473 emit_iinc, emit_load_or_store, emit_load, emit_store, emit_unop,
16474 emit_binop, emit_reloc, emit_switch_reloc, emit_case_reloc,
16475 emit_if, emit_goto, emit_jsr, call_cleanups,
16476 make_class_file_name): Add static prototypes.
16477 (generate_bytecode_return, generate_bytecode_insns): Pass a
16478 NULL_PTR, not a NULL_TREE.
16479
16480 * jv-scan.c: Include "jcf.h".
16481 (main): Declare using DEFUN macro.
16482
16483 * jvspec.c (find_spec_file, lang_specific_pre_link,
16484 lang_specific_driver): Add prototypes.
16485 (find_spec_file): Constify a char*.
16486
16487 * keyword.gperf (hash, java_keyword): Add prototypes.
16488
16489 * lang.c (lang_print_error): Add static prototype.
16490 (lang_init): Prefer memcpy over bcopy to avoid casts.
16491
16492 * lex.c (yylex): Add static prototype.
16493
16494 * parse-scan.y: Include "lex.c" earlier.
16495
16496 * parse.h: Remove redundant declaration for `yylex'.
16497
16498 * parse.y (java_decl_equiv, binop_compound_p, search_loop,
16499 labeled_block_contains_loop_p): Add static prototypes.
16500 (not_accessible_p): Make static to match prototype.
16501
16502 * verify.c (start_pc_cmp): Don't needlessly cast away const.
16503
16504 1999-08-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
16505
16506 * parse.y (check_method_redefinition): Changed leading comment.
16507 (check_abstract_method_definitions): New function.
16508 (java_check_abstract_method_definitions): New function.
16509 (java_check_regular_methods): Call it.
16510 (verify_constructor_super): Fixed indentation.
16511 (lookup_method_invoke): Likewise.
16512
16513 1999-08-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
16514
16515 * parse.y (method_header): Return a null pointer if the current
16516 class node is null.
16517 (finish_method_declaration): Return if the current function decl
16518 is null.
16519 (source_start_java_method): Likewise.
16520 (java_method_add_stmt): Likewise.
16521
16522 1999-08-18 Alexandre Petit-Bianco <apbianco@cygnus.com>
16523
16524 * class.c (emit_register_class): Removed unnecessary call to
16525 start_sequence.
16526 * parse.y (labeled_block_contains_loop_p): Removed unused local
16527 variable.
16528
16529 1999-08-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
16530
16531 * parse.y (java_refold): Added prototype.
16532
16533 1999-08-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
16534
16535 * parse.y (BINOP_COMPOUND_CANDIDATES): New macro.
16536 (java_stabilize_reference): Removed unnecessary `else'.
16537 (java_complete_lhs): Set flag to remember boolean. Call
16538 java_refold. Added comments.
16539 (java_decl_equiv): New function.
16540 (binop_compound_p): Likewise.
16541 (java_refold): Likewise.
16542 (patch_unaryop): Striped static field access assigned to decl and
16543 op. Changed promotion scheme for ++/-- operators.
16544 (search_loop): New function.
16545 (labeled_block_contains_loop_p): Likewise.
16546 (patch_loop_statement): Call labeled_block_contains_loop_p. Added
16547 comment.
16548 (patch_bc_statement): Call search_loop. Fixed comment.
16549
16550 1999-08-14 Anthony Green <green@cygnus.com>
16551
16552 * expr.c (java_lang_expand_expr): Mark static array data as
16553 referenced.
16554
16555 1999-08-10 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
16556
16557 * jvgenmain.c (main): NUL-terminate name_obstack.
16558
16559 1999-08-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16560
16561 * check-init.c (check_bool2_init, done_alternative): Add static
16562 prototypes.
16563
16564 * class.c (add_interface_do, maybe_layout_super_class): Likewise.
16565 (add_method, build_utf8_ref, build_class_ref,
16566 append_gpp_mangled_type, layout_class_method): Constify a char*.
16567
16568 * decl.c (push_promoted_type, make_binding_level): Add static
16569 prototypes.
16570 (push_promoted_type, pushdecl): Constify a char*.
16571
16572 * except.c (find_handler_in_range, link_handler,
16573 check_start_handlers): Add static prototypes.
16574
16575 * expr.c (process_jvm_instruction): Constify a char*.
16576
16577 * gjavah.c (main): Constify a char*.
16578
16579 * java-tree.h (verify_jvm_instructions, process_jvm_instruction):
16580 Constify a char*.
16581
16582 * jcf-depend.c (free_entry, add_entry, munge, print_ents): Add
16583 static prototypes.
16584 (add_entry, jcf_dependency_set_target, jcf_dependency_add_target,
16585 munge, print_ents): Constify a char*.
16586
16587 * jcf-dump.c (disassemble_method): Constify a char*.
16588 (print_constant_pool, print_exception_table): Add static prototypes.
16589 (print_constant, print_exception_table, main, disassemble_method):
16590 Constify a char*.
16591
16592 * jcf-io.c (find_classfile, find_class): Likewise.
16593
16594 * jcf-parse.c (JPOOL_UTF_DATA, find_in_current_zip): Likewise.
16595 (set_source_filename, predefined_filename_p): Add static prototypes.
16596 (set_source_filename, get_constant, get_class_constant,
16597 find_in_current_zip): Constify a char*.
16598
16599 * jcf-path.c (free_entry, append_entry, add_entry, add_path): Add
16600 static prototypes.
16601 (add_entry, add_path, jcf_path_classpath_arg,
16602 jcf_path_CLASSPATH_arg, jcf_path_include_arg): Constify a char*.
16603
16604 * jcf-reader.c (get_attribute, jcf_parse_preamble,
16605 jcf_parse_constant_pool, jcf_parse_class, jcf_parse_fields,
16606 jcf_parse_one_method, jcf_parse_methods,
16607 jcf_parse_final_attributes): Add static prototypes.
16608 (get_attribute): Constify a char*.
16609
16610 * jcf.h (find_class, find_classfile, jcf_dependency_set_target,
16611 jcf_dependency_add_target, jcf_path_classpath_arg,
16612 jcf_path_CLASSPATH_arg, jcf_path_include_arg): Constify a char*.
16613
16614 * jv-scan.c (main): Constify a char*.
16615 (gcc_obstack_init): Add prototype arguments.
16616
16617 * jvgenmain.c (gcc_obstack_init): Likewise.
16618 (main): Constify a char*.
16619
16620 * lang.c (put_decl_string, put_decl_node, java_dummy_print): Add
16621 static prototypes.
16622 (put_decl_string, lang_print_error): Constify a char*.
16623 (lang_init): Remove redundant extern prototype.
16624
16625 * mangle.c (emit_unicode_mangled_name): Constify a char*.
16626
16627 * typeck.c (convert_ieee_real_to_integer, parse_signature_type):
16628 Add static prototypes.
16629 (get_type_from_signature): Constify a char*.
16630
16631 * verify.c (check_pending_block, type_stack_dup, start_pc_cmp ):
16632 Add static prototypes.
16633 (start_pc_cmp): Prefer PTR over GENERIC_PTR.
16634 (verify_jvm_instructions): Constify a char*.
16635
16636 * xref.c (xref_flag_value): Likewise.
16637
16638 * xref.h (xref_flag_value): Likewise.
16639
16640 * zextract.c (makeword, makelong): Add static prototypes.
16641 (makeword, makelong): Constify a uch*.
16642
16643 1999-08-09 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16644
16645 * lang.c (java_dummy_print): Constify a char*.
16646 (lang_print_error): Likewise.
16647 (lang_init): Remove redundant prototype for `print_error_function'.
16648 (lang_init_source): Likewise.
16649 (lang_identify): Constify a char*.
16650
16651 1999-08-09 Tom Tromey <tromey@cygnus.com>
16652
16653 * javaop.h (WORD_TO_FLOAT): only inline if building with gcc.
16654 (WORDS_TO_LONG): Likewise.
16655 (WORDS_TO_DOUBLE): Likewise.
16656
16657 1999-08-04 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16658
16659 * Makefile.in (lang.o): Depend on $(RTL_H) $(EXPR_H).
16660
16661 * expr.c (java_stack_pop, java_array_data_offset,
16662 build_java_throw_out_of_bounds_exception, case_identity,
16663 build_java_check_indexed_type): Add static prototypes.
16664 (linenumber_table, expand_invoke, expand_java_field_op,
16665 build_primtype_type_ref, expand_byte_code): Constify a char*.
16666
16667 * java-tree.h (build_primtype_type_ref, linenumber_table):
16668 Constify a char*.
16669 (java_lang_expand_expr): Add prototype.
16670
16671 * lang.c: Include rtl.h and expr.h. Remove extern prototype for
16672 `java_lang_expand_expr'.
16673
16674 * lex.c (java_lex_error): Constify a char*.
16675 (java_get_unicode, java_read_char, java_allocate_new_line,
16676 java_unget_unicode, java_sneak_unicode): Prototype.
16677
16678 * parse-scan.y (current_class, package_name, method_declarator,
16679 report_class_declaration, yyerror): Constify a char*.
16680
16681 * parse.h (java_report_errors): Prototype.
16682 (yyerror): Constify a char*.
16683
16684 * parse.y (classitf_redefinition_error, check_modifiers,
16685 parse_jdk1_1_error, lookup_package_type,
16686 lookup_package_type_and_set_next, get_printable_method_name,
16687 purify_type_name): Constify a char*.
16688 (build_super_invocation, maybe_generate_finit,
16689 verify_constructor_super, parser_add_interface,
16690 add_superinterfaces, jdep_resolve_class, note_possible_classname,
16691 java_complete_expand_methods, java_expand_finals,
16692 cut_identifier_in_qualified, java_stabilize_reference,
16693 do_unary_numeric_promotion, operator_string, do_merge_string_cste,
16694 merge_string_cste): Prototype.
16695 (single_type_import_declaration, yyerror,
16696 variable_redefinition_error, build_array_from_name,
16697 build_unresolved_array_type, check_class_interface_creation,
16698 resolve_class, complete_class_report_errors,
16699 note_possible_classname, read_import_dir,
16700 find_in_imports_on_demand, resolve_package, fix_constructors,
16701 check_deprecation, lookup_method_invoke,
16702 maybe_build_primttype_type_ref, array_constructor_check_entry):
16703 Constify a char*.
16704 (java_complete_expand_methods, java_expand_finals): Make static.
16705 (convert_narrow): Remove static prototype.
16706
16707 1999-08-03 J"orn Rennecke <amylaar@cygnus.co.uk>
16708
16709 * Makefile.in (decl.o): Depends on $(srcdir)/../defaults.h.
16710
16711 1999-08-02 Richard Henderson <rth@cygnus.com>
16712
16713 * decl.c: Include defaults.h instead of expr.h.
16714 * parse.y: Likewise.
16715
16716 1999-08-02 Jakub Jelinek <jj@ultra.linux.cz>
16717
16718 * java/decl.c (start_java_method): Change all uses of
16719 PROMOTE_PROTOTYPES, so that it tests it as a C expression.
16720 Ensure expr.h is included.
16721 * java/expr.c (pop_arguments): Ditto.
16722 * java/parse.y (expand_start_java_method): Ditto.
16723
16724 1999-08-01 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16725
16726 * Makefile.in (ALL_CFLAGS): Add '-W -Wall'.
16727
16728 1999-07-31 Bernd Schmidt <bernds@cygnus.co.uk>
16729
16730 * decl.c: Include "function.h".
16731 * except.c: Likewise.
16732 * parse.y: Likewise.
16733 * Makefile.in: Update dependencies.
16734
16735 1999-07-30 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16736
16737 * expr.c (build_java_soft_divmod): Provide a default case in switch.
16738 (java_lang_expand_expr): Mark parameters `target', `tmode' and
16739 `modifier' with ATTRIBUTE_UNUSED.
16740
16741 * gjavah.c (process_file): Add braces around ambiguous `else'.
16742
16743 * jcf-dump.c (print_access_flags, localvar_free): Change return
16744 type to void.
16745
16746 * parse.y (java_complete_expand_method): Initialize variable
16747 `exception_copy'.
16748 (resolve_qualified_expression_name): Likewise for `field_decl'.
16749 (patch_method_invocation): Likewise for `class_to_search'.
16750 (qualify_ambiguous_name): Likewise for `name' and `ptr_type'.
16751 (patch_assignment): Likewise for `lhs_type'.
16752
16753 * verify.c (verify_jvm_instructions): Remove unused variable
16754 `caller'.
16755
16756 1999-07-25 Richard Henderson <rth@cygnus.com>
16757
16758 * decl.c (va_list_type_node): New.
16759
16760 1999-07-25 Anthony Green <green@cygnus.com>
16761
16762 * gjavah.c (print_stub): New function.
16763 (METHOD_IS_NATIVE): New macro.
16764 (print_mangled_classname): Make static.
16765 (HANDLE_END_FIELD): Don't emit fields during stub generation.
16766 (process_file): Perform stub generation.
16767 (HANDLE_METHOD): Don't emit class decls during stub
16768 generation.
16769 (HANDLE_END_METHOD): Take into account stub generation.
16770 (print_method_info): Handle stub generation.
16771 (print_stub): New function.
16772 (print_cxx_classname): Make signature consistant with others.
16773 (help): Describe -stubs option.
16774 (main): Create stub file.
16775 (version): Use version.c.
16776 (print_full_cxx_name): New function.
16777 (print_c_decl): Use print_full_cxx_name.
16778
16779 1999-07-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
16780
16781 * check-init.c (check_init): Handle MAX_EXPR.
16782
16783 1999-07-15 Andrew Haley <aph@cygnus.com>
16784
16785 * lang.c (flag_use_divide_subroutine): New variable.
16786 * typeck.c: (convert_ieee_real_to_integer): Bounds check
16787 fp-to-integer conversion.
16788 (convert): Call convert_ieee_real_to_integer when flag_fast_math
16789 is not set.
16790
16791 * expr.c (build_java_soft_divmod): New function.
16792 (build_java_binop): Call build_java_soft_divmod if
16793 flag_use_divide_subroutine is set.
16794 * decl.c: soft_idiv_node, soft_irem_node, soft_ldiv_node, tree
16795 soft_lrem_node: new builtin functions.
16796 (init_decl_processing) Initialize the new builtins.
16797 * java-tree.h soft_idiv_node, soft_irem_node, soft_ldiv_node, tree
16798 soft_lrem_node: new builtin functions.
16799 (build_java_soft_divmod): New function.
16800 * parse.y: Call build_java_soft_divmod if
16801 flag_use_divide_subroutine is set.
16802 * parse.c: Rebuilt.
16803
16804 * jvspec.c (lang_specific_driver): Always allow an extra arg (for
16805 a --specs= arg) even if not linking.
16806 * lang-options.h (DEFINE_LANG_NAME ("Java")): Add
16807 -fuse-divide-subroutine
16808
16809 1999-07-20 Alexandre Petit-Bianco <apbianco@cygnus.com>
16810
16811 * parse.y (resolve_and_layout): Check methods only once.
16812 (resolve_qualified_expression_name): Verify thrown exceptions
16813 compatibility.
16814 (check_thrown_exceptions): Reject exceptions thrown in
16815 initializer. Error message tuned.
16816
16817 1999-07-14 Andrew Haley <aph@cygnus.com>
16818
16819 * expr.c (expand_expr): Do not return the last statement in a
16820 block as the block's value.
16821
16822 1999-07-03 Alexandre Petit-Bianco <apbianco@cygnus.com>
16823
16824 * expr.c (force_evaluation_order): Save the COMPOUND_EXPR'ed
16825 CALL_EXPR, to avoid order of evaluation changes.
16826
16827 1999-07-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
16828
16829 * parse.y (qualify_ambiguous_name): Do not use
16830 IDENTIFIER_LOCAL_VALUE when name is a STRING_CST.
16831
16832 1999-07-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
16833
16834 * check-init.c (check_init): Handle MAX_EXPR.
16835 * expr.c (force_evaluation_order): Force method call arguments to
16836 be evaluated in left-to-right order.
16837 * parse.y (qualify_ambiguous_name): Loop again to qualify
16838 NEW_ARRAY_EXPR properly.
16839
16840 1999-06-30 Alexandre Petit-Bianco <apbianco@cygnus.com>
16841
16842 * parse.y (patch_invoke): Resolve unresolved invoked method
16843 returned type.
16844 (qualify_ambiguous_name): STRING_CST to qualify expression for
16845 type name resolution.
16846
16847 1999-06-24 Andrew Haley <aph@cygnus.com>
16848
16849 * class.c (finish_class): Whenever a deferred method is
16850 output, rescan the list of methods to see if a new candidate for
16851 output can be found.
16852
16853 1999-06-28 Tom Tromey <tromey@cygnus.com>
16854
16855 * jvspec.c (lang_specific_driver): Recognize --help.
16856
16857 1999-06-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
16858
16859 * parse.y (resolve_package): Fixed bogus return statement.
16860 (patch_method_invocation): Resolve method invocation beginning with
16861 a package name qualifier.
16862
16863 1999-06-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16864
16865 * Make-lang.in (java.stage1): Depend on stage1-start.
16866 (java.stage2): Likewise for stage2-start.
16867 (java.stage3): Likewise for stage3-start.
16868 (java.stage4): Likewise for stage4-start.
16869
16870 1999-06-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
16871
16872 * parse.y (java_complete_lhs): When doing cross referencing, don't
16873 try to keep file location on a WFL expanded as a CALL_EXPR.
16874
16875 1999-06-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
16876
16877 * parse.y (finish_method_declaration): Insert a RETURN_EXPR when
16878 compiling to class file a void method with an empty method body.
16879 As a side effect, the bytecode backend will generate the
16880 appropriate `return' instruction.
16881
16882 1999-06-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
16883
16884 * parse.y (lookup_package_type_and_set_next): New function prototype.
16885 (resolve_package): Search current and imported packages.
16886 (lookup_package_type_and_set_next): New function.
16887
16888 1999-06-22 Andrew Haley <aph@cygnus.com>
16889
16890 * verify.c (verify_jvm_instructions): Check for pending blocks
16891 before invalid PC test and opcode switch, not after.
16892
16893 1999-06-21 Andrew Haley <aph@cygnus.com>
16894
16895 * except.c (find_handler_in_range): The upper limit for exception
16896 ranges is exclusive, not inclusive: (start <= pc < end).
16897 (link_handler): find child pointer which points to outer by
16898 searching sibling list: previous code incorrectly assumed that
16899 outer->outer->first_child must point to outer.
16900 * verify.c (verify_jvm_instructions): FIXME added to code for
16901 `athrow'.
16902 (verify_jvm_instructions): Do not assume that the last block
16903 processed in a subroutine is a block which ends with a `ret'
16904 instruction. With some control flows it is possible that the last
16905 block ends with an `athrow'.
16906
16907 1999-06-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
16908
16909 * parse.y (qualify_ambiguous_name): Reorganized the post
16910 evaluation of non WFL leading expression nodes.
16911
16912 1999-06-11 Alexandre Petit-Bianco <apbianco@cygnus.com>
16913
16914 * parse.y (qualify_ambiguous_name): Handle ARRAY_REF after
16915 CONVERT_EXPR.
16916
16917 1999-06-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
16918
16919 * parse.y (qualify_ambiguous_name): Handle qualified expression
16920 beginning with a STRING_CST.
16921
16922 1999-06-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
16923
16924 * parse.y (register_fields): Set DECL_INITIAL on both
16925 pre-initialized static and public fields.
16926 (resolve_field_access): Static field access expressions to always
16927 use pointer types.
16928 (qualify_ambiguous_name): Work out buried CALL_EXPR for proper
16929 qualification. CONVERT_EXPR to be resolved as an expression name.
16930 (java_complete_lhs): Identify and access qualified final
16931 initialized field in switch statement case expression.
16932 (fold_constant_for_init): Pre-initialized field decl constant to
16933 be folded.
16934
16935 1999-06-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
16936
16937 * parse.y (note_possible_classname): Mark returned node with
16938 QUALIFIED_P only if the original class name contained a '/'.
16939
16940 1999-06-05 Anthony Green <green@cygnus.com>
16941
16942 * Make-lang.in (gcjh): More parallel build fixes.
16943
16944 1999-06-03 Mike Stump <mrs@wrs.com>
16945
16946 * Make-lang.in (JCF_DUMP_SOURCES, jvgenmain): Fix parallel builds.
16947
16948 1999-06-02 Anthony Green <green@cygnus.com>
16949
16950 * except.c (link_handler): Chain exception handlers in order.
16951
16952 1999-06-02 Anthony Green <green@cygnus.com>
16953
16954 * expr.c (expand_byte_code): Fill unreachable bytecode regions
16955 with nops and process as usual in order to always set correct EH
16956 ranges. Emit detailed warnings about unreachable bytecodes.
16957
16958 1999-06-02 Anthony Green <green@cygnus.com>
16959
16960 * class.c (build_utf8_ref): Mark cinit and utf8 tree nodes as
16961 constant.
16962
16963 1999-05-28 Alexandre Petit-Bianco <apbianco@cygnus.com>
16964
16965 * parse.y (lookup_field_wrapper): Unified returned value to NULL
16966 or the searched field decl.
16967
16968 1999-05-28 Alexandre Petit-Bianco <apbianco@cygnus.com>
16969
16970 * parse.y (fold_constant_for_init): Convert numerical constant
16971 values to the type of the assigned field.
16972
16973 1999-05-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
16974
16975 * expr.c (lookup_field): Relaxed the test on class loading error
16976 detection.
16977 * parse.y (fold_constant_for_init): Enabeled old code.
16978
16979 1999-05-26 Alexandre Petit-Bianco <apbianco@cygnus.com>
16980
16981 * parse.y (valid_ref_assignconv_cast_p): Let `_Jv_CheckCast'
16982 decide the validity of the cast of a java.lang.Cloneable reference
16983 to an array.
16984 (patch_conditional_expr): Fixed first argument passed to
16985 binary_numeric_promotion.
16986
16987 1999-05-26 Alexandre Petit-Bianco <apbianco@cygnus.com>
16988
16989 * parse.y (qualify_ambiguous_name): Take into account that a
16990 CONVERT_EXPR might specify a type as a WFL.
16991
16992 1999-05-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
16993
16994 * parse.y (patch_assignment): Save the rhs before using it as an
16995 argument to _Jv_CheckArrayStore.
16996
16997 1999-05-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
16998
16999 * lex.c (java_parse_doc_section): Fixed `tag' buffer size.
17000
17001 1999-05-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
17002
17003 * lex.c (java_lex): Accepts `+' or `-' after the beginning of a
17004 floating point literal only when the exponent indicator has been
17005 parsed.
17006
17007 1999-05-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
17008
17009 * parse.y (formal_parameter:): Construct argument tree list
17010 element even if a yet unsupported final parameter was encountered.
17011
17012 1999-05-18 Alexandre Petit-Bianco <apbianco@cygnus.com>
17013
17014 * parse.y (finish_method_declaration): Issue errors for native or
17015 abstract methods declared with a method body, as well as for non
17016 native or non abstract methods with no method body.
17017
17018 1999-05-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17019
17020 * class.c (build_utf8_ref): Initialize variable `field'.
17021
17022 * decl.c (init_decl_processing): Initialize variable `field'.
17023
17024 * expr.c (build_known_method_ref): Mark parameters `method_type',
17025 `method_signature' and `arg_list' with ATTRIBUTE_UNUSED.
17026 (process_jvm_instruction): Likewise for parameter `length'.
17027
17028 * jvspec.c (lang_specific_driver): Mark variables `saw_math',
17029 `saw_libc', `saw_gc', `saw_threadlib' and `saw_libgcj' with
17030 ATTRIBUTE_UNUSED.
17031
17032 * parse.y (maybe_generate_clinit): Remove unused variable
17033 `has_non_primitive_fields'.
17034 (find_in_imports_on_demand): Initialize variables `node_to_use'
17035 and `cl'.
17036 (patch_binop): Likewise for variable `prom_type'.
17037 (patch_unaryop): Likewise for variable `prom_type'.
17038
17039 * verify.c (verify_jvm_instructions): Likewise for variable `last'.
17040
17041 * xref.c (xref_table): Add missing initializer.
17042
17043 1999-05-14 Tom Tromey <tromey@cygnus.com>
17044
17045 * java-except.h (struct eh_range): Removed unused `next' member.
17046 * verify.c (verify_jvm_instructions): Call check_nested_ranges
17047 after adding all exception handlers. Sort exception ranges in
17048 order of start PC.
17049 (struct pc_index): New structure.
17050 (start_pc_cmp): New function.
17051 * except.c (add_handler): Return `void'. Don't call link_handler;
17052 instead construct an ordinary linked list and do range
17053 coalescing.
17054 (check_nested_ranges): New function.
17055 (link_handler): Changed interface to allow merging of eh_ranges.
17056 Split overlapping ranges. Return `void'.
17057
17058 1999-05-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
17059
17060 * parse.y (constructor_block_end:): New rule, tagged <node>.
17061 (constructor_body:): Use `constructor_block_end' instead of
17062 `block_end'.
17063
17064 1999-05-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
17065
17066 * parse.y (statement_nsi:): Pop `for' statement block.
17067 (java_complete_lhs): Labeled blocks containing no statement are
17068 marked as completing normally.
17069
17070 1999-05-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
17071
17072 * xref.c (xref_set_current_fp): New function, defined.
17073 * xref.h (xref_set_current_fp): New function, prototyped.
17074
17075 1999-05-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
17076
17077 * check-init.c (check_init): Take into account that
17078 LABELED_BLOCK_STMT can be empty.
17079
17080 1999-05-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
17081
17082 * parse.y (java_check_regular_methods): Warning check on not
17083 overriding methods with default access in other packages does not
17084 apply to `<clinit>'.
17085 (java_complete_lhs): If block body is an empty_stmt_node, replace
17086 it by NULL_TREE. This prevents gcc from generating an irrelevant
17087 warning.
17088
17089 1999-05-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
17090
17091 * check-init.c (check_init): Removed code accepting to see things
17092 falling through default:, when doing xrefs.
17093 * java-tree.h (do_not_fold): New global variable, declared.
17094 * parse.y (do_not_fold): New global variable, defined.
17095 (java_complete_expand_method): Set `do_not_fold' to the value of
17096 `flag_emit_xref'. When doing xrefs: copy the thrown exceptions,
17097 and reinstall them after them have been purged; do not check for
17098 initializations; do not issue missing return errors.
17099 (java_complete_lhs): Do not attempt to patch INSTANCEOF_EXPR nodes
17100 when doing xrefs.
17101 (patch_binop): Skip the fold part when doing xrefs.
17102 (build_string_concatenation): Skip the concatenation part when
17103 doing xrefs.
17104 (patch_synchronized_statement): Do not generate a try-finally when
17105 doing xrefs.
17106 (patch_throw_statement): When doing xrefs, do not call BUILD_THROW
17107 and keep the location where the throw was seen.
17108 * typeck.c (convert): When `do_not_fold' is set, do not attempt
17109 any treatment on the converted node an simply return a NOP_EXPR of
17110 the targeted type.
17111 * xref.c (xref_get_data): New function, defined.
17112 * xref.h (xref_get_data): New function, declared.
17113 (XREF_GET_DATA): Use xref_get_data.
17114
17115 1999-05-13 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17116
17117 * gjavah.c (print_include): Cast the result of `strlen' to int
17118 when comparing against a signed value.
17119 (add_namelet): Likewise.
17120
17121 1999-05-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17122
17123 * expr.c (expand_invoke): Mark parameter `nargs' with
17124 ATTRIBUTE_UNUSED.
17125 (PRE_LOOKUP_SWITCH): Likewise for variable `match'.
17126
17127 * jcf-io.c (jcf_unexpected_eof): Mark parameter `count' with
17128 ATTRIBUTE_UNUSED.
17129
17130 * jcf-reader.c (get_attribute): Cast a value to long
17131 when comparing against a signed expression. Likewise.
17132
17133 * lex.h: Never define HOST_WIDE_INT, HOST_BITS_PER_WIDE_INT or
17134 HOST_BITS_PER_CHAR.
17135
17136 1999-05-11 Andrew Haley <aph@cygnus.com>
17137
17138 * parse.y (source_end_java_method): If the current method contains
17139 any exception handlers, force asynchronous_exceptions: this is
17140 necessary because signal handlers in libjava may throw exceptions.
17141 * decl.c (end_java_method): Ditto.
17142
17143 1999-05-11 Tom Tromey <tromey@cygnus.com>
17144
17145 * Make-lang.in (jvspec.o): Don't define WITH_THREAD_x or WITH_GC_x
17146 flags.
17147 * jvspec.c (THREAD_NAME): Removed.
17148 (GC_NAME): Likewise.
17149 (MATHLIB): Likewise.
17150 (WITHLIBC): Likewise.
17151 (GCLIB): Likewise.
17152 (THREADLIB): Likewise.
17153 (MATH_LIBRARY): Likewise.
17154 (lang_specific_driver): Don't add `-l' options to command line.
17155 Instead, add a single --specs option. Recognize `-L' options and
17156 use them to search for spec file.
17157 (find_spec_file): New function.
17158 (SPEC_FILE): New define.
17159
17160 1999-05-11 Dave Brolley <brolley@cygnus.com>
17161
17162 * lang-options.h: -MD, -MMD, -M and -MM not needed here for
17163 cpplib-enabled build.
17164
17165 1999-05-05 Per Bothner <bothner@cygnus.com>
17166
17167 * class.c (make_field_value): DECL_INITIAL may be a string literal;
17168 temporarily zero it while calling rest_of_decl_compilation.
17169
17170 * java-tree.h (string_ptr_type_node): Add declaration.
17171 * decl.c: Define and initialize string_ptr_type_node.
17172 * parse.y (patch_string_cst): Use string_ptr_type_node.
17173
17174 * parse.h (LOOP_HAS_LABEL_P, LOOP_HAS_LABEL_SKIP_P): Removed.
17175 * parse.y (for_statement): Now unconditionally exit_block.
17176 (finish_labeled_statement): No longer exit_block if for-loop.
17177 (patch_loop_statement): Check harder if the loop is already labeled.
17178
17179 * parse.y (patch_initialized_static_field): Removed function.
17180 (maybe_generate_clinit): Removed special handling for interfaces.
17181 (java_complete_expand_methods): Do a preliminary java_complete_tree
17182 on <clinit> to determine if it can be removed.
17183 (java_complete_expand_method): Remove special handling for <clinit>.
17184 (java_complete_lhs): For BLOCK and EXPR_WITH_FILE_LOCATION
17185 optimize if we get back empty_stmt_node.
17186 For MODIFY_EXPR, re-do checking of static initializers.
17187 (fold_constant_for_init): Don't return immediate if VAR_DECL.
17188 For VAR_DECL, pass correct context.
17189
17190 * verify.c (verify_jvm_instructions): Better error messages.
17191
17192 1999-05-03 Tom Tromey <tromey@cygnus.com>
17193
17194 * parse-scan.y (interface_declaration): Call
17195 report_class_declaration for interfaces.
17196
17197 1999-04-30 20:54 -0400 Zack Weinberg <zack@rabi.columbia.edu>
17198
17199 * Makefile.in: Remove -v from bison command lines.
17200
17201 1999-04-30 Alexandre Petit-Bianco <apbianco@cygnus.com>
17202
17203 * check-init.c (check_init): Exclude a case of error when doing
17204 xrefs.
17205 * class.c (layout_class_method): Don't generate the error message
17206 twice when compiling from source.
17207 * lang-options.h: Added `-Wredundant-modifers' and
17208 `-Wunusupported-jdk11' flags and help text.
17209 * lang.c (lang_decode_option): Added support for
17210 `-Wunsupported-jdk11' and `-Wredundant-modifiers'.
17211 flag_static_local_jdk11 and flag_redundant set accordingly.
17212 * lex.c (java_lex): Call BUILD_OPERATOR on CCB_TK.
17213 * parse.h (EXPR_WFL_ADD_COL): New macro.
17214 (DECL_END_SOURCE_LINE): Likewise.
17215 (DECL_INHERITED_SOURCE_LINE): Likewise.
17216 * parse.y (static_ref_err): New function, prototyped.
17217 (CCB_TK): Now tagged <operator>.
17218 (class_body:): Remember the location of the closing '}' of a class
17219 definition when doing xrefs.
17220 (block:): Likewise.
17221 (block_end:): Likewise.
17222 (create_class): Remember the location of the inherited class
17223 identifier when doing xrefs.
17224 (register_fields): Added test on first operand of `init' before
17225 testing it TREE_CODE.
17226 (method_header): Store the location of the class identifier in the
17227 class decl when doing xrefs.
17228 (finish_method_declaration): Don't combine first/last method line
17229 when doing xref.
17230 (java_check_regular_methods): Warning check on not overriding
17231 methods with default access on other packages move before check on
17232 static methods. Initialization of `aflags' also moved up.
17233 (resolve_expression_name): Call static_ref_err to report the error.
17234 (static_ref_err): New function, implemented.
17235 (resolve_field_access): Returned simplified static field access
17236 when doing xrefs.
17237 (resolve_qualified_expression_name): Check for illegal use of
17238 static fields in a non static context. Call static_ref_err to
17239 report error in various places.
17240 (java_complete_tree): Do not fold initialized static fields when
17241 doing xrefs.
17242 (java_complete_lhs): Likewise.
17243
17244 1999-04-29 Anthony Green <green@cygnus.com>
17245
17246 * expr.c (generate_name): Use ASM_GENERATE_INTERNAL_LABEL to
17247 create internal labels.
17248 (lookup_label): Ditto.
17249
17250 1999-04-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
17251
17252 * class.c (layout_class_method): Generate <clinit>'s rtl for
17253 interfaces.
17254 * decl.c (complete_start_java_method): Don't call _Jv_InitClass
17255 for interfaces' <clinit>.
17256 * expr.c (lookup_field): Search for fields in interfaces.
17257 (expand_invoke): Fixed indentation.
17258 (expand_java_field_op): Likewise. Use IS_CLINIT.
17259 * parse.h (JPRIMITIVE_TYPE_OR_VOID_P): Macro removed.
17260 (IS_CLINIT): New macro.
17261 * parse.y (type_declaration:): Call maybe_generate_clinit after an
17262 interface was parsed.
17263 (maybe_generate_clinit): Don't generate if the current class is an
17264 interface with only fields of primitive types.
17265 (reset_method_name): Use IS_CLINIT.
17266 (java_complete_expand_method): Expand <clinit> when it exists for
17267 interfaces. Use IS_CLINIT.
17268 (resolve_expression_name): Use DECL_CONTEXT instead of
17269 current_class to build static field references.
17270 (java_complete_lhs): Use IS__CLINIT. Don't use SAVE_EXPR on
17271 ARRAY_REF when doing xreferencing.
17272 (check_final_assignment): Fixed typo in leading comment. Use
17273 IS_CLINIT.
17274 (patch_array_ref): Don't fully expand array references when
17275 xreferencing.
17276 (patch_return): Use IS_CLINIT.
17277 (patch_throw_statement): Likewise.
17278
17279 1999-04-22 Tom Tromey <tromey@cygnus.com>
17280
17281 * Make-lang.in (JAVA_SRCS): Added check-init.c.
17282
17283 1999-04-21 Alexandre Petit-Bianco <apbianco@cygnus.com>
17284
17285 * decl.c (predef_filenames, predef_filenames_size): New globals
17286 (init_decl_processing): predef_filenames and predef_filenames_size
17287 initialized.
17288 * java-tree.h (predef_filenames, predef_filenames_size): Declared
17289 extern.
17290 * jcf-parse.c (predefined_filename_p): New function.
17291 (yyparse): Check that files on the command line are specified only
17292 once and issue a warning otherwise.
17293 * parse.h (JPRIMITIVE_TYPE_OR_VOID_P): New macro.
17294 * parse.y (source_end_java_method): Nullify NOP method bodies, to
17295 avoid a gcc warning with -W -Wall turned on.
17296 (java_expand_classes): Abort if errors were encountered.
17297 (java_complete_lhs): If the cross reference flag is set, wrap
17298 field DECL node around a WFL when resolving expression name.
17299
17300 1999-04-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
17301
17302 * lang.c (lang_decode_option): Fixed returned value when parsing
17303 `-fxref=...' and `-Wall'.
17304 * parse.y (source_end_java_method): Do not generate code when
17305 flag_emit_xref is set.
17306 (resolve_expression_name): Do not build static field access when
17307 flag_emit_xref is set.
17308 (resolve_field_access): No special treatment on `length' when
17309 flag_emit_xref is set. Do not build qualified static field access
17310 when flag_emit_xref is set.
17311 (patch_invoke): Keep the method DECL as operand 0 of the CALL_EXPR
17312 when flag_emit_xref is set.
17313 (patch_assignment): Do not generate array store runtime check when
17314 flag_emit_xref is set.
17315 * xref.c (xref_flag_value): Fixed function declaration
17316 indentation.
17317 (xset_set_data): New function.
17318 * xref.h (xref_set_data): Added prototype for new function.
17319 (typedef struct xref_flag_table): New field data.
17320 (XREF_GET_DATA): New macro.
17321
17322 1999-04-19 Tom Tromey <tromey@cygnus.com>
17323
17324 * xref.h (enum): Removed trailing comma.
17325
17326 * parse.y (resolve_qualified_expression_name): Added missing
17327 `break'.
17328
17329 1999-04-15 Anthony Green <green@cygnus.com>
17330
17331 * gjavah.c: New prototypes for java_float_finite and
17332 java_double_finite.
17333
17334 1999-04-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
17335
17336 * parse.y (patch_unaryop): Fixed ++/-- operator check on array
17337 references.
17338
17339 1999-04-06 Jeffrey A Law (law@cygnus.com)
17340
17341 * Makefile.in (TREE_H): Add tree-check.h.
17342 (RTL_H): Add genrtl.h.
17343
17344 1999-04-06 Alexandre Petit-Bianco <apbianco@cygnus.com>
17345
17346 * parse.y (patch_assignment): Added ArrayStoreException runtime
17347 check.
17348
17349 1999-04-06 Per Bothner <bothner@cygnus.com>
17350
17351 * expr.c (pop_type_0): New function.
17352 (pop_type): Use pop_type_0.
17353 * java-tree.h (pop_type_0): New declaration.
17354 * verify.c (verify_jvm_instructions): Check return instructions.
17355
17356 * parse.y (patch_binop): Don't fold if non-constant and emiting
17357 class files.
17358
17359 1999-04-05 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17360
17361 * Makefile.in (gjavah.o): Depend on $(JAVA_TREE_H).
17362
17363 * gjavah.c: Include math.h earlier. Include tree.h/java-tree.h.
17364 (main_jcf): Don't define.
17365 (process_file): Don't set `main_jcf'.
17366
17367 * java-tree.h (main_jcf): Don't declare.
17368
17369 * jcf-parse.c (main_jcf): Add static definition.
17370
17371 * lang.c (main_jcf): Don't define.
17372
17373 1999-04-05 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17374
17375 * class.c (add_method_1): Cast the argument of `bzero' to PTR.
17376
17377 * decl.c (copy_lang_decl): Likewise for `bcopy'.
17378
17379 * jcf-depend.c: Include "config.h", not <config.h>.
17380
17381 * jcf-parse.c (jcf_figure_file_type): Cast the arguments of
17382 `bcopy' to PTR.
17383
17384 * jcf-path.c: Include "config.h", not <config.h>.
17385
17386 * lex.c: Don't include various system header files.
17387 (java_init_lex): Cast the argument of `bzero' to PTR
17388
17389 * parse-scan.y (java_push_parser_context): Likewise.
17390
17391 * parse.y (java_push_parser_context): Likewise.
17392 (patch_bc_statement): Match format specifier to variable argument.
17393
17394 * xref.c: Don't include <stdio.h>.
17395
17396 1999-04-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
17397
17398 * parse.y (struct parser_ctxt *ctxp): Now global.
17399 (declare_local_variables): Use WFL compound value for the
17400 declaration source line value, when doing cross-referencing.
17401
17402 1999-03-31 Tom Tromey <tromey@cygnus.com>
17403
17404 * gjavah.c (print_field_info): Allow constants of other types.
17405 (print_include): Generate include when new name is proper prefix
17406 of already printed name.
17407 (add_namelet): Likewise.
17408 (cxx_keyword_subst): New function.
17409 (print_method_info): Use it.
17410 (print_field_name): New function.
17411 (get_field_name): New function.
17412 (print_field_info): Use get_field_name and print_field_name.
17413
17414 1999-03-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17415
17416 * Makefile.in (keyword.h): Generate using gperf language 'C', not
17417 'KR-C', so gperf uses the `const' keyword on strings.
17418
17419 * keyword.gperf (java_keyword): Const-ify a char*.
17420
17421 1999-03-30 Alexandre Petit-Bianco <apbianco@cygnus.com>
17422
17423 * parse.y (patch_bc_statement): Fixed identation and a bogus
17424 `printf' format.
17425
17426 1999-03-30 Alexandre Petit-Bianco <apbianco@cygnus.com>
17427
17428 * parse.y (patch_assignment): Allow static variables in other
17429 classes to be assigned.
17430
17431 1999-03-28 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17432
17433 * class.c (maybe_add_interface): Remove unused variable
17434 `interface_binfo'.
17435 (make_class_data): Use = for assignment, not ==. Likewise.
17436 (emit_register_classes): Remove unused variable `decl'.
17437
17438 * lex.c: Fix comment so as not to contain an embedded `/*'.
17439
17440 * verify.c (verify_jvm_instructions): Remove unused variable
17441 `self_type'.
17442
17443 1999-03-27 Per Bothner <bothner@cygnus.com>
17444
17445 * parse.y (complete_loop_body): Rename to finish_loop_body.
17446 (complete_labeled_statement): Rename to finish_labeled_statement.
17447 (complete_for_loop): Rename to finish_for_loop.
17448 (complete_method_declaration): Rename to finish_method_declaration.
17449
17450 * java-tree.h (continue_identifier_node): New global node.
17451 * decl.c: Define and initialize continue_identifier_node.
17452 * parse.y (generate_labeled_block): Remove - no longer needed.
17453 (build_loop_body): Use continue_identifier_node for continue block.
17454 (finish_labeled_statement): Also do pop_labeled_block actions.
17455 (java_complete_lhs): POP_LOOP even if error.
17456 (build_labeled_block): Special handling for continue_identifier_node.
17457 (patch_loop_statement): Re-organize.
17458 (patch_bc_statement): Re-write.
17459
17460 1999-03-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
17461
17462 * parse.h (EXPR_WFL_GET_LINECOL): Set a line and column count
17463 using a WFL compound value.
17464 * parse.y (xref.h): Include.
17465 (maybe_create_class_interface_decl): Set DECL_SOURCE_LINE to the
17466 WFL compound value.
17467 (register_fields): Set WFL compound value to lineno if doing
17468 xrefs.
17469 (java_complete_expand_method): Call expand_xref if flag_emit_xref
17470 is set.
17471 * xref.c (system.h, jcf.h, parse.h, obstack.h): Include.
17472 * xref.h (expand_xref): Prototype renamed from xref_generate.
17473
17474 1999-03-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
17475
17476 * parse.h (BLOCK_CHAIN_DECL): New use GET_CURRENT_BLOCK.
17477 (GET_CURRENT_BLOCK): New macro.
17478 * parse.y (current_static_block): New global variable.
17479 (method_body:): Define action.
17480 (complete_method_declaration): Set current_function_decl to NULL
17481 when work on the current method is done.
17482 (declare_local_variables): Use GET_CURRENT_BLOCK.
17483 (java_method_add_stmt): Likewise.
17484 (java_complete_expand_method): Disable the use of `this' when
17485 expanding <clinit>.
17486 (enter_a_block): If no current method exist, use
17487 current_static_block to link static initializer blocks.
17488 (exit_block): Rewritten to use current_static_block when no current
17489 method decl exists.
17490 (lookup_name_in_blocks): Use GET_CURRENT_BLOCK.
17491 (patch_return): Forbid the use of `return' in static initializers.
17492 (patch_throw_statement): Fixed indentation. Issue specific error
17493 for uncaught thrown checked exception in static initializer
17494 blocks. Removed FIXME.
17495
17496 1999-03-25 Zack Weinberg <zack@rabi.columbia.edu>
17497
17498 * java/Make-lang.in: Remove all references to gcj.o/gcj.c.
17499 Link gcj from gcc.o.
17500
17501 1999-03-23 Alexandre Petit-Bianco <apbianco@cygnus.com>
17502
17503 * parse.y (find_applicable_accessible_methods_list): When dealing
17504 with interface: ensure that a given interface or java.lang.Object
17505 are searched only once.
17506
17507 1999-03-23 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17508
17509 * gjavah.c (print_c_decl): Remove unused argument `flags'.
17510
17511 * jcf-dump.c (print_access_flags): Add braces around if-else.
17512
17513 * jvspec.c (lang_specific_driver): Wrap variable `len' in macro
17514 COMBINE_INPUTS.
17515
17516 * lex.c (build_wfl_node): Add static prototype.
17517
17518 * lex.h (build_wfl_node): Remove static prototype.
17519
17520 * parse.y: Include lex.c early enough to declare everything needed.
17521 Ensure calls to `build_wfl_node' pass the proper arguments.
17522 (create_class): Remove unused variable `super_decl'.
17523 (get_printable_method_name): Initialize variable `name'.
17524
17525 1999-03-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
17526
17527 * Changelog: Fixed 1999-03-22 typos.
17528 * lang.c (lang_decode_option): Fixed typo in error string in the
17529 XARG section.
17530
17531 1999-03-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
17532
17533 * Makefile.in (JAVA_OBJS): Added entry xref.o.
17534 (xref.o): New rule.
17535 * java-tree.h (flag_emit_xref): Declared extern.
17536 * lang.c (xref.h): Included.
17537 (flag_emit_xref): New global variable.
17538 (lang_decode_option): Added support for -fxref.
17539 * xref.c: Created.
17540 * xref.h: Likewise.
17541
17542 1999-03-21 Manfred Hollstein <manfred@s-direktnet.de>
17543
17544 * Make-lang.in ($(GCJ)$(exeext)): Add intl.o to list of files to be
17545 linked with.
17546
17547 1999-03-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17548
17549 * Makefile.in (jcf-dump.o): Depend on $(CONFIG_H)
17550 $(srcdir)/../system.h and $(JAVA_TREE_H).
17551 (jcf-io.o): Depend on $(JAVA_TREE_H).
17552 (mangle.o): Likewise.
17553
17554 * check-init.c (check_cond_init): Add static prototype.
17555
17556 * class.c (build_java_method_type, hashUtf8String,
17557 make_field_value, get_dispatch_vector, get_dispatch_table,
17558 append_gpp_mangled_type, mangle_static_field): Likewise.
17559 (strLengthUtf8): Hide unused definition.
17560 (hashUtf8String): Const-ify.
17561 (make_field_value): Un-ANSI-fy.
17562
17563 * constants.c: Move inclusion of jcf.h above java-tree.h.
17564 (set_constant_entry, find_class_or_string_constant,
17565 find_name_and_type_constant, get_tag_node,
17566 build_constant_data_ref): Add static prototype.
17567
17568 * decl.c (push_jvm_slot, builtin_function,
17569 lookup_name_current_level): Likewise.
17570 (builtin_function): Const-ify.
17571
17572 * except.c (expand_start_java_handler, expand_end_java_handler):
17573 Add static prototype.
17574
17575 * expr.c (flush_quick_stack, push_value, pop_value,
17576 java_stack_swap, java_stack_dup, build_java_athrow,
17577 build_java_jsr, build_java_ret, expand_java_multianewarray,
17578 expand_java_arraystore, expand_java_arrayload,
17579 expand_java_array_length, build_java_monitor, expand_java_pushc,
17580 expand_java_return, expand_java_NEW, expand_java_INSTANCEOF,
17581 expand_java_CHECKCAST, expand_iinc, expand_java_binop, note_label,
17582 expand_compare, expand_test, expand_cond, expand_java_goto,
17583 expand_java_call, expand_java_ret, pop_arguments, expand_invoke,
17584 expand_java_field_op, java_push_constant_from_pool): Likewise.
17585
17586 (decode_newarray_type, expand_iinc): Un-ANSI-fy.
17587 (build_java_arraynull_check): Mark parameters `node' and `type'
17588 with ATTRIBUTE_UNUSED.
17589 (note_label): Likewise for parameter `current_pc'.
17590 (expand_java_call, expand_java_ret): Hide unused definition.
17591
17592 * java-tree.h (make_class, build_constants_constructor,
17593 java_set_exception_lang_code, pop_labeled_block, emit_handlers,
17594 init_outgoing_cpool, register_class, emit_register_classes,
17595 java_layout_seen_class_methods): Prototype.
17596 (unicode_mangling_length): Const-ify.
17597 (append_gpp_mangled_name, append_gpp_mangled_classtype,
17598 emit_unicode_mangled_name, format_int, format_uint,
17599 jcf_trim_old_input, jcf_print_utf8, jcf_print_char,
17600 jcf_print_utf8_replace, open_class): Prototype.
17601
17602 * jcf-dump.c: Include "config.h", not <config.h>. Don't include
17603 <stdio.h>. Include tree.h/java-tree.h.
17604 (utf8_equal_string usage, process_class): Add static prototype.
17605 (open_class): Don't prototype this here.
17606 (utf8_equal_string): Match arguments to format specifiers.
17607 (HANDLE_CODE_ATTRIBUTE, BRANCH, JSR, RET, LOOKUP_SWITCH,
17608 TABLE_SWITCH, disassemble_method): Likewise.
17609
17610 * jcf-io.c: Include tree.h/java-tree.h.
17611 (open_class, find_classfile, jcf_print_utf8,
17612 jcf_print_utf8_replace): Const-ify.
17613
17614 * jcf-parse.c (parse_zip_file_entries, process_zip_dir,
17615 parse_class_file): Add static prototype.
17616 (find_in_current_zip): Match definition to existing static
17617 prototype.
17618
17619 * jcf-write.c: Include jcf.h before tree.h/java-tree.h.
17620 (alloc_chunk, append_chunk, append_chunk_copy, gen_jcf_label,
17621 finish_jcf_block, define_jcf_label, get_jcf_label_here,
17622 put_linenumber, localvar_alloc, localvar_free, get_access_flags,
17623 write_chunks, adjust_typed_op, generate_bytecode_conditional,
17624 generate_bytecode_return, perform_relocations, init_jcf_state,
17625 init_jcf_method, release_jcf_state, generate_classfile):
17626 Add static prototype.
17627 (emit_unop): Mark parameter `type' with ATTRIBUTE_UNUSED.
17628 (make_class_file_name): Const-ify.
17629
17630 * jcf.h (find_classfile): Const-ify.
17631
17632 * jv-scan.c (reset_report): Remove prototype.
17633
17634 * jvgenmain.c: Include jcf.h/tree.h/java-tree.h.
17635 (error): Rewrite to allow varargs.
17636
17637 * lang.c (lang_f_options): Const-ify.
17638
17639 * lex.c (java_parse_escape_sequence): Add static prototype.
17640 (java_allocate_new_line): Match definition to existing static
17641 prototype.
17642
17643 * mangle.c Include tree.h/java-tree.h.
17644 (unicode_mangling_length, emit_unicode_mangled_name,
17645 append_gpp_mangled_name, append_gpp_mangled_classtype): Const-ify.
17646
17647 * parse.h (jdep_code): Remove trailing comma in enumeration.
17648 (java_get_line_col): Move prototype outside of !JC1_LITE test.
17649 (reset_report): Add prototype.
17650
17651 * verify.c (push_pending_label, merge_types): Add static
17652 prototypes.
17653
17654 * zipfile.h (opendir_in_zip, open_in_zip): Prototype.
17655
17656 1999-03-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
17657
17658 * parse.y (find_applicable_accessible_methods_list): Extend the
17659 search to superinterfaces when relevant.
17660 (search_applicable_methods_list): New function.
17661
17662 1999-03-18 Alexandre Petit-Bianco <apbianco@cygnus.com>
17663
17664 * class.c (unmangle_classname): Implemented stricter testing
17665 before setting the QUALIFIED_P flag on an identifier.
17666
17667 1999-03-16 Per Bothner <bothner@cygnus.com>
17668
17669 * parse.y (java_complete_lhs): Call force_evaluation_order
17670 after patch_newarray.
17671 (patch_binop): Don't call fold if there are side effects.
17672
17673 1999-03-16 Alexandre Petit-Bianco <apbianco@cygnus.com>
17674
17675 * parse.y (java_stabilize_reference): Use save_expr instead of
17676 building a SAVE_EXPR node.
17677 (java_complete_lhs): Patch the resulting string of the `+='
17678 operator (if necessary) and complete the RHS after having built
17679 the cast.
17680
17681 1999-03-15 Per Bothner <bothner@cygnus.com>
17682
17683 * class.c (make_class): Don't set CLASS_P here (because
17684 this function is also called by build_java_array_type).
17685 (push_class): Set CLASS_P here instead.
17686 * parse.h (TYPE_CLASS_P): Check for TYPE_ARRAY_P is redundant.
17687
17688 * jcf-dump.c (print_access_flags): Take extra parameter to indicate
17689 context. If the context is class, perfer "super" over "synchronized".
17690 * jcf-write.c (generate_classfile): Don't add ACC_SUPER if interface.
17691
17692 * parse.y (create_class): Don't call parser_check_super here;
17693 it is not robust. Always wait until later.
17694
17695 * parse.y (method_header): For interfaces, set ACC_ABSTRACT (to
17696 match what JDK 1.2 does), but don't set ACC_PUBLIC.
17697
17698 1999-03-13 Per Bothner <bothner@cygnus.com>
17699
17700 * lex.c (java_read_char): UNGET invalid non-initial utf8 character.
17701 * lex.h (UNGETC): Change misleading macro.
17702
17703 1999-03-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
17704
17705 * parse.y (java_stabilize_reference): Return NODE when patching a
17706 COMPOUND_EXPR.
17707 (java_complete_lhs): Put parenthesis around truth values.
17708
17709 1999-03-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
17710
17711 * class.c (layout_class_method): Don't make rtl for interface
17712 methods.
17713 * parse.h (GET_TYPE_NAME): New macro.
17714 * parse.y (if_then_statement:): Fixed indentation.
17715 (if_then_else_statement:): Likewise.
17716 (for_statement:): Fixed spacing.
17717 (try_statement:): Fixed indentation.
17718 (create_interface): Don't force interfaces to be abstract.
17719 (method_header): Abstract methods are OK in interfaces.
17720 (declare_local_variables): Fixed typo in comment.
17721 (java_complete_expand_method): Fixed indentation.
17722 (resolve_qualified_expression_name): Use GET_TYPE_NAME to report
17723 non accessible fields.
17724 (java_stabilize_reference): New function.
17725 (java_complete_lhs): Fixed indentation. Use
17726 java_stabilize_reference in compound assignment. Insert the
17727 cast. If not processing `+' fix string constants before processing
17728 binop.
17729
17730 1999-03-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17731
17732 * constants.c (find_class_or_string_constant): Cast variable `j'
17733 to a `jword' when comparing against one.
17734
17735 * expr.c (java_lang_expand_expr): Remove unused variables
17736 `has_finally_p' and `op0'.
17737
17738 * gjavah.c (print_field_info): Cast a value to jint when comparing
17739 against one. Likewise for a jlong.
17740 (add_namelet): Likewise cast a `sizeof' to an int when comparing
17741 against a signed quantity.
17742
17743 * jcf-dump.c (print_signature_type): Remove unused variable `digit'.
17744 (print_signature): Don't needlessly dereference variable `str'
17745
17746 * jcf-reader.c (get_attribute): Mark variables `max_stack' and
17747 `max_locals' with ATTRIBUTE_UNUSED.
17748 (jcf_parse_class): Likewise for variable `index'.
17749
17750 * parse.h (reverse_jdep_list): Remove static prototype.
17751
17752 * parse.y (build_jump_to_finally): Remove prototype and definition.
17753 (reverse_jdep_list): Add static prototype.
17754
17755 * typeck.c (convert_ieee_real_to_integer): Remove unused variables
17756 `assignment' and `expr_decl'.
17757
17758 * verify.c (verify_jvm_instructions): Remove unused label `bad_ldc'.
17759
17760 1999-03-12 Andrew Haley <aph@cygnus.com>
17761
17762 * jcf-path.c (add_entry): alloca len+2 rather than len+1 bytes;
17763 we'll need a directory separator and a null character.
17764
17765 1999-03-10 Per Bothner <bothner@cygnus.com>
17766
17767 * jcf-write.c (generate_bytecode_insns): Handle __builtin_fmod, for %.
17768
17769 Tue Mar 9 11:52:08 1999 Alexandre Petit-Bianco <apbianco@cygnus.com>
17770
17771 * parse.y (method_header): Don't set ACC_ABSTRACT flags on
17772 interfaces.
17773
17774 1999-03-05 Per Bothner <bothner@cygnus.com>
17775
17776 * lex.c (java_parse_end_comment): Take extra parameter (next char).
17777
17778 * class.c (build_utf8_ref): Fix possible name class/ambiguity.
17779
17780 * class.c (layout_class_method): A static method in a base class
17781 is never overridden, so treat it like it doesn't exist.
17782 However, do complain about private non-static method overriding
17783 public static method.
17784
17785 * parse.y: Don't set unused INITIALIZED_P flag.
17786 * java-tree.h (INITIALIZED_P): Removed no-longer needed flag.
17787
17788 * parse.y (find_expr_with_wfl): Optimize tail-calls.
17789 (build_array_from_name): Re-order &index[string] to &string[index].
17790
17791 * parse.y (java_complete_lhs): Don't call patch_assignment if rhs is
17792 error_mark (it might catch more errors, but it is more likely to lose).
17793
17794 1999-03-06 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17795
17796 * Makefile.in (jcf-parse.o): Depend on $(PARSE_H).
17797 (parse-scan.o): Depend on toplev.h.
17798
17799 * class.c (make_method_value): Add prototype. Make it static.
17800 Remove unused second argument, caller changed.
17801
17802 * expr.c (java_lang_expand_expr): Remove unused variable
17803 `return_label'.
17804
17805 * java-tree.h: Don't prototype find_in_current_zip.
17806 Add prototypes for verify_constant_pool, start_java_method,
17807 end_java_method, give_name_to_locals, expand_byte_code,
17808 open_in_zip, set_constant_value, find_constant1, find_constant2,
17809 find_utf8_constant, find_string_constant, find_class_constant,
17810 find_fieldref_index, find_methodref_index, write_constant_pool,
17811 count_constant_pool_bytes and encode_newarray_type.
17812
17813 * jcf-dump.c: Remove unused variable `LONG_temp'.
17814
17815 * jcf-parse.c: Include parse.h.
17816 (jcf_parse_source): Remove unused parameter, all callers changed.
17817 (jcf_figure_file_type): Add static prototype.
17818 (find_in_current_zip): Likewise. Also remove unused parameter,
17819 all callers changed.
17820 (read_class): Initialize variable `saved_pos'.
17821
17822 * jcf-reader.c (jcf_parse_preamble): Mark variables
17823 `minor_version' and `major_version' with ATTRIBUTE_UNUSED.
17824
17825 * lex.c (java_is_eol): Wrap prototype and definition in !JC1_LITE.
17826 (java_init_lex): Wrap variable `java_lang_imported' in !JC1_LITE.
17827 (java_parse_doc_section): Initialize variable `seen_star'.
17828 (java_lex): Wrap variable `number_beginning' in !JC1_LITE.
17829 (java_lex_error): Mark parameters `msg' and `forward' with
17830 ATTRIBUTE_UNUSED.
17831 (java_get_line_col): Mark parameters `filename' and `line' with
17832 ATTRIBUTE_UNUSED.
17833
17834 * parse-scan.y: Include toplev.h.
17835 (yyerror): Mark parameter `msg' with ATTRIBUTE_UNUSED.
17836
17837 * parse.h: use `struct JCF', not plain `JCF'.
17838 (java_parser_context_save_global, java_expand_classes
17839 java_parser_context_restore_global, java_parse): Add prototypes.
17840
17841 * typeck.c (convert_ieee_real_to_integer): Remove unused variable
17842 `node'.
17843
17844 1999-02-24 Per Bothner <bothner@deneb.cygnus.com>
17845
17846 * check-init.c (check_init): COPYN takes word count, not bit count.
17847
17848 1999-02-26 Per Bothner <bothner@cygnus.com>
17849
17850 * typeck.c (convert_ieee_real_to_integer): Use save_expr instead of
17851 explicit build_decl. (Avoids crash in reload when optimizing.)
17852
17853 1999-02-25 Per Bothner <bothner@cygnus.com>
17854
17855 * decl.c (complete_start_java_method): Handle synchronized method
17856 even when compiling from bytecode.
17857
17858 1999-02-26 Tom Tromey <tromey@cygnus.com>
17859
17860 * gjavah.c (add_class_decl): Only generate `#include' if outer
17861 class is not the name of the class we are processing. Correctly
17862 append `.h' in #include.
17863 (process_file): Clean up newlines around generated `#include's.
17864 (decode_signature_piece): Correctly handle inner classes.
17865 (struct include): New structure.
17866 (all_includes): New global.
17867 (print_include): New function.
17868 (add_class_decl): Use it.
17869 (process_file): Likewise.
17870 (add_class_decl): Generate include for java-array.h if array
17871 seen.
17872 (process_file): Don't generate java-array.h include.
17873
17874 * gjavah.c (add_namelet): Check for standard package names here.
17875 (add_class_decl): Don't check for standard package names here.
17876
17877 1999-02-25 Tom Tromey <tromey@cygnus.com>
17878
17879 * parse.y (read_import_dir): Use `|=', not `+=', to set `found'.
17880 When reading a zip file, only use strncmp if both strings are
17881 bigger than the buffer length. Initialize `k' when looping
17882 through zip file.
17883
17884 1999-02-24 Tom Tromey <tromey@cygnus.com>
17885
17886 * gjavah.c (struct namelet): New structure.
17887 (add_namelet): New function.
17888 (print_namelet): New function.
17889 (print_class_decls): Use add_namelet and print_namelet to generate
17890 namespaces and not classes.
17891 (method_printed): New global.
17892 (HANDLE_END_METHOD): Examine method_printed.
17893 (print_method_info): Set method_printed when required. Print
17894 error if function to be ignored is marked virtual. Handle $finit$
17895 method.
17896 (METHOD_IS_FINAL): New macro.
17897 (print_field_info): Use it.
17898 (HANDLE_METHOD): Clear method_printed.
17899 (method_pass): New global.
17900 (HANDLE_END_FIELD): Call add_class_decl on the first pass.
17901 (process_file): Do two passes over both fields and methods.
17902 (HANDLE_METHOD): Examine method_pass.
17903 (root): New global.
17904 (add_class_decl): New function.
17905 (print_class_decls): Don't scan over entire constant pool.
17906
17907 1999-02-23 Tom Tromey <tromey@cygnus.com>
17908
17909 * jvspec.c (lang_specific_driver): Recognize -fsyntax-only and
17910 disable linking in that case.
17911
17912 1999-02-20 Tom Tromey <tromey@cygnus.com>
17913
17914 * jcf.h (UTF8_GET): Mask first byte of 3-byte encoding with 0x0f,
17915 not 0x1f.
17916
17917 1999-02-21 Per Bothner <bothner@cygnus.com>
17918
17919 * decl.c (build_result_decl), java-tree.h: New method.
17920 (complete_start_java_method): Handle synchronized methods.
17921 Don't build DECL_RESULT here. (Ordering dependency problem.)
17922 (start_java_method): Call build_result_decl here instead ...
17923 * parse.y (java_complete_expand_method): ... and here.
17924 (expand_start_java_method): Don't call complete_start_java_method here.
17925 (java_complete_expand_method): Call it here instead.
17926 * parse.h (BUILD_MONITOR_ENTER, BUILD_MONITOR_EXIT): Moved to ..
17927 * java-tree.h: ... here.
17928
17929 * expr.c (force_evaluation_order): Fix typo, don't handle ARRAY_REF.
17930 * parse.y (java_complete_lhs): Don't call force_evaluation_order
17931 for ARRAY_REF - it doesn't work when array bounds are checked.
17932 (patch_array_ref): Handle it here instead.
17933
17934 * jcf-write.c (generate_classfile): Emit "Exceptions" attribute.
17935
17936 1999-02-19 Per Bothner <bothner@cygnus.com>
17937
17938 Force left-to-right evaluation of binary operations etc.
17939 * expr.c (force_evaluation_order), java-tree.h: New function.
17940 * parse.y (java_complete_lhs): Pass binary operations, procedure
17941 calls, and ARRAY_REFs to force_evaluation_order.
17942 (various): Set TREE_SIDE_EFFECTS more carefully.
17943
17944 Tolerate random (non-UTF8) encoding in comments without complaining.
17945 * lex.c (java_read_char): Return 0xFFFE if bad UTF8 encoding.
17946 (java_is_eol): Handle '\r' followed by '\n' instead of vice versa.
17947
17948 * parse.y (resolve_qualified_expression_name): Handle error_mark.
17949 (java_complete_node case EXPR_WITH_FILE_LOCATION): Likewise.
17950
17951 * parse.y (java_complete_lhs): Ignore an empty statement in a
17952 COMPOUND_EXPR. Don't complain about empty statement after return.
17953
17954 1999-02-19 Per Bothner <bothner@cygnus.com>
17955
17956 * parse.y (obtain_incomplete_type): Don't wrap unknown types
17957 in TREE_LIST - just chain the POINTER_TYPEs together.
17958 (resolve_class): If type already resolved, return decl.
17959 After resolving, update TREE_TYPE(class_type), and name (if array).
17960 * parse.h (do_resolve_class), parse.y: Make non-static.
17961 * class.c (maybe_layout_super_class): Take this_class argument.
17962 Do do_resolve_class if necessary.
17963 (layout_class, layout_class_methods): Adjust calls appropriately.
17964 * parse.h (JDEP_TO_RESOLVE, JDEP_RESOLVED_DECL, JDEP_RESOLVED,
17965 JDEP_RESOLVED_P): Redefined for new TREE_LIST-less convention.
17966 * typeck.c (build_java_array_type): Don't call layout_class.
17967
17968 1999-02-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
17969
17970 * parse.y (check_pkg_class_access): Allow private class access
17971 within the same package.
17972 (strip_out_static_field_access_decl): New function.
17973 (patch_unaryop): Call strip_out_static_field_access_decl on ++/--
17974 operator argument before testing its nature.
17975
17976 1999-02-03 Per Bothner <bothner@cygnus.com>
17977
17978 * java-tree.def (FINALLY_EXPR): Removed. (Now uses TRY_FINALLY_EXPR.)
17979 (TRY_EXPR): Simplify - it no longer has a finally clause.
17980 * check-init.c (check_init): Handle TRY_FINALLY_EXPR.
17981 Simpler handling of TRY_EXPR, which no longer has a finally clause.
17982 * expr.c (java_lang_expand_expr): Likewise.
17983 * java-tree.h (CATCH_EXPR_GET_EXPR): Removed - no longer needed.
17984 * parse.h (java_get_catch_block), parse.y: Removed - no longer needed.
17985 * parse.y (java_complete_lhs): Add support for TRY_FIANLLY_EXPR.
17986 (build_try_statement): Remove finally parameter and handling.
17987 (build_try_finally_statement): New function.
17988 (patch_try_statement): No longer need to support finally clause.
17989 (try_statement): Update grammar action rules.
17990 * jcf-write.c (generate_bytecode_insns): Handle TRY_FINALLY_EXPR.
17991 Simpler handling of TRY_EXPR, which no longer has a finally clause.
17992
17993 1998-11-26 Andrew Haley <aph@viagra.cygnus.co.uk>
17994
17995 * jcf-parse.c (get_constant): Add braces around computation of 'd'
17996 when REAL_ARITHMETIC is not defined. [Oct 26 fix got overwritten -PB]
17997
17998 1999-02-17 Andrew Haley <aph@cygnus.com>
17999
18000 * class.c (build_utf8_ref): Back out broken patch which was
18001 intended to to output signatures using '.' as a separator.
18002
18003 * class.c (make_class_data): Output signatures using '.' as a
18004 separator, rather than '/'.
18005 (mangled_classname): Likewise.
18006 (make_field_value): Likewise.
18007 (make_method_value): Likewise.
18008 * constants.c (alloc_class_constant): Likewise.
18009 * expr.c (build_invokeinterface): Likewise.
18010
18011 1999-02-11 Alexandre Petit-Bianco <apbianco@cygnus.com>
18012
18013 * parse.y (valid_builtin_assignconv_identity_widening_p): Got rid
18014 of an ancient workaround.
18015
18016 1999-02-10 Jeffrey A Law (law@cygnus.com)
18017
18018 * jvspec.c (xmalloc): Kill the prototype. It does not belong
18019 here anymore.
18020
18021 1999-02-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
18022
18023 * lex.c (yylex): Encode \0 as UTF8.
18024
18025 1999-02-10 Tom Tromey <tromey@cygnus.com>
18026
18027 * jvspec.c (lang_specific_driver): Use libgcj, not libjava.
18028 * Makefile.in (jcf-path.o): Define LIBGCJ_ZIP_FILE.
18029 (libgcj_zip): Renamed.
18030 * jcf-path.c (add_entry): Use LIBGCJ_ZIP_FILE, not
18031 LIBJAVA_ZIP_FILE.
18032 (jcf_path_init): Use LIBGCJ_ZIP_FILE.
18033
18034 * jvspec.c (THREAD_NAME): Renamed -lqthreads to -lgcjcoop.
18035 (GC_NAME): Renamed -lgc to -lgcjgc.
18036
18037 1999-02-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
18038
18039 * lex.c (java_lang_cloneable): Initialize.
18040 * parse.y (java_lang_cloneable): New static variable.
18041 (qualify_ambiguous_name): Take CONVERT_EXPR into account when
18042 doing one more qualification round.
18043 (valid_ref_assignconv_cast_p): Reject null source or
18044 destination. Allow an array to be cast into java.lang.Cloneable.
18045 (patch_cast): Swapped two first arguments to first call to
18046 valid_ref_assignconv_cast_p.
18047
18048 1999-02-08 Alexandre Petit-Bianco <apbianco@cygnus.com>
18049
18050 * parse.h: DECL_P renamed JDECL_P.
18051 * parse.y: DECL_P replaced by JDECL_P.
18052 (build_array_from_name): Always use pointer's type.
18053 (patch_bc_statement): Extra code to search continue target in a
18054 for loop. Fixed comments. Continue target is current loop when
18055 unlabeled.
18056
18057 1999-02-05 Andrew Haley <aph@cygnus.com>
18058
18059 * class.c (make_class_data): The superclass of an interface should
18060 be null, not class Object.
18061
18062 * lex.c (java_lex): Sign extend hex literals.
18063
18064 1999-02-04 Andrew Haley <aph@cygnus.com>
18065
18066 * class.c (build_utf8_ref): Output signatures using '.' as a
18067 separator, rather than '/'.
18068 (make_class_data): Likewise.
18069
18070 1999-02-03 Marc Espie <Marc.Espie@liafa.jussieu.fr>
18071
18072 * Make-lang.in ($(GCJ)(exeext)): Remove choose-temp.o, pexecute.o and
18073 mkstemp.o. Get them from libiberty now.
18074
18075 1999-02-02 Jeffrey A Law (law@cygnus.com)
18076
18077 * jcf-io.c: Do not include sys/stat.h or sys/wait.h
18078
18079 1999-02-02 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18080
18081 * jvspec.c (xmalloc): Fix the prototype to match the one obtained
18082 from libiberty.h
18083
18084 1999-02-02 Per Bothner <bothner@cygnus.com>
18085
18086 Optimize: `return (a ? b : c)' as: `if (a) return b; else return c;'.
18087 * jcf-write.c (generate_bytecode_return): New function.
18088 (generate_bytecode_insns): Use it, for RETURN_EXPR.
18089
18090 * jcf-write.c (generate_bytecode_insns): For REAL_CST that is 0 or 1,
18091 generate special [fd]const_[01] instructions.
18092
18093 * jcf-parse.c (yyparse): Don't emit_register_classes if -fsyntax-only.
18094
18095 * verify.c (verify_jvm_instructions): Do INVALIDATE_PC after
18096 handling OPCODE_lookupswitch or OPCODE_tableswitch.
18097
18098 1999-02-01 Per Bothner <bothner@cygnus.com>
18099
18100 * parse.y (patch_method_invocation): Handle calling static methods,
18101 even in the form EXPR.METHOD(ARGS), not just TYPE.METHOD(ARGS).
18102
18103 * parse.y (java_complete_lhs): Don't complain about unreachable
18104 exit condition in a do-while statement.
18105
18106 1999-01-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
18107
18108 * lex.c (java_read_char): Fixed utf8 decoding.
18109 (java_unicode_2_utf8): Fixed utf8 encoding in the 0x800-0xffff
18110 range.
18111 * parse.y (valid_builtin_assignconv_identity_widening_p): Fixed
18112 comments. Local variable `all_primitive' is gone. Broadened
18113 acceptance of `0' to floating point targets. `long' can now be
18114 widened to `double' or `float'.
18115 (valid_method_invocation_conversion_p): Added leading
18116 comment. Fixed tabulation.
18117 (build_string_concatenation): Optimize out left or right empty
18118 string constants.
18119
18120 1999-01-28 Per Bothner <bothner@cygnus.com>
18121
18122 * jcf-write.c (localvar_alloc): Only emit entry for
18123 LocalVariableTable if debug_info_level > DINFO_LEVEL_TERSE.
18124 (generate_bytecode_insns): Only call put_linenumber if
18125 debug_info_level > DINFO_LEVEL_NONE.
18126 * jvspec.c (lang_specific_driver): If no -O* or -g* option
18127 is specified, add -g1 (for compatibility wih javac).
18128
18129 1999-01-28 Hans-Peter Nilsson <hp@axis.se>
18130
18131 * java/Makefile.in: Add missing dependencies for jcf-dump.o,
18132 gjavah.o, check-init.o, jv-scan.o
18133
18134 1999-02-01 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18135
18136 * Makefile.in (gjavah.o): Depend on $(CONFIG_H) and system.h.
18137
18138 * gjavah.c: Include config.h and system.h.
18139
18140 * javaop.h (inline): Don't define, its handled by system.h.
18141 (WORD_TO_FLOAT, WORDS_TO_LONG, WORDS_TO_DOUBLE): Change these
18142 from `inline' to `static inline'.
18143
18144 * jcf.h (inline): Don't define, its handled by system.h.
18145
18146 * lex.c (inline): Likewise.
18147
18148 1999-01-31 Zack Weinberg <zack@rabi.columbia.edu>
18149
18150 * lang-specs.h: Map -Qn to -fno-ident.
18151
18152 1999-01-29 Richard Henderson <rth@cygnus.com>
18153
18154 * check-init.c (check_init): Fix CLEANUP_POINT_EXPR typo.
18155
18156 1999-01-29 Tom Tromey <tromey@cygnus.com>
18157
18158 * parse.h (BUILD_APPEND): If ARG is a non-String object reference,
18159 then cast it to Object before calling `append' method.
18160
18161 1999-01-28 Per Bothner <bothner@cygnus.com>
18162
18163 * check-init.c (check_bool2_init, check_bool_init, check_init):
18164 Handle TRUTH_AND_EXPR, TRUTH_OR_EXPR, and TRUTH_XOR_EXPR.
18165 * jcf-write.c (generate_bytecode_insns): Likewise.
18166
18167 1999-01-28 Alexandre Petit-Bianco <apbianco@cygnus.com>
18168
18169 * jcf-parse.c (jcf_parse): Don't parse the same class file twice.
18170 * parse.y (patch_cast): Allow a boolean to be cast into a
18171 boolean.
18172
18173 1999-01-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
18174
18175 * parse.y: (class_declaration:): Fixed indentation.
18176 (class_member_declaration:): Extra `;' after field declaration now
18177 accepted.
18178 (interface_declaration:): Removed debug messages in error reports.
18179 (patch_binop): Nodes created and returned inherit the orignal
18180 node's COMPOUND_ASSIGN_P flag value.
18181 (patch_cast): Fix cast from char to floating point.
18182
18183 1999-01-25 Andrew Haley <aph@cygnus.com>
18184
18185 * except.c, java-except.h (expand_resume_after_catch): new
18186 function.
18187 * expr.c (java_lang_expand_expr): call expand_resume_after_catch
18188 to branch back to main flow of control after a catch block.
18189
18190 1999-01-23 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18191
18192 * Makefile.in (parse.o): Depend on $(CONFIG_H) and
18193 $(srcdir)/../system.h.
18194 (class.o): Depend on $(PARSE_H) and $(srcdir)/../output.h.
18195 (jcf-parse.o): Depend on $(srcdir)/../toplev.h.
18196 (jcf-write.o): Likewise.
18197 (jv-scan.o): Depend on $(CONFIG_H) and $(srcdir)/../system.h.
18198 (mangle.o): Depend on $(srcdir)/../toplev.h.
18199 (parse-scan.o): Depend on $(CONFIG_H) and $(srcdir)/../system.h.
18200 (zextract.o): Depend on $(CONFIG_H) and $(srcdir)/../system.h.
18201
18202 * class.c: Include output.h and parse.h.
18203 (mangled_classname): Add the `const' keyword to a char*.
18204 (find_named_method): Hide unused function definition.
18205 (build_utf8_ref): Change type of variable `c' to unsigned char.
18206 Use ISALPHA/ISDIGIT instead of isalpha/isdigit.
18207 (build_class_ref): Add the `const' keyword to a char*.
18208 (layout_class_method): Remove unused variable `buf'.
18209
18210 * decl.c (find_local_variable): Remove unused variable `rtl'.
18211 (pushdecl): Likewise for variables `different_binding_level' and
18212 `oldglobal'.
18213 (pushlevel): Mark parameter `unused' with ATTRIBUTE_UNUSED.
18214 (maybe_build_cleanup): Likewise for parameter `decl'.
18215
18216 * except.c (expand_start_java_handler): Mark parameter `range'
18217 with ATTRIBUTE_UNUSED.
18218
18219 * expr.c: Include except.h.
18220 (pop_type): Remove unused variable `i'.
18221 (pop_value): Likewise for variables `n_words' and `i'.
18222 (expand_java_arrayload): Likewise for variable `convert'.
18223 (java_lang_expand_expr): Likewise for variables `op0', `type',
18224 `mode', `unsignedp', `node' and `elements'.
18225 (expand_byte_code): Likewise for variables `prev_eh_ranges' and
18226 `eh_ranges'.
18227 (process_jvm_instruction): Add a `const' qualifier to a char*.
18228
18229 * gjavah.c (output_directory): Add the `const' keyword to a char*.
18230 (temp_directory): Likewise.
18231 (print_c_decl): Likewise.
18232 (print_method_info): Likewise.
18233 (decode_signature_piece): Likewise.
18234 (print_mangled_classname): Likewise.
18235
18236 * java-except.h: Provide prototypes for maybe_start_try,
18237 maybe_end_try and add_handler.
18238
18239 * java-tree.h (mangled_classname): Add the `const' keyword to a char*.
18240 (parse_error_context): Likewise. Also add ATTRIBUTE_PRINTF_2.
18241 (pushdecl_top_level, alloc_class_constant, unicode_mangling_length,
18242 init_expr_processing, push_super_field, init_class_processing,
18243 can_widen_reference_to, class_depth, verify_jvm_instructions,
18244 maybe_pushlevels, maybe_poplevels, process_jvm_instruction,
18245 set_local_type, merge_type_state, push_type, load_type_state,
18246 add_interface, find_in_current_zip, append_gpp_mangled_classtype,
18247 emit_unicode_mangled_name): Add prototypes.
18248
18249 * jcf-dump.c (print_constant): Add the `const' keyword to a char*.
18250 (print_signature_type): Use ISDIGIT, not isdigit.
18251 (print_signature): Remove unused variable `j'.
18252
18253 * jcf-io.c (jcf_filbuf_from_stdio): Cast the result of `fread' to
18254 int when comparing against one.
18255
18256 * jcf-parse.c: Include toplev.h.
18257
18258 * jcf-write.c: Likewise. Don't include <string.h> or <sys/stat.h>.
18259 (localvar_free): Remove unused variable `i'.
18260 (generate_bytecode_conditional): Likewise for variable `kind'.
18261
18262 * jv-scan.c: Include config.h and system.h. Remove redundant
18263 OS header and gansidecl.h includes.
18264 (warning): Add the `const' keyword to a char*. Also add
18265 ATTRIBUTE_PRINTF_1 to the prototype. Check ANSI_PROTOTYPES, not
18266 __STDC__, when determining whether to use ANSI-isms.
18267 (fatal): Likewise. Also add ATTRIBUTE_UNUSED.
18268 (xmalloc): Don't redundantly prototype here.
18269 (main): Remove unused parameter `envp'. Also fix the arguments
18270 passed to function `fatal' to match the format specifier.
18271
18272 * lang.c (java_tree_code_name): Add the `const' keyword to a char*.
18273
18274 * mangle.c: Include toplev.h.
18275 (emit_unicode_mangled_name): Declare parameter `len'.
18276
18277 * parse.y (parse_warning_context): Add the `const' keyword to a
18278 char*. Also add ATTRIBUTE_PRINTF_2 to the prototype. Check
18279 `ANSI_PROTOTYPES' not `__STDC__' for whether to use ANSI-isms.
18280 (issue_warning_error_from_context): Add the `const' keyword to
18281 a char*.
18282 (parse_error_context): Likewise. Also check `ANSI_PROTOTYPES'
18283 not `__STDC__' for whether to use ANSI-isms.
18284
18285 * typeck.c (incomplete_type_error): Mark parameters `value' and
18286 `type' with ATTRIBUTE_UNUSED.
18287 (parse_signature_type): Use ISDIGIT, not isdigit.
18288
18289 * verify.c (check_pending_block): Add the `const' keyword to a char*.
18290 (verify_jvm_instructions): Likewise. Remove unused variables
18291 `field_name' and `default_val'.
18292
18293 * zextract.c: Include config.h and system.h. Remove redundant
18294 OS header includes.
18295
18296 * zipfile.h: Prototype `read_zip_archive'.
18297
18298 1999-01-21 Andrew Haley <aph@cygnus.com>
18299
18300 * typeck.c (convert): Allow conversions to void type: some
18301 optimizations in gcc do this.
18302
18303 1999-01-21 Andrew Haley <aph@cygnus.com>
18304
18305 * typeck.c (convert_ieee_real_to_integer): New function.
18306 (convert): When not using fast-math and using hardware fp, convert
18307 an IEEE NaN to zero.
18308
18309 1999-01-18 Andrew Haley <aph@cygnus.com>
18310
18311 * parse.y (patch_binop): Do a type conversion from signed to
18312 unsigned and then back to signed when a ">>>" is found.
18313
18314 1999-01-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
18315
18316 * java-tree.h: (check_for_initialization): Added prototype.
18317 * lex.c (java_parse_doc_section): `\n' breaks the `*/' string.
18318 * parse.y (do_resolve_class): Removed unused locals.
18319 (read_import_dir): Likewise.
18320 (resolve_qualified_expression_name): Array creation
18321 expressions are valid primary expressions.
18322 (qualify_ambiguous_name): Likewise.
18323 (patch_synchronized_statement): Removed unused local.
18324
18325 1999-01-17 Jeffrey A Law (law@cygnus.com)
18326
18327 * Makefile.in (zextract.o): Add dependencies.
18328
18329 * Makefile.in: Do not put ^Ls at the start of a line.
18330
18331 1999-01-15 Per Bothner <bothner@cygnus.com>
18332
18333 * expr.c (process_jvm_instruction): Coerce to correct Throwable
18334 sub-type the result of the call that gets the exception value.
18335
18336 * parse.y (java_complete_expand_methods): If flags_syntax_only,
18337 don't call finish_class.
18338
18339 * parse.y (java_check_regular_methods): If METHOD_PRIVATE,
18340 clear found before continuing.
18341
18342 * verify.c (verify_jvm_instructions): On an array load, allow
18343 and handle top of stack to be TYPE_NULL.
18344
18345 * gjavah.c (generate_access): Translate Java package private or
18346 protected access to C++ public, but with a comment.
18347
18348 1999-01-13 Andrew Haley <aph@cygnus.com>
18349
18350 * expr.c (generate_name): Name prefix changed to avoid clashes
18351 with assembler temp labels.
18352
18353 * parse.y (patch_synchronized_statement): Set TREE_SIDE_EFFECTS on
18354 MODIFY_EXPR. Without this, code for the assignment may not be
18355 generated at all and the synchronized statement will read an
18356 uninitialized variable.
18357
18358 1999-01-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
18359
18360 * class.c (maybe_layout_super_class): Fixed returned value.
18361 * lex.c: Added 1999 to the copyright.
18362 (java_init_lex): Initialize java_lang_imported.
18363 * lex.h: Added 1999 to the copyright.
18364 * parse.h: Added 1999 to the copyright.
18365 (REGISTER_IMPORT): Fixed typo in trailing macro.
18366 (CURRENT_OSB): New macro.
18367 (struct parser_ctxt): New fields osb_depth, osb_limit.
18368 * parse.y (java_lang_id): New global variable.
18369 (type_import_on_demand_declaration): Don't import java.lang.* twice.
18370 (array_creation_expression:): Use CURRENT_OSB.
18371 (dims:): Uses a stack to keep track of array dimensions.
18372 (cast_expression:): Use CURRENT_OSB.
18373 (find_expr_with_wfl): Return NULL if node found doesn't meet the
18374 conditions.
18375 (register_fields): Fixed typos in comment.
18376 (check_method_redefinition): Fixed comment indentation.
18377 (java_check_regular_methods): Set saved found wfl to NULL after
18378 having reinstalled it in the previously found DECL_NAME.
18379
18380 1999-01-10 Richard Henderson <rth@cygnus.com>
18381
18382 * gjavah.c (java_float_finite): Use a union to do type punning.
18383 (java_double_finite): Likewise.
18384
18385 1999-01-09 Per Bothner <bothner@cygnus.com>
18386
18387 * parse.y (build_new_array_init): Don't set EXPR_WFL_LINECOL
18388 on CONSTRUCTOR (since that trashes TREE_CST_RTL).
18389 (patch_new_array_init): Clear TREE_CONSTANT also if INDIRECT_REF.
18390 (register_fields): Set TREE_STATIC on NEW_ARRAY_INIT, not on
18391 CONSTRUCTOR (which causes expand_expr to call output_constant_def).
18392 * expr.c (java_lang_expand_expr): Check TREE_STATIC of NEW_ARRAY_INIT.
18393
18394 1999-01-08 Per Bothner <bothner@cygnus.com>
18395
18396 * check-init.c (check_init): If compiling to native, we don't
18397 see THROW_EXPR. Instead, look for a call to throw_node (_Jv_Throw).
18398
18399 1999-01-08 Tom Tromey <tromey@cygnus.com>
18400
18401 * parse-scan.y (variable_declarator_id): Set or increment
18402 bracket_count.
18403 (bracket_count): New global.
18404 (formal_parameter): Handle case where bracket pairs trail variable
18405 declarator id.
18406
18407 1999-01-07 Andrew Haley <aph@viagra.cygnus.co.uk>
18408
18409 * jcf-parse.c (yyparse): variable len changed from a char to an
18410 int to prevent overflow.
18411
18412 1999-01-06 Per Bothner <bothner@cygnus.com>
18413
18414 * java-tree.h: Declare read_class.
18415 * jcf-parse.c (read_class): New function.
18416 (load_class): Now just call read_class.
18417
18418 * java-tree.h (java_parse_abort_on_error): Only return if new errors.
18419 * jcf-parse.c (parse_source_file): Declare save_error_count,
18420 which is needed by java_parse_abort_on_error macro,
18421 * parse.y (java_layout_classes, java_expand_classes): Likewise.
18422
18423 * parse.y (register_fields): Set TREE_STATIC flag of NEW_ARRAY_INIT
18424 constructor, if initializing a static field.
18425 (patch_new_array_init): Set TREE_CONSTANT if it is.
18426 * expr.c (java_lang_expand_expr): For a static array constructor
18427 of primitive elements, allocate the array itself statically.
18428 Disabled until we can set the vtable field statically.
18429
18430 * check-init.c: New file. Checks for definite assignment.
18431 * Makefile.in (JAVA_OBJS): Add check-init.o.
18432 * parse.y (java_complete_expand_method): Call check_for_initialization.
18433 * parse.h (BLOCK_EXPR_DECLS, BLOCK_EXPR_BODY): Moved to java-tree.h.
18434
18435 1999-01-06 Graham <grahams@rcp.co.uk>
18436
18437 * parse.y : include system.h instead of including
18438 standard headers directly with the exception of <dirent.h>.
18439
18440 1999-01-06 Per Bothner <bothner@cygnus.com>
18441
18442 * lex.h: Moved static function declarations to lex.c,
18443 to shut up some -Wall warnings.
18444 * lex.c: Static function declarations moved here.
18445 * jcf-dump.c: Small fixes to shut up -Wall warnings.
18446
18447 1999-01-05 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18448
18449 * Make-lang.in ($(GCJ).o): Depend on prefix.h.
18450
18451 1998-12-22 Per Bothner <bothner@cygnus.com>
18452
18453 * expr.c (process_jvm_instruction): Do load_type_state after JSR.
18454 * verify.c (verify_jvm_instructions): Fix off-by-one error.
18455
18456 * jcf-write.c (CHECK_PUT): Add (void) cast to avoid -Wall warnings.
18457 (localvar_alloc): Change return type to void,
18458 (emit_unop): Remove unused variable size.
18459
18460 * jcf-write.c (struct jcf_block): Add new union.
18461 (PENDING_CLEANUP_PC, PENDING_EXIT_PC, UNDEFINED_PC): New macros.
18462 (call_cleanups): New functions.
18463 (struct jcf_partial): New fields num_finalizers and return_value_decl.
18464 (generate_bytecode_insns): Support CLEANUP_POINT_EXPR and
18465 WITH_CLEANUP_EXPR. Handle cleanups in RETURN_EXPR and EXIT_BLOCK_EXPR.
18466 * lang.c (lang_init): Call using_eh_for_cleanups.
18467 * parse.y (java_complete_lhs): For SYNCHRONIZED_EXPR, defer
18468 completing operands to patch_synchronized_statement.
18469 Support CLEANUP_POINT_EXPR, WITH_CLEANUP_EXPR.
18470 (patch_synchronized_statement): Re-write suing CLEANUP_POINT_EXPR and
18471 WITH_CLEANUP_EXPR instead of TRY_EXPR.
18472
18473 1998-12-20 John F. Carr <jfc@mit.edu>
18474
18475 * Make-lang.in: Comment out control-Ls; they upset some makes.
18476
18477 1998-12-18 Tom Tromey <tromey@cygnus.com>
18478
18479 * parse.y (check_class_interface_creation): Use DIR_SEPARATOR
18480 consistently.
18481
18482 1998-12-17 Tom Tromey <tromey@cygnus.com>
18483
18484 * parse.y (DIR_SEPARATOR): New define.
18485 (check_class_interface_creation): Use it.
18486
18487 * parse-scan.y (report_main_declaration): Recognize
18488 `java.lang.String' in argument to main.
18489
18490 1998-12-16 Per Bothner <bothner@cygnus.com>
18491
18492 * parse.y (create_interface): Remove bogus test.
18493
18494 1998-12-16 Per Bothner <bothner@cygnus.com>
18495
18496 * jcf-parse.c (get_constant): Set TREE_TYPE for string constants.
18497 (HANDLE_CONSTANTVALUE): If flag_emit_class_files, call get_constant.
18498
18499 1998-12-16 Tom Tromey <tromey@cygnus.com>
18500
18501 * parse-scan.y (qualified_name): Use correct sprintf format.
18502
18503 1998-12-15 Tom Tromey <tromey@cygnus.com>
18504
18505 * gjavah.c (print_field_info): Changed how most negative number is
18506 printed.
18507
18508 1998-12-14 Per Bothner <bothner@cygnus.com>
18509
18510 * parse.y (fold_constant_for_init): New function.
18511 (resolve_expression_name): Don't replace static final
18512 constant-initialized fields by its value.
18513 (java_complete_lhs): New. Same as java_complete_tree, except does
18514 not replace static final constant-initialized fields by their values.
18515 (register_fields): If there is an initializer, set DECL_INITIAL and
18516 MODIFY_EXPR_FROM_INITIALIZATION_P.
18517 (java_complete_tree): For MODIFY_EXPR, use java_complete_lhs for lhs.
18518 Only call patch_initialized_static_field if
18519 MODIFY_EXPR_FROM_INITIALIZATION_P.
18520 (patch_initialized_static_field): If not valid constant, clear
18521 DECL_INITIAL.
18522
18523 * parse.y (lookup_field_wrapper): Fix thinko.
18524
18525 * parse.y (java_complete_tree): In EXPR_WITH_FILE_LOCATION,
18526 set and restore global lineno.
18527
18528 1998-12-14 Tom Tromey <tromey@cygnus.com>
18529
18530 * gjavah.c (print_field_info): If value to print is the smallest
18531 value of its size, then print as hex to avoid later warnings from
18532 C++ compiler.
18533
18534 1998-12-14 Tom Tromey <tromey@cygnus.com>
18535
18536 * gjavah.c (decompile_method): Decompile `return null'.
18537 (process_file): Generate `#pragma interface'.
18538 (method_declared): New global.
18539 (print_method_info): Set it.
18540 (HANDLE_CODE_ATTRIBUTE): Only print it method_declared set.
18541 (print_method_info): Handle abstract methods.
18542
18543 1998-12-13 Per Bothner <bothner@cygnus.com>
18544
18545 * parse.y (patch_method_invocation): If class_decl is null
18546 (e.g. an array type), use original type.
18547
18548 * parse.y (check_thrown_exceptions): Temporary hack to suppress
18549 errors about uncaught exception from clone (of array, specifically).
18550
18551 1998-12-13 Tom Tromey <tromey@cygnus.com>
18552
18553 * gjavah.c (decompile_method): Handle all types of `return'
18554 opcode. Decompile `return this' and `return'.
18555 (method_access): New global.
18556 (print_method_info): Set it.
18557 (decompile_method): Don't decompile a synchronized method.
18558
18559 1998-12-13 Tom Tromey <tromey@cygnus.com>
18560
18561 * jcf-reader.c (jcf_parse_one_method): Recognize
18562 HANDLE_END_METHOD.
18563 * gjavah.c (HANDLE_END_METHOD): New macro.
18564 (HANDLE_CODE_ATTRIBUTE): New macro.
18565 (decompile_method): New function.
18566 (print_method_info): Don't print `;\n' at end of function decl.
18567 Include java-opcodes.h.
18568 (decompiled): New global.
18569
18570 1998-12-12 Per Bothner <bothner@cygnus.com>
18571
18572 * class.c (build_class_ref): Handle PRIMTYPE.class if
18573 flag_emit_class_files.
18574 * expr.c (expand_java_field_op): Don't optimize java.lang.XXX.TYPE
18575 if flag_emit_class_files.
18576 * parse.y (java_complete_tree): Pre-liminary support for
18577 COMPONENT_REF - only to handle PRIMCLASS.TYPE.
18578
18579 * parse.y (patch_synchronized_statement): Don't call monitorexit
18580 unless block CAN_COMPLETE_NORMALLY. Propagate that flag properly.
18581
18582 * java-tree.h (DECL_LOCAL_STATIC_VALUE): Removed - no longer used.
18583
18584 * zipfile.h (opendir_in_zip): New declaration.
18585 * jcf-io.c (saw_java_source): Moved to jcf-parse.c.
18586 (opendir_in_zip): New function, using code from open_in_zip.
18587 (open_in_zip): Call opendir_in_zip.
18588 (find_class): Remove no-longer-used do_class_file parameter,
18589 but add source_ok parameter. Change logic so if we find a .java file,
18590 we don't look for .class in later classpath emtries.
18591 * jcf-parse.c (load_class): Pass saw_java_source to find_class.
18592 (jcf_figure_file_type): Only call open_in_zip if correct magic number.
18593 * gjavah.c: Update call to find_class.
18594 * jcf-dump.c: Likewise.
18595
18596 * jcf-write.c (put_linenumber): Handle duplicate line numbers.
18597 (generate_bytecode_insns): For EXPR_WITH_FILE_LOCATION, do
18598 nothing if body is empty_stmt_node.
18599 Various little fixes so SP gets correctly adjusted.
18600 For NEW_ARRAY_INIT, handle IGNORE_TARGET.
18601 For CALL_EXPR, test if static first.
18602 (generate_classfile): Ignore fields that are DECL_ARTIFICIAL,
18603 such as the ones we create for Object and Class.
18604 Set and restore current_function_decl.
18605 * parse.y: Check/set IS_AN_IMPORT_ON_DEMAND_P in read_import_dir.
18606 (note_possible_classname): New function.
18607 (read_import_entry): Removed. Merged with read_import_dir.
18608 (read_import_dir): Don't call find_class - that only gives us
18609 the first classpath entry having the needed package.
18610 Use the struct buffer data structure from buffer.h.
18611 (read_import_dir, find_in_imports_on_demand): The remembered
18612 class names now use '.' (not '/') as package separator.
18613
18614 * parse.y (java_complete_expand_methods): Call write_classfile
18615 here, and not in java_expand_classes (which only gets first class).
18616
18617 1998-12-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
18618
18619 * parse.y (<type_declaration>): Do maybe_generate_clinit last.
18620 (register_fields): If a static fields has an initializer, just
18621 chain it on ctxp->static_initialized, and handle later.
18622 (java_complete_expand_methods): Force <clinit> first.
18623 (resolve_expression_name, resolve_field_access): Just get DECL_INITIAL
18624 - it's already been completed.
18625 (patch_initialized_static_field): New function.
18626 (java_complete_field): Call it.
18627
18628 1998-12-12 Per Bothner <bothner@cygnus.com>
18629
18630 * expr.c (encode_newarray_type, build_new_array): New functions.
18631 * java-tree.h: Declare build_new_array.
18632 * jcf-write.c (patch_newarray): Use build_new_array.
18633
18634 * expr.c (java_lang_expand_exp): Support NEW_ARRAY_INIT.
18635 * jcf-write.c (generate_bytecode_insns): Support NEW_ARRAY_INIT.
18636
18637 * parse.y (patch_new_array_init): Re-organize.
18638 Now is passed the actual array (pointer) type of the value.
18639 Set the type of the CONSTRUCTOR to be an ARRAY_TYPE.
18640 (patch_array_constructor): Removed - merged into patch_new_array_init.
18641 (java_complete_tree): Update patch_new_array_init.
18642
18643 * jcf-write.c (find_constant_index): New function.
18644 (generate_bytecode_insns): Use find_constant_index.
18645 (generate_classfile): Use find_constant_index for ConstantValue.
18646
18647 1998-12-11 Tom Tromey <tromey@cygnus.com>
18648
18649 * expr.c (invoke_build_dtable): Renamed dtable -> vtable.
18650 * decl.c (init_decl_processing): Renamed dtable -> vtable.
18651 * class.c (make_class_data): Renamed dtable -> vtable, and
18652 dtable_method_count -> vtable_method_count.
18653
18654 1998-12-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
18655
18656 * decl.c (long_zero_node, float_zero_node, double_zero_node): New
18657 global variables, initialized.
18658 * java-tree.h (long_zero_node, float_zero_node, double_zero_node):
18659 Declared new global variables.
18660 * lex.c (java_lex): Return long_zero_node, float_zero_node,
18661 double_zero_node, integer_zero_node upon direct matching.
18662 * parse.y (purify_type_name): Added function prototype.
18663 (duplicate_declaration_error_p): Consider new_type as potentially
18664 being a incomplete type. Use purify_type_name on type string.
18665 (method_header): saved_type: unused variable removed. Don't figure
18666 return type if method name is invalid.
18667 (java_complete_tree): Set CAN_COMPLETE_NORMALLY after `node' was
18668 processed by patch_unaryop.
18669 (patch_unaryop): Fixed typo in comment. Re-convert pre/post
18670 increment/decrement node into its original type after binary
18671 numeric promotion on its operands.
18672
18673 1998-12-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
18674
18675 * parse.y (array_initializer:): Array init operand is NULL_TREE
18676 instead of a TREE_LIST of NULL_TREEs when parsing `{}'. `{,}' is
18677 now an error. Fixed indentation problems.
18678 (patch_string): Handle error_mark_node as an argument.
18679 (patch_new_array_init): Fixed indentation problems.
18680 (array_constructor_check_entry): Removed check on null wfl_value.
18681 Return an error if wfl_value's walk returns an error.
18682
18683 1998-12-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
18684
18685 * java-tree.def (NEW_ARRAY_INIT): New Java tree code.
18686 * lex.c (java_lex): Remember column position before advancing one
18687 token. Retain location information on OCB_TK.
18688 * lex.h (typedef struct java_lc): Added new field.
18689 * parse.h (GET_SKIP_TYPE): New macro.
18690 (QUAL_DECL_TYPE): Redefined using GET_SKIP_TYPE.
18691 * parse.y (build_new_array_init, patch_new_array_init,
18692 patch_array_constructor, maybe_build_array_element_wfl,
18693 array_constructor_check_entry): New function prototypes.
18694 (switch_block:): Tagged <node>.
18695 (OCB_TK): Tagged <operator>.
18696 (array_initializer:): Installed actions.
18697 (variable_initializer): Build location information on element if
18698 necessary.
18699 (switch_statement:): Fixed indentation typo.
18700 (switch_block:): Redefined default action.
18701 (java_complete_tree): Handle NEW_ARRAY_INIT in MODIFY_EXPR:.
18702 (patch_assignment): Removed duplicate code.
18703 (maybe_build_array_element_wfl, build_new_array_init,
18704 patch_new_array_init, patch_array_constructor,
18705 array_constructor_check_entry): New functions.
18706
18707 1998-12-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
18708
18709 * parse.y (array_initializer): Tagged <node>.
18710 (variable_initializer:): Use default rule.
18711 (array_initializer:): Defined actions.
18712 (variable_initializers:): Likewise.
18713 (resolve_qualified_expression_name): Use DECL_CONTEXT to build
18714 non-static field accesses.
18715 (patch_invoke): Fixed indentation typo.
18716 (java_complete_tree): Likewise.
18717 (build_labeled_block): Changed leading comment. Generate an error
18718 in case of duplicate loop labels.
18719 (patch_conditional_expr): Patch results of string concatenation
18720 operations.
18721
18722 1998-12-06 Per Bothner <bothner@cygnus.com>
18723
18724 * constants.c (find_methodref_index): When the class is an interface,
18725 generate CONSTANT_InterfaceMethodref instead of a CONSTANT_MethodRef.
18726
18727 * decl.c (finit_identifier_node): Use "$finit$", rather than
18728 "<finit>" (which Sun's verifier rejects).
18729 * parse.y (maybe_generate_finit): Leave out meaningless final flag.
18730 (generate_field_initialization_code): Removed.
18731 (fix_constructors) Don't add call to $finit$ here (wrong order).
18732 (patch_method_invocation): Add $finit$ call here.
18733
18734 * java-tree.h (CALL_USING_SUPER): New macro.
18735 * parse.y (patch_invoke): Remove im local variable.
18736 (patch_method_invocation, patch_invoke): Don't pass super parameter.
18737 (patch_invoke): Use CALL_USING_SUPER instead of from_super parameter.
18738 (resolve_qualified_expression_name): Maybe set CALL_USING_SUPER.
18739
18740 * jcf-write.c (get_access_flags): Fix typo ACC_PUBLIC -> ACC_FINAL.
18741
18742 * parse.y (java_complete_tree): Don't complain about unreachable
18743 statement if it is empty_stmt_node.
18744
18745 * jcf-write.c (find_constant_wide): New function.
18746 (push_long_const): Use find_constant_wide.
18747
18748 * jcf-write.c (generate_bytecode_insn): Fix bug in switch handling.
18749 (generate_bytecode_insn): Use correct dup variant for MODIFY_EXPR.
18750 Add "redundant" NOTE_PUSH/NOTE_POP uses so code_SP_max gets set.
18751 Emit invokeinterface when calling an interface method.
18752 Emit invokespecial also when calling super or private methods.
18753
18754 * jcf-write.c (generate_classfile): Emit ConstantValue attributes.
18755
18756 1998-12-06 Per Bothner <bothner@cygnus.com>
18757
18758 * jcf-dump.c (INVOKE): If invokeinterface, print number of args.
18759
18760 1998-12-03 Alexandre Petit-Bianco <apbianco@cygnus.com>
18761
18762 * java-tree.h (java_layout_seen_class_methods): New function
18763 prototype.
18764 (LAYOUT_SEEN_CLASS_METHODS): Macro removed.
18765 * jcf-parse.c (parse_class_file): Call java_layout_seen_class_methods.
18766 * parse.h (PROMOTE_RECORD_IF_COMPLETE): New macro.
18767 * parse.y (method_declarator:): Defined action.
18768 (issue_warning_error_from_context): input_filename saved, set to
18769 the appropriate value and restored after java_error is called.
18770 (build_unresolved_array_type): Fixed comment.
18771 (register_fields): Use PROMOTE_RECORD_IF_COMPLETE.
18772 (method_header): Deal with return type the same way type are
18773 handled for fields and method's parameters and local variables
18774 types are handled.
18775 (check_method_redefinition): Removed extra CR.
18776 (declare_local_variables): Use PROMOTE_RECORD_IF_COMPLETE.
18777 (java_layout_seen_class_methods): New function.
18778 (java_layout_classes): Call java_layout_seen_class_methods.
18779
18780 1998-12-03 Per Bothner <bothner@cygnus.com>
18781
18782 * parse,y (patch_synchronized_statement): Set CAN_COMPLETE_NORMALLY.
18783
18784 1998-12-03 Per Bothner <bothner@cygnus.com>
18785
18786 * jcf-dump.c (main): Fix error message.
18787 * jcf-path.c (add_entry): Style fix.
18788
18789 1998-12-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
18790
18791 * class.c (layout_class_method): Call build_java_argument_signature
18792 on constructors too.
18793 * parse.y (check_method_redefinition): Use TYPE_ARGUMENT_SIGNATURE.
18794 (patch_method_invocation): Define a primary when resolving an
18795 expression name. Augmented comment on code checking illegal `this'
18796 usage. Loosened it test by accepting NEW_CLASS_EXPR.
18797
18798 1998-12-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
18799
18800 * class.c (layout_class_method): Don't report error on non-static
18801 overriding static if the method is private.
18802 * java-tree.h (finish_class): Prototype added.
18803 * lex.c (java_get_line_col): Handle col argument -2 value.
18804 * parse.h: All static method declarations moved to parse.y.
18805 * parse.y: Now contains all static method declarations previously
18806 found in parse.h.
18807 (find_expr_with_wfl, missing_return_error,
18808 unreachable_stmt_error): New functions.
18809 (java_get_real_method_name): Identify constructors bearing class
18810 names in source code compiled classes only.
18811 (java_complete_expand_methods): Call missing_return_error.
18812 (invocation_mode): Private methods invoked as static methods.
18813 (java_complete_tree): Call unreachable_stmt_error.
18814
18815 1998-12-01 Tom Tromey <tromey@cygnus.com>
18816
18817 * Makefile.in (+target): Removed.
18818 (+xmake_file): Likewise.
18819 (+tmake_file): Likewise.
18820 (.NOEXPORT): Removed duplicate.
18821
18822 1998-11-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18823
18824 * Makefile.in (jc1, jv-scan): Link with $(SUBDIR_OBSTACK).
18825
18826 * jv-scan.c: Fix xmalloc prototype. Provide an xmalloc definition.
18827
18828 * jvgenmain.c: Remove the xmalloc prototype, we get it from
18829 libiberty.h. Provide an xmalloc definition.
18830
18831 * jvspec.c: Remove the xmalloc prototype.
18832
18833 * parse-scan.y: Include config.h and system.h. Don't include
18834 OS headers or gansidecl.h. Don't prototype xmalloc/xstrdup.
18835 Provide an xstrdup definition.
18836
18837 1998-11-26 Alexandre Oliva <oliva@dcc.unicamp.br>
18838
18839 * jcf-path.c (add_entry): Recognize ".jar" too.
18840 * lang-specs.h: Likewise.
18841
18842 1998-11-26 Per Bothner <bothner@cygnus.com>
18843
18844 * jcf-write.c (generate_bytecode_insns): In Call_EXPR, handle
18845 soft_monitorenter_node, soft_monitorexit_node, throw_node.
18846
18847 * jcf-write.c (generate_bytecode_insns):
18848 Handle pre/post-increment/decrement of long.
18849
18850 * jcf-write.c (generate_bytecode_insns):
18851 Handle missing exception handler (finally for synchronized).
18852
18853 1998-11-25 Per Bothner <bothner@cygnus.com>
18854
18855 * java-tree.h (end_params_node): Declare global.
18856 * decl.c (end_params_node): New global.
18857 (init_decl_processing, start_java_method): Use end_params_node for
18858 end of list of parameter types. Follows correct gcc conventions.
18859 * expr.c (pop_argument_types, pop_arguments): Likewise.
18860 * lang.c (put_decl_node): Likewise.
18861 * typeck.c (various places): Likewise.
18862 * class.y (various places): Likewise.
18863 * parse.y (various places): Likewise.
18864
18865 * parse.y (java_complete_tree): Move CAN_COMPLETE_NORMALLY.
18866 (build_jump_to_finally): Add missing CAN_COMPLETE_NORMALLY.
18867
18868 * class.c: Add #include flags.h, remove no-longer needed declaration.
18869
18870 * class.c (layout_class_method): Remove commented-out code, re-format.
18871 Don't add vtable entry (or index) for private methods.
18872 * expr.c (expand_invoke): A private method is implicitly final.
18873 * class.c (make_class_data): If inlining or optimizing,
18874 skip private methods.
18875
18876 * class.c (finish_class): New function. Calls existing methods,
18877 but alls emits deferred inline functions.
18878 * jcf-parse.c (parse_class_file): Call finish_class.
18879 * parse.y (java_complete_expand_methods): Likewise.
18880
18881 * expr.c (build_java_binop): Explicit default, to silence -Wall.
18882
18883 * expr.c (CHECK_PC_IN_RANGE): Add void cast to kill warnings.
18884
18885 1998-11-25 Marc Espie <espie@quatramaran.ens.fr>
18886
18887 * jcf-write.c (generate_bytecode_conditional): Fix typo.
18888
18889 1998-11-24 Per Bothner <bothner@cygnus.com>
18890
18891 * (generate_classfile): Always write class access flag with
18892 ACC_SUPER set.
18893
18894 1998-11-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
18895
18896 * class.c (maybe_layout_super_class): New function.
18897 (layout_class): Reorganized. Loop on class methods dispatched into
18898 a new function. Call maybe_layout_super_class.
18899 (layout_class_methods, layout_class_method): New functions.
18900 * expr.c (expand_java_NEW): Call layout_class_methods on loaded
18901 class.
18902 (expand_invoke): Likewise.
18903 * java-tree.h (all_class_list): New global variable declared.
18904 (layout_class_methods, layout_class_method): New function
18905 prototypes.
18906 (LAYOUT_SEEN_CLASS_METHODS): New macro.
18907 * jcf-parse.c (all_class_list): New global variable.
18908 (load_class): Extended what class_or_name can be. Use parser
18909 context mechanism to save globals before calling jcf_parse.
18910 (jcf_parse_source): Don't parse twice if HAS_BEEN_ALREADY_PARSED_P
18911 is set on the file name.
18912 (jcf_parse): Layout class methods when Object is loaded, otherwise
18913 record class in all_class_list for delayed method layout.
18914 (parse_class_file): Use LAYOUT_SEEN_CLASS_METHODS.
18915 * lang.c (put_decl_node): Decode <init> into the decl context
18916 class name.
18917 * lex.c (java_allocate_new_line): Use xmalloc.
18918 * parse.h (INCOMPLETE_TYPE_P): Redefined to work with incomplete
18919 pointers, not TREE_LIST elements.
18920 (struct parser_ctxt): Fixed comment indentations, added comments
18921 and reordered some fields.
18922 (java_check_methods): Function prototype removed.
18923 * parse.y (java_push_parser_context): Use xmalloc.
18924 (java_parser_context_restore_global): Pop extra pushed ctxp only
18925 when there's nothing next.
18926 (maybe_create_class_interface_decl): Fixed comment, add new
18927 created class decl to all_class_list.
18928 (method_header): Use GET_REAL_TYPE on argument's types.
18929 (method_declarator): Use GET_REAL_TYPE, change type to the real
18930 type in TREE_LIST dependency node. Build argument list with the
18931 real type.
18932 (create_jdep_list): Use xmalloc. Removed allocation error message.
18933 (obtain_incomplete_type): Fixed leading comment. Broadened
18934 incoming argument meaning.
18935 (register_incomplete_type): Use xmalloc. Removed allocation error
18936 message.
18937 (safe_layout_class): Fixed leading comment.
18938 (jdep_resolve_class): Reversed if statement condition and switch
18939 if and else bodies.
18940 (resolve_and_layout): Fixed leading comment. Broadened incoming
18941 argument meaning.
18942 (complete_class_report_errors): New local variable name, for
18943 clarity. purify_type_name used for all error cases.
18944 (java_get_real_method_name): Stricter check on constructors.
18945 (java_check_regular_methods): Reverse methods list only if not
18946 already laid out. Layout artificial constructor.
18947 (java_check_methods): Deleted.
18948 (source_start_java_method): Obtain incomplete type for patchable
18949 method arguments.
18950 (java_layout_classes): Fixed leading comment. Use
18951 LAYOUT_SEEN_CLASS_METHODS, use a loop to check methods. Added else
18952 statement to layout operation, reuse LAYOUT_SEEN_CLASS_METHODS
18953 before returning. Fixed comments.
18954 (java_expand_classes): Check for errors up front.
18955 (patch_method_invocation): Class to search is resolved and laid
18956 out.
18957
18958 1998-11-24 Per Bothner <bothner@cygnus.com>
18959
18960 * expr.c (java_lang_expand_expr): Add missing emit_queue.
18961
18962 * javaop.h (int8): Removed - not used.
18963 (jbyte): Redefine portably with correct signedness.
18964
18965 * jcf-write.c (generate_bytecode_insns): Don't free sw_state.cases.
18966
18967 * jcf-write.c (generate_bytecode_insns): Fix typo
18968 OPCODE_getstatic to OPCODE_getfield.
18969
18970 * java-tree.def (CASE_EXPR, DEFAULT_EXPR): Kind is 'x', not '1'.
18971 * parse.y (java_complete_tree): For CASE_EXPR and DEFAULT_EXPR,
18972 set TREE_SIDE_EFFECTS (otherwise expand_expr may skip them).
18973
18974 1998-11-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
18975
18976 * jcf-parse.c (jcf_parse_source): Function returned type is
18977 void. Added prototype.
18978 (jcf_parse): Function returned type is void.
18979 (yyparse): Remove call to fclose on the last parsed file.
18980
18981 * java-tree.h (jcf_parse): Changed jcf_parse prototype.
18982
18983 1998-11-18 Alexandre Petit-Bianco <apbianco@cygnus.com>
18984
18985 * class.c (unmangle_classname): Set QUALIFIED_P when appropriate.
18986 (layout_class): Cope with methods featuring WFL in decl names.
18987 * decl.c (unqualified_object_id_node): New global variable,
18988 initialized.
18989 (build_decl_no_layout): Removed.
18990 * expr.c (build_primtype_type_ref): Handle Double.
18991 (java_lang_expand_expr): Fixed indentations.
18992 * java-tree.h (CLASS_METHOD_CHECKED_P): Flag deleted.
18993 (flag_wall, flag_redundant, flag_not_overriding,
18994 flag_static_local_jdk1_1, unqualified_object_id_node): Global
18995 variable declarations.
18996 (build_decl_no_layout): Removed prototype.
18997 (java_get_real_method_name): Added prototype.
18998 (IS_UNCHECKED_EXPRESSION_P): Renamed IS_UNCHECKED_EXCEPTION_P.
18999 (java_parse_abort_on_error): Macro now just returns.
19000 * jcf-parse.c (jcf_parse_source): Check fclose returned
19001 value. Call emit_register_classes if java_report_errors returns
19002 zero.
19003 * lanc.c (flag_wall, flag_redundant, flag_not_overriding,
19004 flag_static_local_jdk1_1): New integer flags.
19005 (lang_decode_option): New flags set here.
19006 * parse.h (GET_REAL_TYPE, GET_METHOD_NAME): New macros.
19007 (OBSOLETE_MODIFIER_WARNING): Issue error message conditionally to
19008 the flag_redundant variable.
19009 (SET_TYPE_FOR_RESOLUTION): Consider Object being java.lang.Object
19010 when parsing java.lang.Object class.
19011 (BUILD_MONITOR_ENTER, BUILD_MONITOR_EXIT): Added terminal
19012 NULL_TREE to build.
19013 (resolve_qualified_expression_name): Fixed indentation.
19014 (patch_array_ref): Changed prototype.
19015 (not_initialized_as_it_should_p): Prototype removed.
19016 (java_report_errors): Added function prototype.
19017 * parse.y (formal_parameter:): Changed error message for not yet
19018 supported final parameters.
19019 (class_type_list:): Set both PURPOSE and VALUE of created
19020 TREE_LIST to be class_type.
19021 (primary_no_new_array:): Handle class literals on primitive types.
19022 (parse_warning_context): Reinstalled correct force_error and
19023 do_warning flags setups.
19024 (java_report_errors): Changed prototype. Return java_error_count
19025 value.
19026 (variable_redefinition_error): Consider treating variable type as
19027 a fake pointer.
19028 (create_interface): Warn about redundant abstract modifier if
19029 flag_redundant is set. Changed error message.
19030 (lookup_field_wrapper): Save/restore globals before/after looking
19031 up field.
19032 (duplicate_declaration_error_p): Consider treating declaration
19033 type as a fake pointer.
19034 (register_fields): Extract real type from dependency node. Check
19035 for duplicate field declaration after type adjustment. Use
19036 DECL_INITIAL to store static final initialized values.
19037 (method_header): Extract real function type from dependency node.
19038 (check_abstract_method_header): Use GET_METHOD_NAME.
19039 (obtain_incomplete_type): Layout fake pointer type.
19040 (safe_layout_class): Don't try to check for methods before layout.
19041 (java_complete_class): Don't check for correct throws clause
19042 elements inheritance here.
19043 (resolve_and_layout): Broadened name parameter meaning.
19044 (reset_method_name): Use GET_METHOD_NAME.
19045 (java_get_real_method_name): New function.
19046 (java_check_regular_methods): Don't check methods in
19047 java.lang.Object. Verify lineage of throws clause elements. Use
19048 flag_no_overriding in warning report.
19049 (check_throws_clauses): Don't check if class was from
19050 bytecode. Use IS_UNCHECKED_EXCEPTION_P macro.
19051 (java_check_methods): Don't set CLASS_METHOD_CHECKED_P flag.
19052 (declare_local_variables): Use flag_static_local_jdk1_1 to report
19053 warning on unsupported final local variables. Use build_decl
19054 instead of build_decl_no_layout. Get real local variable type from
19055 dependency node.
19056 (source_start_java_method): Get real parameter type from
19057 dependency node. Call build_decl instead of build_decl_no_layout.
19058 (java_layout_classes): Reverse tree and layout type and class as
19059 required. Mark class as loaded when done.
19060 (resolve_field_access): Fixed indentation. Restricted condition
19061 leading to static field access code generation. Set field_type
19062 decl's TREE_TYPE if QUAL_DECL_TYPE not available.
19063 (resolve_qualified_expression_name): Initialize type_found to
19064 null. Handle static field resolved during qualification. Fixed
19065 layout on non primitive field decl types.
19066 (not_accessible_p): Fixed typo in comment.
19067 (patch_method_invocation): Resolve and layout class to search from
19068 type.
19069 (lookup_method_invoke): Keep integer constant 0 as is. Resolve and
19070 layout non primitive type, if necessary. Make method node only to
19071 report errors.
19072 (find_applicable_accessible_methods_list): Consider WFL'ed method
19073 decl names. Fixed indentation.
19074 (argument_types_convertible): Resolve and layout target type if
19075 necessary.
19076 (java_complete_tree): Fixed indentation problems. Rewrote
19077 CALL_EXPR thrown exceptions check. Re-installed further processing
19078 of the assignment in certain cases.
19079 (patch_assignment): Call maybe_build_primttype_type_ref to perform
19080 inlining on class literals.
19081 (valid_builtin_assignconv_identity_widening_p): Cope with constant
19082 0 literal.
19083 (valid_method_invocation_conversion_p): Likewise.
19084 (patch_string): Temporary disable forbidden use of `this' in
19085 explicit constructor invocations when doing string concatenation
19086 within their scope.
19087 (patch_unaryop): Added comment. Reinstalled code to disable
19088 further check on assignment operation with cast expression RHS.
19089 (patch_switch_statement): Fixed indentation.
19090 (build_try_statement): Call build_decl instead of
19091 build_decl_no_layout.
19092 (patch_synchronized_statement): Likewise.
19093 (patch_throw_statement): Use IS_UNCHECKED_EXCEPTION_P instead of
19094 IS_UNCHECKED_EXPRESSION_P.
19095 (check_thrown_exceptions_do): Changed leading comment. Resolve and
19096 layout argument exception type.
19097 (purge_unchecked_exceptions): Use IS_UNCHECKED_EXCEPTION_P instead
19098 of IS_UNCHECKED_EXPRESSION_P.
19099
19100 1998-11-18 Anthony Green <green@cygnus.com>
19101
19102 * jcf-parse.c (yyparse): Open class file in binary mode.
19103
19104 1998-11-15 Per Bothner <bothner@cygnus.com>
19105
19106 * jvgenmain.c: Need to #include "gansidecl.h" (to get PROTO).
19107
19108 * jcf-write.c (perform_relocations): Move check out one loop.
19109
19110 1998-11-15 Anthony Green <green@hoser.cygnus.com>
19111
19112 * Make-lang.in: Fix reference to srcdir.
19113 * jv-scan.c: Add missing xmalloc prototype.
19114 * jvgenmain.c: Ditto.
19115
19116 1998-11-15 Per Bothner <bothner@cygnus.com>
19117
19118 * decl.c (error_mark_node), java-tree.h: New global.
19119 * parse.y: Use empty_stmt_node instead of size_zero_node.
19120 (build_if_else_statement): If missing else, use empty_stmt_node.
19121
19122 * parse.y (not_initialized_as_it_should_p): Removed, with its callers.
19123 (java_complete_expand_method): Complain if return is missing.
19124 (java_check_regular_methods): Comment out incorrect error check.
19125 (not_accessible_p): Fix incorrect handling of protected methods.
19126 (patch_method_invocation): Pass correct context to not_accessible_p.
19127 (find_applicable_accessible_methods_list): Likewise.
19128 (qualify_ambiguous_name): If ARRAY_REF, it's an expression name.
19129 (java_complete_tree): For CASE_EXPR and DEFAULT_EXPR, set
19130 TREE_TYPE (to void_type_node); otherwise expand_expr crashes.
19131 (patch_if_else_statement): Fix setting of CAN_COMPLETE_NORMALLY.
19132
19133 * jcf-write.c (CHECK_OP, CHECK_PUT): Add some error checking.
19134 (push_int_const): Remove reundant NOTE_PUSH.
19135 (generate_bytecode_insns - case STRING_CST): Do NOTE_PUSH.
19136 (- case SWITCH_EXPR): Fix code generation bug.
19137 (- case PREDECREMENT_EXPR etc): Remove redundant NOTE_PUSH.
19138 (generate_classfile): More robust for abstract methods.
19139
19140 1998-11-15 Anthony Green <green@cygnus.com>
19141
19142 * Makefile.in: jv-scan and jvgenmain all require libiberty.
19143 * Make-lang.in: Ditto.
19144
19145 * jv-scan.c: Remove xmalloc and xstrdup definitions.
19146 * jvgenmain: Ditto.
19147
19148 1998-11-15 Per Bothner <bothner@cygnus.com>
19149
19150 * jcf-parse.c (HANDLE_EXCEPTIONS_ATTRIBUTE): New macro.
19151
19152 * jcf-io.c (find_class): Simpler/cleaner structure fixes a bug.
19153
19154 1998-11-14 Per Bothner <bothner@cygnus.com>
19155
19156 Allow uses of interface types to verify. This is not really
19157 type-safe, but it matches what Sun does, and is OK as long as
19158 there are appropriate run-time checks.
19159 * verify.c (merge_types): If merging two interface types,
19160 just set the result to java.lang.Object.
19161 * expr.c (pop_type): Any interface is matches by java.lang.Object.
19162
19163 1998-11-13 Tom Tromey <tromey@cygnus.com>
19164
19165 * gjavah.c (main): Handle --output-class-directory argument.
19166 * jvspec.c (lang_specific_driver): Translate `-d' into
19167 -foutput-class-dir.
19168 * jcf.h (jcf_write_base_directory): Declare.
19169 * lang.c (lang_decode_option): Recognize -foutput-class-dir.
19170 * lang-options.h: Mention -foutput-class-dir.
19171 * jcf-write.c (jcf_write_base_directory): New global.
19172 (make_class_file_name): Put generated .class file into `-d'
19173 directory, or into source directory if -d not given. Function now
19174 static.
19175 (write_classfile): Free class file name. Handle case where class
19176 file name is NULL.
19177 (DIR_SEPARATOR): New macro.
19178 Include <sys/stat.h>
19179
19180 * Makefile.in (prefix): New macro.
19181
19182 1998-11-12 Per Bothner <bothner@cygnus.com>
19183
19184 * parse.y (patch_invoke): Do less if flag_emit_class_files.
19185 * expr.c (build_known_method_ref): Don't check flag_emit_class_files
19186 here (done in patch_invoke instead).
19187 (case_identity): Moved here from parse.y.
19188
19189 * java-tree.h (CAN_COMPLETE_NORMALLY): New macro.
19190 * parse.y (java_complete_tree etc): Maybe set CAN_COMPLETE_NORMALLY.
19191 * parse.y (java_complete_tree): Re-order COMPOUND_EXPR in BLOCK
19192 so they can be efficiently scanned without recursion.
19193 Error it ! CAN_COMPLETE_NORMALLY first part of COMPOUND_EXPR.
19194 * expr.c (java_lang_expand_expr): Expand statements of COMPOUND_EXPR
19195 in BLOCK iteratively, rather than recursively.
19196
19197 * parse.y (do_unary_numeric_promotion): New function.
19198 (patch_unaryop, patch_binop, patch_array_ref): Use it.
19199
19200 * parse.y (patch_newarray): Various fixes.
19201
19202 Re-do handling of switch statements (for proper block scoping).
19203 * parse.y: Add just a single block for the enture switch block,
19204 but don't create any "case blocks".
19205 (group_of_labels): Rmeoved unneeded non-terminal.
19206 CASE_EXPR and DEFAULT_EXPR are added to current block.
19207 * expr.c (java_lang_expand_expr): Inline SWITCH_EXPR here.
19208 Now also need to handle CASE_EXPR and DEFAULT_EXPR.
19209 * java-tree.h (SWITCH_HAS_DEFAULT): New macro.
19210 * parse.y (wfl_operator, print_int_node): Make non-static.
19211 (java_complete_tree): CASE_EXPR and DEFAULT_EXPR are now processed
19212 as part of recursive scan of block.
19213 (java_expand_switch ): Removed - inlined into java_lang_expand_expr.
19214 (patch_switch_statement): Most tests move dinto java_complete_tree.
19215
19216 * parse.y: Make various production be non-typed (void).
19217 * parse.y (parse_error): Merged into issue_warning_error_from_context.
19218 * parse.y (add_stmt_to_compound): Don't create/change extra node.
19219 (patch_method_invocation_stmt): Renamed to patch_method_invocation.
19220
19221 * jcf-write.c (struct jcf_handler): New type.
19222 (struct jcf_switch_state): New type.
19223 (SWITCH_ALIGN_RELOC, BLOCK_START_RELOC): New relocation kinds.
19224 (alloc_handler, emit_unop, emit_reloc): New functions.
19225 (adjust_typed_op): Add extra parameter ("max type" offset).
19226 (emit_switch_reloc, emit_case-reloc): New function.
19227 (generate_bytecode_conditional): Handle REAL_TYPE comparisons.
19228 (generate_bytecode_insns): Support REAL_CST, switch statements,
19229 exception handling, method calls, object/array creation, and more.
19230
19231 * class.c: Remove some unused variables.
19232 * constants.c (find_string_constant): New function.
19233 (count_constant_pool_bytes): Fix to correctly handle wide constants.
19234 * decl.c (complete_start_java_method): Don't _Jv_InitClass
19235 if flag_emit_class_files.
19236
19237 1998-11-12 Tom Tromey <tromey@cygnus.com>
19238
19239 * jcf-io.c (find_class): Added explanatory comment.
19240
19241 * jcf-path.c (add_entry): Look for `.zip' at end of filename. Add
19242 trailing slash to `.zip' entries.
19243
19244 * jvspec.c (lang_specific_driver): Correctly handle case where
19245 GC_NAME not defined.
19246
19247 1998-11-11 Tom Tromey <tromey@cygnus.com>
19248
19249 * jvspec.c (GC_NAME): New define.
19250 (lang_specific_driver): Use GC_NAME. Add GC_NAME to command line
19251 if required.
19252 * Make-lang.in (jvspec.o): Define WITH_GC_<name>.
19253
19254 1998-11-11 Per Bothner <bothner@cygnus.com>
19255
19256 * jcf-dump.c (TABLE_SWITCH): Fix typos.
19257
19258 1998-11-11 Tom Tromey <tromey@cygnus.com>
19259
19260 * jcf-dump.c (main): Correctly recognize `--'-style long options.
19261
19262 1998-11-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
19263
19264 * class.c (is_compiled_class): Call safe_layout_class for class
19265 compiled from source.
19266 * conver.h (convert_to_integer, convert_to_real,
19267 convert_to_pointer): Added prototypes.
19268 * decl.c (init_decl_processing): Non longer push the decls of
19269 `methodtable', `constants', `Class', `Field', `dispatchTable'
19270 `jexception' and `Method'.
19271 * expr.c (build_invokeinterface): New function.
19272 (expand_invoke): static variable CLASS_IDENT now in
19273 build_invokeinterface. Use build_invokeinterface.
19274 (expand_java_field_op): Moved code to inline
19275 java.lang.PRIMTYPE.TYPE into a function.
19276 (build_primtype_type_ref): New function.
19277 * java-tree.def (INSTANCEOF_EXPR): New tree code.
19278 * java-tree.h (CLASS_METHOD_CHECKED_P, METHOD_DEPRECATED,
19279 FIELD_DEPRECATED, CLASS_DEPRECATED): New flag macros.
19280 (DECL_CONSTRUCTOR_P): Fixed typo in comment.
19281 (DECL_LOCAL_STATIC_VALUE): New macro.
19282 (build_invokeinterface, build_primtype_type_ref): New function
19283 prototypes.
19284 (java_parse_abort_on_error): Macro rewritten.
19285 * jcf-parse.c (current_method): Add comment to declaration.
19286 (parse_zip_file_entries, process_zip_dir, void parse_source_file):
19287 Function prototypes fixed.
19288 (jcf_parse_source): push/pop parser context. save/restore global.
19289 (parse_source_file): Fixed leading comment. Now take a
19290 IDENTIFIER_NODE as an argument. Doesn't check methods, layout
19291 classes and pop the parser context anymore.
19292 (yyparse): Push parser context, save globals, parse the source
19293 file, restore globals and pop the parser context when processing a
19294 source file.
19295 * jcf.h (VERBOSE_SKELETON): Replaces SOURCE_FRONTEND_DEBUG define.
19296 * lex.c (java_parse_doc_section): New function.
19297 (java_lex): Call java_parse_doc_section when appropriate. Build an
19298 operator around INSTANCEOF_TK.
19299 * lex.h (java_lineterminator, java_sprint_unicode,
19300 java_unicode_2_utf8, java_lex_error, java_store_unicode):
19301 Prototypes rewritten.
19302 (java_parse_escape_sequence, java_letter_or_digit_p,
19303 java_parse_doc_section, java_parse_end_comment, java_get_unicode,
19304 java_read_unicode, java_store_unicode, java_read_char,
19305 java_allocate_new_line, java_unget_unicode, java_sneak_unicode):
19306 Added function prototypes.
19307 * parse.h (VERBOSE_SKELETON): Replaces SOURCE_FRONTEND_DEBUG
19308 define.
19309 (JNULLP_TYPE_P, CHECK_METHODS, CHECK_DEPRECATED, REGISTER_IMPORT):
19310 New macros
19311 (struct parser_ctxt): New fields: deprecated,
19312 current_parsed_class_un, gclass_list.
19313 (fix_method_argument_names, issue_warning_error_from_context,
19314 resolve_package, lookup_package_type): New function prototypes.
19315 (resolve_expression_name): Fixed function prototype.
19316 (find_applicable_accessible_methods_list): Fixed indentation, added
19317 extra argument in prototype.
19318 (check_final_assignment, build_null_of_type, check_deprecation,
19319 check_method_redefinition, reset_method_name,
19320 java_check_regular_methods, java_check_abstract_methods,
19321 maybe_build_primttype_type_ref): New function prototype.
19322 * parse.y (conver.h): Include.
19323 (INSTANCEOF_TK): Tagged <operator>.
19324 (single_type_import_declaration): Use REGISTER_IMPORT macro.
19325 (relational_expression:): Build binop for instanceof.
19326 (java_push_parser_context): Remember ctxp->gclass_list across
19327 contexts.
19328 (java_pop_parser_context): Simply return if no context
19329 exists. Remember gclass_list across contexts.
19330 (issue_warning_error_from_context): New function.
19331 (parse_error_context): Don't setup ctxp->elc here. Call
19332 issue_warning_error_from_context instead.
19333 (parse_warning_context): Likewise.
19334 (maybe_create_class_interface_decl): Removed DECL_ARTIFICIAL
19335 setup. Link new class/interface to ctxp->gclass_list.
19336 (add_superinterfaces): Register interface as incomplete if not
19337 loaded.
19338 (create_class): Remember class unqualified name in
19339 ctxp->current_parsed_class_un. Check class deprecation.
19340 (register_fields): Check field deprecation. Remember static final
19341 field value in DECL_LOCAL_STATIC_VALUE. Changed comment in part
19342 processing INIT.
19343 (method_header): New local variable ORIG_ARG. Use unqualified
19344 current class name for check on constructor errors. Promote return
19345 type if of record type. Argument list fix moved in
19346 fix_method_argument_names, called here. Check method deprecation.
19347 (fix_method_argument_names): New function.
19348 (method_declarator): Promote record typed arguments.
19349 (safe_layout_class): Check class methods before layout.
19350 (java_complete_class): Compute field layout when patched.
19351 (do_resolve_class): Try to load class after having it renamed
19352 after the package name.
19353 (get_printable_method_name): Use DECL_CONTEXT.
19354 (reset_method_name): New function.
19355 (check_method_redefinition): Use reset_method_name.
19356 (java_check_regular_methods): New local variable
19357 SAVED_FOUND_WFL. Temporarily reinstall overriding/hiding method
19358 names for error report. Check for compile-time error when method
19359 found has default (package) access.
19360 (java_check_abstract_methods): Now takes an interface DECL node as
19361 an argument. Also reinstall real name on unchecked
19362 overriding/hiding methods for error report.
19363 (java_check_methods): Fixed leading comment. Get classes to verify
19364 from ctxp->gclass_list. Use CHECK_METHODS macro and set
19365 CLASS_METHOD_CHECKED_P on class verification.
19366 (lookup_java_method2): Get real method name if necessary.
19367 (find_in_imports): Don't check package class access here.
19368 (resolve_package, lookup_package_type): New functions.
19369 (java_layout_classes): Fixed leading comment. Take classes to be
19370 laid out from ctxp->gclass_list.
19371 (java_complete_expand_methods): Don't expand native and abstract
19372 methods.
19373 (java_expand_classes): New function.
19374 (resolve_expression_name): Use additional argument ORIG. Retrieve
19375 values of static final field of primitive types.
19376 (resolve_field_access): Handles static final field of promotive
19377 type.
19378 (resolve_qualified_expression_name): Handle STRING_CST as
19379 primaries and package name resolution. Check deprecation on found
19380 decls. Set where_found and type_found on non static field resolved
19381 during qualification. Layout non primitive field decl types.
19382 (check_deprecation): New function.
19383 (maybe_access_field): Simplified.
19384 (patch_method_invocation_stmt): Local variable CLASS_TYPE
19385 removed. Reverse method's argument when primary is a type. Don't
19386 use CLASS_TYPE to report problems, use IDENTIFIER_WFL
19387 instead. Include abstract class in the list of class searchable
19388 for constructors. Use DECL_CONTEXT of found method for access
19389 checks. Check method deprecation.
19390 (patch_invoke): Pay extra care to NEW_CLASS_EXPR type call when
19391 converting arguments. Handle INVOKE_INTERFACE.
19392 (lookup_method_invoke): Search constructor using existing
19393 infrastructure (don't rely on lookup_java_constructor anymore).
19394 (find_applicable_accessible_methods_list): Extra argument flag
19395 LC. Now include constructor in the search.
19396 (qualify_ambiguous_name): Conditional expression are primaries.
19397 (not_initialized_as_it_should_p): static final are always
19398 initialized.
19399 (java_complete_tree): Pass extra NULL argument to
19400 resolve_expression_name. Stricter test to carry on patching
19401 assignments. New case for INSTANCEOF_EXPR.
19402 (complete_function_arguments): Inline PRIMTYPE.TYPE read access.
19403 (check_final_assignment, maybe_build_primttype_type_ref): New
19404 functions.
19405 (patch_assignment): Detect resolved static finals and carry normal
19406 assignment error check on them. Inline PRIMTYPE.TYPE read access.
19407 (try_builtin_assignconv): Access constant 0 on all primitive
19408 types.
19409 (valid_builtin_assignconv_identity_widening_p): Accept identical
19410 types. Accept all promoted type on int type.
19411 (valid_ref_assignconv_cast_p): Accept a null pointer to be
19412 assigned to a reference.
19413 (valid_method_invocation_conversion_p): Accept to check null
19414 pointers.
19415 (build_binop): Merge declaration and initialization of local
19416 variable BINOP.
19417 (patch_binop): New case for INSTANCEOF_EXPR. NE_EXPR to accept all
19418 numeric types. Improved validity test for qualify operators on
19419 references.
19420 (patch_unaryop): Broadened rejection test for PREDECREMENT_EXPR
19421 and PREINCREMENT_EXPR. Also detect resolved static finals of a
19422 primitive type and issue the appropriate error message.
19423 (resolve_type_during_patch): Mark class loaded when resolved.
19424 (patch_cast): Allow null to be cased to reference types.
19425 (build_null_of_type): New function.
19426 (patch_array_ref): Handle array on references correctly.
19427 (patch_return): Removed unused local variable MODIFY. Force
19428 boolean to be returned as integers. Allows null to be returned by
19429 a function returning a reference.
19430 * typeck.c (convert_to_integer, convert_to_real,
19431 convert_to_pointer): Prototypes moved to convert.h
19432 (lookup_argument_method): Use method real name, if necessary.
19433
19434 1998-10-30 Tom Tromey <tromey@cygnus.com>
19435
19436 * class.c (build_class_ref): Changed name of primitive classes to
19437 start with `_Jv_'.
19438
19439 * class.c (make_class_data): Renamed fields: nmethods to
19440 method_count, method_count to dtable_method_count. Always set
19441 `state' field to 0.
19442 * decl.c (init_decl_processing): Likewise.
19443
19444 1998-10-28 Alexandre Petit-Bianco <apbianco@cygnus.com>
19445
19446 * class.c (layout_class): Don't mangle <finit>, produce
19447 __finit<class> instead. Don't verify artificial methods.
19448 * decl.c (finit_identifier_node): New declared global.
19449 (init_decl_processing): finit_identifier_node initialized.
19450 * java-tree.def (CONDITIONAL_EXPR): New Java tree code.
19451 * java-tree.h (finit_identifier_node): Declared as extern.
19452 (struct lang_decl): New field called_constructor.
19453 (DECL_CONSTRUCTOR_CALLS): Access macro to called_constructor.
19454 (CLASS_HAS_FINIT_P): New macro.
19455 (CALL_CONSTRUCTOR_P): Leading comment changed. Macro now checks
19456 explicit constructor invocation.
19457 (CALL_EXPLICIT_CONSTRUCTOR_P, CALL_THIS_CONSTRUCTOR_P,
19458 CALL_SUPER_CONSTRUCTOR_P): New macros.
19459 (write_classfile): Added prototype.
19460 * jcf-parse.c (jcf_parse_source): Parse and remember for
19461 generation if the file was seen on the command line.
19462 (parse_source_file): Don't write the class file here.
19463 (yyparse): Loop on files rewritten. Set current_jcf.
19464 (parse_zip_file_entries): Parse class file only if it was found.
19465 * lang.c (init_parse): Don't open command line provided filename
19466 here.
19467 (lang_parse): Don't set main_jcf anymore.
19468 * parse.h (ABSTRAC_CHECK): Capitalized arguments.
19469 (JCONSTRUCTOR_CHECK): New macro.
19470 (JBSC_TYPE_P): New macro.
19471 (IN_TRY_BLOCK_P, EXCEPTIONS_P): Fixed leading comment.
19472 (COMPLETE_CHECK_OP_2): New macro.
19473 (struct parse_ctxt): New field explicit_constructor_p.
19474 (check_class_interface_creation): Fixed prototype indentation.
19475 (patch_method_invocation_stmt): Prototype reflects added argument.
19476 (patch_invoke): Likewise.
19477 (complete_method_declaration, build_super_invocation,
19478 verify_constructor_circularity,
19479 build_this_super_qualified_invocation, get_printable_method_name,
19480 patch_conditional_expr, maybe_generate_finit, fix_constructors,
19481 verify_constructor_super, create_artificial_method,
19482 start_artificial_method_body, end_artificial_method_body,
19483 generate_field_initialization_code): New function prototypes.
19484 * parse.y: Fixed leading comment
19485 (constructor_header:, constructor_body:, block_end:): Rules tagged
19486 <node>.
19487 (type_declaration:): Call maybe_generate_finit.
19488 (method_declaration:): Action for method_body: placed in new
19489 function complete_method_declaration, called here.
19490 (constructor_declaration:): Defined actions. Removed leading
19491 FIXME.
19492 (constructor_header:): New rule with action.
19493 (constructor_body:): Rule rewritten using block_begin: and
19494 block_end:. Defined actions.
19495 (constructor_declarator:, explicit_constructor_invocation:):
19496 Defined actions.
19497 (block:): Use new rules block_begin: block_end:.
19498 (block_begin:, block_end:): New rules and actions.
19499 (block_statements:): Fixed error message for explicit
19500 constructors.
19501 (method_invocation:): Call build_this_super_qualified_invocation
19502 if primary is `this' or `super' was seen.
19503 (conditional_expression:): Action defined.
19504 (extra_ctxp_pushed_p): New static global flag.
19505 (java_parser_context_save_global): Create parser context if
19506 necessary. Use extra_ctxp_pushed_p to remember it.
19507 (java_parser_context_restore_global): Pop extra parser context if
19508 one exists.
19509 (build_array_from_name): Array on primitive types are marked
19510 loaded.
19511 (register_fields): Restore new name in field initializer
19512 expression if type was altered. Non static fields initialized upon
19513 declaration marked initialized.
19514 (maybe_generate_finit): New function.
19515 (maybe_generate_clinit): Use create_artificial_method,
19516 start_artificial_method_body, end_artificial_method_body. Generate
19517 debug info for enclosed initialization statements.
19518 (method_header): Fixed leading comment. Check constructor
19519 flags. Detect constructor declarations and set DECL_CONSTRUCTOR_P
19520 accordingly.
19521 (complete_method_declaration, constructor_circularity_msg,
19522 verify_constructor_circularity): New functions.
19523 (get_printable_method_name): New function.
19524 (check_method_redefinition): Don't rename <finit> methods. Fix
19525 declared constructor names. Error message for
19526 constructors modified.
19527 (java_check_regular_methods): Local variable seen_constructor
19528 renamed saw_constructor. Skip verification on constructors. Create
19529 default constructor with create_artificial_method.
19530 (java_check_methods): Removed unnecessary empty line.
19531 (create_artificial_method, start_artificial_method_body,
19532 end_artificial_method_body): New functions.
19533 (java_layout_classes): Changed leading comment. Reverse fields
19534 list if necessary. Always layout java.lang.Object if being
19535 defined.
19536 (java_complete_expand_methods): Verify constructor circularity.
19537 (java_complete_expand_method): Call fix_constructor on
19538 constructors. Local variable no_ac_found removed. Restore
19539 bindings if method body expansion failed.
19540 (fix_constructors, verify_constructor_super,
19541 generate_field_initialization_code): New function.
19542 (java_expand_classes): Fixed leading comment. Write class file
19543 here.
19544 (resolve_expression_name): Check for illegal instance variable
19545 usage within the argument scope of an explicit constructor
19546 invocation.
19547 (resolve_qualified_expression_name): Pass extra from_super flag
19548 when invoking patch_method_invocation_stmt. New case for
19549 conditional expression when used as a primary. Check for error
19550 when acquiring super.
19551 (patch_method_invocation_stmt): Added extra argument super. New
19552 local variable is_static_flag. Set class_to_search according to
19553 the nature of the constructor invocation. Don't add `this'
19554 argument when expanding NEW_CLASS_EXPR. Check for illegal method
19555 invocation within the argument scope of explicit constructor
19556 invocation. Set is_static according to is_static_flag. Provide
19557 extra `super' argument to patch_invoke invocation.
19558 (patch_invoke): New argument from_super. Loop on arguments
19559 indentation fixed. Pass from_super to invocation_mode. New switch
19560 case INVOKE_SUPER. Fixed error message in switch default case.
19561 Don't use CALL_CONSTRUCTOR_P but rather a test on the tree node
19562 value.
19563 (invocation_mode): Return INVOKE_SUPER mode when appropriate.
19564 (lookup_method_invoke): Fixed prototypes in candidates list. Error
19565 message takes constructors into account.
19566 (find_applicable_accessible_methods_list): Fixed indentation.
19567 (qualify_ambiguous_name): Take explicit constructor invocation
19568 into account. Deal with a conditional expression as a primary to
19569 a method call.
19570 (java_complete_tree): Added local wfl_op3. New CONDITIONAL_EXPR
19571 case. Added extra argument to patch_method_invocation_stmt.
19572 Register calls made to explicit constructor `this'. Don't call
19573 save_expr in ARRAY_REF case when emitting class files. Check for
19574 illegal use of this when expanding explicit constructor invocation
19575 arguments.
19576 (complete_function_arguments): Set and reset parser context
19577 explicit_constructor_p field value when appropriate.
19578 (build_super_invocation, build_this_super_qualified_invocation):
19579 New functions.
19580 (patch_assignment): Fixed typo.
19581 (patch_unaryop): Check on final fields occurs only when a decl
19582 exits.
19583 (patch_return): Take constructors into account.
19584 (patch_conditional_expr): New function.
19585 * typeck.c (build_java_signature): Removed unnecessary empty line.
19586
19587 1998-10-28 Jeffrey A Law (law@cygnus.com)
19588
19589 * Makefile.in (jcf-dump, gcjh): Link in $(LIBS) too.
19590
19591 1998-10-28 Tom Tromey <tromey@cygnus.com>
19592
19593 * decl.c (init_decl_processing): Renamed fields.
19594 * class.c (make_class_data): Renamed bfsize, nfields, nsfields,
19595 interface_len, msize fields.
19596
19597 * class.c (make_class_data): Removed subclass_head and
19598 subclass_next fields.
19599 * decl.c (init_decl_processing): Removed subclass_head and
19600 subclass_next fields.
19601
19602 1998-10-28 Jeffrey A Law (law@cygnus.com)
19603
19604 * jcf-write.c (emit_load_or_store): Avoid implicit int arguments.
19605 * mangle.c (emit_unicode_mangled_name): Similarly.
19606
19607 1998-10-26 Nick Clifton <nickc@cygnus.com>
19608
19609 * jcf-parse.c (get_constant): Place braces around code to compute
19610 'd' when REAL_ARITHMETIC is not defined.
19611
19612 1998-10-25 H.J. Lu (hjl@gnu.org)
19613
19614 * Make-lang.in (jv-scan$(exeext)): Add stamp-objlist to
19615 dependency.
19616
19617 1998-10-23 Tom Tromey <tromey@cygnus.com>
19618
19619 * lang-specs.h: `.zip' files are input to jc1.
19620
19621 1998-10-22 Per Bothner <bothner@cygnus.com>
19622
19623 * jvspecs.c: Add (but don't enable) support for combining multiple
19624 .class and .java input filenames to a single jc1 invocation.
19625 Add support for -C flag (copile to .class files).
19626 Translate -classpath and -CLASSPATH arguments.
19627 * lang-specs.h: Don't set %2 spec.
19628
19629 1998-10-22 Tom Tromey <tromey@cygnus.com>
19630
19631 * jcf-path.c (add_entry): Don't add trailing separator if entry is
19632 a .zip file.
19633 (add_path): Don't add trailing separator to non-empty path
19634 elements.
19635
19636 * lang.c (lang_decode_option): Check for -fclasspath and
19637 -fCLASSPATH before examining other `-f' options.
19638
19639 * java-tree.h (finalize_identifier_node): Don't declare.
19640 * class.c (make_class_data): Don't push "final" field.
19641 * decl.c (init_decl_processing): Don't push "final" field.
19642 (finalize_identifier_node): Removed.
19643 (init_decl_processing): Don't set finalize_identifier_node.
19644
19645 * config-lang.in (stagestuff): Added jcf-dump and jv-scan.
19646
19647 1998-10-11 Anthony Green <green@cygnus.com>
19648
19649 * Make-lang.in (java): Depend on jcf-dump and jv-scan.
19650 (JV_SCAN_SOURCES): New macro.
19651 (JCF_DUMP_SOURCES): Likewise.
19652 (jcf-dump$(exeext)): New target.
19653 (jv-scan$(exeext)): New target.
19654
19655 1998-10-22 Tom Tromey <tromey@cygnus.com>
19656
19657 * Makefile.in (LEX): Removed.
19658 (LEXFLAGS): Likewise.
19659 (SET_BISON): New macro.
19660 (BISON): Removed.
19661 ($(PARSE_C)): Use SET_BISON. Run bison from srcdir to avoid
19662 spurious diffs in parse.c.
19663 ($(PARSE_SCAN_C)): Likewise.
19664 (PARSE_DIR): New macro.
19665 (PARSE_C): Use it.
19666 (PARSE_SCAN_C): Likewise.
19667 (PARSE_RELDIR): New macro.
19668
19669 * jcf-io.c (saw_java_source): Define here, not in jcf-parse.c.
19670
19671 * jcf-io.c (find_class): Use saw_java_source to determine when to
19672 look for `.java' file.
19673 * jcf-parse.c (saw_java_source): New global.
19674 (yyparse): Set it if `.java' file seen.
19675
19676 * Make-lang.in (JAVA_SRCS): Added jcf-path.c.
19677 (GCJH_SOURCES): Likewise.
19678 * Makefile.in (datadir): New macro.
19679 (libjava_zip): Likewise.
19680 (JAVA_OBJS): Added jcf-path.o.
19681 (../jcf-dump$(exeext)): Depend on and link with jcf-depend.o.
19682 (../gcjh$(exeext)): Likewise.
19683 (jcf-path.o): New target.
19684 * java-tree.h (fix_classpath): Removed decl.
19685 * jcf-parse.c (fix_classpath): Removed.
19686 (load_class): Don't call fix_classpath.
19687 * parse.y (read_import_dir): Don't call fix_classpath.
19688 * lex.h: Don't mention classpath.
19689 * lex.c (java_init_lex): Don't initialize classpath.
19690 * jcf-io.c (classpath): Removed global.
19691 (find_class): Use jcf_path iteration functions. Correctly search
19692 class path for .java file.
19693 (open_in_zip): New argument `is_system'.
19694 * jcf-dump.c (main): Call jcf_path_init. Recognize all new
19695 classpath-related options.
19696 * lang.c (lang_decode_option): Handle -fclasspath, -fCLASSPATH,
19697 and -I.
19698 (lang_init): Call jcf_path_init.
19699 * lang-options.h: Mention -I, -fclasspath, and -fCLASSPATH.
19700 * lang-specs.h: Handle -I. Minor cleanup to -M options.
19701 Correctly put braces around second string in each entry.
19702 * gjavah.c (main): Call jcf_path_init. Recognize all the new
19703 classpath-related options.
19704 (help): Updated for new options.
19705 * jcf.h: Declare functions from jcf-path.c. Don't mention
19706 `classpath' global.
19707 * jcf-path.c: New file.
19708
19709 * jcf-depend.c: Include jcf.h.
19710
19711 * jcf-write.c (localvar_alloc): Returns `void'.
19712 (localvar_free): Removed unused variable.
19713
19714 * lang.c (OBJECT_SUFFIX): Define if not already defined.
19715 (init_parse): Use OBJECT_SUFFIX, not ".o".
19716
19717 1998-10-21 Alexandre Petit-Bianco <apbianco@cygnus.com>
19718
19719 * class.c (emit_register_classes): Renamed from
19720 emit_register_class.
19721 * java-tree.h (emit_register_classes): Prototype renamed from
19722 emit_register_class.
19723 * jcf-parse.c (yyparse): Call emit_register_classes once before
19724 returning.
19725 * parse.y (java_expand_classes): No longer register classes.
19726
19727 1998-10-20 Alexandre Petit-Bianco <apbianco@cygnus.com>
19728
19729 * class.c (is_compiled_class): New local variable
19730 seen_in_zip. Identify classes found in currently compiled source
19731 file(s).
19732 * decl.c (complete_start_java_method): Fixed typo.
19733 * java-tree.h (CLASS_FROM_CURRENTLY_COMPILED_SOURCE_P,
19734 HAS_BEEN_ALREADY_PARSED_P, IS_A_COMMAND_LINE_FILENAME_P): New macros.
19735 (CLASS_P): Moved around.
19736 (java_parse_abort_on_error): Macro moved from jcf-parse.c
19737 * jcf-parse.c (java_parse_abort_on_error): Macro moved to
19738 java-tree.h
19739 (jcf_parse_source): Changed leading comment. Removed unnecessary
19740 fclose and CLASS_FROM_SOURCE_P marking.
19741 (parse_source_file): New local variables remember_for_generation
19742 and filename. Mark parsed file name identifier node. Removed block
19743 executed when parse_only was null. Set remember_for_generation.
19744 Use it as an argument to java_pop_parser_context.
19745 (yyparse): New local variables several_files, list, next node and
19746 current_file_list. Split ampersand separated file names into
19747 current_file_list. Iterate through the list and parse accordingly.
19748 * parse.h (java_pop_parser_context): New function prototype.
19749 * parse.y (ctxp_for_generation): New static global variable.
19750 (java_pop_parser_context): New argument generate. Link popped ctxp
19751 to ctxp_for_generation list accordingly.
19752 (java_complete_expand_methods): Fixed indentation.
19753 (java_expand_classes): New function.
19754
19755 1998-10-17 Per Bothner <bothner@cygnus.com>
19756
19757 * Makefile.in: Link with libiberty.a instead of memmove.o.
19758
19759 1998-10-16 Alexandre Petit-Bianco <apbianco@cygnus.com>
19760
19761 * lex.c (setjmp.h): No longer included.
19762 * lex.h (setjmp.h): Included.
19763 * parse.h (SET_TYPE_FOR_RESOLUTION): New macro.
19764 (duplicate_declaration_error_p): Renamed from
19765 duplicate_declaration_error.
19766 (build_array_from_name): New function prototype.
19767 * parse.y (setjmp.h): No longer included.
19768 (variable_declarator_id): Define action.
19769 (build_array_from_name): New function.
19770 (duplicate_declaration_error_p): Renamed from
19771 duplicate_declaration_error. Fixed leading comment.
19772 (register_fields): Main `for' loop reorganized. Uses
19773 SET_TYPE_FOR_RESOLUTION and build_array_from_name.
19774 (method_declarator): Uses SET_TYPE_FOR_RESOLUTION and call
19775 build_array_from_name.
19776 (resolve_class): Set CLASS_LOADED_P on newly build array dimension
19777 types.
19778 (read_import_dir): Don't try to skip `.' and `..'.
19779 (declare_local_variables): Uses SET_TYPE_FOR_RESOLUTION and
19780 build_array_from_name. Main `for' loop reorganized.
19781 (resolve_qualified_expression_name): When building access to a
19782 field, use the type where the field was found, not its own type.
19783 (maybe_access_field): Use field DECL_CONTEXT if the type where the
19784 field was found is null.
19785 (qualify_ambiguous_name): Sweep through all successive array
19786 dimensions.
19787
19788 1998-10-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
19789
19790 * java-tree.h (pop_labeled_block, lang_printable_name,
19791 maybe_add_interface, set_super_info, get_access_flags_from_decl,
19792 interface_of_p, inherits_from_p, fix_classpath,
19793 complete_start_java_method, emit_handlers, init_outgoing_cpool,
19794 make_class_data, register_class, alloc_name_constant): New
19795 function prototypes.
19796 * lang.c (lang_decode_option): Set argc argument unused. Fixed
19797 indentation. Added cast to remove warning.
19798 (lang_printable_name): Set v argument unused.
19799 (lang_print_error): Added argument to lang_printable_name call.
19800 (java_dummy_print, print_lang_decl, print_lang_type,
19801 print_lang_identifier, lang_print_xnode): All argument marked
19802 unused.
19803 * lex.c (java_unget_unicode): Removed unnecessary argument.
19804 (java_allocate_new_line): Unused local variable is gone.
19805 (java_read_char): Added parenthesis in expressions to remove
19806 warnings. Added final return statement.
19807 (java_read_unicode): Added parenthesis in expression to remove
19808 warning.
19809 (java_parse_end_comment): Fixed java_unget_unicode invocation.
19810 (java_parse_escape_sequence): Likewise.
19811 (java_lex): Unused local variables are gone. Fixed
19812 java_unget_unicode invocation.
19813 * lex.h (set_float_handler): Prototype added when JC1_LITE not
19814 defined.
19815 * parse.h (ERROR_CANT_CONVERT_TO_BOOLEAN): Fixed
19816 lang_printable_name invocation in macro.
19817 (ERROR_CANT_CONVERT_TO_NUMERIC, ERROR_CAST_NEEDED_TO_INTEGRAL):
19818 Likewise.
19819 (duplicate_declaration_error): Suppressed unused argument in
19820 prototype.
19821 (identical_subpath_p): Function declaration is gone.
19822 (patch_invoke): Suppressed unused argument in prototype.
19823 (patch_cast, build_labeled_block, check_thrown_exceptions):
19824 Likewise.
19825 * parse.y (setjmp.h): Included
19826 (toplev.h): Likewise.
19827 (field_declaration:): Suppressed unused local
19828 (label_decl:): Fixed build_labeled_block invocation.
19829 (java_pop_parser_context): Put extra parenthesis around assignment
19830 in if.
19831 (yyerror): Suppressed unused local variables.
19832 (variable_redefinition_error): Fixed lang_printable_name
19833 invocation.
19834 (create_interface): Suppressed unused local variables.
19835 (create_class): Likewise.
19836 (duplicate_declaration_error): Suppressed unused argument. Fixed
19837 lang_printable_name invocation.
19838 (register_fields): Suppressed unused local variable. Fixed
19839 duplicate_declaration_error invocation.
19840 (method_header): Suppressed unused local variable.
19841 (method_declarator, parser_check_super): Likewise.
19842 (java_complete_class): Suppressed unused local variable. Fixed
19843 fatal error message.
19844 (complete_class_report_errors): Added default: in switch.
19845 (java_check_regular_methods): Fixed lang_printable_name
19846 invocations.
19847 (check_throws_clauses): Likewise.
19848 (java_check_abstract_methods): Suppressed unused local
19849 variable. Fixed lang_printable_name invocation.
19850 (read_import_entry): Added supplemental return statement.
19851 (read_import_dir): Suppressed unused local variables.
19852 (check_pkg_class_access, declare_local_variables): Likewise.
19853 (source_start_java_method): Suppressed unused extern variable
19854 declarations
19855 (expand_start_java_method): Suppressed unused extern and local
19856 variable declarations.
19857 (java_complete_expand_methods): Likewise.
19858 (java_complete_expand_method): Suppressed unused local variables.
19859 (make_qualified_name): Likewise.
19860 (resolve_qualified_expression_name): Added default: in
19861 switch. Fixed lang_printable_name invocation.
19862 (class_instance_creation_expression): Added parenthesis around
19863 expressions.
19864 (patch_method_invocation_stmt): Fixed lang_printable_name and
19865 patch_invoke invocations.
19866 (check_for_static_method_reference): Fixed lang_printable_name
19867 invocation.
19868 (patch_invoke): Suppressed unused arguments and local variables.
19869 (lookup_method_invoke): Suppressed unused local variables.
19870 (qualify_ambiguous_name): Added default: in switch.
19871 (identical_subpath_p): Function removed.
19872 (patch_assignment): Suppressed unused local variables. Suppressed
19873 unnecessary if statement. Fixed lang_printable_name invocations.
19874 (try_builtin_assignconv): Fixed lang_printable_name invocations.
19875 (valid_ref_assignconv_cast_p): Parenthesis around
19876 expression. Suppressed unused local variables.
19877 (build_binop): Suppressed unused local variables. fixed
19878 lang_printable_name invocations.
19879 (string_constant_concatenation): Suppressed unused local
19880 variables.
19881 (patch_unaryop): Fixed lang_printable_name invocation.
19882 (patch_cast): Suppressed unnecessary argument. Fixed
19883 lang_printable_name invocation.
19884 (patch_array_ref): Fixed lang_printable_name invocation.
19885 (patch_newarray, patch_return, patch_if_else_statement): Likewise.
19886 (build_labeled_block): Suppressed unused argument.
19887 (generate_labeled_block): Fixed build_labeled_block invocation.
19888 (build_loop_body): Suppressed unused local variables.
19889 (patch_loop_statement): Likewise.
19890 (patch_exit): Fixed lang_printable_name invocation.
19891 (patch_switch_statement): Likewise.
19892 (case_identity): First argument marked unused.
19893 (patch_try_statement): Fixed lang_printable_name invocations.
19894 (patch_synchronized_statement, patch_throw_statement): Likewise.
19895 (check_thrown_exceptions): Fixed check_thrown_exceptions and
19896 lang_printable_name invocations.
19897 (check_thrown_exceptions_do): Suppressed unused argument.
19898
19899 1998-10-14 Tom Tromey <tromey@cygnus.com>
19900
19901 * jcf-write.c (write_classfile): Add output class file as target.
19902 * lang-options.h: Added -MD, -MMD, -M, and -MM.
19903 * jcf.h: Added declarations for dependency-tracking functions.
19904 * lang-specs.h: Handle -M, -MM, MD, and -MMD.
19905 * lang.c (lang_decode_option): Recognize -MD and -MMD.
19906 (finish_parse): Call jcf_dependency_write.
19907 (dependency_tracking): New global.
19908 (DEPEND_SET_FILE): New define.
19909 (DEPEND_ENABLE): New define.
19910 (init_parse): Enable dependency tracking if required.
19911 Include "flags.h".
19912 * Makefile.in (JAVA_OBJS): Added jcf-depend.o.
19913 (../jcf-dump$(exeext)): Depend on and link with jcf-depend.o.
19914 (../gcjh$(exeext)): Likewise.
19915 (jcf-depend.o): New target.
19916 * Make-lang.in (JAVA_SRCS): Added jcf-depend.c.
19917 (GCJH_SOURCES): Likewise.
19918 * jcf-io.c (open_class): Call jcf_dependency_add_file. Added
19919 dep_name argument.
19920 (find_classfile): Added dep_name argument.
19921 (find_class): Compute name of dependency.
19922 (open_in_zip): Call jcf_dependency_add_file.
19923 * gjavah.c (output_file): No longer global.
19924 (usage): Don't mention "gjavah".
19925 (help): Likewise.
19926 (java_no_argument): Likewise.
19927 (version): Likewise.
19928 (main): Recognize and handle -M family of options.
19929 (print_mangled_classname): Return is void.
19930 (process_file): Handle case where output is suppressed.
19931 (HANDLE_END_FIELD): Likewise.
19932 (HANDLE_METHOD): Likewise.
19933 * jcf-depend.c: New file.
19934
19935 1998-10-13 Jeffrey A Law (law@cygnus.com)
19936
19937 * java-tree.def: Add missing newline at EOF.
19938
19939 1998-10-13 Tom Tromey <tromey@cygnus.com>
19940
19941 * jcf-dump.c (process_class): Use FATAL_EXIT_CODE, not -1.
19942 (main): Likewise. Exit with SUCCESS_EXIT_CODE at end of
19943 function.
19944 Include <config.h> and "system.h".
19945 (disassemble_method): Undefine RET to avoid clash with
19946 config/i386/i386.h.
19947
19948 1998-10-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
19949
19950 * decl.c (runtime_exception_type_node, error_exception_type_node):
19951 New global variables.
19952 (init_decl_processing): Initialized.
19953 * expr.c (java_lang_expand_expr): Set caught exception type to
19954 null if catch handler argument doesn't exit.
19955 * java-tree.def (SYNCHRONIZED_EXPR, THROW_EXPR): New Java specific
19956 tree codes.
19957 * java-tree.h (runtime_exception_type_node,
19958 error_exception_type_node): Global variables declared.
19959 (DECL_FUNCTION_THROWS): New macro.
19960 (DECL_FUNCTION_BODY): Modified comment.
19961 (DECL_SPECIFIC_COUNT): Likewise.
19962 (struct lang_decl): New field throws_list.
19963 (IS_UNCHECKED_EXPRESSION_P): New macro.
19964 * lex.c (java_lex): Generate location information for THROW_TK.
19965 * parse.h (PUSH_EXCEPTIONS, POP_EXCEPTIONS, IN_TRY_BLOCK_P,
19966 EXCEPTIONS_P): New macros.
19967 (enum jdep_code): New value JDEP_EXCEPTION.
19968 (BUILD_MONITOR_ENTER, BUILD_MONITOR_EXIT,
19969 BUILD_ASSIGN_EXCEPTION_INFO, BUILD_THROW, SET_WFL_OPERATOR,
19970 PATCH_METHOD_RETURN_ERROR): New macros.
19971 (patch_method_invocation_stmt): Added new argument to prototype.
19972 (patch_synchronized_statement, patch_throw_statement,
19973 check_thrown_exceptions, check_thrown_exceptions_do,
19974 purge_unchecked_exceptions, check_throws_clauses): New function
19975 prototypes.
19976 * parse.y Fixed typo in keyword section.
19977 (throw:): Rule tagged <node>.
19978 (THROW_TK): Keyword tagged <operator>.
19979 (method_header:): Last argument to call to method_header passed
19980 from throws: rule.
19981 (throws:, class_type_list:, throw_statement:,
19982 synchronized_statement:, synchronized:): Defined actions.
19983 (method_header): New local variable current. Register exceptions
19984 from throws clause.
19985 (java_complete_tree): Complete and verify exceptions from throws
19986 clause.
19987 (complete_class_report_errors): Error message on exceptions not
19988 found
19989 (java_check_regular_methods): Fixed typo. Shortcut on private
19990 overriding methods. Changed error message on method
19991 redefinition. Check for throws clause compatibility.
19992 (check_throws_clauses): New function.
19993 (java_check_abstract_methods): Use DECL_NAME for wfl or current
19994 method. Changed error message on method redefinition.
19995 (currently_caught_type_list): New static variable.
19996 (java_complete_expand_methods): Purge unchecked exceptions from
19997 throws clause list. Call PUSH_EXCEPTIONS before walk and
19998 POP_EXCEPTIONS after.
19999 (resolve_qualified_expression_name): Pass new argument as NULL to
20000 patch_method_invocation_stmt.
20001 (patch_method_invocation_stmt): New argument ref_decl. Invoke
20002 PATCH_METHOD_RETURN_ERROR when returning with error. Reverse
20003 argument list when appropriate. Use new argument if non null to
20004 store selected method decl.
20005 (patch_invoke): Convert if necessary args of builtin types before
20006 forming CALL_EXPR. Argument list no longer reversed here.
20007 (invocation_mode): Treat final methods as static methods.
20008 (java_complete_tree): New cases for THROW_EXPR: and
20009 SYNCHRONIZED_EXPR:. Check thrown exceptions when completing
20010 function call.
20011 (complete_function_arguments): No more RECORD_TYPE
20012 conversion. Function parameter nodes no longer saved.
20013 (valid_ref_assignconv_cast_p): Avoid handling null type.
20014 (patch_binop): Fixed null constant reference handling.
20015 (build_try_statement): Use BUILD_ASSIGN_EXCEPTION_INFO and
20016 BUILD_THROW macros.
20017 (patch_try_statement): Fixed comments. Record caught types in
20018 list, push the list, expand try block and pop the list.
20019 (patch_synchronized_statement, patch_throw_statement,
20020 check_thrown_exceptions, check_thrown_exceptions_do,
20021 purge_unchecked_exceptions): New functions.
20022 * typeck.c (lookup_argument_method): Allow WFL in place of method
20023 DECL_NAME during method definition check
20024
20025 1998-10-09 Tom Tromey <tromey@cygnus.com>
20026
20027 * gjavah.c (decode_signature_piece): New function.
20028 (print_c_decl): Use it. Added `name_override' argument.
20029 (print_method_info): Use name_override argument to print_c_decl.
20030 (seen_fields): Removed.
20031 (print_field_info): Don't update seen_fields.
20032 (struct method_name): New structure.
20033 (method_name_list): New global.
20034 (print_method_info): Add new method to list of methods.
20035 (name_is_method_p): New function.
20036 (print_field_info): If field name has same name as method, then
20037 change field name.
20038 (process_file): Parse methods before fields.
20039 (field_pass): New global.
20040 (HANDLE_END_FIELD): Take field_pass into account.
20041
20042 1998-10-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
20043
20044 * Makefile.in (keyword.h): Add -L KR-C -F ', 0' flags to gperf.
20045 (keyword.h): Regenerate using gperf 2.7.1 (19981006 egcs).
20046
20047 1998-10-03 Anthony Green <green@cygnus.com>
20048
20049 * jvspec.c: Fix bug in jvgenmain_spec patch.
20050
20051 1998-10-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
20052
20053 * Makefile.in (lang.o:): Install dependency on java-tree.def.
20054 * decl.c (soft_exceptioninfo_call_node): New global variable.
20055 (init_decl_processing): Fixed indentation. soft_badarrayindex_node
20056 takes extra integer argument. soft_exceptioninfo_call_node
20057 initialized.
20058 * except.c (java_set_exception_lang_code): New function
20059 (method_init_exceptions): Called here.
20060 (prepare_eh_table_type): New function.
20061 (expand_end_java_handler): Called here.
20062 * expr.c (build_java_throw_out_of_bounds_exception): Now features
20063 one argument. Modified generation of call to
20064 soft_badarrayindex_node to use new argument.
20065 (build_java_arrayaccess): Pass faulty index value to
20066 build_java_throw_out_of_bounds_exception.
20067 (generate_name): New function.
20068 (java_lang_expand_expr): New local variables node, current,
20069 has_finally_p. Expand TRY_EXPR node.
20070 (process_jvm_instruction): Replace top of the stack with thrown
20071 object reference when entering exception handler.
20072 * java-tree.def (TRY_EXPR, CATCH_EXPR, FINALLY_EXPR): New Java
20073 specific tree codes.
20074 * java-tree.h (soft_exceptioninfo_call_node): Declaration of new
20075 global.
20076 (DECL_SPECIFIC_COUNT): New macro.
20077 (prepare_eh_table_type, java_set_exception_lang_code,
20078 generate_name): New function declarations.
20079 (match_java_method): Declaration deleted.
20080 (FINALLY_EXPR_LABEL, FINALLY_EXPR_BLOCK, CATCH_EXPR_GET_EXPR): New
20081 macros.
20082 * lex.c (TRY_TK, CATCH_TK): Generate location information.
20083 * parse.h (redefinition_error, refine_accessible_methods_list,
20084 can_cast_to_p): Function declaration removed.
20085 (classitf_redefinition_error, variable_redefinition_error,
20086 parse_jdk1_1_error, find_applicable_accessible_methods_list,
20087 find_most_specific_methods_list, argument_types_convertible,
20088 enter_a_block, valid_builtin_assignconv_identity_widening_p,
20089 valid_cast_to_p, valid_method_invocation_conversion_p,
20090 try_reference_assignconv, add_stmt_to_compound,
20091 build_jump_to_finally, build_tree_list, patch_try_statement,
20092 java_get_catch_block): New function declarations.
20093 * parse.y (string_buffer_type): Global variable deleted.
20094 (group_of_labels, catches, catch_clause, catch_clause_parameter,
20095 finally): Rules tagged <node>.
20096 (TRY_TK, CATCH_TK): Token tagged <operator>.
20097 (class_body_declaration:, class_member_declaration:,
20098 formal_parameter:, explicit_constructor_invocation:,
20099 interface_member_declaration:, constant_declaration:,
20100 primary_no_new_array:, class_instance_creation_expression:,
20101 array_creation_expression:): Issue error on unsuported JDK1.1
20102 features.
20103 (try_statement:, catches:, finally:): Define actions.
20104 (catch_clause_parameter): New rule.
20105 (catch_clause:): Use new rule catch_clause_parameter.
20106 (parse_jdk1_1_error): New function.
20107 (redefinition_error): Renamed classitf_redefinition_error.
20108 (variable_redefinition_error): New function.
20109 (check_class_interface_creation): Call
20110 classitf_redefinition_error.
20111 (java_complete_tree): Added error message on JDEP_TYPE: case.
20112 (complete_class_report_errors): Fixed indentation.
20113 (declare_local_variables): Call variable_redefinition_error.
20114 (source_end_java_method): Call java_set_exception_lang_code and
20115 emit_handlers where appropriate.
20116 (java_method_add_stmt): Call add_stmt_to_block.
20117 (add_stmt_to_block): New function.
20118 (lookup_method_invoke): Fixed outside comment. new local variable
20119 candicates. Call find_applicable_accessible_methods_list and
20120 find_most_specific_methods_list when searching for a
20121 method. Modified error report to list possible candidates when
20122 applicable.
20123 (find_applicable_accessible_methods_list,
20124 find_most_specific_methods_list, argument_types_convertible): New
20125 function.
20126 (refine_accessible_methods_list): Function deleted.
20127 (java_complete_tree): Handle TRY_EXPR. ARRAY_REF handling: save
20128 expr (if applicable) before calling patch_array_ref.
20129 (build_expr_block): Fixed BLOCK_EXPR_BODY assignment.
20130 (enter_block): Fixed comment.
20131 (enter_a_block): New function.
20132 (patch_assignment): Reorganized. Call try_reference_assignconv for
20133 references. Call valid_cast_to_p instead of can_cast_to_p.
20134 (try_reference_assignconv,
20135 valid_builtin_assignconv_identity_widening_p): New functions.
20136 (valid_ref_assignconv_cast_p): Fixed inverted test on CLASS_FINAL.
20137 (valid_cast_to_p, valid_method_invocation_conversion_p): New
20138 functions.
20139 (build_string_concatenation): Don't resolve StringBuffer.
20140 (patch_cast): Fixed inverted arguments.
20141 (patch_array_ref): Code to save array expr deleted. Call
20142 valid_cast_to_p instead of can_cast_to_p.
20143 (generate_labeled_block): Call generate_name.
20144 (build_jump_to_finally, build_try_statement, java_get_catch_block,
20145 patch_try_statement): New functions.
20146 * typeck.c (match_java_method): Function deleted.
20147
20148 1998-10-02 Anthony Green <green@cygnus.com>
20149
20150 * jvspec.c: jvgenmain_spec uses different temporary file names.
20151
20152 1998-10-02 Anthony Green <green@cygnus.com>
20153
20154 * jvspec.c (lang_specific_driver): Fail if user specifies
20155 --main= when not linking.
20156
20157 1998-09-28 Tom Tromey <tromey@cygnus.com>
20158
20159 * class.c (make_class_data): Push value for `thread' field.
20160 * decl.c (init_decl_processing): Added `thread' field to class.
20161
20162 * class.c (add_field): Always make static fields externally
20163 visible.
20164
20165 1998-09-26 Anthony Green <green@cygnus.com>
20166
20167 * expr.c (build_java_athrow,
20168 build_java_throw_out_of_bounds_exception, expand_invoke,
20169 build_newarray, expand_java_multianewarray, build_java_monitor):
20170 Update comments to reflect _Jv_* function names.
20171
20172 1998-09-25 Per Bothner <bothner@cygnus.com>
20173
20174 * decl.c (complete_start_java_method): DECL_RESULT is always promoted.
20175 * decl.c (start_java_method): Handle PROMOTE_PROTOTYPES target macro.
20176 * parse.y (expand_start_java_method): Likewise.
20177
20178 1998-09-24 Per Bothner <bothner@cygnus.com>
20179
20180 * expr.c (pop_arguments): Handle PROMOTE_PROTOTYPES target macro.
20181
20182 * class.c (push_class): IDENTIFIER_SIGNATURE_TYPE is now POINTER_TYPE.
20183 (add_field): No longer need to convert from RECORD_TYPE to pointer,
20184 * expr.c: Remove no-longer-needed calls to promote_type.
20185 * decl.c (give_name_to_locals): Liekwise.
20186 * jcf-parse.c (get_class_constant): Compensate for new signatures.
20187 * parse.y: Add/remove promote_type calls as appropriate.
20188 * typeck.c (parse_signature_type): Returns POINTER_TYPE for objects.
20189 (parse_signature_string): Likewise.
20190 (build_java_array_type): Fix for now signature convenions.
20191
20192 * lex.c (java_lex): Fix (from Alex) for JC1_LITE problem.
20193
20194 1998-09-23 Tom Tromey <tromey@cygnus.com>
20195
20196 * class.c (init_class_processing): libjava function renamed to
20197 _Jv_RegisterClass.
20198
20199 1998-09-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
20200
20201 * expr.c (java_lang_expand_expr): New case for SWITCH_EXPR.
20202 * java-tree.def: Fixed DEFTREECODE third argument.
20203 (UNARY_PLUS_EXPR, NEW_ARRAY_EXPR, NEW_CLASS_EXPR, THIS_EXPR,
20204 CASE_EXPR, DEFAULT_EXPR): New tree codes for Java.
20205 * java-tree.h: (IS_CRAFTED_STRING_BUFFER_P): New macro.
20206 (JAVA_UNARY_PLUS_EXPR, JAVA_NEW_ARRAY_EXPR, JAVA_NEW_CLASS_EXPR,
20207 JAVA_THIS_EXPR): Now replaced by tree code definitions.
20208 (CALL_CONSTRUCTOR_P): Now uses NEW_CLASS_EXPR.
20209 * lang.c (java_tree_code_type, java_tree_code_length,
20210 java_tree_code_name): New arrays.
20211 (lang_init): Append Java tree node definitions to Gcc ones.
20212 * lex.c (expression_obstack): Declared as extern when JC1_LITE
20213 defined.
20214 (java_init_lex): Initialize wfl_append, wfl_string_buffer,
20215 wfl_to_string.
20216 (java_lex): Allow declaration of empty string constants. Retain
20217 location information on CASE_TK and DEFAULT_TK.
20218 * parse.h (JFLOAT_TYPE_P, JINTEGRAL_TYPE_P, JNUMERIC_TYPE_P,
20219 JPRIMITIVE_TYPE_P, JSTRING_TYPE_P, JSTRING_P, JREFERENCE_TYPE_P):
20220 Modified to be more robust.
20221 (BUILD_APPEND, BUILD_STRING_BUFFER): New macros.
20222 (build_new_invocation, try_builtin_assignconv,
20223 patch_switch_statement, string_constant_concatenation,
20224 build_string_concatenation, patch_string_cst, patch_string,
20225 java_expand_switch): New function declarations.
20226 * parse.y: Rules related to switch and EH tagged <node>.
20227 (label_id): Set to NULL_TREE
20228 (wfl_string_buffer, wfl_append, wfl_to_string): New static global
20229 tree nodes.
20230 (this_or_super:): Fixed indentation.
20231 (statement:, statement_nsi:, statement_without_trailing_substatement:,
20232 statement_expression:): Removed call to RULE on all sub-rules.
20233 (switch_expression:, switch_labels:): New rules.
20234 (switch_statement:, switch_block:, switch_block_statement_groups:,
20235 switch_block_statement_group:, switch_labels:, switch_label:):
20236 Defined actions.
20237 (throw_statement:, synchronized_statement:, try_statement:):
20238 Defined temporary actions.
20239 (class_instance_creation_expression:): Call
20240 build_new_invocation. Fixed indentation.
20241 (field_access): Fixed indentation.
20242 (method_invocation): Likewise.
20243 (make_qualified_primary): Use THIS_EXPR.
20244 (resolve_qualified_expression_name): Use NEW_CLASS_EXPR. When
20245 resolving from SUPER, set *type_found.
20246 (qualify_ambiguous_name): Use NEW_CLASS_EXPR.
20247 (java_complete_tree): Removed unused local variable `location'. Case
20248 for SWITCH_EXPR, sharing code with LOOP_EXPR. Use NEW_ARRAY_EXPR,
20249 NEW_CLASS_EXPR, UNARY_PLUS_EXPR and THIS_EXPR. New string handling
20250 on MODIFY_EXPR: and all binary operator tree code cases. Removed
20251 STRING_CST: case. default: checks for patchable strings.
20252 (complete_function_arguments): Transform string constant or
20253 crafted StringBuffer if necessary.
20254 (build_method_invocation): Fixed comments.
20255 (build_new_invocation): New function.
20256 (patch_assignment): Call try_builtin_assignconv to figure a valid
20257 assignment conversion between builtin types.
20258 (try_builtin_assignconv): New function.
20259 (build_binop): Use URSHIFT_EXPR directly to call build.
20260 (operator_string): Use UNARY_PLUS_EXPR.
20261 (patch_binop): Use UNARY_PLUS_EXPR. Handle string concatenation
20262 operator.
20263 (do_merge_string_cste, merge_string_cste,
20264 string_constant_concatenation, build_string_concatenation,
20265 patch_string, patch_string_cst): New function.
20266 (build_unary_op): Use UNARY_PLUS_EXPR and CONVERT_EXPR.
20267 (patch_unaryop): Likewise. New test of valid ++/-- operands.
20268 (build_newarray_node): Use NEW_ARRAY_EXPR.
20269 (build_this): Use THIS_EXPR.
20270 (build_return): Enable debug information on return statement.
20271 (build_if_else_statement): Likewise.
20272 (complete_labeled_statement): Fixed related comment.
20273 (build_loop_body): Fixed comment.
20274 (build_bc_statement): Enable debug information on break/continue
20275 statements.
20276 (patch_bc_statement): Fixed typos. Handle SWITCH statement
20277 context.
20278 (patch_switch_statement, case_identity, java_expand_switch): New
20279 functions.
20280
20281 1998-09-21 Per Bothner <bothner@cygnus.com>
20282
20283 * buffer.h (BUFFER_INIT): New macro.
20284 * jcf-write.c (struct jcf_partial): New type. Put global stuff here.
20285 Pass (struct jcf_partial *state) to most functions.
20286 (jcf_block, jcf_relocation): New types.
20287 Support labels, branches, conditionals, loops.
20288
20289 1998-09-21 Tom Tromey <tromey@cygnus.com>
20290
20291 * decl.c (INT_TYPE_SIZE): Define as BITS_PER_WORD if not defined.
20292
20293 1998-09-21 Per Bothner <bothner@cygnus.com>
20294
20295 * decl.c (integer_type_node): Make it have INT_TYPE_SIZE.
20296 * verify.c (verify_jvm_instructions): Use int_type_not (32 bits),
20297 not integer_type_node (INT_TYPE_SIZ bits).
20298
20299 * parse.y (patch_if_else_statement): Accept promoted_boolean_type_node.
20300
20301 * jcf-reader.c (get_attribute): New HANDLE_EXCEPTION_TABLE hook.
20302 * jcf-dump.c (print_exception_table): New function.
20303 (disassemble_method): Better handling of wide instructions.
20304 Make more robust for bad input.
20305
20306 1998-09-30 Jeffrey A Law (law@cygnus.com)
20307
20308 * jcf-write.c (OP2, OP4): Use "_i", not "_I" to avoid problems on
20309 FreeBSD.
20310
20311 1998-09-17 Jeffrey A Law (law@cygnus.com)
20312
20313 * Makefile.in (jcf-dump, jvgenmain): Link in memmove.o too.
20314
20315 1998-09-17 Tom Tromey <tromey@cygnus.com>
20316
20317 * Makefile.in ($(PARSE_H)): Removed target.
20318
20319 1998-09-17 Jeffrey A Law (law@cygnus.com)
20320
20321 * Makefile.in (JAVA_OBJS): Add memmove.o
20322 (memmove.o): New target & rules.
20323
20324 1998-09-15 Tom Tromey <tromey@cygnus.com>
20325
20326 * expr.c (expand_invoke): Don't generate a call to the class init
20327 code.
20328
20329 1998-09-14 Jeffrey A Law (law@cygnus.com)
20330
20331 * Makefile.in: Add many missing dependencies.
20332 * buffer.c, class.c, constants.c, decl.c: Use system.h and toplev.h
20333 as appropriate.
20334 * except.c, expr.c, jcf-io.c jcf-parse.c, jcf-write.c: Likewise.
20335 * jvgenmain.c lang.c mangle.c typeck.c verify.c: Likewise.
20336
20337 1998-09-11 Per Bothner <bothner@cygnus.com>
20338
20339 * decl.c (complete_start_java_method): If method is static (and
20340 not private) call _Jv_InitClass.
20341 * expr.c (expand_invoke): Don't call build_class_init.
20342
20343 * jvspec.c (jvgenmain_spec): Fix spec for generated .o file.
20344
20345 1998-09-10 Jeffrey A Law (law@cygnus.com)
20346
20347 * Make-lang.in (GCJ): Define before using.
20348
20349 1998-09-09 Jeffrey A Law (law@cygnus.com)
20350
20351 * gjavah.c (java_no_argument): Renamed from no_argument to avoid
20352 losing due to namespace pollution in GNU getopt.h
20353
20354 1998-09-09 Tom Tromey <tromey@cygnus.com>
20355
20356 * Make-lang.in (java.all.build): Don't mention jvgenmain or gcjh.
20357 (java.all.cross): Likewise.
20358 (java.rest.encap): Likewise.
20359
20360 1998-09-08 Jeffrey A Law (law@cygnus.com)
20361
20362 * gjavah.c (print_class_decls): Fix thinko in arglist
20363 * jcv-io.c (find_classfile): Similarly.
20364
20365 1998-09-07 Jeffrey A Law (law@cygnus.com)
20366
20367 * Makefile.in (INCLUDES): Update for recent toplevel gcc changes.
20368
20369 1998-09-05 Tom Tromey <tromey@cygnus.com>
20370
20371 * Make-lang.in (java.maintainer-clean): Don't remove parse.h.
20372 (java.mostlyclean): Remove parse.c and parse-scan.c, not parse.h.
20373 * Makefile.in (PARSE_C): New macro.
20374 (PARSE_H): Likewise.
20375 (PARSE_SCAN_C): Likewise.
20376 ($(PARSE_C)): Target renamed from parse.c.
20377 ($(PARSE_SCAN_C)): Target renamed from parse-scan.c.
20378 (clean): Remove parse-scan.c as well.
20379 (parse.o): Depend on $(PARSE_C).
20380
20381 1998-09-05 Anthony Green <green@cygnus.com>
20382
20383 * README, license.terms: Removed.
20384
20385 * Make-lang.in, Makefile.in, class.c, config-lang.in, constants.c,
20386 decl.c, except.c, expr.c, gjavah.c, java-except.h, java-tree.h,
20387 javaop.def, javaop.h, jcf-dump.c, jcf-io.c, jcf-parse.c,
20388 jcf-reader.c, jcf-write.c, jcf.h, jvgenmain.c, jvspec.c,
20389 keyword.gperf, keyword.h, lang-options.h, lang-specs.h, lang.c,
20390 lex.c, lex.h, mangle.c, parse-scan.y, parse.h, parse.y, typeck.c,
20391 verify.c, zextract.c, zipfile.h: Fixed copyright assignment,
20392 and Java trademark attribution.
20393
20394 1998-09-04 Tom Tromey <tromey@cygnus.com>
20395
20396 * Makefile.in: Use gcjh, not gjavah.
20397 * config-lang.in (stagestuff): Use gcjh, not gjavah.
20398 * Make-lang.in: Changed gjavah to gcjh everywhere.
20399
20400 1998-09-03 Per Bothner <bothner@cygnus.com>
20401
20402 * gjavah.c: Support new -prepend -add -append flags.
20403 (print_method_info): Method is not virtual if class is final.
20404
20405 1998-09-03 Alexandre Petit-Bianco <apbianco@cygnus.com>
20406
20407 * jv-scan.c: Fixed copyright assignment.
20408 * keyword.gperf: Likewise.
20409 * keyword.h: Likewise.
20410 * lex.c: Fixed copyright assignment.
20411 (java_lex): Push unicode back when parsing '<'.
20412 * lex.h: Fixed copyright assignment.
20413 * parse-scan.y: Likewise.
20414 * parse.h: Fixed copyright assignment.
20415 (build_debugable_stmt, complete_for_loop): New function prototypes.
20416 * parse.y: Fixed copyright assignment.
20417 (for_statement:): Call complete_for_loop. Set EXIT_EXPR to be
20418 size_zero_node when completing a loop with no exit condition.
20419 (for_statement_nsi:): Define action.
20420 (for_init:, for_update:): Return size_zero_node when empty.
20421 (declare_local_variables): Call build_debugable_stmt.
20422 (build_debugable_stmt): New function.
20423 (build_loop_body): Build debugable statement around loop
20424 condition part.
20425 (complete_loop_body): Take into account the debugable statement
20426 around the EXIT_EXPR.
20427 (complete_loop_body): New function.
20428 (patch_exit_expr): Fixed condition inversion.
20429
20430 1998-09-02 Tom Tromey <tromey@cygnus.com>
20431
20432 * Make-lang.in (jvspec.o): Use GCC_THREAD_FILE to compute correct
20433 name of thread define.
20434 * jvspec.c (THREAD_NAME): New macro.
20435 (GCLIB): Likewise.
20436 (THREADLIB): Likewise.
20437 (lang_specific_driver): Recognize attempt to link with thread
20438 library or gc library. Recognize -ljava on command line so it
20439 isn't linked against more than once.
20440
20441 1998-09-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
20442
20443 * parse-scan.y (report_main_declaration): Name of the class
20444 containing `main' can be a qualified name.
20445
20446 1998-08-31 Tom Tromey <tromey@cygnus.com>
20447
20448 * config-lang.in: Changed gjavac to gjc everywhere.
20449 * Make-lang.in: Changed gjavac to gjc everywhere.
20450
20451 1998-08-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
20452
20453 * Make-lang.in (JAVA_TARGET_INDEPENDENT_BIN_TOOLS): New variable.
20454 (java.install-common:): Loop over JAVA_TARGET_INDEPENDENT_BIN_TOOLS
20455 and install the files.
20456 * Makefile.in (JAVA_OBJS_LITE): New variable.
20457 (compiler:): Now include jv-scan as a dependency.
20458 (../jv-scan$(exeext), parse-scan.c): New targets.
20459 (../jcf-dump$(exeext)): Was jcf-dump$(exeext) before.
20460 * config-lang.in (compilers): Removed gcj, gjavah from the list.
20461 * jcf-parse.c (parse_source_file): Call java_layout_classes and
20462 check for errors even if parse_only.
20463 * lex.c (java_init_lex): Reorganized and skip parts if JC1_LITE is
20464 defined.
20465 (yylex): New function. Uses java_lex body.
20466 (java_lex): Removed commented out statement. Remove local variable
20467 literal. Use SET_LVAL_NODE_TYPE and SET_LVAL_NODE where
20468 appropriate. Use macros FLOAT_TYPE_NODE, DOUBLE_TYPE_NODE,
20469 DCONST0, SET_FLOAT_HANDLER, SET_REAL_VALUE_ATOF,
20470 SET_LVAL_NODE_TYPE and GET_TYPE_PRECISION. Don't create STRING_CST
20471 if JC1_LITE is defined. Use BUILD_ID_WFL to build identifiers. Use
20472 SET_MODIFIER_CTX, SET_LVAL_NODE, BUILD_ID_WFL and GET_IDENTIFIER
20473 where appropriate.
20474 (java_lex_error): Empty if JC1_LITE is defined.
20475 (java_get_line_col): Return 0 if JC1_LITE is defined.
20476 * lex.h (JAVA_FLOAT_RANGE_ERROR, JAVA_INTEGRAL_RANGE_ERROR,
20477 SET_MODIFIER_CTX): Moved into the section containing the macros
20478 conditionally defined by JC1_LITE.
20479 (BUILD_OPERATOR,BUILD_OPERATOR2): Just return the TOKEN
20480 argument if JC1_LITE is defined.
20481 (HOST_BITS_PER_WIDE_INT, HOST_WIDE_INT, REAL_VALUE_ATOF,
20482 REAL_VALUE_ISINF, REAL_VALUE_ISNAN): Preset to values if JC1_LITE
20483 is defined.
20484 (DCONST0, SET_FLOAT_HANDLER, GET_IDENTIFIER, SET_REAL_VALUE_ATOF,
20485 FLOAT_TYPE, DOUBLE_TYPE, SET_MODIFIER_CTX, GET_TYPE_PRECISION,
20486 SET_LVAL_NODE, SET_LVAL_NODE_TYPE, BUILD_ID_WFL): New macros, set
20487 to different values according to JC1_LITE.
20488 * parse.h (int_fits_type_p, stabilize_reference): Prototype not
20489 declared if JC1_LITE set.
20490 (jdep_code, typedef struct _jdep, typedef struct _jdeplist): Not
20491 defined if JC1_LITE not set.
20492 (struct parser_ctx): Reorganized and skip the jc1 front end part
20493 if JC1_LITE set.
20494 (java_layout_classes): New function definition.
20495 (java_push_parser_context, java_init_lex, yyparse, yylex,
20496 yyerror): Prototype always declared. All other static function
20497 prototypes declared only if JC1_LITE is not set.
20498 * parse.y (yyparse, yylex, yyerror): No longer declared here. Now
20499 declared in parse.h.
20500 (java_layout_classes): New function.
20501 (java_complete_expand_methods): No longer layout the class here.
20502 * parse-scan.y: New file.
20503 * jv-scan.c: New file.
20504
20505 1998-08-25 Tom Tromey <tromey@cygnus.com>
20506
20507 * gjavah.c (main): Handle -friend option.
20508 (friend_specs): New global.
20509 (generate_access): Handle friend_specs.
20510 (process_file): Likewise.
20511 (MAX_FRIENDS): New macro.
20512 (friend_count): New global.
20513 (print_cxx_classname): Added `prefix' argument. Ignore arrays.
20514 Changed all callers.
20515
20516 1998-08-24 Per Bothner <bothner@cygnus.com>
20517
20518 * jcf-dump.c (process_class): Move JCF_FINISH use to main,
20519 (main): Handle processing all the entries of a named .zip archive.
20520 * jcf-io.c (jcf_trim_old_input): New function.
20521 * jcf.h (GET_u2_le,GET_u4_le,JCF_readu2_le,JCF_readu4_le): New macros.
20522
20523 1998-08-24 Per Bothner <bothner@cygnus.com>
20524
20525 * lang.c (flag_assume_compiled): Make default be on.
20526
20527 1998-08-21 Per Bothner <bothner@cygnus.com>
20528
20529 * jcf-dump.c: Add bunches of flags to control output more.
20530 (process_class): New function; support printing more than one class.
20531 (main): Support new --print-main and --javap flags.
20532 * jcf-reader.c (IGNORE_ATTRIBUTE): New hook.
20533 * jcf.h (CPOOL_INDEX_IN_RANGE): New macro.
20534
20535 1998-08-20 Per Bothner <bothner@cygnus.com>
20536
20537 Change mangling of dispatch table to match C++ vtable (w/thunks).
20538 * class.c (build_dtable_decl), java-tree.h: New function.
20539 (make_class_data): Call it.
20540 * decl.c (init_decl_processing): Likewise.
20541
20542 1998-08-19 Warren Levy <warrenl@cygnus.com>
20543
20544 * decl.c (init_decl_processing): Use _Jv_NewObjectArray, not
20545 soft_anewarray; adjust args passed.
20546 * expr.c (build_anewarray): Adjust args for soft_anewarray_node to
20547 match _Jv_NewObjectArray.
20548
20549 1998-08-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
20550
20551 * decl.c (push_labeled_block, pop_labeled_block): New functions.
20552 * expr.c (loopup_label): Call create_label_decl.
20553 (create_label_decl): New function.
20554 (java_lang_expand_expr): Call expand_start_bindings with argument
20555 set to zero.
20556 * java-tree.h Added space after PROTO in function declarations
20557 when necessary.
20558 (IS_FOR_LOOP_P, IS_BREAK_STMT_P): New macros.
20559 (create_label_decl, push_labeled_block): New function
20560 declarations.
20561 * lex.c (label_id): Initialize.
20562 (SUPER_TK, THIS_TK, RETURN_TK): Merged common actions in final
20563 switch.
20564 * parse.h Added space after PROTO in function declarations when
20565 necessary.
20566 (LOOP_EXPR_BODY_MAIN_BLOCK, LOOP_EXPR_BODY_UPDATE_BLOCK,
20567 LOOP_EXPR_BODY_CONDITION_EXPR, LOOP_EXPR_BODY_LABELED_BODY,
20568 LOOP_EXPR_BODY_BODY_EXPR, LOOP_HAS_LABEL_P, LOOP_HAS_LABEL_SKIP_P,
20569 PUSH_LABELED_BLOCK, POP_LABELED_BLOCK, PUSH_LOOP, POP_LOOP): New
20570 macros.
20571 (struct parser_ctxt): New fields current_loop,
20572 current_labeled_block.
20573 (build_if_else_statement, patch_if_else_statement,
20574 add_stmt_to_compound, patch_exit_expr, build_labeled_block,
20575 generate_labeled_block, complete_labeled_statement,
20576 build_bc_statement, patch_bc_statement, patch_loop_statement,
20577 build_new_loop, build_loop_body, complete_loop_body): New function
20578 declarations.
20579 * parse.y (java_warning_count): New global variable.
20580 (label_id): New static variable.
20581 (BREAK_TK, CONTINUE_TK): Token tagged <operator>.
20582 (block:): Return size_zero_node when block is empty.
20583 (empty_statement:): Return size_zero_node.
20584 (statement:): Implement supplemental action when for_statement: is
20585 reduced.
20586 (label_decl:): New rule.
20587 (labeled_statement:): Rewritten using label_decl. Actions
20588 implemented.
20589 (labeled_statement_nsi:): Likewise.
20590 (if_then_statement): Actions implemented.
20591 (while_expression): New rule.
20592 (while_statement:): Rewritten using while_expression. Actions
20593 implemented.
20594 (while_statement_nsi:): Likewise.
20595 (do_statement_begin:): New rule.
20596 (do_statement:): Rewritten using do_statement_begin. Actions
20597 implemented.
20598 (for_statement:): Rewritten using for_begin. Actions implemented.
20599 (for_statement_nsi:): Likewise.
20600 (for_header:, for_begin:): New rules.
20601 (for_init:): Actions implemented.
20602 (statement_expression_list:, break_statement:,
20603 continue_statement:): Likewise.
20604 (yyerror): Count number of issued warning(s).
20605 (java_report_errors): Report error(s) and/or warning(s).
20606 (java_complete_class): Use build_java_argument_signature to
20607 recompute completed method signature.
20608 (java_check_regular_methods): New locals method_wfl and aflags.
20609 Use method_wfl instead of lookup_cl during error reports. Fixed
20610 indentation and modified some error messages. Use
20611 lang_printable_name in method instead of the DECL_NAME. New code
20612 to issue warnings on methods not overriding corresponding methods
20613 private to a different package.
20614 (java_method_add_stmt): Call add_stmt_to_compound.
20615 (add_stmt_to_compound): New function.
20616 (java_complete_tree): Handle LABELED_BLOCK_EXPR, EXIT_BLOCK_EXPR,
20617 LOOP_EXPR, EXIT_EXPR and COND_EXPR.
20618 (build_if_else_statement, patch_if_else_statement,
20619 build_labeled_block, generate_labeled_block,
20620 complete_labeled_statement, build_new_loop, build_loop_body,
20621 complete_loop_body, patch_loop_statement, build_bc_statement,
20622 patch_bc_statement, patch_exit_expr): New functions.
20623 * typeck.c (build_java_signature): Build argument signature before
20624 enclosing it in between parenthesis.
20625
20626 1998-08-17 Warren Levy <warrenl@cygnus.com>
20627
20628 * Make-lang.in (JAVA_SRCS): Created for dependencies * Makefile.in
20629 (JAVA_OBJS): Added reminder comment
20630
20631 1998-08-13 Nick Clifton <nickc@cygnus.com>
20632
20633 * gjavah.c (D_NAN_MASK): Append LL to the constant to force it to
20634 be interpreted as a long long.
20635
20636 1998-08-13 Warren Levy <warrenl@cygnus.com>
20637
20638 * decl.c (init_decl_processing): Use _Jv_InitClass, not
20639 soft_initialise_class. Use _Jv_NewMultiArray, not
20640 soft_multianewarray. Use _Jv_ThrowBadArrayIndex, not
20641 soft_badarrayindex. Use _Jv_CheckCast, not soft_checkcast. Use
20642 _Jv_CheckArrayStore, not soft_checkarraystore. Use
20643 _Jv_LookupInterfaceMethod, not soft_lookupinterfacemethod.
20644
20645 1998-08-12 Per Bothner <bothner@cygnus.com>
20646
20647 * decl.c, java-tree.h (this_identifier_node, super_identifier_node,
20648 length_identifier_node): New global tree node constants.
20649 * parse.y (kw_super, kw_this, kw_length): Removed globals.
20650 Replace uses by super_identifier_node etc.
20651 * lex.c (kw_super, kw_this, kw_length): Don't initialize.
20652
20653 * parse.y (resolve_field_access): Don't special-case ".length" if
20654 flag_emit_class_files.
20655 (patch_array_ref): Leave as ARRAY_REF if flag_emit_class_files.
20656 * jcf-write.c (generate_bytecode_insns): Handle ARRAY_REF opcode
20657 and ARRAY.length.
20658
20659 1998-08-11 Per Bothner <bothner@cygnus.com>
20660
20661 * decl.c (init_decl_processing): Remove unused method_type_node fields.
20662 * class.c (make_method_value): Remove init for removed fields.
20663
20664 * class.c (layout_class): Use build_java_argument_signature.
20665 * java-tree.h (TYPE_ARGUMENT_SIGNATURE): New macro.
20666
20667 * typeck.c (push_java_argument_signature): Removed. Merged into ...
20668 (build_java_argument_signature): Use TYPE_ARGUMENT_SIGNATURE cache.
20669 (build_java_signature): Don't use push_java_argument_signature.
20670
20671 * typeck.c (lookup_argument_method): New function.
20672 * parse.y (java_check_regular_methods): Use lookup_argument_method
20673 instead of lookup_java_method2 followed by lookup_java_method.
20674
20675 * parse.y (check_method_redefinition): Minor optimization.
20676
20677 * jcf-write.c (generate_bytecode_insns): Handle RETURN_EXPR,
20678 MINUS_EXPR, MULT_EXPR, TRUNC_DIV_EXPR, and RDIV_EXPR.
20679
20680 1998-08-10 Tom Tromey <tromey@cygnus.com>
20681
20682 * Make-lang.in (jc1$(exeext)): Don't depend on c-common.o or
20683 c-pragma.o.
20684
20685 * gjavah.c (java_float_finite): Use K&R-style definition.
20686 (java_double_finite): Likewise.
20687 (generate_access): Now returns void. Changed all callers.
20688 (last_access_generated): Removed.
20689 (process_file): Only make a single pass over the .class file.
20690
20691 1998-07-29 Per Bothner <bothner@cygnus.com>
20692
20693 * class.c (get_dispatch_table): Add extra dummy vtable entry,
20694 for compatibility for G++ (with -fvtable-thunks).
20695 * expr.c (build_invokevirtual): Add one for extra dummy vtable entry.
20696
20697 * gjavah.c (process_file): Use public inheritance for super-class.
20698
20699 1998-07-29 Alexandre Petit-Bianco <apbianco@cygnus.com>
20700
20701 * lex.c (java_init_lex): Initialize ctxp->package.
20702 * parse.h (struct parser_ctxt): package and package_len replaced
20703 by tree package, an identifier node. Field method_decl_list is
20704 gone. Fixed comments.
20705 (lookup_field_wrapper, merge_qualified_name, not_accessible,
20706 class_in_current_package): New function prototypes.
20707 * parse.y (array_type:): Set class loaded flag on primitive type
20708 arrays.
20709 (package_declaration:): Assign ctxp->package to the
20710 identifier node.
20711 (method_invocation:): Handle invocation of method qualified by
20712 `super'.
20713 (single_type_import_declaration:): Removed ambiguity check.
20714 (java_pop_parser_context): New local variable `next'. Reset and
20715 set IMPORT_CLASSFILE_NAME flags on current and previous import
20716 list.
20717 (java_accstring_lookup): Use new local macro COPY_RETURN.
20718 (lookup_field_wrapper): New function.
20719 (parser_qualified_classname): Use merge_qualified_name.
20720 (parser_check_super_interface): Broaden error message.
20721 (do_resolve_class): Check for qualified class name in the current
20722 compilation unit if appropriate.
20723 (process_imports): Check for already defined classes.
20724 (check_pkg_class_access): Got rid of call to
20725 get_access_flags_from_decl.
20726 (java_complete_expand_methods): Call safe_layout_class based on
20727 the current class size.
20728 (make_qualified_primary): Build a WFL qualification on primary if
20729 none exists.
20730 (merge_qualified_name): New function.
20731 (make_qualified_name): Use merge_qualified_name.
20732 (resolve_expression_name): Use safe_lookup_field.
20733 (resolve_field_access): Got rid of call to get_access_flags_from_decl.
20734 (resolve_qualified_expression_name): Likewise. Check on resolved
20735 element accessibility.
20736 (not_accessible_p, class_in_current_package): New functions.
20737 (maybe_access_field): Got rid of call to get_access_flags_from_decl.
20738 (patch_method_invocation_stmt): Merged common pieces. Check
20739 accessibility of invoked method.
20740 (check_for_static_method_reference): Add returned type in error
20741 message.
20742 (invocation_mode): Get rid of bogus check on PRIVATE methods.
20743 (refine_accessible_methods_list): Merged two conditions in test.
20744 (java_complete_class): Sanity check on stabilize_ref gone.
20745 * zextract.c (read_zip_archive): Cast lseek second argument to long.
20746
20747 1998-07-28 Per Bothner <bothner@cygnus.com>
20748
20749 * class.c (hashUtf8String): Fix - use new JavaSoft specification.
20750
20751 1998-07-24 Tom Tromey <tromey@cygnus.com>
20752
20753 * gjavah.c (F_NAN): Removed.
20754 (F_NAN_MASK): New macro.
20755 (F_POSITIVE_INFINITY): Removed.
20756 (F_NEGATIVE_INFINITY): Likewise.
20757 (java_float_finite): Rewrote.
20758 (D_NAN_MASK): Renamed.
20759 (java_double_finite): Rewrote.
20760 (D_POSITIVE_INFINITY): Removed.
20761 (D_NEGATIVE_INFINITY): Likewise.
20762
20763 * jcf-dump.c (print_constant): [CONSTANT_Double, CONSTANT_Float]
20764 If verbose, print underlying representation of value in hex.
20765
20766 1998-07-24 Per Bothner <bothner@cygnus.com>
20767
20768 * buffer.h, buffer.c: New files.
20769 * Makefile.in (JAVA_OBJS): Add buffer.o.
20770
20771 Support locals variables and writing their debug entries to .class.
20772 * jcf-write.c: Simplify some by user new buffer type.
20773 (vode_buffer_grow): Removed.
20774 (struct localvar_info): New type.
20775 (localsvars, localvartable): New buffers.
20776 (localvar_alloc, localvar_free): New functions.
20777 (generate_bytecode_insns): Handle local variables.
20778 (generate_classfile): Write LocalVariableTable attribute.
20779
20780 1998-07-24 Alexandre Petit-Bianco <apbianco@cygnus.com>
20781
20782 * jcf-io.c (open_in_zip): Check the zipfile magic number.
20783 * zipfile.h (ZIPMAGIC): New macro.
20784
20785 1998-07-24 Tom Tromey <tromey@cygnus.com>
20786
20787 * Makefile.in (gjavah.o): Updated dependencies.
20788 (jcf-dump.o): Likewise.
20789 (all.indirect): Use ../gjavah.
20790 (../gjavah$(exeext)): Likewise.
20791 (clean): Don't remove gjavah.
20792 (clean): Remove parse.c, not java/parse.c.
20793 * Make-lang.in (java): Added gjavah.
20794 (gjavah$(exeext)): New target.
20795 (GJAVAH_SOURCES): New macro.
20796 (java.all.build): Added gjavah.
20797 (java.all.cross): Likewise.
20798 (java.rest.encap): Likewise.
20799 * config-lang.in (compilers, stagestuff): Added gjavah.
20800
20801 1998-07-23 Tom Tromey <tromey@cygnus.com>
20802
20803 * gjavah.c (java_float_finite): New function.
20804 (java_double_finite): Likewise.
20805 (F_POSITIVE_INFINITY): New macro.
20806 (F_NEGATIVE_INFINITY): Likewise.
20807 (F_NAN): Likewise.
20808 (D_POSITIVE_INFINITY): Likewise.
20809 (D_NEGATIVE_INFINITY): Likewise.
20810 (D_NAN): Likewise.
20811 (print_field_info): Use java_float_finite and java_double_finite.
20812
20813 1998-07-23 Per Bothner <bothner@cygnus.com>
20814
20815 * parse.y (method_header): Name "this" implicit argument.
20816
20817 1998-07-22 Per Bothner <bothner@cygnus.com>
20818
20819 * jcf-write.c: Write out LineNumberTable attribute in .class file.
20820 (linenumber_buffer, linenumber_ptr, linenumber_limit): New statics.
20821 (put_linenumber): New function.
20822 (generate_bytecode_insns, generate_classfile): Write line numbers.
20823
20824 1998-07-22 Alexandre Petit-Bianco <apbianco@cygnus.com>
20825
20826 * java-tree.h (CALL_EXPR_FROM_PRIMARY_P): Changed in PRIMARY_P.
20827 (lookup_name, build_known_method_ref, build_class_init,
20828 build_invokevirtual, invoke_build_dtable, match_java_method,
20829 build_field_ref, pushdecl_force_head, build_java_binop,
20830 binary_numeric_promotion, build_decl_no_layout,
20831 build_java_arrayaccess, build_newarray, build_anewarray,
20832 build_java_array_length_access, build_java_arraynull_check): New
20833 extern function prototypes.
20834 (JAVA_UNARY_PLUS_EXPR, JAVA_NEW_ARRAY_EXPR, JAVA_NEW_CLASS_EXPR,
20835 JAVA_THIS_EXPR, CALL_CONSTRUCTOR_P): Macro definition moved in
20836 java-tree.h.
20837 * jcf-parse.c (init_outgoing_cpool): Set current_constant_pool_data_ref
20838 to NULL
20839 * jcf.h (jcf_out_of_synch): New extern function prototype.
20840 * parse.h: Static/global function implemented in parse.y
20841 prototyped and declarations moved at the end of the file.
20842 (DECL_P): Check that the argument isn't null.
20843 (JAVA_UNARY_PLUS_EXPR, JAVA_NEW_ARRAY_EXPR, JAVA_NEW_CLASS_EXPR,
20844 JAVA_THIS_EXPR): No longer defined here. See java-tree.h
20845 (QUAL_DECL_TYPE): New macro.
20846 (PARAMS): Macro definition removed.
20847 * parse.y: (yyparse, yyerror): Use PROTO instead of PARAMS.
20848 (return_statement:): Call build_return.
20849 (field_access:): Call make_qualified_primary in sub rule.
20850 (method_invocation:): Build method invocation and call
20851 make_qualified_primary when processing primaries.
20852 (java_complete_class): Set IDENTIFIER_SIGNATURE_TYPE by calling
20853 get_type_from_signature.
20854 (java_check_regular_method): Extra integer 0 argument when calling
20855 lookup_java_method2.
20856 (lookup_java_interface_method2): Extra method DECL argument when
20857 calling lookup_java_interface_method2.
20858 (java_method_add_stmt): Set TREE_SIDE_EFFECTS on newly created
20859 COMPOUND_EXPR node.
20860 (java_complete_expand_method): Layout current class iff not
20861 already done. Don't process interface's methods.
20862 (java_complete_expand_method): Use super class only if it
20863 exists. Use current class otherwise.
20864 (make_qualified_primary): New function.
20865 (resolve_expression_name): Process qualified expression or
20866 expression from primary the same way.
20867 (resolve_expression_name): Two last arguments to
20868 resolve_field_access are now NULL_TREEs.
20869 (resolve_field_access): New variable is_static. Local field must
20870 be DECLs. is_static computed on field DECLs only. Append code in
20871 where_found to the field access if necessary. Use QUAL_DECL_TYPE
20872 to initialize field_type.
20873 (resolve_qualified_expression_name): New local variable,
20874 previous_call_static and is_static. Handle primaries with function
20875 calls, casts, array references and `this'. `super' now handled as
20876 `(super_class)this'. Use is_static to clarify boolean expressions.
20877 Added code to handle case where a proper handle is required to
20878 access a field. Use QUAL_DECL_TYPE where applicable.
20879 (maybe_access_field): New function.
20880 (patch_method_invocation_stmt): New arguments primary, where,
20881 is_static. Branch of the test on CALL_EXPR_FROM_PRIMARY_P
20882 deleted. Use `where' as a type to search from if specified. Check
20883 for static method reference where forbidden. Append primary or
20884 current_this to the argument list if not calling constructor nor
20885 static methods.
20886 (check_for_static_method_reference): New function.
20887 (patch_invoke): Layout the class on which new is done if
20888 necessary.
20889 (lookup_method_invoke): Changed format to report errors on
20890 methods.
20891 (qualify_ambiguous_name): New local variable this_found. Now
20892 handle things from primaries. Method call are considered
20893 expression names.
20894 (identical_subpath_p): NULL_TREE arguments to breakdown_qualified
20895 changed into NULLs.
20896 (not_initialized_as_it_should_p): Comply with the new DECL_P.
20897 (java_complete_tree): New case fo RETURN_EXPR. Process function
20898 call arguments in separate function.
20899 (complete_function_arguments): New function.
20900 (build_method_invocation): Don't use CALL_EXPR_FROM_PRIMARY_P
20901 anymore.
20902 (patch_assignment): Take the return function slot into account as
20903 a RHS. Distinguish assignment from a return.
20904 (valid_ref_assignconv_cast_p): Use build_java_argument_signature
20905 when checking methods in interfaces.
20906 (resolve_type_during_patch): NULL argument to unresolve_type_p
20907 instead of NULL_TREE.
20908 (patch_newarray): Fixed typo in comment.
20909 (buid_this): Build a WFL with `kw_this' instead of a FIELD_DECL.
20910 (build_return, patch_return): New functions.
20911 * typeck.c (lookup_java_constructor): Fixed typo in comment.
20912
20913 1998-07-21 Per Bothner <bothner@cygnus.com>
20914
20915 * constants.c (find_name_and_type_constant, find_fieldref_index,
20916 find_methodref_index): New methods.
20917 * expr.c (build_invoke_non_interface): If flag_emit_class_files,
20918 just return given method. Also, rename to build_known_method_ref.
20919 (expand_invoke): Rename call to build_invoke_non_interface.
20920 * java-tree.h, parse.h: Update prototype.
20921 * parse.y, decl.c, jcf-parse.c: Suppress calls to back-end functions
20922 (such as expand_expr_stmt) if flag_emit_class_files.
20923 * jcf-write.c (RESERVE, OP1, OP2, OP4, NOTE_PUSH, NOTE_POP,
20924 STACK_TARGET, IGNORE_TARGET): New macros.
20925 (code_buffer, code_ptr, code_limit, code_S, code_SP_max): New globals.
20926 (generate_bytecode_insn): New function to generate method's bytecode.
20927 (generate_classfile): Node generate Code attribute for a method.
20928 (code_buffer_grow, push_constant1, push_constant2, push_int_const,
20929 push_long_const, field_op, adjust_typed_op, maybe_wide):
20930 New functions used by generate_bytecode_insn.
20931
20932 * typeck.c (signature_include_return): Remove variable.
20933 (push_java_argument_signature, build_java_argument_signature): New.
20934 (build_java_signature): Use push_java_argument_signature.
20935 * parse.y: Use build_java_argument_signature instead of fiddling
20936 with signature_include_return.
20937
20938 1998-07-17 Tom Tromey <tromey@cygnus.com>
20939
20940 * gjavah.c (print_c_decl): Always generate JArray<>* for array
20941 types.
20942
20943 * Makefile.in (all.indirect): Added gjavah$(exeext).
20944 (gjavah$(exeext)): Added $(exeext).
20945 (clean): Likewise.
20946
20947 1998-07-16 Alexandre Petit-Bianco <apbianco@cygnus.com>
20948
20949 * class.c (layout_class): Call to java_layout_parsed_class replace
20950 by safe_layout_class.
20951 * expr.c (build_java_array_length_access): Removed static storage
20952 class in the function definition.
20953 (build_java_arraynull_check): Likewise.
20954 Also fixed typos in two comments.
20955 * lex.c (java_init_lex): Initialize static global kw_length.
20956 (java_lex): Use BUILD_OPERATOR on RETURN_TK.
20957 * lex.h (JAVA_FLOAT_RANGE_ERROR): Add extra argument to
20958 java_lex_error.
20959 (JAVA_INTEGRAL_RANGE_ERROR): Likewise.
20960 * parse.h (resolve_no_layout): New static function declaration.
20961 (get_identifier_in_static): Declaration removed.
20962 (java_layout_parsed_class): Function name declaration changed to
20963 safe_layout_class.
20964 (build_newarray_node, patch_newarray, resolve_type_during_patch,
20965 not_initialized_as_it_should_p, build_this): New static function
20966 declarations.
20967 (pushdecl_force_head, build_java_binop, int_fits_type_p,
20968 binary_numeric_promotion, stabilize_reference,
20969 build_decl_no_layout, build_java_arrayaccess): Extern function
20970 declarations moved into their own section.
20971 (build_newarray, build_anewarray, build_java_array_length_access,
20972 build_java_arraynull_check): New extern function declarations.
20973 (UNARY_PLUS_EXPR): Macro renamed into JAVA_UNARY_PLUS_EXPR.
20974 (JAVA_NEW_ARRAY_EXPR, JAVA_NEW_CLASS_EXPR, JAVA_THIS_EXPR): New
20975 fake tree codes.
20976 (CALL_CONSTRUCTOR_P): New macro.
20977 * parse.y (kw_length): New static global tree node.
20978 (return_statement): Tagged <node>.
20979 (RETURN_TK): Tagged <operator>.
20980 (variable_declarator_id:): Build variable declaration with an
20981 empty initialization value if a syntax error was found in the
20982 initialization part of the variable declaration.
20983 (statement_without_trailing_substatement:): return_statement: now
20984 uses the default rule.
20985 (return_statement:): Temporarily fixed to return NULL_TREE.
20986 (primary_no_new_array:): Call build_this when THIS_TK was parsed.
20987 (class_instance_creation_expression:): Class creation rules now
20988 call build_method_invocation upon reduction.
20989 (array_creation_expression:): Rules call build_newarray_node upon
20990 reduction.
20991 (dim_exprs:): Build a list of dimension expressions.
20992 (dim_expr:): Store location of the OSB_TK in the dimension
20993 expression node.
20994 (method_invocation:): Added a new error rule.
20995 (build_unresolved_array_type): WFL argument may also be an array
20996 on a primitive type. Name of the argument changed to reflect this.
20997 (method_declarator): Insert argument type at the beginning of the
20998 argument type list and later reverse the list.
20999 (unresolved_type_p): Argument 'returned' may be optionally
21000 NULL_TREE.
21001 (java_layout_class_from_source): Function renamed
21002 safe_layout_class.
21003 (resolve_and_layout): Now call resolve_no_layout and
21004 safe_layout_class.
21005 (resolve_no_layout): New function.
21006 (purify_type_name): New function.
21007 (complete_class_report_errors): Call purify_type_name during error
21008 report on a type not found.
21009 (process_imports): error_found local variable doesn't need to be
21010 initialized to zero.
21011 (declare_local_variables): New local type_wfl. Fixed typo in error
21012 message. type_wfl assigned to unresolved type and used to register
21013 incomplete type. Build a WFL around the variable initialization
21014 statement so that debug info can be generated on it.
21015 (source_start_java_method): Reverse argument list after they've
21016 been processed.
21017 (current_this): New static global variable.
21018 (java_complete_expand_methods): Set current_this when appropriate.
21019 (resolve_expression_name): Build correct static and non static
21020 field access bearing a simple name.
21021 (resolve_field_access): Resolve the length field of arrays. Handle
21022 f.m() cases.
21023 (patch_method_invocation_stmt): Set the type of the method
21024 invocation to error_mark_node. This value is later overridden by a
21025 valid type, if any. Don't handle qualified constructor invocation
21026 as qualified method invocation. Call lookup_method_invoke with its
21027 new flag. It's no longer necessary to access the selected method
21028 as the value of a tree list. Handle constructor invocation.
21029 (patch_invoke): Reverse argument list when invoking non interface
21030 methods. Insert call to new as the first argument of the
21031 constructor.
21032 (invocation_mode): Return a INVOKE_STATIC is the invoked method is
21033 defined within a final class. Return INVOKE_STATIC if the invoked
21034 method is a constructor.
21035 (lookup_method_invoke): New lc argument is a flag to indicate a
21036 constructor lookup. Now handle constructor lookup. Choose the most
21037 specific method in case several were matching the invocation
21038 requirements. Return a method decl instead of a tree list featuring
21039 one single method decl element.
21040 (refine_accessible_methods_list): New lc flag argument to
21041 indicate that a constructor is being looked up.
21042 (not_initialized_as_it_should_p): New function.
21043 (java_complete_tree): Now process fake tree codes
21044 JAVA_NEW_ARRAY_EXPR, JAVA_NEW_CLASS_EXPR and JAVA_THIS_EXPR. Call
21045 save_expr on resolved function call arguments. Case on
21046 UNARY_PLUS_EXPR changed into a case on JAVA_UNARY_PLUS_EXPR.
21047 (patch_assignment): LHS can be a field access expression. When
21048 dealing with reference, lhs_type is the promoted type of the
21049 rhs_type, not the RHS. Use not_initialized_as_it_should_p where
21050 applicable.
21051 (operator_string): JAVA_UNARY_PLUS_EXPR replaces UNARY_PLUS_EXPR.
21052 (patch_binop): Use not_initialized_as_it_should_p where
21053 applicable.
21054 (build_unaryop): JAVA_UNARY_PLUS_EXPR replaces UNARY_PLUS_EXPR.
21055 (patch_unaryop): Likewise. And use not_initialized_as_it_should_p
21056 where applicable.
21057 (resolve_type_during_patch): New function.
21058 (patch_cast): Call resolve_type_during_patch to resolve type and
21059 report error accordingly.
21060 (patch_array_ref): Use not_initialized_as_it_should_p where
21061 applicable. Array base expression is saved before being
21062 used. Promote the type of an array elements if it contains non
21063 builtin types.
21064 (build_newarray_node, patch_newarray, build_this): New functions.
21065
21066 1998-07-16 Tom Tromey <tromey@cygnus.com>
21067
21068 * gjavah.c (print_c_decl): UTF8_GET increments pointer; don't
21069 increment it in `for' statement.
21070 (print_field_info): If number is inf or nan, don't print it.
21071 (print_method_info): If method name is `delete', just ignore it.
21072 (print_c_decl): Special-case jstringArray.
21073
21074 * gjavah.c (help): New function.
21075 (no_argument): New function.
21076 (usage): Changed text.
21077 (main): Rewrote argument handling. Now handles -v, --help,
21078 --version.
21079 (version): New function.
21080 (found_error): New global.
21081 (main): Return found_error.
21082 (generate_access): Set found_error.
21083 (print_c_decl): Likewise.
21084
21085 1998-07-15 Tom Tromey <tromey@cygnus.com>
21086
21087 * gjavah.c (print_c_decl): Don't print "," when examining field.
21088 Skip type name when looking at "[L" types.
21089 (process_file): Now static.
21090 (generate_access): Now returns int.
21091 (last_access_generated): New global.
21092 (process_file): Clear last_access_generated; make multiple passes
21093 over the class.
21094 (print_field_info): Just return if generate_access returns true.
21095 (print_method_info): Likewise. Also, allow <init> functions to
21096 pass through.
21097 (print_c_decl): Added is_init argument. Print constructors
21098 properly.
21099 (print_cxx_classname): Use UTF8_GET to extract characters from
21100 string.
21101 (print_base_classname): New function.
21102 (print_class_decls): New function.
21103 (process_file): Use it.
21104 (utf8_cmp): New function.
21105
21106 1998-07-13 Nick Clifton <nickc@cygnus.com>
21107
21108 * lang-options.h: Format changed to match changes in gcc/toplev.c
21109 to implement a --help option.
21110
21111 1998-07-10 Brendan Kehoe <brendan@cygnus.com>
21112
21113 * decl.c (init_decl_processing): Revert change to dtable_type.
21114
21115 1998-07-09 Per Bothner <bothner@cygnus.com>
21116
21117 * java-tree.h (CLASS_P): Changed DECL_LANG_FLAG_7 -> TYPE_LANG_FLAG_4.
21118
21119 1998-07-08 Brendan Kehoe <brendan@cygnus.com>
21120
21121 * decl.c (init_decl_processing): Set CLASS_LOADED_P on dtable_type.
21122
21123 * lang.c (lang_init): Default flag_exceptions to 1, without
21124 checking to see if it's 2 first.
21125
21126 1998-07-08 Jeffrey A Law (law@cygnus.com)
21127
21128 * constants.c: Include "system.h".
21129 * decl.c: Likewise.
21130 * lang.c (flag_new_exceptions): Get via extern now.
21131 (lang_init_options): New functions. Turn on flag_new_exceptions.
21132
21133 1998-07-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
21134
21135 * lex.c (java_lex): Return 0 when we see an invalid character in
21136 the input.
21137
21138 * lex.c (java_read_char): Specify extra argument when calling
21139 java_lex_error.
21140 (java_read_unicode, java_parse_end_comment,
21141 java_parse_escape_sequence): Likewise,
21142 (java_lex): Specify extra argument when calling
21143 java_lex_error. Test that IDs are beginning with a legal character
21144 for IDs. Handle invalid characters with an error message and a
21145 call to java_lex_error.
21146 (java_lex_error): Adjust column position by new argument
21147 `forward'. Issue an error even if in the middle of reporting an
21148 other error.
21149
21150 1998-07-07 Brendan Kehoe <brendan@cygnus.com>
21151
21152 * jcf-io.c (find_class): Zero out BUFFER before we use it, since
21153 we don't explicitly put a null pointer when we're copying it.
21154
21155 1998-07-07 Tom Tromey <tromey@cygnus.com>
21156
21157 * gjavah.c (print_cxx_classname): New function.
21158 (super_class_name): Likewise.
21159 (print_super_fields): Removed.
21160 (in_super): Removed.
21161 (print_field_info): Never generate #defines.
21162 (print_c_decl): Changed generated types to match JNI. No longer
21163 print class name before method name.
21164 (print_method_info): Print "static" before static methods.
21165 Print "virtual" before non-final methods.
21166 (usage): Use exit(1), not exit(-1).
21167 (main): Likewise.
21168 (print_field_info): Use %.17g to print a double.
21169 (last_access): New globals.
21170 (process_file): Initialize last_access.
21171 (usage): Now static.
21172 (ACC_VISIBILITY): New define.
21173 (generate_access): New function.
21174 (print_field_info): Call it.
21175 (print_method_info): Likewise. Also, generate information for all
21176 methods, not just native methods. Return void.
21177 (print_c_decl): Return void.
21178 (print_field_info): Return void.
21179
21180 1998-07-02 Alexandre Petit-Bianco <apbianco@cygnus.com>
21181
21182 * Makefile.in (JAVABISONFLAGS): Specific flag for bison when
21183 processing the jc1 grammar file. Prefix bison functions and
21184 variables with java_.
21185 (parse.c): Dependencies on parse.h and lex.h
21186 * expr.c (build_java_arrayaccess): Function now global.
21187 * java-tree.h: Comment reorganized to carry on previous
21188 classification effort.
21189 (RESOLVE_EXPRESSION_NAME_P, RESOLVE_PACKAGE_NAME_P,
21190 RESOLVE_TYPE_NAME_P): New flags on WFLs.
21191 * jcf-parse.c (parse_source_file): java_parse_source_file renamed
21192 java_parse (new prefix java_ generated by bison).
21193 (java_layout_parsed_class, java_register_parsed_class): Function
21194 call removed.
21195 (yyparse): Removed unnecessary call to init_outgoing_cpool.
21196 * lex.c (static tree wfl_op): Variable deleted.
21197 (java_init_lex): Initialize kw_super and kw_this. Initialize more
21198 ctxp fields to NULL_TREE.
21199 (java_lex): No longer create WFL for operators. Filename caching
21200 mechanism deleted. Call BUILD_OPERATOR for `.', '(', '['. Strings
21201 created as STRING_CST and later expanded. Removed extra argument
21202 to BUILD_OPERATOR and BUILD_OPERATOR2. Build operators for THIS
21203 and SUPER.
21204 (build_wfl_node): Removed code in comments.
21205 * lex.h (BUILD_OPERATOR, BUILD_OPERATOR2): No longer build a WFL but
21206 store token and location data in the current bison token.
21207 * parse.h: Removed pre-processor based symbol prefixes hack. Moved
21208 static/extern function declaration at the beginning of the file.
21209 (struct qualification): Data structure definition deleted.
21210 (RESOLVE_CHAIN_REMAINDER): Macro definition deleted.
21211 (qualify_ambiguous_name): Function declaration modified. Function
21212 now returns nothing.
21213 (build_array_ref, patch_array_ref, make_qualified_name,
21214 resolve_qualified_expression_name, maybe_generate_clinit,
21215 resolve_field_access): New static function declarations.
21216 (build_java_arrayaccess): New extern function declaration.
21217 (enum { RESOLVE_EXPRESION_NAME...}): Enum deleted.
21218 (CALL_EXPR_PRIMARY): Macro deleted.
21219 (EXPR_WFL_QUALIFICATION, QUAL_WFL, QUAL_RESOLUTION): New macros.
21220 (struct parser_ctxt): Field initialized_final
21221 removed. non_static_initialized, static_initialized: New fields.
21222 * parse.y (static tree kw_super, static tree kw_this): New global
21223 static.
21224 (%union): tree wfl field of operator member replaced by int
21225 location. WFLs are non longer created for operators.
21226 (OSB_TK, DOT_TK, THIS_TK, SUPER_TK): Tagged <operator>.
21227 (qualified_name:): Now calls make_qualified_name to build the
21228 identifier.
21229 (type_declaration:): Consider generating <clinit> when class
21230 parsing completed.
21231 (variable_declarator:): Directly build an assignment node when the
21232 variable is initialized when declared.
21233 (this_or_super:): Build a WFL and set current location when THIS
21234 or SUPER are parsed.
21235 (expression_statement:): Wrap statement around a WFL.
21236 (primary_no_new_array:): Fixed typo. Changed value returned by
21237 THIS_TK because of its new type (temporary).
21238 (dim_exprs:): Temporary fix because of OSB_TK's new type.
21239 (field_access:): Build qualified name with SUPER.
21240 (method_invocation:): Fixed returned value because of SUPER's new
21241 type.
21242 (array_access:): Use OSB_TK location information.
21243 (post_increment_expression:, post_decrement_expression:,
21244 unary_expression:, pre_increment_expression:,
21245 pre_decrement_expression:, unary_expression_not_plus_minus:,
21246 cast_expression:, multiplicative_expression:,
21247 additive_expression:, shift_expression:, relational_expression:,
21248 equality_expression:, and_expression:, exclusive_or_expression:,
21249 inclusive_or_expression:, conditional_and_expression:,
21250 conditional_or_expression:, assignment:): Use new location/token
21251 information available on operators.
21252 (create_class): Set super_decl_type to NULL_TREE when processing
21253 java.lang.Object.
21254 (register_fields): Field initialization is now a MODIFY_EXPR
21255 node. Chain initialization code to the matching lists (according
21256 to the field declaration modifiers).
21257 (maybe_generate_clinit): New function.
21258 (method_header): Don't set method's DECL_NAME to a WFL when adding
21259 methods to java.lang.Object.
21260 (resolve_and_layout): Now can return NULL_TREE if the type
21261 resolution fails. Otherwise, return the class DECL instead of its
21262 TYPE.
21263 (check_method_redefinition): Don't patch method DECL_NAME if it
21264 belongs to java.lang.Object.
21265 (process_imports): Simply assign error_found to the value returned
21266 by check_pkg_class_access.
21267 (declare_local_variables): Don't use their init statements (if
21268 any) when parsing error were previously found. Reuse MODIFY_EXPR
21269 build during parsing as an init statement.
21270 (java_method_add_stmt): Now return the current method body.
21271 (java_layout_parsed_class, java_register_parsed_class): Functions
21272 removed.
21273 (java_complete_expand_methods): Initialize the constant pool on a
21274 per class basis. Layout the classes before expanding their method
21275 bodies. Don't try expand artificial constructor code if error were
21276 found. Make the classes data and register them if no error were
21277 found.
21278 (java_complete_expand_method): Retrieve an artificial constructor
21279 argument list before entering its body. Assign the top block to
21280 the artificial constructor function body and set types of declared
21281 blocks and compound statements to void. Walk method body if not an
21282 artificial constructor.
21283 (make_qualified_name, cut_identifier_in_qualified): New functions.
21284 (resolve_expression_name): Fixed comments. Save/restore the
21285 current class CLASS_LOADED_P flag value. Build non qualified
21286 static field access and handle qualified expression names.
21287 (resolve_field_access, resolve_qualified_expression_name): New
21288 functions.
21289 (patch_method_invocation_stmt): Use the new expression resolution
21290 scheme, calling resolve_field_access when the function call is
21291 resolved as an expression.
21292 (qualify_ambiguous_name): Function rewritten to work on qualified
21293 expression produced by make_qualified_name.
21294 (java_complete_tree): Promote type when function's argument are
21295 RECORD_TYPEs. While processing the MODIFY_EXPR case: don't patch
21296 the assignment to discover further errors if RHS is a expression
21297 name that fails to evaluate. Declare LHS initialized even though
21298 the assignment failed. Don't use the location variable and removed
21299 extra argument in patch function calls. Now handle the ARRAY_REF
21300 case and build internal string representation when STRING_CSTs are
21301 walked.
21302 (build_method_invocation): Don't wrap function call around a WFL.
21303 (build_assignment): Likewise. Use the operator location
21304 information.
21305 (patch_assignment): Handle array access LHSs. Handle error
21306 provenance, resulting in a better error report.
21307 (build_binop): Use op_location from operator as binop location
21308 information.
21309 (build_unaryop, build_incdec, build_cast): Likewise.
21310 (patch_binop): Extract location information from the node. Fixed
21311 typo in error message.
21312 (patch_unary_op): Extract location information from the node.
21313 (build_array_ref, patch_array_ref): New functions.
21314
21315 1998-07-01 Tom Tromey <tromey@cygnus.com>
21316
21317 * expr.c (expand_java_INSTANCEOF): Changed calling convention to
21318 match _Jv_IsInstanceOf.
21319 * decl.c (init_decl_processing): Use _Jv_NewArray, not
21320 soft_newarray. Use _Jv_IsInstanceOf, not soft_instanceof.
21321
21322 1998-06-30 Tom Tromey <tromey@cygnus.com>
21323
21324 * decl.c (init_decl_processing): Functions are now named
21325 _Jv_MonitorEnter and _Jv_MonitorExit, and return jint.
21326
21327 1998-06-29 Per Bothner <bothner@cygnus.com>
21328
21329 * java-tree.h (load_class): Add prototype.
21330 * class.c (is_compiled_class): Add missing arg to load_class.
21331 * expr.c (expand_java_NEW): Call load_class.
21332 * parse.y (process_import): Removed bogus use of void return value.
21333
21334 1998-06-25 Per Bothner <bothner@cygnus.com>
21335
21336 * decl.c, java-tree.h (soft_athrow_node): Renamed to soft_node.
21337 Function name is "_Jv_Throw" instead of "soft_athrow".
21338 * decl.c, java-tree.h (soft_new_node): Renamed to alloc_object_node.
21339 Function name is "_Jv_AllocObject" instead of "soft_new".
21340 Takes an extra parameter (object size).
21341 * expr.c: Update calls.
21342
21343 1998-06-24 Per Bothner <bothner@cygnus.com>
21344
21345 * lex.c (java_get_line_col): Handle end-of-file.
21346 * except.c (expand_end_java_handler): Handle null type (i.e. finally).
21347
21348 1998-06-24 Andrew MacLeod <amacleod@cygnus.com>
21349
21350 * lang.c (lang_init): Make -fexceptions the default.
21351 * except.c (maybe_start_try, maybe_end_try): Don't do anything if
21352 exception handling is not turned on.
21353
21354 1998-06-23 Andrew MacLeod <amacleod@cygnus.com>
21355
21356 * lang.c (flag_new_exceptions): Make this this default.
21357 * decl.c (end_java_method): Call emit_handlers.
21358 * except.c (method_init_exceptions): Set language code and version.
21359 (expand_start_java_handler): Enable exception, and call
21360 expand_eh_region_start.
21361 (expand_end_java_handler): Enable exception, and set up catch blocks.
21362 (emit_handlers): New routine to generate the saved handlers.
21363 * java-except.h (emit_handlers): Add prototype.
21364
21365 1998-06-12 Per Bothner <bothner@cygnus.com>
21366
21367 We used to have three different representations of the constant pool:
21368 the CPool structure, the tree_constant_pool, and the constructures
21369 used to build the Class object (which may need class and string
21370 constants) in compiled code. None were appropriate for compiling
21371 to .class files, so I did a major overhaul.
21372
21373 First, the tree_constant_pool array was removed. Things were
21374 modified to the CPool structure in the JCF could be used.
21375 Second, a "capacity" field was added to the CPool, and functions
21376 written to search for a matching constant, adding one if not found.
21377 The code that generated the Class object was changed to use a CPool.
21378 The actual TREE_LISTs used to build the CONSTRUCTORs used for
21379 the static Class object are now only in build_constants_constructor.
21380 Finally, I wrote code which can generate a .class file (including its
21381 constant pool) from the RECORD_TYPE of a class. This is a big step
21382 on the way to compiling Java source into .class files.
21383
21384 * jcf-write.c: New file. Writes out a RECORD_TYPE as a .class file.
21385 * Makefile.in (JAVA_OBJS): Added jcf-write.o.
21386
21387 * java-tree.h (CPOOL_UTF, CONSTANT_ResolvedFlag,
21388 CONSTANT_ResolvedString, CONSTANT_ResolvedClass): New macros.
21389 (NAME_AND_TYPE_NAME, NAME_AND_TYPE_SIGNATURE, COMPONENT_REF_NAME,
21390 COMPONENT_REF_NAME_AND_TYPE, COMPONENT_REF_SIGNATURE): Redefined.
21391 (COMPONENT_REF_CLASS): Replaced by COMPONENT_REF_CLASS_INDEX.
21392 (lang_type): Removed constant_pool field.
21393 * jcf.h (CPool): Renamed size to count. Added field capacity.
21394 (CPOO_COUNT, CPOOL_UINT, CPOOL_USHORT1, CPOOL_USHORT2,
21395 CPOOL_FINISH, CPOOL_INIT, CPOOL_REINIT): New macros.
21396 Rewrite some of the old JCF_XXX in terms of CPOOL_XXX macros.
21397
21398 * constants.c (current_constant_pool_tags, current_constant_pool_data,
21399 current_constant_pool_length), java-tree.h: Replaced by outgoing_cpool.
21400 * constants.c (build_constants_constructor): Use new outgoing_cpool.
21401 (set_constant_entry, find_constant1, find_constant2,
21402 find_class_constant, count_constant_pool_bytes, write_constant_pool,
21403 find_utf8_constant, find_class_or_string_constant): New functions.
21404
21405 * jcf-parse.c (load_class): Don't save/restore tree-constant_pool.
21406 (get_constant): Use current_jcf.cpool instead of tree_constant_pool.
21407 (give_name_to_class, get_class_constant): Likewise.
21408 * jcf-parse.c, java-tree.h (tree_constant_pool): Removed.
21409 (get_name_and_type_constant, get_ref_constant): Removed.
21410 * parse.h (parser_ctxt): Remove field tree_constant_pool.
21411 * parse.y: Don't save/restore tree_constant_pool.
21412 * verify.c (verify_jvm_instructions): Update for new approach.
21413 * expr.c (expand_invoke, expand_java_field_op): Likewise.
21414
21415 * lang-options.h: Added -femit-class-file, -femit-class-files.
21416 * lang.c (flag_emit_class_files), java-tree.h: New flag.
21417 (lang_f_options): Added "emit-class-file(s)".
21418
21419 * expr.c (build_java_arrayaccess): Generate more efficient array
21420 bounds checking, by using unsigned compare.
21421
21422 * expr.c (expand_invoke): Re-arrange error checks to make more robust.
21423
21424 1998-06-10 Alexandre Petit-Bianco <apbianco@cygnus.com>
21425
21426 * parse.h: New comment on the handling of unresolved type
21427 identifiers. JDEPs are now part of the jdep_code enum.
21428 (typedef struct jdep): Now use enum jdep_code or int, depending on
21429 availability. Both are narrowed down to an 8 bits bitfield.
21430 (CALL_EXPR_PRIMARY): Fixed comment.
21431
21432 1998-06-10 Tom Tromey <tromey@cygnus.com>
21433
21434 * Make-lang.in (java): Added gjavac and jvgenmain.
21435 (java.start.encap): Depend on gjavac.
21436 (java.rest.encap): Depend on jvgenmain.
21437
21438 * Make-lang.in (JAVA_INSTALL_NAME): Name is gjavac, not c++.
21439 (JAVA_CROSS_NAME): Likewise.
21440 (java.all.build): Depend on jvgenmain and gjavac.
21441 (java.all.cross): Depend on jvgenmain and gjavac-cross.
21442 (jvgenmain$(exeext)): New target.
21443 (java.install-common): Wrote.
21444 * config-lang.in (compilers, stagestuff): Added gjavac and
21445 jvgenmain.
21446
21447 1998-06-10 Dave Brolley <brolley@cygnus.com>
21448
21449 * lang.c (lang_decode_option): New argc/argv interface.
21450
21451 1998-06-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
21452
21453 * ChangeLog: Fixed entries not compliant with the Gnu Coding Standard.
21454 * decl.c (build_decl_no_layout): New function.
21455 * expr.c (java_lang_expand_expr): Layout declarations found in
21456 blocks before they're pushed.
21457 * jcf-parse.c (load_class): Save current line when parsing class
21458 file.
21459 (parse_source_file): Register class before expanding their
21460 methods.
21461 * lang.c (put_decl_node): Produce `null' when `void *' is
21462 processed.
21463 * lex.c (static tree wfl_op): New static global, for error report
21464 on casts.
21465 (java_init_lex): wfl_operator and wfl_op initialized
21466 here. Filename caching added for wfl_op. Return wfl_op when `(' is
21467 parsed.
21468 * parse.h (build_unaryop, build_incdec, patch_unaryop, build_cast,
21469 patch_cast, valid_ref_assignconv_cast_p, can_cast_to_p,
21470 build_unresolved_array_type): New static function definitions.
21471 (build_decl_no_layout): New extern function declared.
21472 (OBSOLETE_MODIFIER_WARNING): Report error only if the WFL of the
21473 faulty modifier exists.
21474 (TYPE_INTERFACE_P, TYPE_CLASS_P): New macros.
21475 (ERROR_CAST_NEEDED_TO_INTEGRAL): Error message tuned.
21476 (UNARY_PLUS_EXPR): New fake operator.
21477 (struct parser_ctxt): New field osb_number.
21478 * parse.y (static tree wfl_operator): New static WFL for operator
21479 bound error messages.
21480 (DECR_TK, INCR_TK): Moved.
21481 (OP_TK): Tagged <operator>.
21482 (array_type:): Now call build_unresolved_array_type.
21483 (dim_expr:): Count the number of '[' seen.
21484 (post_increment_expression, post_decrement_expression,
21485 pre_increment_expression, pre_decrement_expression,
21486 unary_expression_not_plus_minus, unary_expression:): Actions are
21487 now building the corresponding unary expressions.
21488 (cast_expression:): Actions are now building cast expressions.
21489 (build_unresolved_array_type): New function.
21490 (create_interface): Reset the number of declared interfaces.
21491 (create_class): Likewise.
21492 (method_header): Methods declared within the scope of an interface
21493 are now implicitly set public and abstract.
21494 (java_complete_class): Variable's and parameter's type are patched
21495 with a promoted type.
21496 (declare_local_variables): Resolved non builtin types are promoted
21497 before being used to build a variable decl. Removed type patch
21498 posted on variable initialization statement.
21499 (source_start_java_method): Use build_decl_no_layout to build the
21500 decl of a parameter of incomplete type.
21501 (java_register_parsed_class): Process interfaces too. Call
21502 rest_of_decl_compilation on each processed class declarations.
21503 (java_complete_expand_methods): Don't attempt to expand things in
21504 interfaces.
21505 (java_complete_tree): Process CONVERT_EXPR, even though it always
21506 has a type. Propagate error_mark_node to node's type too. Promote
21507 method's call argument type and return error_mark_node if
21508 argument's completion didn't work. MODIFY_EXPR can have a WFL as a
21509 RHS. Fixed bug in the handling of bogus RHS of a fixed type. Now
21510 handle unary operator nodes.
21511 (build_assignment): Added comment.
21512 (print_int_node): New function.
21513 (patch_assignment): New second argument. New error handling. Use
21514 print_int_node. Handle references. Use can_cast_to_p to issue
21515 different error message according to the context and check upon
21516 the initialization of the RHS.
21517 (can_cast_to_p, valid_ref_assignconv_cast_p): New functions.
21518 (operator_string): Handle more operators.
21519 (patch_binop): No longer use a function static
21520 wfl_operator. Improved error message on shift distance.
21521 (build_unaryop, build_incdec, build_cast, patch_unaryop,
21522 patch_cast): New functions.
21523
21524 1998-06-05 Per Bothner <bothner@cygnus.com>
21525
21526 * jvspec.c: New file.
21527 * Make-lang.in: New rules to build gjavac from jvspec.c and ../gcc.c.
21528
21529 * java-tree.h (identifier_subst): Add declaration.
21530
21531 1998-06-04 Tom Tromey <tromey@cygnus.com>
21532
21533 * jvgenmain.c (main): Generate call to JvRunMain.
21534
21535 * class.c (make_class_data): Push value for "sync_info" field.
21536 * decl.c (init_decl_processing): Push "sync_info" field.
21537
21538 1998-06-03 Per Bothner <bothner@cygnus.com>
21539
21540 * typeck.c (build_java_array_type): Set TYPE_NAME to actual
21541 Java (source) name, not signature.
21542 Set TYPE_ALIGN to (at least) that of element_type.
21543
21544 1998-06-02 Per Bothner <bothner@cygnus.com>
21545
21546 * class.c: Moved classname-mangling-rekated code to ...
21547 * mangle.c: ... this new file.
21548 * jvgenmain.c: New program (needs mangle.c) to generate main program.
21549 * Makefile.in: Update for above changes.
21550
21551 1998-06-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
21552
21553 * expr.c (truthvalue_conversion): Convert integer and floating
21554 point value to their truth value.
21555 * lex.c (java_lex): Handle the `null' literal.
21556 * parse.h (JREFERENCE_TYPE_P, DECL_P): New macros.
21557 (ERROR_CANT_CONVERT_TO_BOOLEAN, ERROR_CANT_CONVERT_TO_NUMERIC,
21558 ERROR_CAST_NEEDED_TO_INTEGRAL, ERROR_VARIABLE_NOT_INITIALIZED):
21559 New macros.
21560
21561 * parse.y: Reorganization/documentation on token declaration.
21562 (binop_lookup[]): New added new tree codes.
21563 (relational_expression): Build corresponding binary operators.
21564 (equality_expression, conditional_and_expression,
21565 conditional_or_expression): Likewise.
21566 (java_complete_class): Fix crash in debug message.
21567 (java_complete_tree): Check initialization of method call
21568 arguments. Further bogus node evaluation to detect more error
21569 during assignments. Handles more binary operators.
21570 (patch_assignment): Use DECL_P.
21571 (build_binop): Fix crash when using URSHIFT_EXPR, a Java only tree
21572 code.
21573 (operator_string): Handle more case. Compacted source.
21574 (patch_binop): Changed function comment. Checking for
21575 uninitialized first operand takes the compound assignment into
21576 account and uses DECL_P. Checking for uninitialized second operand
21577 delayed to routine's end. Use macros to issue type bound error
21578 messages and issue messages on both operands if their types are
21579 different. Force fixed type into node. Handle all binary
21580 operators.
21581
21582 1998-05-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
21583
21584 * java-tree.h (COMPOUND_ASSIGN_P, INITIALIZED_P): New macros.
21585 * lex.c (java_lex): Use BUILD_OPERATOR and BUILD_OPERATOR2 to
21586 build operator node and return tokens.
21587 * lex.h (BUILD_OPERATOR, BUILD_OPERATOR2): New macros.
21588 * parse.h (java_complete_tree): Changed returned type in prototype.
21589 (build_method_invocation, build_assignment, patch_assignment,
21590 patch_binop): New static function declarations.
21591 (JFLOAT_TYPE_P, JNUMERIC_TYPE_P, JPRIMITIVE_TYPE_P, JSTRING_P,
21592 BUILD_EXPR_WFL): New macros.
21593 * parse.y (enum tree_code binop_lookup[]): New static for token to
21594 TREE_CODE lookup.
21595 (%union): Parser union has new sub-structure `operator'.
21596 (ASSIGN_TK, MULT_ASSIGN_TK, DIV_ASSIGN_TK, REM_ASSIGN_TK,
21597 PLUS_ASSIGN_TK, MINUS_ASSIGN_TK, LS_ASSIGN_TK, SRS_ASSIGN_TK,
21598 ZRS_ASSIGN_TK, AND_ASSIGN_TK, XOR_ASSIGN_TK, OR_ASSIGN_TK,
21599 ASSIGN_ANY_TK): Tokens tagged `operator'.
21600 (EQ_TK, GTE_TK, ZRS_TK, SRS_TK, GT_TK, LTE_TK, LS_TK, BOOL_AND_TK,
21601 AND_TK, BOOL_OR_TK, OR_TK, INCR_TK, PLUS_TK, DECR_TK, MINUS_TK,
21602 MULT_TK, DIV_TK, XOR_TK, REM_TK, NEQ_TK, NEG_TK, REL_QM_TK,
21603 REL_CL_TK, NOT_TK, LT_TK): Tokens tagged `operator'.
21604 (assignment_operator:): Rule tagged `operator'.
21605 (expression_statement:): Re-installed default rule.
21606 (method_invocation:): Sub rules call build_method_invocation.
21607 (postfix_expression:): Don't attempt to resolve name here. Just
21608 return an ID.
21609 (multiplicative_expression:): Sub-rules build corresponding binop
21610 expression node.
21611 (additive_expression:, shift_expression:, and_expression:,
21612 exclusive_or_expression:, inclusive_or_expression:): Likewise.
21613 (assignment:): Sub rule invoke build_assignment.
21614 (assignment_operator:): Default rules on sub rules.
21615 (force_error): Added documentation on this variable.
21616 (declare_local_variables): Build initialization calling
21617 build_assignment.
21618 (expand_start_java_method): Removed unused rtx declaration. Mark
21619 arguments as already initialized.
21620 (java_method_add_stmt): Type of built COMPOUND_EXPR set to NULL.
21621 (java_complete_expand_methods): Don't process next method if
21622 completion of the previous one triggered errors.
21623 (java_complete_expand_method): Call source_end_java_method if no
21624 error were found during completion.
21625 (resolve_expression_name): Use IDENTIFIER_LOCAL_VALUE to retrieve
21626 locals declaratilon. Handle names found within a class. Return
21627 error_mark_node when things aren't found.
21628 (patch_method_invocation_stmt): Return error_mark_node on failures.
21629 (patch_invoke): Removed unused local. Return the correct node.
21630 (java_complete_tree): Now returns a value. The BLOCK section binds
21631 local identifiers and the type of a BLOCK is now void. Assign the
21632 result of operand completion on COMPOUND_EXPR. Assign the
21633 encapsulated node of a WFL to the result of its completion, except
21634 when the node is an identifier. Now handle MODIFY_EXPR and several
21635 binary operators. Return error_mark_node on errors.
21636 (build_method_invocation, build_assignment, patch_assignment,
21637 build_binop, operator_string, patch_binop): New functions.
21638 * typeck.c (binary_numeric_promotion): New function.
21639
21640 1998-05-21 Per Bothner <bothner@cygnus.com>
21641
21642 * class.c (identifier_subst): New convenience wrapper for ident_subst.
21643 Replace most uses of ident_subst by identifier_subst.
21644
21645 * class.c (push_class_static_dummy_field): Removed function.
21646 (build_class_ref): Find Class object decl by looking up "CNAME.class",
21647 instead of looking got "class" static field. Create that decl here.
21648 (class_identifier_node): Removed; no longer needed.
21649 (init_class_processing): Don't init class_identifier_node.
21650 * jcf-parse.c (jcf_parse): Don't call push_class_static_dummy_field.
21651 Do nreverse 0 times (instead of twice) for Object and Class.
21652 * parse.y (java_layout_parsed_class): No push_class_static_dummy_field.
21653
21654 1998-05-20 Per Bothner <bothner@cygnus.com>
21655
21656 * jcf-parse.c (parse_class-file): Set lino to smallest line number,
21657 while initializing linenumber_count and linenumber_table.
21658 Do it before init_function_start (which calls emit_line_note).
21659 * expr.c (expand_byte_code): Don't need to clear lineno here.
21660
21661 1998-05-18 Tom Tromey <tromey@cygnus.com>
21662
21663 * class.c (append_gpp_mangled_type): If `qualifications' is >=9,
21664 then mangle number as _N_.
21665
21666 * class.c (mangle_class_field): New function.
21667 (build_class_ref): Set assembler name of class reference using
21668 mangle_class_field.
21669 (push_class_static_dummy_field): Likewise.
21670
21671 1998-05-17 Michael Tiemann <tiemann@cygnus.com>
21672
21673 * parse.y (source_start_java_method): Use TREE_SET_CODE instead
21674 of assigning to TREE_CODE. The latter method exploits a feature
21675 of GCC that is not ANSI compliant.
21676
21677 1998-05-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
21678
21679 * decl.c (pushdecl_force_head): New function.
21680 (pushlevel): Removed conditional printf.
21681 (complete_start_java_method): Don't enter local variable scope if
21682 function is compiled from source code.
21683 * expr.c: parse.h now included
21684 (java_lang_expand_expr): New function.
21685 * jcf-io.c (find_class): Use SOURCE_FRONTEND_DEBUG instead of
21686 printf. Terminate buffer when doing directories.
21687 * jcf-parse.c (parse_source_file): Call lang_init_source before
21688 parsing and before code generation.
21689 * jcf.h (SOURCE_FRONTEND_DEBUG): Macro redefined to conditionally
21690 use printf if the macro is defined.
21691 * lang.c (lang_init): Install lang_expand_expr hook on
21692 java_lang_expand_expr.
21693 (java_dummy_print): New function.
21694 (lang_init_source): New function.
21695 * lex.c (java_lex): Remember location of an opening brace at the
21696 second nesting level.
21697 (java_is_eol): Unget character seen after a CR if it is EOF.
21698 * parse.h: Now includes lex.h
21699 (SOURCE_FRONTEND_DEBUG): Macro redefined to conditionally use
21700 printf if the macro is defined.
21701 (expand_start_java_method, build_expr_block, enter_block,
21702 exit_block, lookup_name_in_blocks, maybe_absorb_scoping_blocks):
21703 New static function declarations.
21704 (pushdecl_force_head): New extern function declaration.
21705 (INCOMPLETE_TYPE_P): New macro.
21706 (JDEP_PARM, JDEP_TYPE): New entries in JDEPs enum.
21707 (BLOCK_CHAIN_DECL, BLOCK_EXPR_DECLS, BLOCK_EXPR_BODY,
21708 BLOCK_EXPR_ORIGIN): New macros.
21709 (DECL_SOURCE_LINE_MERGE, DECL_SOURCE_LINE_FIRST,
21710 DECL_SOURCE_LINE_LAST): New macros.
21711 (struct parser_ctxt): Removed field current_method_decl, redundant
21712 with the field current_function_decl. Added fields
21713 first_ccb_indent1 and pending_block.
21714 * parse.y (method_body, literal, INT_LIT_TK, FP_LIT_TK,
21715 BOOL_LIT_TK, CHAR_LIT_TK, STRING_LIT_TK, NULL_TK, VOID_TK): Rules
21716 tagged <node>
21717 (SOURCE_FRONTEND_DEBUG): Used as macro accepting varargs.
21718 (compilation_unit:): Cosmetic on sub rule.
21719 (type_declaration:): Cosmetic on sub rules. Added an error rule.
21720 (variable_initializer:): Installed default rule on expression:.
21721 (method_declaration:): method_header: starts a new
21722 method. method_body: installs the function body, absorbs blocks
21723 emitted for temporary variable scopings, pops function's body block
21724 and merges function's last statement lineno in DECL_SOURCE_LINE.
21725 (method_body:): Installed default rules.
21726 (block:): Call enter_block when an opening brace is seen. Absorb
21727 scoping blocks and call exit_block when a closing brace is seen.
21728 (block_statement:): Cosmetic changes.
21729 (method_invocation:): Create WFL around CALL_EXPR node.
21730 (patch_stage): Added comment around definition.
21731 (method_header): Try to use first_ccb_indent1 as the first line of
21732 the method, so BP debug info are emitted at the first opening
21733 brace of the function. If the function has no body, use the
21734 location of the function's name. Override currently defined method
21735 name with the matching WFL so we can point redefinition errors
21736 using the location where the function's name was declared.
21737 (check_abstract_method_header): Interprets DECL_NAME as an
21738 identifier or as a WFL, accordingly.
21739 (java_complete_class): New cases for JDEP_TYPE and JDEP_PARM.
21740 (check_method_redefinition): Use DECL_NAME as a WFL. Extract
21741 location and name information out of it and reinstall DECL_NAME to
21742 its original identifier node value.
21743 (lookup_cl): Use DECL_SOURCE_LINE_FIRST (first line of the
21744 function's source code).
21745 (read_import_dir): Test the value returned by find_class and issue
21746 a fatal accordingly.
21747 (declare_local_variables): Push a new block for the scope of the
21748 new variable(s) if code has been already generated at that nesting
21749 level. Pinpoint redefinition errors using the variable id
21750 WFLs. Generate initialization code if necessary. If the variable
21751 type is incomplete, register a patch on its decl.
21752 (source_start_java_method): Rewritten. Define a new block for the
21753 function's parameters. Build parameter decl out of function's
21754 arguments and register them for a patch if their types are
21755 incomplete.
21756 (expand_start_java_method): Includes the part of
21757 source_start_java_method that was pushing the parameter decls and
21758 completing the method start code.
21759 (source_end_java_method): Removed call the expand_end_bindings and
21760 poplevel (already taken care of). Reinstall function's arguments
21761 and get function's last line of code before calling
21762 expand_function_end.
21763 (java_method_add_stmt): New comment before the function's
21764 code. Complement the second operand of the current COMPOUND_EXPR
21765 if necessary.
21766 (java_complete_expand_methods): Don't generate debug info on line
21767 zero when expanding a generated constructor.
21768 (java_complete_expand_method): Set start and end line numbers for
21769 a artificially generated constructor to one and manually call
21770 enter_block and exit_block when defining it. For all methods:
21771 expand function's start calling the new expand_start_java_method
21772 and invoke java_complete_tree on the effective method's body, if
21773 any.
21774 (resolve_expression_name): Now use lookup_name_in_blocks to search
21775 local variable decls and print out an error when variables are
21776 undefined.
21777 (patch_method_invocation_stmt): Inserted comment before the
21778 function's code.
21779 (lookup_method_invoke): Chain method's arguments using chainon
21780 with the current arg list as a second argument. Inserted missing
21781 IDENTIFIER_POINTER when reporting an error on methods not found.
21782 (refine_accessible_methods_list): Don't retain constructors.
21783 (patch_arguments): Function removed.
21784 (java_complete_tree): Inserted comment before the function's
21785 code. New case for BLOCKs. Moved the WFL case a bit
21786 further. Complete function's arguments.
21787 (build_expr_block, enter_block, exit_block, lookup_name_in_blocks,
21788 maybe_absorb_scoping_blocks): New functions.
21789
21790 1998-04-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
21791
21792 * jcf-io.c (find_class): Reset jcf->java_source after JCF_ZERO, if
21793 previously set.
21794 * jcf-parse.c (parse_source_file, java_error_count): New forward
21795 and extern declarations.
21796 (java_parse_abort_on_error): Macro moved.
21797 (jcf_parse_source): fatal called if fopen fails. Now calls
21798 parse_source_file.
21799 (parse_source_file): New parse_only parameter. Reflects the
21800 elimination of the second pass.
21801 (yyparse): parse_source_file called with argument set to 0.
21802 * jcf.h (JCF_ZERO): Sets java_source to zero.
21803 * lex.c (java_init_lex): pass argument is gone. Function modified
21804 to be called once during the analysis of a file.
21805 (java_unget_unicode): Fixed typo in fatal message.
21806 (java_get_line_col): Likewise.
21807 (java_lval): Likewise. String literals no longer built during
21808 second pass.
21809 * lex.h (JAVA_COLUMN_DELTA): Take the tabulation character into
21810 account.
21811 * parse.h (MODIFIER_WFL): New macro.
21812 (parse_check_super, parser_check_super_interface): Now return int.
21813 (parser_chain_incomplete_item, not_builtin_p,
21814 complete_method_decl): Declarations removed.
21815 (build_method_invocation_stmt, build_invoke): Renamed using the
21816 `patch' instead of `build'
21817 (register-incomplete_type, obtain_incomplete_type,
21818 java_complete_tree, java_complete_expand_method,
21819 unresolved_type_p, create_jdep_list): New function declarations.
21820 (IC_TYPE, IC_DEPEND, DEPEND_DECL, DEPEND_WFL, BEGIN_ONLY_PASS,
21821 END_ONLY_PASS, ELSE_ONLY_PASS): Macro deleted.
21822 (jdep): New typedef on new struct _jdep.
21823 (JDEP_DECL, JDEP_DECL_WFL, JDEP_KIND, JDEP_SOLV, JDEP_WFL,
21824 JDEP_MISC, JDEP_APPLY_PATCH, JDEP_GET_PATCH, JDEP_CHAIN,
21825 JDEP_TO_REVOLVE, JDEP_RESOLVED_DECL, JDEP_RESOLVED,
21826 JDEP_RESOLVED_P): New macros.
21827 (JDEP_NO_PATCH, JDEP_SUPER, JDEP_FIELD, JDEP_METHOD,
21828 JDEP_METHOD_RETURN, JDEP_METHOD_END, JDEP_INTERFACE,
21829 JDEP_VARIABLE): New enum values and jdep kinds.
21830 (jdeplist): New typedef on struct _jdeplist.
21831 (CLASSD_FIRST, CLASSD_LAST, CLASSD_CHAIN, JDEP_INSERT): New
21832 macros.
21833 (CALL_EXPR_PRIMARY): New macro.
21834 (struct parser_ctxt): Fields java_pass, current_method_decl,
21835 method_decl_list deleted. New field jdeplist.
21836 (INCOMPLETE_P): Macro deleted.
21837 * parse.y (single_type_import_declaration:): Removed pass switch.
21838 (type_import_on_demand_declaration): Likewise.
21839 (field_declaration:): Removed pass switch on all sub rules.
21840 (class_declaration:): Call the complete_class_decl removed on
21841 class_body rules.
21842 (method_declaration:): Removed second pass switch. No longer chain
21843 methods decl when method_header reduced.
21844 (method_header:): Sub rules no longer depend on pass switch.
21845 (method_declarator:): Likewise.
21846 (method_body:): Likewise.
21847 (abstract_method_declaration:): Likewise.
21848 (block_statement:): Likewise.
21849 (local_variable_declaration:): Likewise.
21850 (argument_list:): Likewise.
21851 (method_invocation:): Likewise. Call to build_method_invocation_stmt
21852 removed. Partial CLASS_EXPR tree node built instead.
21853 (postfix_expression:): Removed pass switch on all sub rules.
21854 (java_pop_parser_context): Free classd_list content.
21855 (yyerror): Call obstrack_grow0 to finalize error message.
21856 (check_class_interface_creation): Comment modified to reflect new
21857 returned value meaning. Removed second pass switch. Return 1 if an
21858 error was found, 0 otherwise. Adjust pointer on filename if a
21859 leading path separator was found.
21860 (maybe_create_class_interface_decl): Removed first pass switch
21861 when linking the class decl to the class_list. Install a new
21862 jdep_list for the class.
21863 (add_superinterfaces): List of unresolved interfaces is
21864 gone. Unresolved interfaces are directly added to the current
21865 dependencies list.
21866 (create_interface): Second pass shortcut removed.
21867 ctpx->modifier_ctx access through MODIFIER_WFL.
21868 (create_class): Second pass shortcut removed. Call to
21869 register_incomplete_type replaces the call to
21870 parser_chain_incomplete_item.
21871 (complete_class_decl): Function removed.
21872 (duplicate_declaration_error): New way of retrieving redeclared
21873 item type.
21874 (register_fields): Call to lookup_modifier_cl replaced by
21875 MODIFIER_WFL. New way of handling unresolved type, using
21876 unresolved_type_p and obtain_incomplete_type.
21877 register_incomplete_type replaces call to parser_chain_incomplete_item.
21878 (patch_stage): New static global variable.
21879 (method_header): New way of handling unresolved type, using
21880 unresolved_type_p and obtain_incomplete_type. patch_stage used to
21881 indicates that the method decl needs to be patched.
21882 (check_abstract_method_header): Call to lookup_modifier_cl
21883 replaced by MODIFIER_WFL.
21884 (method_declarator): Incomplete argument type are registered
21885 calling register_incomplete_type. Patch on the declared method is
21886 issued in that case.
21887 (unresolved_type_p): New function.
21888 (parser_check_super_interface): New comment to reflect function's
21889 modified returned type (int). Function and has a new argument
21890 this_wfl. Call to parse_error_context uses this_wfl instead of
21891 relying on lookup_cl.
21892 (parser_check_super): Comment reflects function's new returned
21893 type (int). Function returns nonzero value on error.
21894 (create_jdep_list, reverse_jdep_list, obtain_incomplete_type,
21895 register_incomplete_type, jdep_resolve_class): New functions to
21896 handle incomplete types in declarations.
21897 (java_complete_class): Rewritten to work with the new incomplete
21898 type handling scheme.
21899 (complete_class_report_errors): Likewise.
21900 (complete_method_decl): Removed: it jobs is now handled by
21901 java_complete_class.
21902 (do_resolve_class): Class loaded in not already loaded and not
21903 found in Java source code.
21904 (java_check_regular_methods, java_check_abstract_methods): Don't
21905 call complete_method_decl anymore.
21906 (lookup_modifier_cl, not_builtin_p): Functions deleted.
21907 (read_import_dir): Got rid of the pass number dependency.
21908 (declare_local_variables): New handling of unresolved types (patch
21909 issued).
21910 (source_start_java_method): New parameter level. Function called
21911 with level set to 1 when argument types are potentially
21912 unresolved. Called to complete the job with level set to 2 once
21913 types are complete.
21914 (source_end_java_method): Call to permanent_allocation
21915 removed. Waiting to be replaced by a more suitable obstack
21916 management.
21917 (java_complete_expand_methods, java_complete_expand_method,
21918 java_expand_finals): New functions.
21919 (build_method_invocation_stmt): Renamed
21920 patch_method_invocation_stmt. Extracts function call expression
21921 (wfl) and arguments (args) from CALL_EXPR tree operands.
21922 (build_invoke): Renamed patch_invoke. Fixed typo in fatal
21923 call. Patch the function and argument operand of the CALL_EXPR
21924 tree argument.
21925 (patch_argument, java_complete_tree): New functions.
21926
21927 1998-04-20 Per Bothner <bothner@cygnus.com>
21928
21929 Recover from missing fields and methods (i.e. error instead of fatal).
21930 * decl.c, java-tree.h (TYPE_identifier_node): New global constant.
21931 * expr.c (expand_invoke): Recover from missing method.
21932 (expand_java_field_op): Recover from missing field.
21933 Inline references to java.lang.{Integer,Char,...}.TYPE.
21934 * typeck.c (get_type_from_signature), java-tree.h: New function.
21935 * class.c (add_method): Use get_type_from_signature.
21936 (build_class_ref): Handle a class that was not found.
21937 * typeck.c (convert): Handle conversion to pointers (for convenience).
21938 * verify.c (verify_jvm_instructions): Use get_type_from_signature
21939 instead of lookup_field to handle missing fields.
21940
21941 * jcf-parse.c (process_zip_dir): Set java_source.
21942
21943 1998-04-20 Brendan Kehoe <brendan@cygnus.com>
21944
21945 * jcf-parse.c (set_source_filename): Use TYPE_NAME, not DECL_NAME.
21946
21947 1998-04-14 Alexandre Petit-Bianco <apbianco@cygnus.com>
21948
21949 * jcf-parse.c (load_class): Don't change input_filename before
21950 calling jcf_parse_source (but still do it before calling
21951 jcf_parse).
21952 (jcf_parse_source): Assign input_filename after having saved the
21953 parser context.
21954 * lex.c (java_init_lex): Chain a WFL node to the import on demand
21955 list. ctxp->modifier_ctx zeroed according to its new
21956 definition. ctxp->filename initialized. Removed
21957 JAVA_MODIFIER_CTX_UNMARK.
21958 (java_unget_unicode): Update the character based column position.
21959 (java_allocate_new_line): ref_count not used anymore. Always free
21960 ctxp->p_line. Initialize c_line->char_col to 0.
21961 (java_get_unicode): Update the character based column position.
21962 (java_lex): Use ctxp->elc to store current position in source
21963 file, at the beginning of the parsed token. Set modifier_ctx entry
21964 corresponding to the parse modifier to a WFL node. Return a WFL
21965 node when an identifier is parsed.
21966 (java_lex_error): Now uses ctxp->elc to store current position in
21967 source.
21968 (build_wfl_node, java_is_eol, java_get_line_col): New functions.
21969 * lex.h (build_wfl_node): New function definitions.
21970 (struct java_line): ref_count and next fields are gone. New field
21971 char_col.
21972 (JAVA_LINE_CHECK, JAVA_LINE_MARK, JAVA_LINE_CHAIN,
21973 JAVA_LINE_UNMARK, ID_NAME, ID_CL): Macro definitions deleted.
21974 (JAVA_COLUMN_DELTA): New macro.
21975 (java_lc): New typedef on new struct _java_lc.
21976 * parse.h (lookup_cl, lookup_modifier_cl): Changed returned types.
21977 (parse_error_context, parse_warning_context): Changed prototypes.
21978 (java_get_line_col): Added as an available global function.
21979 (JAVA_MODIFIER_CTX_UNMARK): Macro removed.
21980 (IC_DECL): Replaced by macro IC_TYPE
21981 (DEPEND_WFL): New macro.
21982 (THIS_MODIFIER_ONLY): Now works with WFL and only remembers the first
21983 wrong modifier.
21984 (exit_java_complete_class): Removed a commented out statement.
21985 (struct parser_ctxt): Added comments on fields. modifier_ctx is
21986 now an array of tree nodes. Deleted fields line_list and
21987 e_line. New field elc, to replace e_line.
21988 * parse.y (array_type:): Build WFL node.
21989 (qualified_name:): Build a single WFL node out of two. Retain
21990 the location information of the first node in the resulting node.
21991 (package_declaration:): Use package name as a WFL node
21992 (single_type_import_declaration:): Use imported name as a WFL node.
21993 (type_import_on_demand_declaration:): Use root of the imported
21994 packages as a WFL node.
21995 (field_declaration:): Removed unused local variable cl.
21996 (method_declaration:): Don't call JAVA_MODIFIER_CTX_UNMARK.
21997 (yyerror): New static elc. Removed static error_line, error_pos.
21998 New local code_from_source. Save ctxp->elc into elc at the first
21999 pass. Call java_get_line_col to get a string of the line where
22000 the error occurred.
22001 (debug_line): Removed static function.
22002 (parse_error_context, parse_warning_context): Parameter cl is now
22003 a WFL node. Use its value to initialize ctxp->elc.
22004 (redefinition_error): Parameter cl is now a WFL node.
22005 (parse_add_interface): New parameter wfl. No longer call
22006 lookup_cl, use wfl instead.
22007 (check_class_interface_creation): Parameter cl is now a WFL node.
22008 (maybe_create_class_interface_decl): Likewise.
22009 (add_superinterfaces): New function.
22010 (create_interface): Removed local cl, node, super_decl,
22011 super_decl_type. Function now uses id as a WFL node. Better
22012 warning/error report on obsolete or forbidden mix of
22013 modifiers. Now calls add_superinterfaces to register interfaces.
22014 (create_class): Removed local cl, node. Local variable id is used
22015 as a WFL node. Better error report on forbidden modifier
22016 mix. Uses add_superinterfaces to register interfaces.
22017 (find_field): Argument cl is now a WFL node. Now store the WFL
22018 node of a fields that needs to be checked for their
22019 initialization.
22020 (method_header): Local variable node non longer used. Local
22021 variable id replaces cl.
22022 (check_modifiers_consistency): Local variable cl is now a WFL
22023 node.
22024 (method_declarator): Local variable cl replaced by parameter id.
22025 (parser_qualified_name): Now uses parameter name as a WFL node.
22026 (parser_check_super_interface): New parameter wfl, for achieve
22027 greater accuracy during error reports.
22028 (parser_chain_incomplete_item): New parameter named location. Used,
22029 along the decl, to construct the incomplete item node.
22030 (java_complete_class): resolve_class now uses WFL node extracted
22031 from the incomplete item node. Macro IC_TYPE replaces TREE_PURPOSE
22032 where appropriate.
22033 (complete_method_decl): Unresolved function's argument types are WFL.
22034 (resolve_class): Parameter cl is now a WFL node.
22035 (resolve_and_layout): Likewise.
22036 (do_resolve_class): Likewise. Try first to use cl and then do the
22037 lookup on the decl when calling check_pkg_class_access.
22038 (complete_class_report_errors): Use IC_TYPE in place of
22039 TREE_PURPOSE where appropriate. Use DEPEND_WFL on dependency
22040 instead of doing a lookup over the decl.
22041 (java_check_final): Use WFL info from field tree list.
22042 (lookup_cl): Rewritten and returns a statically defined WFL node.
22043 (lookup_modifier_cl): Now uses information from WFL nodes.
22044 (process_imports): Likewise.
22045 (read_import_dir): name and cl arguments replaced by a single WFL
22046 node. Function modified accordingly.
22047 (find_in_imports_on_demand): Now uses WFL node.
22048 (check_pkg_class_access): cl argument is now a WFL node.
22049 (declare_local_variables): Fixed to use WFL nodes.
22050 (resolve_expression_name): Likewise.
22051 (build_method_invocation_stmt): name_combo argument renamed
22052 wfl. Function modified to use WFL nodes.
22053 (build_invoke): cl used as a WFL node when calling build_expr_wfl.
22054 (lookup_method_invoke): cl is now a WFL node. Added missing
22055 IDENTIFIER_POINTER to class type decl name.
22056
22057 1998-04-14 Dave Brolley <brolley@cygnus.com>
22058
22059 * lang.c (init_parse): Now returns char* containing the filename.
22060
22061 1998-04-10 Per Bothner <bothner@cygnus.com>
22062
22063 * class.c (layout_class): Mangle repeated arg types to match cc1plus.
22064
22065 * decl.c, java-tree.h (integer_four_node): New INTEGER_CST node.
22066 * class.c (make_class_data): If flag_assume_compiled, initial class
22067 state is CSTATE_PREPARED; make superclass and interfaces direct
22068 references, rather than constant pool indexes.
22069
22070 1998-04-09 Alexandre Petit-Bianco <apbianco@cygnus.com>
22071
22072 * parser.y: Include flags.h. Removed debug variable pl.
22073 (method_declaration:): Uses ctxp->parser_ccb_indent instead of pl.
22074 (block:): Likewise.
22075 (labeled_statement_nsi:): Generate debug info when reducing
22076 expression_statement:.
22077 (check_pkg_class_access): get_access_flags_from_decl invocation
22078 fixed for new CLASS_* flags location.
22079 (source_end_java_method): Save/restore parser context when
22080 entering/leaving this routine. Restore lineno to its right value
22081 before calling expand_end_bindings.
22082 (build_method_invocation_stmt): build_invoke called with the
22083 current line information.
22084 (build_invoke): New argument cl. Wrap the function call around a
22085 wfl node.
22086 (refine_accessible_methods_list): Changed comment, removed
22087 unnecessary code.
22088 * parse.h: Fixed typo in comments.
22089 (CLASS_OR_INTERFACE): Handle the new CLASS_* flags location.
22090 (JAVA_MAYBE_GENERATE_DEBUG_INFO): New macro.
22091 (struct parser_ctxt): New fields ccb_indent, last_ccb_indent1,
22092 parser_ccb_indent.
22093 * lex.c (java_lex): Record the last closing curly bracket of a
22094 function.
22095 * jcf-parse.c (jcf_parse_source): Now calls
22096 java_check_methods. Clarified comment, fixed typo.
22097
22098 1998-04-09 Dave Brolley <brolley@cygnus.com>
22099
22100 * lang.c (init_parse): Expose for non USE_CPPLIB builds.
22101 (finish_parse): Expose for non USE_CPPLIB builds.
22102
22103 1998-04-08 Jeffrey A Law (law@cygnus.com)
22104
22105 * lang.c (lang_print_xnode): New function.
22106
22107 1998-04-03 Per Bothner <bothner@cygnus.com>
22108
22109 * decl.c (class_dtable_decl), java-tree.h: New tree node.
22110 * class.c (get_dispatch_vector, get_dispatch_table): New functions
22111 used to build a class's dispatch table.
22112 (make_class_data): Generate dispatch table if flag_assume_compiled.
22113 Set dtable of class object to address of class_dtable_decl.
22114
22115 * decl.c (int_decl_processing): Make soft_badarrayindex_node
22116 be volatile and have side effects - generates better code.
22117
22118 * class.c, expr.c, parse.y: CLASS_INTERFACE, CLASS_FINAL, etc:
22119 These flags were defined for TYPE_DECLs, but used on RECORD_TYPEs.
22120
22121 * expr.c (expand_invoke): If class is final, method is
22122 effectively final, so can call it directly.
22123
22124 * java-tree.h (TYPE_NVIRTUALS, TYPE_VTABLE): New macros.
22125
22126 * Makefile.in, Make-lang.in: Add missing $(exeext)s.
22127
22128 1998-03-19 Alexandre Petit-Bianco <apbianco@cygnus.com>
22129
22130 * parse.y (build_method_invocation_stmt): Removed extra argument
22131 to build_invoke.
22132
22133 1998-03-16 Alexandre Petit-Bianco <apbianco@cygnus.com>
22134
22135 * expr.c (dtable_indent): Now static global.
22136 (expand_invoke): Now call invoke_build_dtable and
22137 build_invokevirtual.
22138 (invoke_build_dtable, build_invokevirtual): New functions.
22139 * jcf-io.c (find_class): Defer issuing a warning by setting
22140 jcf->outofsynch to 1.
22141 * jcf-parse.c (jcf_out_of_synch): New function.
22142 (load_class): Test this_jcf.outofsynch flag and call
22143 jcf_out_of_synch accordingly.
22144 * jcf.h: (typedef struct JCF): New flag outofsynch. Fixed typo in
22145 comment indentation.
22146 * lex.c (java_get_unicode): Fixed code indentation.
22147 (java_lex): Create string literal. Fixed typo. Removed several
22148 premature obstack_free.
22149 * parse.h: New enums for name resolution and invocation mode.
22150 (struct qualification): New data structure.
22151 (RESOLVE_CHAIN_REMAINDER, BUILD_PTR_FROM_NAME): New macros.
22152 (do_resolve_class, build_method_invocation_stmt,
22153 breakdown_qualified, qualify_ambiguous_name, resolve_and_layout,
22154 debug_line, identical_subpath_p, invocation_mode,
22155 refine_accessible_methods_list, build_invoke,
22156 lookup_method_invoke): New functions declared.
22157 (build_invokevirtual, invoke_build_dtable, match_java_method,
22158 build_field_ref, jcf_out_of_synch): New references to external
22159 functions.
22160 (struct parse_ctxt): Removed artificial_constructor field.
22161 * parse.y: (array_type:): Type defined for this rule.
22162 (class_type:): Installed default rule for interface_type:.
22163 (array_type:): Now build Java array type.
22164 (qualified_name:): Now use obstack_grow0.
22165 (method_declaration:): Skip the artificial constructor added to
22166 the list, if any.
22167 (abstract_method_declaration:): Execute the code only during pass 1.
22168 (block:): Installed default rule in block_statements:.
22169 (block_statement:): Add the statement to the method during pass 2.
22170 (statement_expression): Installed default rule for
22171 method_invocation:.
22172 (argument_list:): Added code to build the argument list.
22173 (method_invocation:): Added call to create the method invocation
22174 node.
22175 (yyerror): Now use obstack_grow0. Removed bogus obstack_free.
22176 (debug_line): New function for debug.
22177 (complete_class_decl): No longer do something during pass 1.
22178 (method_header): Use BUILD_PTR_FROM_NAME.
22179 (parser_qualified_classname): Use obstack_grow0. Removed bogus
22180 obstack_free.
22181 (parser_chain_incomplete_item): Use BUILD_PTR_FROM_NAME. Modified
22182 function's main comment.
22183 (java_complete_class): Set CLASS_LOADED_P on all fixed incomplete
22184 classes.
22185 (complete_method_decl): Use BUILD_PTR_FROM_NAME and promote types.
22186 (resolve_class): Now works with arrays.
22187 (do_resolve_class, resolve_and_layout): New functions.
22188 (java_check_regular_methods): Reverse method list before and after
22189 having processed it. No longer set ctxp->artificial_constructor.
22190 (read_import_dir): Test jcf->outofsynch and call jcf_out_of_synch
22191 accordingly. Fixed typo in issued error message. Now use
22192 obstack_grow0.
22193 (find_in_imports_on_demand): Now use obstack_grow0.
22194 (declare_local_variables): Use BUILD_PTR_FROM_NAME.
22195 (source_end_java_method): Call expand_expr_stmt instead of
22196 expand_expr. Calls it before calling expand_function_end.
22197 (java_method_add_stmt): Do nothing if errors were found during
22198 parsing.
22199 (java_layout_parsed_class): Set CLASS_LOADED_P and fixed typo.
22200 (build_method_invocation_stmt, build_invoke, invocation_mode,
22201 lookup_method_invoke, refine_accessible_methods_list,
22202 qualify_ambiguous_name, breakdown_qualified, identical_subpath_p):
22203 New functions.
22204 * typeck.c (build_java_signature): Properly end method signature
22205 if return type skipped.
22206 (match_java_method): New function.
22207
22208 1998-03-16 Per Bothner <bothner@cygnus.com>
22209
22210 * jcf-io.c (find_classfile): If USE_JCF_STDIO, fopen in binary mode.
22211
22212 1998-02-25 Alexandre Petit-Bianco <apbianco@cygnus.com>
22213
22214 * expr.c (build_invoke_non_interface): New function.
22215 (methods_ident, ncode_ident): Now static globals.
22216 (expand_invoke): Use build_invoke_non_interface.
22217 * java-tree.h (struct lang_decl): New field function_decl_body.
22218 (DECL_FUNCTION_BODY): New macro.
22219 * jcf-parse.c (jcf_parse_source): Deeper check before setting
22220 CLASS_FROM_SOURCE_P.
22221 (parse_source_file): Fixed typos. Call java_layout_parsed_class
22222 before starting pass 2. Call to java_generate_parsed_class replaced
22223 by java_register_parsed_class.
22224 * lex.c: Fixed typo in header. Some line width related formating.
22225 * lex.h: Some line width related formating.
22226 * parse.h (source_end_java_method, resolve_expression_name,
22227 complete_class_decl, maybe_create_class_interface_decl,
22228 check_class_interface_creation): New static function declarations.
22229 (java_layout_parsed_class, java_method_add_stmt): New function
22230 declarations.
22231 (struct parser_ctxt): Field mark_class_generate removed. New
22232 fields class_list and artificial_constructor.
22233 * parse.y: Fixed typo in header.
22234 (class_declaration:): Call complete_class_decl when class body
22235 parsed.
22236 (method_declaration:): Call source_end_java_method in pass 2 when
22237 the method body is defined.
22238 (postfix_expression:): Do expression name resolution on sub-rule
22239 name during pass 2.
22240 (create_class, create_interface): Merged common pieces.
22241 (check_class_interface_creation, maybe_create_class_interface_decl):
22242 New functions.
22243 (complete_class_decl): New function.
22244 (register_fields): Fixed line width related typo.
22245 (method_header): Correctly skip first argument when fixing
22246 argument line. Changed the loop.
22247 (java_check_circular_reference): Now use ctxp->class_list.
22248 (java_complete_class): Removed start/stop marking.
22249 (java_check_regular_methods): Now takes a class decl as an
22250 argument. Add default constructor if none were encountered.
22251 (java_check_methods): Now use ctxp->class_list. Changed call to
22252 java_check_regular_methods.
22253 (source_start_java_method): Set DECL_ARG_TYPE for each function
22254 arguments.
22255 (source_end_java_method, java_method_add_stmt): New functions.
22256 (java_generate_parsed_class): No longer exists.
22257 (java_layout_parsed_class, java_register_parsed_class): New functions.
22258 (resolve_expression_name): New function.
22259
22260 1998-02-12 Alexandre Petit-Bianco <apbianco@cygnus.com>
22261
22262 * jcf-parse.c: (parse_source_file): Check on errors after init lex.
22263 * lex.c: (java_init_lex): Defer ctxp->java_pass initialization
22264 until pass initializations are done. Call read_import_dir with
22265 pass set to 0.
22266 * parse.h: (lookup_modifier_cl): New function declared.
22267 (INTERFACE_FIELD_MODIFIERS): New macro.
22268 (OBSOLETE_MODIFIER_WARNING): New macro.
22269 * parse.y: (register_fields): Class type and current field name in
22270 local variables. Check modifier(s) if adding field(s) to an interface.
22271 (check_abstract_method_header): Now use OBSOLETE_MODIFIER_WARNING
22272 and report errors using the faulty modifier line context.
22273 (lookup_modifier_cl): New function.
22274 (read_import_dir): Detect and report default import processing
22275 failure.
22276
22277 1998-02-11 Brendan Kehoe <brendan@cygnus.com>
22278
22279 Add a pair of -fassume-compiled/-fno-assume-compiled options.
22280 * class.c (is_compiled_class): Return 1 after making sure it
22281 qualifies as loaded, if FLAG_ASSUME_COMPILED is set.
22282 * lang-options.h: Add -fassume-compiled/-fno-assume-compiled.
22283 * java-tree.h (flag_assume_compiled): Add decl.
22284 * lang.c (lang_f_options): Add the flag.
22285 (flag_assume_compiled): Add decl, default to 0.
22286
22287 1998-02-11 Alexandre Petit-Bianco <apbianco@cygnus.com>
22288
22289 * class.c (class_depth): Call to load_class uses extra VERBOSE arg.
22290 (is_compiled_class): Likewise.
22291 (layout_class): Likewise.
22292 (layout_class): Detect and lay out classes defined in source code.
22293 (interface_of_p, add_interface_do, may_add_interface): New
22294 function.
22295 (add_interface): Now use add_interface_do.
22296 (add_method_1): New function.
22297 (add_method): Now use add_method_1.
22298 (pushlevel): Debug message conditional to SOURCE_FRONTEND_DEBUG.
22299 (complete_start_java_method): New function.
22300 (start_java_mehod): Now call complete_start_java_method.
22301 * expr.c (lookup_field): Call to load_class uses extra VERBOSE arg.
22302 (expand_invoke): Likewise and fixed typo.
22303 *gjava.c: (print_super_field): Use new argument to find_class
22304 DO_CLASS_FILE.
22305 (main): Likewise.
22306 *java-tree.h: (CLASS_FROM_SOURCE_P): New flag on RECORD_TYPE.
22307 (IS_A_SINGLE_IMPORT_CLASSFILE_NAME_P, IS_A_CLASSFILE_NAME,
22308 QUALIFIED_P, IS_AN_IMPORT_ON_DEMAND_P): New flags on
22309 IDENTIFIER_NODE.
22310 (CLASS_COMPLETE_P): New flag on TYPE_DECL.
22311 (add_method_1, push_class): New prototypes.
22312 *jcf-dump.c: find_class now uses new DO_CLASS_FILE argument.
22313 *jcf-io.c: (open_in_zip): jcf now stores a pointer to the Zip
22314 directory where the class was found.
22315 (find_class): New argument DO_CLASS_FILE. Function find_class
22316 modified accordingly.
22317 *jcf-parse.c: (fix_class_path): New function.
22318 (load_class): Use new VERBOSE argument. load_class now finds and
22319 loads/parses .class/.java files. Save read_state of current_jcf
22320 if necessary.
22321 (java_parser_abort_on_error): New macro.
22322 (jcf_parse_source, parse_source_file): New function.
22323 (jcf_parse): Fixed typo.
22324 (yyparse): Call parse_source_file () only.
22325 (process_zip_dir): Fixed typo, fix zdir->filename_length when
22326 writing the real class name back in the zip directory entry.
22327 (find_in_current_zip): IDENTIFIER_CLASS_VALUE may be null.
22328 (jcf_figure_file_type): Fixed bogus alloc and bcopy.
22329 *jcf.h: (typedef struct JCF): New fields java_source and zipd.
22330 (find_class): Prototype fixed.
22331 *lex.c: Added 1998 time stamp.
22332 Removed all static global variables, moved into the parser
22333 context data structure.. Now include unistd.h if SEEK_SET not
22334 defined.
22335 (java_init_lex): Rewritten.
22336 (java_sneak_unicode): Modified current unicode access in current line.
22337 (java_unget_unicode): Likewise.
22338 (java_allocate_new_line): New allocation management.
22339 (java_read_char): Modified access and storage of unget_utf8_value.
22340 New way of processing current unicode.
22341 (java_store_unicode, java_read_unicode): Fixed typo in declaration.
22342 (java_get_unicode): Now use the parser context.
22343 (java_lineterminator): Likewise.
22344 (java_lex): Now used java_lval argument (pointer to YYSTYPE), part
22345 of the reentrant parser implementation. Function now use the
22346 parser context data structure and java_lval. Fixed production of
22347 the float and double constant "out of range" error message. Fixed
22348 obstack use. Return integer value when hitting a modifier. Now
22349 return type for TRUE, FALSE and other predefined types. Return
22350 identifier as a TREE_LIST list containing the current line context
22351 as the TREE_VALUE sub-node.
22352 (java_unicode_2_utf8): Fixed typo in declaration.
22353 (java_lex_error): Now use the parser context data structure.
22354 *lex.h: Added 1998 time stamp.
22355 (struct java_line): New fields ref_count and next.
22356 (JAVA_LINE_CHECK, JAVA_LINE_MARK, JAVA_LINE_CHAIN,
22357 JAVA_LINE_UNMARK, ID_NAME, ID_CL): New macros.
22358 (JAVA_FLOAT_RANGE_ERROR, JAVA_INTEGRAL_RANGE_ERROR, UNGETC): Fixed.
22359 *parse.h: Added 1998 time stamp.
22360 (java_parse_source_file): Renamed from parse_source_file.
22361 (YYERROR_NOW, YYNOT_TWICE): Fixed.
22362 (CLASS_MODIFIERS, FIELD_MODIFIERS, METHOD_MODIFIERS,
22363 INTERFACE_MODIFIER, INTERFACE_METHOD_MODIFIERS,
22364 JAVA_MODIFIER_CTX_UNMARK, IC_DECL, IC_DEPEND, DEPEND_DECL,
22365 THIS_MODIFIER_ONLY, ABSTRACT_CHECK, BEGIN_ONLY_PASS,
22366 END_ONLY_PASS, ELSE_ONLY_PASS, exit_java_complete_class,
22367 CLASS_OR_INTERFACE, INCOMPLETE_P): New macros.
22368 (struct parser_ctxt): New data structure to keep the parser context.
22369 *parse.y: Added 1998 time stamp, got rid of static global variables.
22370 (java_error_count, ctxp): New global variables.
22371 (%union): New value field.
22372 (numeric_type, integral_type): Rules removed.
22373 (primitive_type): Rule defined to handle integral, float, double and
22374 boolean types.
22375 (qualified_name, package_declaration,
22376 single_type_import_declaration, type_import_on_demand_declaration,
22377 modifiers, class_declaration, super, interfaces,
22378 interface_type_list, class_body, field_declaration,
22379 field_declaration, variable_declarators, variable_declarator,
22380 variable_declarator_id, method_declaration, method_header,
22381 formal_parameter_list, formal_parameter, method_body, block,
22382 static, interface_declaration, extends_interfaces,
22383 abstract_method_declaration, local_variable_declarators): Rules now
22384 define actions.
22385 (force_error, do_warning): New global statics.
22386 (push_parser_context, parser_context_save_global,
22387 parser_context_restore_global, pop_parser_context): New functions.
22388 (yyerror): Now uses the global parser context. Fixed use of obstack.
22389 (parse_error, parse_error_context, parse_warning_context,
22390 java_accstring_lookup, redefinition_error, check_modifiers,
22391 parser_add_interface, create_interface, create_class, find_field,
22392 duplicate_declaration_error, register_fields, method_header,
22393 check_modifiers_consistency, check_abstract_method_header,
22394 method_declarator, parser_qualified_classname,
22395 parser_check_super_interface, parser_check_super,
22396 parser_chain_incomplete_item, java_check_circular_reference,
22397 layout_class_from_source, java_complete_class,
22398 complete_method_decl, resolve_class, complete_class_report_errors,
22399 java_check_final, check_method_redefinition,
22400 java_check_regular_methods, java_check_abstract_methods,
22401 java_check_methods, lookup_java_interface_method2,
22402 lookup_java_method2, lookup_cl, find_name_in_single_imports,
22403 process_imports, find_in_imports, read_import_entry,
22404 read_import_dir, find_in_imports_on_demand,
22405 check_pkg_class_access, not_builtin_p, declare_local_variables,
22406 source_start_java_method, java_generate_parsed_class): New
22407 functions.
22408 *typeck.c: (signature_include_return): New global variable.
22409 (build_java_signature): Use SIGNATURE_INCLUDE_RETURN figure whether
22410 to add the function returned type in the signature.
22411
22412 1998-02-09 Brendan Kehoe <brendan@cygnus.com>
22413
22414 * jcf-io.c (open_in_zip): Use strncmp and LEN.
22415
22416 1998-01-29 Dave Brolley <brolley@cygnus.com>
22417
22418 * Make-lang.in (java.info): Added.
22419 (java.install-info): Added
22420
22421 1998-01-27 Brendan Kehoe <brendan@cygnus.com>
22422
22423 * Makefile.in (clean): Also remove java/parse.c.
22424
22425 1998-01-26 Brendan Kehoe <brendan@cygnus.com>
22426
22427 Add a pair of -fbounds-check/-fno-bounds-check options.
22428 * lang.c (lang_decode_option): Add code to grok arguments.
22429 (flag_bounds_check): Add decl.
22430 (lang_f_options): New array w/ the option in it.
22431 * java-tree.h (flag_bounds_check): Add decl.
22432 * lang-options.h: New file.
22433 * expr.c (build_java_arrayaccess): Use flag_bounds_check instead
22434 of a static macro value.
22435 (JAVA_ARRAY_EXCEPTION): Delete macro.
22436
22437 1998-01-23 Per Bothner <bothner@cygnus.com>
22438
22439 * typeck.c (build_java_array_type): Fix two bugs in previous change.
22440 * expr.c (build_anewarray): Add missing promote_type.
22441
22442 1998-01-22 Per Bothner <bothner@cygnus.com>
22443
22444 Add array types with known length to optimize bounds checking.
22445 * typeck.c (build_java_array_type): Take length parameter.
22446 (java_array_type_length, build_prim_array_type): New functions.
22447 * java-tree.h: Update for new functions.
22448 * expr.c, typeck.c, verify.c: Update build_java_array_type calls.
22449 * class.c: Use build_prim_array_type.
22450 * expr.c (can_widen_reference_to): Handle known-length array types.
22451 (verify_jvm_instructions): Keep track of integer push instructions
22452 followed by newarray/anewarray, so we can build known-length arrays.
22453 (JAVA_ARRAY_DATA_OFFSET): Replace by ...
22454 (java_array_data_offset): New function.
22455 (build_java_array_length_access): New function. Optimize if constant.
22456 (build_java_arrayaccess): Constant fold bounds check.
22457 (expand_java_newarray, expand_java_anewarray): Replaced by ...
22458 (build_newarray, build_anewarray): New functions.
22459 (ARRAY_NEW_NUM, ARRAY_NEW_PTR): Use build_{a,}newarray.
22460 * verify.c (merge_types): Handle known-lengh array types.
22461
22462 1998-01-19 Per Bothner <bothner@cygnus.com>
22463
22464 * expr.c (expand_byte_code): Fix performace bug, which caused
22465 searching linenumber_table to be linear rather than constant.
22466
22467 1997-12-12 Per Bothner <bothner@cygnus.com>
22468
22469 * Makefile.in (BISON, BISONFLAGS): Add missing macros.
22470
22471 * decl.c, java-tree.h (soft_fmod_node): New global.
22472 * decl.c (init_decl_processing): Define __builtin_fmod.
22473 * expr.c (build_java_binop): Implement TRUNC_MOD_EXPR for REAL_TYPE
22474 using __builtin_fmod.
22475
22476 1997-12-04 Alexandre Petit-Bianco <apbianco@cygnus.com>
22477
22478 * keyword.h: New file, output of keyword.gperf as processed by
22479 gperf.
22480 * lex.c (java_lex_init): Initialize java_error_flag.
22481 * parse.c (YYERROR_NOW): Uses java_error_flag.
22482 * parse.y: New static java_error_flag. Useless definition of
22483 buffer_error gone.
22484 * parse.y (java_error): Portable error recovery using
22485 java_error_flag (not yet completely tuned).
22486
22487 1997-12-04 Brendan Kehoe <brendan@lisa.cygnus.com>
22488
22489 * Makefile.in (parse.c): Use $(srcdir) for parse.y.
22490
22491 1997-12-03 Alexandre Petit-Bianco <apbianco@cygnus.com>
22492
22493 * Makefile.in: (JAVA_OBJS): New object jcf-parse.o.
22494 (parse.c, lex.c, keyword.h): New rules for Java source code
22495 front-end.
22496 * parse.c: Renamed into jcf-parse.c.
22497 * jcf-parse.c (yyparse): Invoke the parser to process Java source code.
22498 * keyword.gperf: New file, Java keywords.
22499 * parse.y: New file, Java language grammar.
22500 * parse.h: New file, Java language grammar definitions.
22501 * lex.c: New file, Java language lexer.
22502 * lex.h: New file, Java language lexer definitions.
22503
22504 1997-12-03 Per Bothner <bothner@cygnus.com>
22505
22506 * decl.c (clinit_identifier_node), java-tree.h: New global.
22507 * java-tree.h (IS_METHOD_INIT_P, IS_METHOD_CLINIT_P): Removed.
22508 * verify.c (verify_jvm_instructions): Inline use of removed macros.
22509 * expr.c (expand_java_field_op): Check for invalid assignment
22510 to final field.
22511
22512 * jcf-reader.c (get_attribute): Test for wrong attribute length.
22513
22514 1997-10-27 Per Bothner <bothner@cygnus.com>
22515
22516 * verify.c (verify_jvm_instructions): When processing a handler,
22517 attempt to set the current_subr to the right value.
22518 (More complicated code combines Sep 17 and Oct 22 versions.)
22519
22520 1997-10-24 Per Bothner <bothner@cygnus.com>
22521
22522 * class.c (push_class): Figure out (guess) name of source file.
22523 * parse.c (set_source_filename): Set DECL_SOURCE_FILE of class decl.
22524 (give_name_to_class): Don't guess source name; use DECL_SOURCE_FILE.
22525 (parse_class_file): Change return type from int to void.
22526 Call debug_start_source_file/debug_end_source_file.
22527
22528 * expr.c (build_java_binop): Fix masking 2nd operand.
22529 * decl.c (init_decl_processing): Set sizetype first.
22530
22531 1997-10-22 Per Bothner <bothner@cygnus.com>
22532
22533 * verify.c (verify_jvm_instructions): Don't set current_subr to NULL.
22534 (Revert Sep 17 change.)
22535
22536 1997-10-21 Alexandre Petit-Bianco <apbianco@cygnus.com>
22537
22538 * parse.c (process_zip_dir): Skip ZIP entries not bearing the
22539 .class extension in their name and fix thing so we don't process
22540 them parse_zip_file_entries().
22541 (parse_zip_file_entries): Cleaned unused local variables.
22542
22543 1997-10-20 Per Bothner <bothner@cygnus.com>
22544
22545 * expr.c (can_widen_reference_to): Allows equal array element types.
22546 (expand_byte_code): PRE_RET must expand OPERAND_VALUE (to get index).
22547 * jcf-dump.c (RET): Get (and print) index.
22548
22549 * verify.c (verify_jvm_instructions case OPCODE_anewarray):
22550 Promote element type to POINTER_TYPE.
22551
22552 1997-10-20 Alexandre Petit-Bianco <apbianco@cygnus.com>
22553
22554 * jcf-reader.c, parse.c: (parse_zip_file, process_zip_dir,
22555 find_in_current_zip, jcf_figure_file_type): Moved from
22556 jcf-reader.c to parse.c.
22557 * zextract.c: (read_zip_archive): takes file_comment_length possible
22558 field into account.
22559
22560 1997-10-20 Per Bothner <bothner@cygnus.com>
22561
22562 * verify.c (verify_jvm_instructions): Var can also be promoted to int.
22563
22564 * verify.c (merge_types): Handle array types even better ...
22565
22566 1997-10-17 Per Bothner <bothner@cygnus.com>
22567
22568 * expr.c (java_stack_pop): Fix use of NULL_TREE for TYPE_SECOND.
22569
22570 * java-tree.h (PUSH_FIELD): Set DECL_ARTIFICIAL.
22571 * class.c (make_class_data): Don't build fields_decl if no fields.
22572 When building fields_decl, skip if DECL_ARTIFICIAL.
22573
22574 * expr.c (java_stack_swap): Update stack_type_map.
22575 * verify.c (merge_types): Handle array types better.
22576
22577 1997-10-15 Per Bothner <bothner@cygnus.com>
22578
22579 * class.c (add_field): Don't promote short integral fields to
22580 int any more (unless JAVA_PROMOTE_TO_INT), since Kaffe doesn't.
22581 * expr.c (push_value): Promote and convert short integral values.
22582
22583 * decl.c, java-tree.h (integer_two_node): New constant node.
22584 * verify.c (merge_types): Check for TYPE_RETURN_ADDR.
22585
22586 1997-10-15 Alexandre Petit-Bianco <apbianco@cygnus.com>
22587
22588 * class.c (append_gpp_mangled_type): Use function argument
22589 unpromoted type to generate mangled name.
22590
22591 1997-10-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
22592
22593 * constants.c (build_constant_data_ref): Now uses current_class
22594 instead of main_class.
22595 (build_constants_constructor): Now uses current_class instead of
22596 main_class.
22597 * zipfile.h: (struct ZipFileCache): Now defined here. Declaration
22598 of the global variable SeepZipFiles done here.
22599 * zextract.c (read_zip_archive): extra_field optional field taken
22600 into account while computing the position of the class file in the
22601 archive.
22602 * verify.c (verify_jvm_instructions): Use current_jcf to search
22603 the constant pool.
22604 * parse.c (load_class): First search for the class to load in the
22605 current zip file. Saves current_jcf (restored before returning
22606 from that function). Don't call JCF_FINISH in the class was found
22607 in the current ZIP file.
22608 (jcf_parse): If the class was found in the current ZIP file, save
22609 its tree_constant_pool (for later reuse).
22610 (parse_class_file): New function. Process each method defined in
22611 the current class and record the class as to be later registered.
22612 (yyparse): Rewritten. Figure the type of the current file and switch
22613 accordingly.
22614 * lang.c: New global variable current_jcf.
22615 (lang_init): Removed compiling_from_source test (done later, in
22616 yyparse). Removed call the jcf_parse ().
22617 * jcf.h (JCF_ZIP, JCF_CLASS, JCF_SOURCE): New defined values.
22618 (typedef struct JCF): New fields seen_in_zip (to mark a class found
22619 in the current ZIP file) and zip_offset (offset to the class data in
22620 the current zip file).
22621 * jcf-reader.c: zipfile.h included.
22622 localToFile: New ZipFileCache static global variable
22623 (parse_zip_file_entries): New function. Browse the current ZIP
22624 file directory and process each class found.
22625 (process_zip_dir): New function. Register each class found in the
22626 ZIP file directory. The class aren't parsed but a valid JCF is
22627 link to each of them.
22628 (find_in_current_zip): New function. Search for a class in the
22629 current ZIP file directory. If found, prepare the class so that it
22630 can be loaded.
22631 (jcf_figure_file_type): New function. Examine the file structure
22632 to figure a class file, a ZIP file. If none of these categories are
22633 matched, a source file is assumed.
22634 * jcf-io.c: Removed definition of ZipFileCache (moved in zipfile.h).
22635 SeenZipFile: New global variable.
22636 (open_in_zip): Use zipmember's length to accelerate the search for
22637 a member. If zipmember was NULL and zip file successfully read,
22638 return 0.
22639 * java-tree.h: New global variable current_jcf declared. Added
22640 declaration for current_constant_pool_tags, current_constant_pool_data,
22641 current_constant_pool_length, current_constant_pool_data_ref.
22642 (struct lang_type): Augmented with two fields. struct JCF *jcf (to
22643 store the JCF of classes seen in a zip file) and tree *constant_pool
22644 (to save a loaded class constant pool). current_class declared here.
22645 * expr.c (expand_invoke): Use current_jcf instead of main_jcf to
22646 retrieve method_ref_constant.
22647 (PUSHC): java_push_constant_from_pool now uses current_jcf.
22648 (OBJECT): get_class_constant now uses current_jcf.
22649 (ARRAY_NEW_PTR): get_class_constant now uses current_jcf.
22650 (ARRAY_NEW_MULTI): get_class_constant now uses current_jcf.
22651 (expand_invoke): Now uses current_class instead of main_class
22652 (build_class_init): Now uses current_class instead of main_class
22653 * class.c: New static global variable registered_class.
22654 (register_class): New function.
22655 (emit_register_class): Modified to use registered_class instead of
22656 main_class
22657 (is_compiled_class): Now take into account class seen in the archive.
22658
22659 1997-10-06 Per Bothner <bothner@cygnus.com>
22660
22661 * except.h: Renamed to: java-except.h.
22662 * parse.c, except.c, expr.c, verify.c: Update #include accordingly.
22663 * except.c: Add semi-working (commented out) implementation.
22664
22665 * expr.c (expand_iinc): Add needed flush_quick_stack.
22666 * parse.c (set_source_filename): New function.
22667 (give_name_to_class): Set input_filename from package.classname.java.
22668
22669 * jcf-io.c (find_class): Don't look first in ".".
22670
22671 1997-10-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
22672
22673 * zextract.c (read_zip_archive): Now takes into account the
22674 extra_field field.
22675 * expr.c (can_widen_reference_to): Modified to handle sub-interfaces.
22676
22677 1997-09-20 Per Bothner <bothner@cygnus.com>
22678
22679 * constants.c, java-tree.h (build_internal_class_name): New function.
22680 (alloc_class_constant): Re-implement using build_internal_class_name.
22681 * class.c (make_class_data): Likewise.
22682 * class.c (hashUtf8String): Make hash algorithm match String.hashCode.
22683
22684 1997-09-17 Per Bothner <bothner@cygnus.com>
22685
22686 * verify.c (verify_jvm_instructions): Temporarily set current_subr
22687 to NULL before pushing an exception handler target.
22688
22689 * expr.c (flush_quick_stack): Save from low stack indexes to high.
22690 (java_stack_swap, java_stack_dup): Re-write to be safe from
22691 clobbering registers.
22692 (build_class_init): New function.
22693
22694 1997-09-17 Alexandre Petit-Bianco <apbianco@cygnus.com>
22695
22696 * typeck.c (build_java_array_type): Temporary use
22697 permanent_obstack to create the array 'length' field.
22698 * expr.c (lookup_label): Temporay use permanent_obstack to create
22699 label if not found.
22700 * class.c (push_super_field): Tempory use permanent_obstack.
22701
22702 1997-09-15 Alexandre Petit-Bianco <apbianco@cygnus.com>
22703
22704 * typeck.c (type_for_mode): Now handles double_type_node and
22705 float_type_node.
22706 * verify.c (verify_jvm_instructions): The instruction following
22707 the wide bytecode is checked. OPCODE_ret added to the list of
22708 wide.
22709
22710 1997-09-11 Alexandre Petit-Bianco <apbianco@cygnus.com>
22711
22712 * class.c (make_class): Temporary use permanent_obstack. Set the
22713 class CLASS_P field to 1.
22714 (push_class): Temporary use permanent_obstack.
22715 (set_super_info): Temporary use permanent_obstack.
22716 (add_method): Temporary use permanent_obstack, set
22717 METHOD_TRANSIENT().
22718 (add_field): Temporary use permanent_obstack. Sets
22719 FIELD_VOLATILE() and FIELD_TRANSIENT().
22720 (build_class_ref): Temporary use permanent_obstack if the class
22721 isn't compiled.
22722 (build_static_field_ref): Temporary use permanent_obstack when
22723 creating field's rtl.
22724 (get_access_flags_from_decl): Handle ACC_VOLATILE, ACC_TRANSIENT,
22725 ACC_SYNCHRONIZED, ACC_NATIVE, ACC_ABSTRACT flags for methods
22726 and fields. Function finalized, as far as flag handling.
22727 (push_class_static_dummy_field): Temporary use permanent_obstack.
22728 (emit_register_class): Force generation of class registration at
22729 -O3 or deeper.
22730 * decl.c (end_java_method): Call permanent_allocation() before
22731 returning.
22732 * expr.c (can_widen_reference_to): Added comment to interface
22733 handling, fixed typo.
22734 (lookup_field): Now uses CLASS_P() to correct FIXME
22735 (expand_invoke): Verification on public && !static &&
22736 !abstract moved into soft_lookupinterfacemethod (kaffe).
22737 Use Object class dtable if objectref is an array when expanding
22738 invokeinterface.
22739 (java_push_constant_from_pool): Temporary use permanent_obstack
22740 for CONSTANT_string
22741 * parse.c (get_ref_constant): Temporary use permanent_obstack to
22742 create constant references.
22743 (get_constant): Temporary use permanent_obstack to create constant.
22744 (load_class): Temporary use permanent_obstack to load class.
22745 (jcf_parse): Temporary use permanent_obstack to perform class
22746 layout.
22747 * typeck.c: (parse_signature_string): Temporary use permanent_obstack.
22748 (build_java_signature): Temporary use permanent_obstack.
22749 * verify.c: (verify_jvm_instruction): removed unnecessary verification
22750 on ACC_SUPER flag.
22751 * java-tree.h (METHOD_NATIVE, METHOD_TRANSIENT): Defined.
22752 (FIELD_VOLATILE, FIELD_TRANSIENT): Defined.
22753 (CLASS_P): Defined
22754
22755 1997-09-11 Per Bothner <bothner@cygnus.com>
22756
22757 * class.c (append_gpp_mangled_type): Fix typo.
22758 (emit_register_class): Use main_class to get class object, rather
22759 than looking for no-longer-existing static decl starting with _CL.
22760 * typeck.c (parse_signature_type): Promote array element type
22761 if it is a RECORD_TYPE.
22762
22763 1997-09-10 Per Bothner <bothner@cygnus.com>
22764
22765 * class.c (push_class_static_dummy_field): New function.
22766 (mangle_static_field): New. Do G++-style mangling of static fields.
22767 (layout_class): Mandle static fields here, not in add_field.
22768 (build_class_ref): The class object is now a dummy static field.
22769 * decl.c (find_local_variable): Look for best, instead of first match.
22770 * expr.c (push_type): Always promote_type, not just for RECORD_TYPE.
22771 (build_java_athrow): Don't check here if exception is Throwable.
22772 * java-tree.h (TYPE_UNSET): Renamed to TYPE_UNKNOWN.
22773 (TYPE_USED): Removed. No longer used ...
22774 * parse.c (jcf_parse): Call push_class_static_dummy_field.
22775 * verify.c (push_pending_label): New function.
22776 (push_pending_block): Renamed to check_pending_block.
22777 (merge_types): Remove unneeded suuport for TYPE_UNUSED.
22778 (verify_jvm_instructions): Only reset prev_eh_ranges (to force
22779 re-checking possible handlers) after a store (less wasted work).
22780 Check for null handler (finally) before calling add_handler.
22781 Various changes to (finally?) correctly handle try/finally.
22782
22783 1997-09-09 Brendan Kehoe <brendan@lisa.cygnus.com>
22784
22785 * class.c: Include stdio.h.
22786
22787 1997-09-04 Per Bothner <bothner@cygnus.com>
22788
22789 * expr.c (expand_invoke): Use COMPOUND_EXPR (and TREE_SIDE_EFFECTS)
22790 to make sure class is initialized before static/special invoke.
22791
22792 * verify.c (verify_jvm_instructions): On a store instruction,
22793 call find_local_variable to force pre-allocation of decl and rtx.
22794 * decl.c (push_jvm_slot): Set DECL_REGISTER on stack slots.
22795
22796 1997-09-03 Per Bothner <bothner@cygnus.com>
22797
22798 * class.c (build_class_ref): Strip off "promoted_" if need be.
22799 (make_field_value): Call build_java_signature when needed.
22800 (layout_class): Don't make_function_rtl if METHOD_ABSTRACT.
22801 * expr.c (build_java_athrow): Don't push_value of exception.
22802 (build_java_binop): Implement COMPARE_L_EXPR and COMPARE_G_EXPR to
22803 match specification of [fd]cmp[lg] for NaNs.
22804 (expand_byte_code): Add support for exception handler ranges.
22805 * except.c: Add skeleton for EH code-generation.
22806 * verify.c (merge_types): Treat all promoted integral types as equal.
22807 * constants.c (build_constants_constructor): To force creation of
22808 current_constant_pool_data_ref, call build_constant_data_ref.
22809
22810 * javaop.def (lload): Fix typo.
22811 * jcf-dump.c (main): Clear filename to prevent possibly-bad free.
22812
22813 1997-09-02 Brendan Kehoe <brendan@lisa.cygnus.com>
22814
22815 * parse.c: Don't include function.h.
22816
22817 1997-08-27 Per Bothner <bothner@cygnus.com>
22818
22819 * except.[ch]: New files.
22820 * Makefile.in (JAVA_OBJS): Add except.o
22821 * expr.c: Temporary warning about unimplemented exceptions.
22822 * verify.c: Verify exception handlers.
22823
22824 * jcf-dump.c (disassemble_method): Print exception table.
22825
22826 1997-08-27 Alexandre Petit-Bianco <apbianco@cygnus.com>
22827
22828 * expr.c (verify_jvm_instructions): Started a thorough
22829 verification of invoke* bytecodes.
22830 (expand_byte_code): flush quick stack if PC is the target of a
22831 branch. and undef RET (conflicting with config/i386/i386.h).
22832 (expand_java_arrayload): Fixed bogus cast, when Boolean type is
22833 used.
22834 (expand_invoke): Now handles invokeinterface and do more
22835 verification according to the bytecode.
22836 (lookup_field): Don't try to load the class if processing
22837 dtable_type.
22838 (can_widen_reference_to): Now handles interfaces.
22839 * decl.c (init_decl_processing): New global variable
22840 soft_lookupinterfacemethod_node, declared in java-tree.h.
22841 Call set_super_info on string_type_node.
22842 * java-tree.h (CLASS_INTERFACE, CLASS_ABSTRACT, CLASS_SUPER): Now
22843 defined.
22844 * class.c (set_super_info): Fills the CLASS_* flags according to
22845 access_flags.
22846 (get_access_flags_from_decl): Handles all class flags.
22847
22848 1997-08-26 Per Bothner <bothner@cygnus.com>
22849
22850 * class.c (add_method): Zero out newly-allocated DECL_LANG_SPECIFIC.
22851 * parse.c (yyparse): Check for abstract method, and missing code.
22852 * expr.c (expand_byte_code): Change interface.
22853 * lang.c (put_decl_node): Print promoted types prettier.
22854 * verify.c (verify_jvm_instruction): Change interface.
22855 Partial support for scanning exception table.
22856 For load instructions, handle promoted integral types.
22857
22858 1997-08-21 Per Bothner <bothner@cygnus.com>
22859
22860 * verify.c: New file, with contents moved from expr.c.
22861 * expr.c: Bunch of stuff (mostly verification) moved to verify.c.
22862 * typeck.c (is_array_type_p): Moved here from expr.c.
22863 * java-tree.h: Add some now-needed function declarations.
22864 * Makefile.in (JAVA_OBJS): Added verify.o.
22865
22866 1997-08-20 Alexandre Petit-Bianco <apbianco@cygnus.com>
22867
22868 * class.c (add_method): Sets the METHOD_SYNCHRONIZED flag, sets the
22869 METHOD_ABSTRACT flag.
22870
22871 * java-tree.h (METHOD_SYNCHRONIZED): Set to DECL_LANG_FLAG_4.
22872 (IS_METHOD_CLINIT_P, IS_METHOD_INIT_P): New macros.
22873 (METHOD_ABSTRACT): Set to DECL_LANG_FLAG_5
22874
22875 * decl.c (soft_monitorenter_node, soft_monitorexit_node): New global
22876 variables.
22877 (start_java_method): Hook for SYNCHRONIZED methods.
22878
22879 * expr.c (build_java_jsr, build_java_ret): New functions
22880 (JSR,PRE): New macros
22881 (PRE_TABLE_SWITCH, PRE_LOOKUP_SWITCH): Fixed and secured.
22882 (verify_jvm_instructions): tableswitch, lookupswitch,
22883 monitorenter, monitorexit, goto_w: verified.
22884 (LOOKUP_SWITCH, TABLE_SWITCH): Fixed generation of default: label
22885 (build_java_monitor): New function.
22886 (MONITOR_OPERATION): Modified to call build_java_monitor()
22887 (verify_jvm_instructions): Started a thorough verification of
22888 invoke* bytecodes.
22889
22890 1997-08-19 Per Bothner <bothner@cygnus.com>
22891
22892 Support verification of jsr/ret subroutines (used for try/finally).
22893 * decl.c (return_address_type_node): New type node.
22894 * java-tree.h (LABEL_RETURN_LABEL, LABEL_RETURN_TYPE_STATE,
22895 RETURN_MAP_ADJUSTED, LABEL_RETURN_LABELS, LABEL_IN_SUBR,
22896 LABEL_SUBR_START, LABEL_SUBR_CONTEXT, BCODE_VERIFIED): New macros.
22897 (TYPE_UNSET, TYPE_SECOND, TYPE_NULL, TYPE_RETURN_ADDR, TYPE_UNUSED,
22898 TYPE_USED): New macros for special types in type_map.
22899
22900 * java-tree.h (BCODE_JUMP_TARGET): Renamed to BCODE_TARGET.
22901 (BCODE_BACKWARDS_TARGET, CODE_FORWARDS_TARGET): Replaced by
22902 BCODE_JUMP_TARGET.
22903 * expr.c (expand_byte_code): Fix logic to warn of unused instructions.
22904
22905 * expr.c (can_widen_reference_to): New function.
22906 (pop_type): Use it.
22907 (merge_type_state): Support handling start of subroutine.
22908 (push_pending_block): Return char* error message, instead of calling
22909 fatal on an error. Also handle subroutines.
22910 (verify_jvm_instructions): Handle errors from push_poending_block.
22911 Support jsr and ret instructions.
22912
22913 1997-08-19 Per Bothner <bothner@cygnus.com>
22914
22915 * jcf-io.c (find_classfile): Fix thinko.
22916 * jcf-dump.c: Add CONVERT2 (to match changed javaop.def).
22917
22918 1997-08-12 Jason Merrill <jason@yorick.cygnus.com>
22919
22920 * Makefile.in (BISON): Remove.
22921
22922 1997-08-07 Per Bothner <bothner@cygnus.com>
22923
22924 * Makefile.in: Convert to autoconf.
22925 * config-lang.in (outputs): Added java/Makefile.
22926
22927 * Make-lang.in, lang-specs.h, config-lang.in, Makefile.in:
22928 Rename cc1java to jc1.
22929
22930 * lang.c (init_parse, finihs_parse): New functions #ifdef USE_CPPLIB.
22931 * Makefile.in (INTERNAL_CFLAGS): Add @extra_c_flags.
22932
22933 * class.c (class_depth): Do load_class if needed.
22934
22935 Mostly better verification.
22936 * decl.c (pushdecl): Set TYPE_STUB_DECL for a type.
22937 (init_decl_processing): Change return type of soft_checkcast.
22938 * expr.c (expand_java_CHECKCAST): Do push_value of the "casted" value.
22939 * lang.c (put_decl_string, put_decl_node, lang_printable_name,
22940 lang_print_error): New functions.
22941 (lang_init): Set global hook print_error_function to lang_print_error.
22942 * expr.c: In the type_map ptr_type_node is only used for null now.
22943 (pop_type, merge_types): Hence ptr_type_node matches any reference.
22944 (merge_types): Dererence pointer to record types before comparing.
22945 (decode_newarray_type, merge_types): On error just return NULL.
22946 (build_java_binop): Add preliminary implementation (with warning)
22947 for COMPARE_L_EXPR and COMPARE_G_EXPR (i.e. [fd]cmp[lg]).
22948 (lookup_label): Set DECL_IGNORED_P (for dwarf2out).
22949 (expand_compare, expand_java_goto, expand_java_call): Don't
22950 push_pending_block, since that only makes sense when verifying.
22951 (merge_type_state): Different return codes.
22952 (push_pending_block): A block may need to be verified more than once.
22953 (expand_byte_code): Warn about unused code at code generation time.
22954 (verify_jvm_instruction): Changed logic, since code may need to be
22955 re-verified if type-state has changed. Also, better error handling.
22956 Implement acmpeq, acmpne, pop, pop2, swap, checkcast, instanceof.
22957 Improve newarray, anewarray, ?aload, athrow,
22958 * java-tree.h (LABEL_CHANGED): New macro.
22959
22960 1997-08-05 Alexandre Petit-Bianco <apbianco@cygnus.com>
22961
22962 * decl.c (soft_athrow_node): New global variable initialized.
22963 * javaop.def (i2b, i2c, i2s): Invoke CONVERT2
22964 * typeck.c (convert): Added support for REAL_TYPE.
22965 (convert_to_char): New function.
22966 (convert): Handle CHAR_TYPE.
22967 * expr.c (expand_java_arraystore): Modified because CHAR/BYTE/BOOLEAN/
22968 SHORT now expect INT but store as CHAR/BYTE/BOOLEAN/SHORT.
22969 (expand_java_arrayload): CHAR/BYTE/BOOLEAN/SHORT now convert result to
22970 promoted type.
22971 (verify_jvm_instructions): Added break a the end of bogus unop: label.
22972 (OPCODE_<b|c|s>astore): Pop an int operand from the type stack
22973 (OPCODE_<b|c|s>astore): Push the promoted type onto the stack
22974 (process_jvm_instruction): New macro CONVERT2 for i2c, i2s and i2b.
22975 (JAVA_ARRAY_LENGTH_OFFSET, JAVA_ARRAY_DATA_OFFSET): Modified
22976 to Use The Right Things.
22977 (pop_type): Accept CHAR/BYTE/BOOLEAN/SHORT promoted type as
22978 compatible with INT. BOOLEAN is made equivalent to BYTE.
22979 (OPCODE_athrow, OPCODE_aconst_null, OPCODE_ifnull,
22980 OPCODE_ifnonnull): Now supported.
22981 (build_java_athrow): New function.
22982
22983 1997-08-04 Per Bothner <bothner@cygnus.com>
22984
22985 Rename method name <init> to match G++ (and fix mangling).
22986 * class.c (layout_class): Replace method name of <init> by class name.
22987 (make_method_value): Do inverse renaming of constructor from <init>.
22988 * java-tree.h (DECL_CONSTRUCTOR_P): New macro.
22989 * typeck.c (lookup_java_constructor): New function.
22990 * expr.c (expand_invoke): If method_name is <init>, call
22991 lookup_java_constructor to find constructor.
22992
22993 * parse.c (get_constant): Handle CONSTANT_Float and CONSTANT_Double.
22994
22995 1997-08-01 Alexandre Petit-Bianco <apbianco@cygnus.com>
22996
22997 * parse.c (get_class_constant): Modified to handle array "classes"
22998 * typeck.c (set_local_type): Bug fixed when filling type_map[] with
22999 wide type.
23000 (convert): Modified to handle real type.
23001 * java-tree.h (soft_badarrayindex_node, soft_anewarray_node,
23002 soft_multianewarray, soft_newarray_node, soft_throw_node): New global
23003 variables declared.
23004 * decl.c (soft_badarrayindex_node, soft_anewarray_node,
23005 soft_multianewarray, soft_newarray_node, soft_throw_node): New
23006 global variables initialized.
23007 (find_local_variable): Handles the case of a pointer
23008 (end_java_method): Restore the use of one more scope
23009 * expr.c (build_java_arraynull_check, build_java_arrayaccess,
23010 build_java_array_length_access, expand_java_arrayload,
23011 expand_java_arraystore, expand_java_array_length,
23012 expand_java_multianewarray, expand_java_anewarray,
23013 build_java_check_indexed_type, is_array_type_p,
23014 build_java_throw_out_of_bound_exception): New functions.
23015 (STORE_INTERNAL): Now forces type of the decl to be type of the value.
23016 (OPCODE_arraylength, OPCODE_newarray, OPCODE_<t>astore,
23017 OPCODE_<t>aload): Implemented code for verification.
23018 (ARRAY_STORE, ARRAY_LOAD, ARRAY_LENGTH, ARRAY_NEW_PTR, ARRAY_NEW_NUM
23019 ARRAY_NEW_MULTI): Macro defined.
23020 (CONVERT): Modified to invoke convert().
23021 (case OPCODE_aload2): Fixed index typo from 2 to 1.
23022
23023 1997-07-31 Per Bothner <bothner@cygnus.com>
23024
23025 * class.c (push_class): Set DECL_ARTIFICIAL (for dbxout.c).
23026 (build_class_ref, is_compiled_class): Handle pointer-to-record types.
23027 (make_class_data): Field name needs '/' as package prefix.
23028 * expr.c (type_stack_dup, java_stack_dup): Fix fencepost errors.
23029
23030 1997-07-25 Per Bothner <bothner@cygnus.com>
23031
23032 Implement debug information for local variables.
23033 * java-tree.h (DECL_CODE_LENGTH, DECL_ARG_SLOT_COUNT,
23034 DECL_LOCAL_SLOT_NUMBER, DECL_LOCAL_START_PC, DECL_LOCAL_END_PC,
23035 DECL_LOCAL_SLOT_CHAIN): New macros.
23036 (struct lang_decl_var): New type.
23037 * parse.c (give_name_to_locals): Move to decl.c.
23038 * decl.c (give_name_to_locals): Re-written to Do The Right Thing.
23039 (start_java_method): Re-write parameter handling.
23040 (pending_local_decls): New global variable.
23041 (push_jvm_slot, maybe_pushlevels, maybe_poplevels): New functions.
23042 (find_local_variable): Accept pc so we can skips decls not in range.
23043 (struct binding_level): Add end_pc field.
23044 * expr.c (expand_byte_code): Call maybe_pushlevels and maybe_poplevels.
23045 (various): Change so current pc gets passed to find_local_variable.
23046
23047 * decl.c (init_decl_processing): Re-arrange fields in
23048 class_type_node and and method_type_node to match kaffe 0.9.1.
23049 * class.c (make_method_value, make_class_data): Update
23050 initializations to match.
23051
23052 1997-07-16 Per Bothner <bothner@cygnus.com>
23053
23054 * class.c (unicode_mangling_length, emit_unicode_mangled_name,
23055 append_gpp_mangled_name, append_gpp_mangled_type): New functions.
23056 (push_super_field): New function.
23057 (make_class_data): Handle inheritance of class static initializer.
23058 (layout_class): New name mangling.
23059 * constants.c (build_constant_data_ref): Init type of data array
23060 to a one-element array.
23061 (build_constants_constructor): Set DECL_SIZE from complete array type.
23062 * decl.c: Rename class_type, object_type etc to class_type_node,
23063 object_type_node etc. Make former inherit from latter.
23064 * expr.c (expand_invoke): Add cast of function address.
23065 * java-tree.h (TYPE_ARRAY_ELEMENT, PUSH_SUPER_VALUE): New.
23066 * parse.c (yyparse): Don't call layout_class here.
23067 * typeck.c (build_java_array_type): Set TYPE_ARRAY_ELEMENT.
23068
23069 1997-06-14 Per Bothner <bothner@cygnus.com>
23070
23071 * decl.c, class.c: Update method type to match latest Kaffe snapshot.
23072 * constants.c (lookup_name_constant): Renamed to alloc_name_constant.
23073 (alloc_class_constant): New.
23074 * expr.c (expand_invoke): Make sure method's class is initialized.
23075 * class.c (interits_from_p, emit_register_class): New functions.
23076 * parse.c (yyparse): Call emit_register_class.
23077
23078 1997-06-09 Per Bothner <bothner@cygnus.com>
23079
23080 * constants.c: New file, to handle constant pool.
23081 * Makefile.in (JAVA_OBJS): Add constants.o.
23082 * decl.c (init_decl_processing): Update, fix, finish various structs.
23083 (pushdecl_top_level): New.
23084 * parse.c (layout_class): Moved to class.c.
23085 * expr.c (java_push_constant_from_pool): New function.
23086 * class.c (build_class_ref): Make work fully
23087 (make_class_data): Emit super-class, constant pool, interface vector.
23088
23089 1997-06-03 Per Bothner <bothner@cygnus.com>
23090
23091 java-tree.h (DECL_SIGNATURE, BCODE_EMITTED): Remove.
23092 (LABEL_VERIFIED, BCODE_EXCEPTION_TARGET, TYPE_ARRAY_P): New.
23093 * class.c (class_depth): New function.
23094 (lookup_named_class): Replaced by new function lookup_class.
23095 * decl.c (object_type_node, string_type_node): New.
23096 Remove various types that we no longer need.
23097 * expr.c (verify_jvm_instructions): New separate verifier pass.
23098 (push_type, pop_type): New functions for verifier.
23099 (type_stack_dup, pop_argument_types, merge_types): Likewise.
23100 (expand_byte_code): Simplify, since we assume already verified.
23101 (expand_invoke): Now mostly works.
23102 * javaop.def: Rename ldc1->ldc, ldc2->ldc_w, ldc2w->ldc2_w.
23103 * lang.c (main_class): Move to parse.c. Don't make_class yet.
23104 * parse.c: Wait to allocate class object until we know its name.
23105 (layout_class): Calculate DECL_VINDEX for each virtual method.
23106 * typeck.c (get_array_type): Rename to ...
23107 (build_java_array_type): ... and provide working implementation.
23108 (build_java_signature): New function - build Java signature of type.
23109 (set_java_signature): New function - cache signature with type.
23110 (lookup_java_method): New function.
23111
23112 1997-05-06 Per Bothner <bothner@deneb.cygnus.com>
23113
23114 * class.c (ident_subst): Take extra SUFFIX parameter.
23115 (add_field): Set DECL_ASSEMBLER_NAME of static fields; more.
23116 (set_constant_value, build_static_field_ref, is_compiled_class): New.
23117 (build_class_ref): Actually implement.
23118 * decl.c, java-tree.h: Renamed some xx_type to xx_type_node.
23119 * decl.c (builtin_function): New.
23120 (init_decl_processing): Update for current Kaffe. Declare some
23121 builtin Kaffe functions.
23122 * expr.c (build_address_of): New.
23123 (expand_java_NEW, expand_java_INSTANCEOF, expand_java_CHECKCAST):
23124 Renamed (from expand_java_new etc), and added working implementations.
23125 (build_field_ref): Now also handle static fields.
23126 (expand_invoke): Implement invokestatic, and start implement rest.
23127 * java-opcodes.h: Use javaop.def to avoid duplicated list.
23128 * javaop.def: Rename invokevirt -> invokevirtual.
23129 * lang.c (use_handles): Removed.
23130 * parse.c: Add support for ConstantValue attribute.
23131 Handle nested loading of a class. (JPOOL_UTF): New.
23132
23133 1997-03-11 Per Bothner <bothner@deneb.cygnus.com>
23134
23135 * expr.c (expand_java_pushc): Support #ifndef REAL_ARITHMETIC case.
23136
23137 1997-02-27 Per Bothner <bothner@deneb.cygnus.com>
23138
23139 * Make-lang.in (java.install-man): New empty rule.
23140 * typeck.c (set_local_type): New function.
23141 * expr.c (STORE_INTERNAL): Call find_local_variable,
23142 not find_stack_slot. Call set_local_type.
23143
23144 1997-02-12 Per Bothner <bothner@kalessin.cygnus.com>
23145
23146 * java-tree.h: Various new macros for constructing RECORD_TYPEs,
23147 and building RECORD_TYPE CONSTRUCTORs.
23148 Also support for creating Utf8Const objects from an INDETIFIER_NODE.
23149
23150 * lang.c (use_handles): Change the default to 0.
23151 * decl.c: Define and build class_type, field_type, utf8const_type.
23152 * class.c (make_class_data, make_field_value,
23153 get_access_flags_from_decl, build_class_ref, build_utf8_ref,
23154 hashUtf8String, strLengthUtf8, mangled_classname:
23155 Functions to build reflective data structures.
23156 * parse.c (yyparse): Call make_class_data.
23157
23158 * jcf-io.c (open_class, find_classfile): New functions.
23159 * jcf-dump.c: Support reading classfile from explicitly-named
23160 class file (without CLASSPATH searching).
23161
23162 1996-10-24 Per Bothner <bothner@deneb.cygnus.com>
23163
23164 * jcf-reader.c: Add parameter list to HANDLE_CONSTANT_Utf8.
23165 * parse.c (JPOOL_UTF_LENGTH, JPOOL_UTF_DATA, HANDLE_CONSTANT_Utf8):
23166 Override jcf-reader macros so CONSTANT_Utf8 becomes tree node here.
23167 (get_constant): Now trivial for CONSTANT_Utf8.
23168
23169 * jcf.h: Make NEW_CPOOL the default.
23170 * jcf.h, jcf-reader.c, parse.c: Remove support for !NEW_CPOOL.
23171
23172 1996-10-24 Per Bothner <bothner@deneb.cygnus.com>
23173
23174 New directory.
23175
23176 \f
23177 Copyright (C) 1996-2015 Free Software Foundation, Inc.
23178
23179 Copying and distribution of this file, with or without modification,
23180 are permitted in any medium without royalty provided the copyright
23181 notice and this notice are preserved.