OSDN Git Service

f8d176c2e7182fa5af114b62cea14f084ff2497d
[pf3gnuchains/gcc-fork.git] / gcc / fortran / ChangeLog
1 2004-07-11  Joseph S. Myers  <jsm@polyomino.org.uk>
2
3         * f95-lang.c (set_block): Remove.
4         (gfc_clear_binding_stack): New.
5         (LANG_HOOKS_CLEAR_BINDING_STACK): Define.
6         (struct binding_level): Remove block_created_by_back_end.
7         (clear_binding_level): Likewise.
8         (poplevel): Don't handle block_created_by_back_end.
9
10 2004-07-10  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
11
12         * trans-decl.c (gfc_create_module_variable): Nothing to do if
13         symbol is in common, because we ...
14         (gfc_generate_module_vars): Call gfc_trans_common.
15
16 2004-07-10  Paul Brook  <paul@codesourcery.com>
17
18         * trans-array.c (gfc_build_null_descriptor): New function.
19         (gfc_trans_static_array_pointer): Use it.
20         * trans-array.h (gfc_build_null_descriptor): Add prototype.
21         * trans-expr.c (gfc_conv_structure): Handle array pointers.
22
23 2004-07-10  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
24         
25         PR fortran/16336
26         * decl.c (gfc_match_save): Use-associated common block
27         doesn't collide.
28         * gfortran.h (gfc_common_head): Add new field 'name'.
29         Fix typo in comment after #endif.
30         * match.c (gfc_get_common): Add new argument from_common,
31         mangle name if flag is set, fill in new field in structure
32         gfc_common_head.
33         (match_common): Set new arg in call to gfc_get_common,
34         use-associated common block doesn't collide.
35         * match.h (gfc_get_common): Adapt prototype.
36         * module.c (load_commons): Set new arg in call to
37         gfc_get_common.
38         * symbol.c (free_common_tree): New function.
39         (gfc_free_namespace): Call new function.
40         * trans-common.c (several functions): Remove argument
41         'name', use name from gfc_common_head instead.
42
43 2004-07-10  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
44
45         * expr.c (gfc_check_pointer_assign): Verify that rank of the LHS
46         and RHS match. Return early if the RHS is NULL().
47
48         PR fortran/16336
49         * match.c (match_common): Fix error reporting for used common.
50
51         PR fortran/15969
52         * trans-expr.c (gfc_conv_structure): Handle initialization
53         of scalar pointer components.
54
55         * parse.c (decode_statement): Fix matching of BLOCK DATA.
56
57         * trans-decl.c (generate_local_decl): Remove workaround obsoleted
58         by fix for PR 15481.
59         
60 2004-07-10  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
61
62         * trans-common.c: Fix whitespace issues, make variable names
63         more readable.
64         (create_common): Additionally, make loop logic more obvious.
65
66 2004-07-10  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
67         Paul Brook  <paul@codesourcery.com>
68
69         PR fortran/13415
70         * trans-common.c (calculate_length): Remove ...
71         (get_segment_info): Merge into here.  Save field type.
72         (build_field): Use saved type.
73         (create_common, new_condition, new_segment, finish_equivalences):
74         Use new get_segment_info.
75         * trans-types.c: Update comment.
76
77 2004-07-09  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
78         
79         PR fortran/14077
80         * moduele.c (mio_symbol): Don't I/O initial values unless
81         symbol is a parameter.
82
83 2004-07-09  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
84         
85         PR fortran/13201
86         * resolve.c (resolve_symbol): Verify that the shape of a
87         parameter array is not only explicit, but also constant.
88         * array.c (gfc_is_compile_time_shape): New function.
89         * gfortran.h (gfc_is_compile_time_shape): Add prototype.
90
91 2004-07-09  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
92
93         PR fortran/15481
94         PR fortran/13372
95         PR fortran/13575
96         PR fortran/15978
97         * module.c (write_symbol, write_symtree): Remove workaround.
98         * primary.c (match_actual_arglist): Enhance comment.
99         (gfc_match_rvalue): Handle function call with first argument
100         a keyword argument correctly.
101         * resolve.c (resolve_symbol): Change call to
102         gfc_set_default_type to issue error if no implicit type
103         can be found.
104         * trans-decl.c (gfc_create_module_variable): Remove workaround.
105         
106 2004-07-08  Paul Brook  <paul@codesourcery.com>
107
108         * intrinsic.c (add_sym_4s): New function.
109         (add_subroutines): Change gfc_add_sym_? to gfc_add_sym_?s.
110
111 2004-07-04  Janne Blomqvist  <jblomqvi@cc.hut.fi>
112         Paul Brook  <paul@codesourcery.com>
113
114         PR fortran/15280
115         PR fortran/15665
116         * gfortran.h (enum gfc_generic_isym_id): Add GFC_ISYM_IARGC and
117         GFC_ISYM_COMMAND_ARGUMENT_COUNT.
118         * intrinsic.c (add_functions):  Identify iargc.  Add
119         command_argument_count.
120         (add_subroutines): Resolve getarg.  Add get_command and
121         get_command_argument.
122         * intrinsic.h (gfc_resolve_getarg, gfc_resolve_get_command,
123         gfc_resolve_get_command_argument): Add prototypes.
124         * iresolve.c (gfc_resolve_getarg, gfc_resolve_get_command,
125         gfc_resolve_get_command_argument): New functions.
126         * trans-decl.c (gfor_fndecl_iargc): New variable.
127         (gfc_build_intrinsic_function_decls): Set it.
128         * trans-intrinsic.c (gfc_conv_intrinsic_iargc): New function.
129         (gfc_conv_intrinsic_function): Use it.
130         * trans.h (gfor_fndecl_iargc): Declare.
131
132 2004-07-04  Matthias Klose  <doko@debian.org>
133
134         * Make-lang.in: Generate and install gfortran man page.
135         * invoke.texi: Remove extra '@c man end'.
136
137 2004-07-04  Richard Henderson  <rth@redhat.com>
138
139         * f95-lang.c (gfc_mark_addressable): Don't put_var_into_stack.
140
141 2004-07-04  Paul Brook  <paul@codesourcery.com>
142
143         * decl.c (gfc_match_implicit_range): Don't use typespec.
144         (gfc_match_implicit): Handle character selectors.
145         * gfortran.h (gfc_set_implicit): Remove prototype.
146         (gfc_add_new_implicit_range, gfc_merge_new_implicit): Update.
147         * parse.c (accept_statement): Don't call gfc_set_implicit.
148         * symbol.c (new_ts): Remove.
149         (gfc_set_implicit_none): Use same loop bounds as other functions.
150         (gfc_set_implicit): Remove.
151         (gfc_clear_new_implicit, gfc_add_new_implicit_range): Only set flags.
152         (gfc_merge_new_implicit): Combine with gfc_set_implicit.
153
154 2004-06-30  Richard Henderson  <rth@redhat.com>
155
156         * match.c (var_element): Remove unused variable.
157
158         * trans-decl.c (gfc_generate_function_code): Don't set
159         x_whole_function_mode_p.
160         (gfc_generate_constructors): Likewise.
161
162 2004-06-30  Richard Henderson  <rth@redhat.com>
163
164         * trans-decl.c (gfc_generate_function_code): Don't set
165         immediate_size_expand.
166         (gfc_generate_constructors): Likewise.
167
168 2004-06-30  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
169
170         PR fortran/16161
171         * decl.c (gfc_match_type_spec): Rename second argument to
172         'implicit_flag', reverse meaning. Don't match_char_spec if
173         'implicit_flag' is set. Rename to ...
174         (match_type_spec): ... this.
175         (gfc_match_implicit_none, match_implicit_range): Move here
176         from match.c.
177         (gfc_match_implicit): Move here from match.c, try to
178         match_char_len if match_implicit_range doesn't succeed for
179         CHARACTER implicits. Call renamed fucntion match_type_spec.
180         (gfc_match_data_decl, match_prefix): Call renamed function
181         match_type_spec.
182         * match.c (gfc_match_implicit_none, match_implicit_range,
183         gfc_match_implicit): Move to decl.c.
184         * match.h (gfc_match_implicit_none, gfc_match_implicit):
185         Move protoypes to section 'decl.c'.
186         (gfc_match_type_spec): Remove prototype.
187
188 2004-06-29  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
189
190         * decl.c, interface.c, symbol.c, trans-common.c: Add 2004 to 
191         copyright years.
192
193 2004-06-29  Steven Bosscher  <stevenb@suse.de>
194
195         Make sure types in assignments are compatible.  Mostly mechanical.
196         * trans-const.h (gfc_index_one_node): New define.
197         * trans-array.c (gfc_trans_allocate_array_storage,
198         gfc_trans_allocate_temp_array, gfc_trans_array_constructor_subarray,
199         gfc_trans_array_constructor_value, gfc_trans_array_constructor,
200         gfc_conv_array_ubound, gfc_conv_array_ref,
201         gfc_trans_scalarized_loop_end, gfc_conv_section_startstride,
202         gfc_conv_ss_startstride, gfc_conv_loop_setup, gfc_array_init_size,
203         gfc_trans_array_bounds, gfc_trans_dummy_array_bias,
204         gfc_conv_expr_descriptor, gfc_trans_deferred_array): Use the correct
205         types in assignments, conversions and conditionals for expressions.
206         * trans-expr.c (gfc_conv_expr_present, gfc_conv_substring,
207         gfc_conv_unary_op, gfc_conv_cst_int_power, gfc_conv_string_tmp,
208         gfc_conv_function_call, gfc_trans_pointer_assignment,
209         gfc_trans_scalar_assign): Likewise.
210         * trans-intrinsic.c (build_fixbound_expr, gfc_conv_intrinsic_bound,
211         gfc_conv_intrinsic_anyall, gfc_conv_intrinsic_count,
212         gfc_conv_intrinsic_minmaxloc, gfc_conv_intrinsic_btest,
213         gfc_conv_intrinsic_singlebitop, gfc_conv_intrinsic_ishft,
214         gfc_conv_intrinsic_ishftc, gfc_conv_intrinsic_strcmp,
215         gfc_conv_allocated, gfc_conv_associated,
216         gfc_conv_intrinsic_rrspacing, gfc_conv_intrinsic_trim): Likewise.
217         * trans-io.c (set_string): Likewise.
218         * trans-stmt.c (gfc_trans_do, gfc_trans_forall_loop,
219         gfc_do_allocate, generate_loop_for_temp_to_lhs,
220         generate_loop_for_rhs_to_temp, compute_inner_temp_size,
221         compute_overall_iter_number, gfc_trans_assign_need_temp,
222         gfc_trans_pointer_assign_need_temp, gfc_trans_forall_1,
223         gfc_evaluate_where_mask, gfc_trans_where_assign,
224         gfc_trans_where_2): Likewise.
225         * trans-types.c (gfc_get_character_type, gfc_build_array_type,
226         gfc_get_nodesc_array_type, gfc_get_array_type_bounds): Likewise.
227
228         * trans.c (gfc_add_modify_expr): Add sanity check that types
229         for the lhs and rhs are the same for scalar assignments.
230
231 2004-06-29  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
232
233         * dump-parse-tree.c (show_common): New function.
234         (gfc_show_namespace): Show commons.
235
236 2004-06-29  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
237         Andrew Vaught  <andyv@firstinter.net>
238
239         PR fortran/13249
240         PR fortran/15481
241         * decl.c (gfc_match_save): Adapt to new common structures,
242         don't allow saving USE-associated common.
243         * dump-parse-tree (gfc_show_attr): (saved_)common are not
244         symbol attributes any longer.
245         (gfc_show_symbol): Don't show old-style commons any longer.
246         (gfc_show_namespace): Adapt call to gfc_traverse_symtree to new
247         interface.
248         * gfortran.h (symbol_attribute): Remove common and saved_common
249         attributes.
250         (gfc_symbol): Remove common_head element.
251         (gfc_common_head): New struct.
252         (gfc_get_common_head): New macro.
253         (gfc_symtree): Add field 'common' to union.
254         (gfc_namespace): Add field 'common_root'; change type of field
255         'blank_common' to blank_common.
256         (gfc_add_data): New prototype.
257         (gfc_traverse_symtree): Expect a symtree as first argument
258         instead of namespace.
259         * match.c (gfc_get_common): New function.
260         (match_common_name): Change to take char * as argument, adapt,
261         fix bug with empty name.
262         (gfc_match_common): Adapt to new data structures. Disallow
263         redeclaration of USE-associated COMMON-block. Fix bug with
264         empty common.
265         (var_element): Adapt to new common structures.
266         * match.h (gfc_get_common): Declare.
267         * module.c: Add 2004 to copyright years, add commons to module
268         file layout description.
269         (ab_attribute, attr_bits, mio_symbol_attributes): Remove code
270         for removed attributes.
271         (mio_symbol): Adapt to new way of storing common relations.
272         (load_commons): New function.
273         (read_module): Skip common list on first pass, load_commons at
274         second.
275         (write_commons): New function.
276         (write_module): Call write_commons().
277         * symbol.c (gfc_add_saved_comon, gfc_add_common): Remove
278         functions related to removed attributes.
279         (gfc_add_data): New function.
280         (gfc_clear_attr): Don't set removed attributes.
281         (gfc_copy_attr): Don't copy removed attributes.
282         (traverse_symtree): Remove.
283         (gfc_traverse_symtree): Don't traverse symbol 
284         tree of the passed namespace, but require a symtree to be passed
285         instead. Unify with traverse_symtree.
286         (gfc_traverse_ns): Call gfc_traverse_symtree according to new
287         interface.
288         (save_symbol): Remove setting of removed attribute.
289         * trans-common.c (gfc_sym_mangled_common_id): Change to
290         take 'char *' argument instead of 'gfc_symbol'.
291         (build_common_decl, new_segment, translate_common): Adapt to new
292         data structures, add new
293         argument name.
294         (create_common): Adapt to new data structures, add new
295         argument name. Fix typo in intialization of derived types.
296         (finish_equivalences): Add second argument in call to
297         create_common.
298         (named_common): take 'gfc_symtree' instead of 'gfc_symbol'.
299         (gfc_trans_common): Adapt to new data structures.
300         * trans-decl.c (gfc_create_module_variables): Remove test for 
301         removed attribute.
302
303 2004-06-29  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
304
305         * io.c: Add 2004 to copyright years.
306
307 2004-06-29  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
308         Andrew Vaught  <andyv@firstinter.net>
309
310         * gfortran.h (gfc_gsymbol): New typedef.
311         (gfc_gsym_root): New variable.
312         (gfc_get_gsymbol, gfc_find_gsym): New prototypes.
313         * parse.c (global_used): New function.
314         (parse_block_data): Check for double empty BLOCK DATA,
315         use global symbol table.
316         (parse_module): Use global symbol table.
317         (add_global_procedure, add_global_program): New functions.
318         (gfc_parse_file): Use global symbol table.
319         * symbol.c (gfc_gsym_root): New variable.
320         (gfc_find_gsym, gsym_compare, gfc_get_gsymbol): New
321         functions.
322
323 2004-06-29  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
324
325         * module.c (mio_gmp_real): Correct writing of negative numbers.
326
327 2004-06-29  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
328
329         PR fortran/15963
330         * expr.c (check_intrinsic_op): Allow comparison of characters.
331         Make logic easier.
332
333 2004-06-26  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
334         Andrew Vaught  <andyv@firstinter.net>
335
336         * decl.c (contained_procedure): New function.
337         (match_end): Verify correctness of END STATEMENT in
338         all cases.
339
340 2004-06-26  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
341         Andrew Vaught  <andyv@firstinter.net>
342
343         PR fortran/15190
344         * decl.c (gfc_match_type_spec), io.c (match_io), parse.c
345         (decode_statement): Enforce required space in free-form.
346
347 2004-06-22  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>
348
349         * f95-lang.c (LANG_HOOKS_GIMPLE_BEFORE_INLINING): Deleted.
350         * trans-array.c (gfc_conv_descriptor_data): Add operand
351         for COMPONENT_REF.
352         (gfc_conv_descriptor_offset, gfc_conv_descriptor_dtype): Likewise.
353         (gfc_conv_descriptor_dimension, gfc_conv_descriptor_stride): Likewise.
354         (gfc_conv_descriptor_lbound, gfc_conv_descriptor_ubound): Likewise.
355         * trans-common.c (create_common): Likewise.
356         * trans-expr.c (gfc_conv_component_ref): Likewise.
357         * trans-io.c (set_parameter_value): Likewise.
358         (set_parameter_ref, set_string, set_flag, io_result): Likewise.
359         (transfer_expr): Likewise.
360         * trans-decl.c (gfc_trans_auto_character_variable):
361         Set up to get DECL_SIZE and DECL_SIZE_UNIT gimplified.
362         (gfc_gimplify_function): New function.
363         (gfc_generate_function-code): Properly handle nested functions.
364         * trans.c (gfc_build_array_ref): Add two new operands for ARRAY_REF.
365
366 2004-06-22  Janne Blomqvist  <jblomqvi@cc.hut.fi>
367
368         PR fortran/15750
369         * io.c (gfc_match_inquire): Bugfix for iolength related stuff.
370         (gfc_resolve_inquire): Resolve the iolength tag.  Return
371         SUCCESS at end of function if no failure has occured.
372         * resolve.c (resolve_code): Resolve if iolength is encountered.
373         * trans-io.c: (ioparm_iolength, iocall_iolength,
374         iocall_iolength_done): New variables.
375         (last_dt): Add IOLENGTH.
376         (gfc_build_io_library_fndecls ): Set iolength related variables.
377         (gfc_trans_iolength): Implement.
378         (gfc_trans_dt_end): Treat iolength as a third form of data transfer.
379
380 2004-06-21  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de
381
382         PR fortran/15511
383         * scanner.c (load_line): Don't truncate preprocessor lines.
384         Reformat error message.
385         (preprocessor_line): Issue warning in case of malformed
386         preprocessor line. 
387
388 2004-06-21  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
389
390         * resolve.c (resolve_symbol): Add comment in function body.
391         (check_data_variable): Change type of mark to ar_type, adapt code
392         accordingly.
393
394 2004-06-21  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
395
396         * array.c (gfc_insert_constructor): Avoid redundant call to
397         mpz_comp. Add 2004 to copyright years.
398         
399 2004-06-21  Joseph S. Myers  <jsm@polyomino.org.uk>
400
401         * trans.h (stmtblock_t): Change has_scope to unsigned int.
402
403 2004-06-20  Steven G. Kargl  <kargls@comcast.net>
404
405         * arith.c (gfc_range_check): correct complex underflow.
406
407 2004-06-15  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
408
409         PR fortran/15962
410         * match.c (match_case_selector): Call gfc_match_init_expr
411         instead of gfc_match_expr.
412         * resolve.c (validate_case_label_expr): No need to check for
413         constant, since it wouldn't have been matched with the fix to
414         match.c.
415
416 2004-06-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
417
418         PR fortran/15211
419         * trans-intrinsic.c (gfc_conv_intrinsic_len): Deal with arrays
420         of strings. 
421
422 2004-06-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
423
424         PR fortran/15510
425         * trans-deecl.c (generate_local_decl): Do not issue warning for
426         unused variables if they're use associated.
427
428 2004-06-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
429         Andrew Vaught <andyv@firstinter.net>
430
431         PR fortran/14928
432         * gfortran.h (gfc_check_f): Add new field f3ml.
433         * check.c (gfc_check_minloc_maxloc): Take argument list instead
434         of individual arguments, reorder if necessary.
435         * intrinsic.h (gfc_check_minloc_maxloc): ... adapt prototype.
436         * intrinsic.c (add_sym_3ml): New function.
437         (add_functions): Change to add_sym_3ml for MINLOC, MAXLOC.
438         (check_specific): Catch special case MINLOC, MAXLOC. 
439
440 2004-06-14  Paul Brook  <paul@codesourcery.com>
441
442         * intrinsic.c (add_sym_2s): Use correct function types.
443
444 2004-06-12  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
445
446         * Make-lang.in (F95_OBJS, F95_PARSER_OBJS): Alphabetize.  Move data.c
447         * data.c (gfc_get_section_index):  Remove dependency on trans.h.
448
449 2004-06-12  Steven G. Kargl  <kargls@comcast.net>
450
451         * check.c (gfc_check_second_sub, gfc_check_irand, gfc_check_rand
452         gfc_check_srand, gfc_check_etime, gfc_check_etime_sub): New functions.
453         * gfortran.h (gfc_generic_isym_id): New symbols GFC_ISYM_ETIME,
454         GFC_ISYM_IRAND, GFC_ISYM_RAND, GFC_ISYM_SECOND.
455         * trans-intrinsic.c:  Use symbols.
456         * intrinsic.c (add_sym_2s): New function.
457         * intrinsic.c: Add etime, dtime, irand, rand, second, srand.
458         * intrinsic.h: Function prototypes.
459         * iresolve.c (gfc_resolve_etime_sub, gfc_resolve_second_sub 
460         gfc_resolve_srand):  New functions.
461
462 2004-06-12  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
463
464         PR fortran/14957
465         * decl.c (gfc_match_end): Require END {SUBROUTINE|FUNCTION} for
466         contained procedure.
467         
468 2004-06-12  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
469
470         PR fortran/12841
471         * interface.c (compare_parameter, compare_actual_formal): Don't
472         check types and array shapes for NULL()
473         * trans-expr.c (conv_function_call): No double indirection for
474         NULL() 
475
476 2004-06-09  Toon Moene  <toon@moene.indiv.nluug.nl>
477
478         * trans-expr.c (gfc_conv_cst_int_power): Compute
479         x**(-n) by converting it to (1/x)**n instead of
480         1/x**n.
481
482 2004-06-09  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
483
484         PR fortran/13372
485         * module.c (write_symbol, write_symtree): Don't write symbols
486         wrongly added to namespace.
487         * trans-decl.c (gfc_create_module_variable): Don't create a
488         backend decl for a symbol incorrectly added to namespace.
489
490 2004-06-09  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
491
492         PR fortran/13201
493         * resolve.c (resolve_symbol): Verify that parameter array has an
494         explicit shape. Fix typos and coding style issues in surrounding
495         lines.
496
497 2004-06-05  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
498
499         PR fortran/15478
500         * gfortran.texi: The documentation doesn't contain infomration on
501         how to report bugs, and shouldn't, so remove the line which
502         says it does.
503
504 2004-06-05  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
505
506         * intrinsic.c (sort_actual): Keep track of type of missing 
507         arguments. (Missing from previous commit.)
508
509 2004-06-03  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
510
511         * gfortran.h (gfc_actual_arglist): New field missing_arg_type.
512         * interface.c (compare_actual_formal): Keep type of omitted
513         optional arguments.
514         * trans-expr.c (gfc_conv_function_call): Add string length
515         argument for omitted string argument.
516
517 2004-06-03  Paul Brook  <paul@codesourcery.com>
518
519         * trans.c (gfc_finish_block, gfc_add_expr_to_block): Build statement
520         lists instead of compound expr chains.
521         (gfc_trans_code): Annotate statement lists.
522
523 2004-06-03  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
524
525         * trans-array.c: Fix spelling in comments.
526
527 2004-06-02  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
528
529         PR fortran/15557
530         * data.c (assign_substring_data_value): New function.
531         (gfc_assign_data_value): Call the new function if we're dealing
532         with a substring LHS.
533
534 2004-06-01  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
535
536         PR fortran/15477
537         * gfortran.h (GFC_VERSION): Remove.
538         * gfortran.texi (version-gfortran): Remove, replace by version-GCC
539         where used.
540
541 2004-05-31  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
542
543         * trans-types.c: Fix spelling & layout in comments.
544
545 2004-05-30  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
546
547         PR fortran/14067
548         * trans-const.c (gfc_conv_string_init): Allow variable string
549         length lower than initialization string length.
550
551 2004-05-30  Paul Brook  <paul@codesourcery.com>
552
553         PR fortran/15620
554         * trans-decl.c (gfc_shadow_sym, gfc_restore_sym): New functions.
555         * trans-expr.c (gfc_trans_string_copy): New function.
556         (gfc_conv_statement_function): Use them.  Create temp vars.  Enforce
557         character lengths.
558         (gfc_conv_string_parameter): Use gfc_trans_string_copy.
559         * trans-stmt.c (gfc_trans_forall_1): Use gfc_{shadow,restore}_sym.
560         * trans.h (struct gfc_saved_var): Define.
561         (gfc_shadow_sym, gfc_restore_sym): Add prototypes.
562
563 2004-05-30  Steven G. Kargl  <kargls@comcast.net>
564
565         * iresolve.c (gfc_resolve_random_number): Clean up conditional.
566
567 2004-05-29  Steven G. Kargl  <kargls@comcast.net>
568
569         * simplify.c (gfc_simplify_log): Remove useless line of code.
570
571 2004-05-29  Paul Brook  <paul@codesourcery.com>
572
573         * trans-common.c (find_equivalence): Find multiple rules.
574
575 2004-05-27  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
576
577         * gfortran.h (gfc_current_locus, gfc_set_locus): Remove.
578         (gfc_current_locus): Declare new global variable.
579         * scanner.c (gfc_current_locus, gfc_set_locus): Remove.
580         (gfc_current_locus1): Rename ...
581         (gfc_current_locus): ... to this.
582         (gfc_at_eof, gfc_at_bol, gfc_at_eol, gfc_advance_line, next_char,
583         skip_fixed_comments, skip_free_comments, gfc_next_char_literal,
584         gfc_peek_char, gfc_gobble_whitespace, gfc_new_file): Use
585         gfc_current_locus instead of gfc_current_locus1, gfc_set_locus()
586         and gfc_current_locus(), respectively.
587         * array.c (match_subscript, gfc_match_array_ref, match_array_list,
588         match_array_cons_element, gfc_match_array_constructor):
589         Read/modify gfc_current_locus instead of calling gfc_set_locus()
590         and gfc_current_locus().
591         * decl.c (gfc_match_null, variable_decl, gfc_match_kind_spec,
592         match_attr_spec, gfc_match_function_decl, gfc_match_end,
593         attr_decl1, gfc_match_save): Likewise.
594         * error.c (error_print, gfc_internal_error): Likewise.
595         * expr.c (gfc_int_expr, gfc_default_logical_kind): Likewise.
596         * interface.c (gfc_add_interface): Likewise.
597         * io.c (gfc_match_format, match_dt_format, match_dt_element,
598         match_io_iterator, match_io): Likewise.
599         * match.c (gfc_match_space, gfc_match_eos,
600         gfc_match_small_literal_int, gfc_match_st_label,
601         gfc_match_strings, gfc_match_name, gfc_match_iterator,
602         gfc_match_char, gfc_match, gfc_match_assignment,
603         gfc_match_pointer_assignment, gfc_match_if, gfc_match_do,
604         gfc_match_nullify, gfc_match_call, match_implicit_range,
605         gfc_match_implicit, gfc_match_data, match_case_selector,
606         gfc_match_case, match_forall_iterator): Likewise.
607         * matchexp.c (gfc_match_defined_op_name, next_operator,
608         match_level_1, match_mult_operand, match_ext_mult_operand,
609         match_add_operand, match_ext_add_operand, match_level_2,
610         match_level_3, match_level_4, match_and_operand, match_or_operand,
611         match_equiv_operand, match_level_5, gfc_match_expr): Likewise.
612         * module.c (gfc_match_use, mio_array_ref, mio_expr): Likewise.
613         * parse.c (match_word, decode_statement, next_free, next_fixed,
614         add_statement, verify_st_order, parse_if_block, gfc_parse_file):
615         Likewise.
616         * primary.c (match_digits, match_integer_constant,
617         match_boz_constant, match_real_constant, match_substring,
618         next_string_char, match_charkind_name, match_string_constant,
619         match_logical_constant, match_const_complex_part,
620         match_complex_constant, match_actual_arg, match_keyword_arg,
621         gfc_match_actual_arglist, gfc_match_structure_constructor,
622         gfc_match_rvalue, gfc_match_variable): Likewise.
623         * st.c (gfc_get_code): Likewise.
624         * symbol.c (check_conflict, check_used, check_done,
625         duplicate_attr, add_flavor, gfc_add_procedure, gfc_add_intent,
626         gfc_add_access, gfc_add_explicit_interface, gfc_add_type,
627         gfc_add_component, gfc_reference_st_label, gfc_new_symbol): Likewise.
628
629 2004-05-26  Roger Sayle  <roger@eyesopen.com>
630
631         * io.c (format_asterisk): Silence compiler warnings by correcting
632         the number of elements of a "locus" initializer.
633
634 2004-05-25  Roger Sayle  <roger@eyesopen.com>
635
636         PR fortran/13912
637         * matchexp.c: Allow unary operators after arithmetic operators
638         as a GNU extension.
639         (match_ext_mult_operand, match_ext_add_operand): New functions.
640         (match_mult_operand): Tweak to call match_ext_mult_operand.
641         (match_add_operand): Tweak to call match_ext_mult_operand.
642         (match_level_2): Rearrange to call match_ext_add_operand.
643
644 2004-05-25  Paul Brook  <paul@codesourcery.com>
645
646         * expr.c (check_inquiry): Remove bogus tests.
647
648 2004-05-23  Paul Brook  <paul@codesourcery.com>
649
650         PR fortran/13773
651         * expr.c (restricted_args): Remove redundant checks/argument.
652         (external_spec_function): Update to match.
653         (restricted_intrinsic): Rewrite.
654
655 2004-05-23  Paul Brook  <paul@codesourcery.com>
656         Victor Leikehman  <lei@haifasphere.co.il>
657
658         * gfortran.h (struct gfc_symbol): Add equiv_built.
659         * trans-common.c: Change int to HOST_WIDE_INT.  Capitalize error
660         messages.
661         (current_length): Remove.
662         (add_segments): New function.
663         (build_equiv_decl): Create initialized common blocks.
664         (build_common_decl): Always add decl to bindings.
665         (create_common): Create initializers.
666         (find_segment_info): Reformat to match coding conventions.
667         (new_condition): Use add_segments.
668         (add_condition, find_equivalence, add_equivalences): Move iteration
669         inside functions.  Only process each segment once.
670         (new_segment, finish_equivalences, translate_common): Simplify.
671
672 2004-05-23  Steven G. Kargl  <kargls@comcast.net>
673
674         * check.c (gfc_check_random_seed): Issue for too many arguments.
675
676 2004-05-22  Steven G. Kargl  <kargls@comcast.net>
677
678         * intrinsic.c (add_subroutines): Use add_sym_3s for random_seed.
679
680 2004-05-22  Paul Brook  <paul@codesourcery.com>
681
682         * dump-parse-tree.c (gfc_show_equiv): New function.
683         (gfc_show_namespace): Use it.
684
685 2004-05-22  Victor Leikehman  <lei@haifasphere.co.il>
686
687         PR fortran/13249
688         * symbol.c (gfc_add_common): Disable checks to work around other more
689         fundamental inadequacies.
690
691 2004-05-22  Tobias Schlüter  <tobias.schlueter@physik.uni-muenchen.de>
692
693         * trans-decl.c (gfc_get_extern_function_decl): Set DECL_IS_PURE
694         only for functions.
695         (gfc_build_function_decl): Likewise.
696
697 2004-05-22  Steven G. Kargl  <kargls@comcast.net>
698
699         * check.c (gfc_check_system_clock): New function.
700         * intrinsic.c (add_sym_3s): New function.
701         (add_subroutines): Use it.
702         * intrinsic.h (gfc_check_system_clock, gfc_resolve_system_clock):
703         Add prototypes.
704         * iresolve.c (gfc_resolve_system_clock): New function.
705
706 2004-05-22  Steven G. Kargl  <kargls@comcast.net>
707
708         * invoke.texi: Document -Wunderflow and spell check.
709         * lang.opt: Add Wunderflow.
710         * gfortran.h (gfc_option_t): Add warn_underflow option.
711         * options.c (gfc_init_options, set_Wall): Use it.
712         * primary.c (match_real_constant): Explicitly handle UNDERFLOW.
713         * arith.c (gfc_arith_uminus, gfc_arith_plus, gfc_arith_minus,
714         gfc_arith_times, gfc_arith_divide, gfc_arith_power, gfc_real2real,
715         gfc_real2complex, gfc_complex2real, gfc_complex2complex): Ditto.
716         * arith.c (common_logarithm): Fix typo in comment.
717
718 2004-05-21  Roger Sayle  <roger@eyesopen.com>
719
720         * io.c (check_format): As a GNU extension, allow the comma after a
721         string literal to be optional in a format.  Use gfc_notify_std to
722         issue an error/warning as appropriate.
723
724 2004-05-21  Roger Sayle  <roger@eyesopen.com>
725
726         * io.c (check_format): Use gfc_notify_std to determine whether to
727         issue an error/warning for omitting the digits from the X format.
728
729 2004-05-20  Roger Sayle  <roger@eyesopen.com>
730
731         * io.c (check_format): Allow the number before the X format to
732         be optional when not -pedantic.
733
734 2004-05-18  Feng Wang  <fengwang@nudt.edu.cn>
735         Paul Brook  <paul@codesourcery.com>
736
737         * f95-lang.c (gfc_init_builtin_functions): Use vold_list_node.
738         Create decls for __builtin_pow{,f}.
739         * gfortran.h (PREFIX_LEN): Define.
740         * trans-decl.c (gfor_fndecl_math_powi): Add.
741         (gfor_fndecl_math_powf, gfor_fndecl_math_pow): Remove.
742         (gfc_build_intrinsic_function_decls): Create decls for powi.
743         * trans-expr.c (powi_table): Add.
744         (gfc_conv_integer_power): Remove.
745         (gfc_conv_powi): New function.
746         (gfc_conv_cst_int_power): New function.
747         (gfc_conv_power_op): Use new powi routines.
748         * trans.h (struct gfc_powdecl_list): Add.
749         (gfor_fndecl_math_powi): Add.
750         (gfor_fndecl_math_powf, gfor_fndecl_math_pow): Remove.
751
752 2004-05-18  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
753
754         * trans.c, trans-decl.c: Fix comment typos.
755
756 2004-05-18  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
757
758         * trans-const.c (gfc_conv_mpf_to_tree): Fix typo.
759
760 2004-05-18  Steve Kargl  <kargls@comcast.net>
761
762         * arith.c (gfc_int2complex): Fix incorrect range checking.
763
764 2004-05-18  Paul Brook  <paul@codesourcery.com>
765
766         PR fortran/13930
767         * decl.c (add_init_expr_to_sym): Remove incorrect check.
768         (default_initializer): Move to expr.c.
769         (variable_decl): Don't assign default initializer to variables.
770         * expr.c (gfc_default_initializer): Move to here.
771         * gfortran.h (gfc_default_initializer): Add prototype.
772         * resolve.c (resolve_symbol): Check for illegal initializers.
773         Assign default initializer.
774
775 2004-05-17  Steve Kargl  <kargls@comcast.net>
776
777         * arith.c (gfc_arith_power): Complex number raised to 0 power is 1.
778
779 2004-05-17  Steve Kargl  <kargls@comcast.net>
780
781         * arith.c (gfc_real2complex): Range checking wrong part of complex
782         number. 
783         
784 2004-05-16  Paul Brook  <paul@codesourcery.com>
785
786         * options.c (gfc_handle_module_path_options): Fix buffer overrun.
787
788 2004-05-16  Paul Brook  <paul@codesourcery.com>
789
790         * arith.c (gfc_range_check): Fix logic error.
791
792 2004-05-16  Steve Kargl  <sgk@troutmask.apl.washington.edu>
793
794         * arith.c: Fix comment typos.
795
796 2004-05-15  Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
797
798         PR fortran/13742
799         * decl.c (add_init_expr_to_sym): Verify that COMMON variable is
800         not initialized in a disallowed fashion.
801         * match.c (gfc_match_common): Likewise.
802         (var_element): Verify that variable is not in the blank COMMON,
803         if it is in a common. 
804
805 2004-05-15  Joseph S. Myers  <jsm@polyomino.org.uk>
806
807         * Make-lang.in (f95.generated-manpages): Remove.
808         (f95.srcextra): New.
809         (f95.info, fortran/gfortran.info, fortran/gfortran.dvi,
810         f95.maintainer-clean): Generate info and dvi files in objdir/doc.
811         (f95.dvi): Remove.
812         (dvi): New.
813         (f95.install-info): Remove.
814         (install-info): New.
815
816 2004-05-15  Victor Leikehman  <lei@haifasphere.co.il>
817
818         * decl.c (add_init_expr_to_sym): Check for variable size arrays.
819
820 2004-05-15  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
821
822         * primary.c (match_boz_constant): Use gfc_notify_std() for
823         issuing a warning or an error.
824
825 2004-05-15  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
826
827         PR fortran/13826
828         * primary.c (match_structure_constructor): Rename ...
829         (gfc_match_structure_constructor): ... to this. Make non-static.
830         (gfc_match_rvalue): Call renamed function.
831         * match.h (gfc_match_structure_constructor): Declare.
832         * match.c (gfc_match_data_constant): Handle structure
833         constructor.
834
835 2004-05-15  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
836
837         PR fortran/13702 
838         (Port from g95)
839         * gfortran.h (gfc_linebuf): New typedef.
840         (linebuf): Remove.
841         (gfc_file): Revamped, use new gfc_linebuf.
842         (locus): Revamped, use new types.
843         (gfc_current_file): Remove.
844         (gfc_current_form, gfc_source_file): New global variables.
845         * match.c (gfc_match_space, gfc_match_strings): Use
846         gfc_current_form to find source form.
847         * module.c (gfc_dump_module): Use gfc_source_file when printing
848         module header.
849         * error.c (show_locus, show_loci) Use new data structures to print
850         locus.
851         * scanner.c (first_file, first_duplicated_file, gfc_current_file):
852         Remove.
853         (file_head, current_file, gfc_current_form, line_head, line_tail,
854         gfc_current_locus1, gfc_source_file): New global variables.
855         (gfc_scanner_init1): Set new global variables.
856         (gfc_scanner_done1): Free new data structures.
857         (gfc_current_locus): Return pointer to gfc_current_locus1.
858         (gfc_set_locus): Set gfc_current_locus1.
859         (gfc_at_eof): Set new variables.
860         (gfc_at_bol, gfc_at_eol, gfc_advance_line, gfc_next_char): Adapt
861         to new locus structure.
862         (gfc_check_include): Remove.
863         (skip_free_comments, skip_fixed_comments): Use gfc_current_locus1.
864         (gfc_skip_comments): Use gfc_current_form, find locus with
865         gfc_current_locus1.
866         (gfc_next_char): Use gfc_current_form.
867         (gfc_peek_char, gfc_gobble_whitespace): Use gfc_current_locus1.
868         (load_line): Use gfc_current_form. Recognize ^Z as EOF. Fix
869         comment formatting.
870         (get_file): New function.
871         (preprocessor_line, include_line): New functions.
872         (load_file): Move down, rewrite to match new data structures.
873         (gfc_new_file): Rewrite to match new data structures.
874         * parse.c (next_statement): Remove code which is now useless. Use
875         gfc_source_form and gfc_source_file where appropriate.
876         * trans-decl.c (gfc_get_label_decl): adapt to new data structures
877         when determining locus of frontend code.
878         * trans-io.c (set_error_locus): Same.
879         * trans.c (gfc_get_backend_locus, gfc_set_backend_locus): Likewise.
880         * lang-specs.h (@f77-cpp-input, @f95-cpp-input): Remove '-P' from
881         preprocessor flags.
882         (all): Add missing initializers.
883
884 2004-05-15  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
885
886         * Make-lang.in (trans-common.o): Remove redundant dependency.
887         (data.c): Replace object file name ...
888         (data.o): ... by the correct one.
889
890 2004-05-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
891
892         * dump-parse-tree.c (gfc_show_array_ref): Print colon only
893         for ranges when dumping array references.
894
895 2004-05-14  Victor Leikehman  <lei@haifasphere.co.il>
896
897         * decl.c (variable_decl): Always apply default initializer.
898
899 2004-05-08  Tobias Schlüter <tobias.schlueter@physik.uni-muenchen.de>
900
901         PR fortran/15206
902         * trans-intrinsic.c (gfc_conv_intrinsic_rrspacing): Fixed to
903         handle zero correctly.
904
905 2004-05-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
906
907         * match.c (gfc_match): Eliminate dead code.
908
909 2004-05-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
910
911         * parse.c (gfc_statement_next_fixed): (Change from Andy's tree)
912         Detect bad continuation line in fixed form sources.
913
914 2004-05-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
915
916         PR fortran/15205
917         * iresolve.c (gfc_resolve_nearest): Add new function.
918         * intrinsic.h: ... declare it here.
919         * intrinsic.c (add_functions): ... add it as resolving function
920         for NEAREST.
921         
922 2004-05-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
923
924         PR fortran/14066
925         * match.c (gfc_match_do): Allow infinite loops with
926         label-do-stmt. Do not enforce space after comma.
927
928 2004-05-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
929
930         PR fortran/15051
931         * parse.c (parse_interface): Allow empty INTERFACE, remove
932         seen_body.
933
934 2004-05-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
935
936         * Make-lang.in, arith.c, arith.h, array.c, bbt.c, check.c,
937         decl.c, dependency.c, dependency.h, dump-parse-tree.c, error.c,
938         expr.c, f95-lang.c, gfortran.h, interface.c, intrinsic.c,
939         intrinsic.h, io.c, iresolve.c, lang-specs.h, match.c, match.h,
940         matchexp.c, misc.c, module.c, options.c, parse.c, parse.h,
941         primary.c, resolve.c, scanner.c, simplify.c, st.c, symbol.c,
942         trans-array.c, trans-array.h, trans-common.c, trans-const.c,
943         trans-const.h, trans-decl.c, trans-expr.c, trans-intrinsic.c,
944         trans-io.c, trans-stmt.c, trans-stmt.h, trans-types.c,
945         trans-types.h, trans.c, trans.h: Update copyright years and
946         boilerplate.
947         * data.c: Likewise, also removed two whitespace-only lines.
948         * gfortranspec.c, lang.opt: Update copyright years.
949
950 2004-05-14  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
951
952         PR fortran/14568
953         * trans-decl.c (generate_local_decl): Don't warn for unused
954         variables which are in common blocks. 
955
956 2004-05-13  Diego Novillo  <dnovillo@redhat.com>
957
958         * Make-lang.in, f95-lang.c, trans-array.c, trans-decl.c,
959         trans-expr.c, trans-intrinsic.c, trans-io.c, trans-stmt.c,
960         trans.c: Rename tree-simple.[ch] to tree-gimple.[ch].
961
962 2004-05-13  Victor Leikehman  <lei@haifasphere.co.il>
963
964         PR fortran/15314
965         * trans-expr.c (gfc_conv_structure): Use field type, not expr type.
966
967 2004-05-13  Joseph S. Myers  <jsm@polyomino.org.uk>
968
969         * gfortran.texi: Use @table @emph instead of @itemize @emph.
970         Remove "set DEVELOPMENT".
971         (Compiling GFORTRAN): Remove.
972
973 2004-05-09  Tobias Schlüter  <tobias.schlueter@physik.uni-muenchen.de>
974
975         * array.c (match_subscript, match_array_ref): Add comments
976         explaining argument 'init'.
977         * decl.c, f95-lang.c, match.c, resolve.c, trans-array.c,
978         trans-expr.c, trans.c: Fix some typos in comments.
979         * dump-parse-tree.c (gfc_show_expr): Remove wrong comment.
980         * primary.c (match_digits, match_integer_constant): Add comment
981         explaining signflag.
982
983 2004-05-01  Tobias Schlüter <tobias.schlueter@physik.uni-muenchen.de>
984
985         PR fortran/13940
986         * primary.c: Include system.h and flags.h, needed for pedantic.
987         (match_boz_constant): Allow "x" for hexadecimal constants, warn if
988         pedantic is set.
989
990 2004-05-01  Tobias Schlüter <tobias.schlueter@physik.uni-muenchen.de>
991
992         PR fortran/13940
993         * match.c (match_data_constant): Handle case where
994         gfc_find_symbol sets sym to NULL
995
996 2004-04-28  Tobias Schlüter <tobias.schlueter@physik.uni-muenchen.de>
997
998         * Make-lang.in (f95-lang.o, trans-intrinsic.o): Add missing
999         dependency on mathbuiltins.def
1000
1001 2004-04-24  Victor Leikehman  <lei@il.ibm.com>
1002
1003         * trans-io.c (transfer_expr): Implemented recursive printing
1004         of derived types.
1005
1006 2004-04-24  Andrew Pinski  <pinskia@physics.uc.edu>
1007
1008         * gfortranspec.c: Do not include multilib.h.
1009
1010 2004-04-24  Tobias Schlüter  <tobias.schlueter@physik.uni-muenchen.de>
1011
1012         * trans-intrinsic.c: Fix comment, this is not trans-expr.c. Add
1013         2004 to copyright years.
1014         * trans-expr.c, trans-decl.c: Comment update, we now generate
1015         GENERIC, not SIMPLE. Add 2004 to copyright years.
1016
1017 2004-04-24  Paul Brook  <paul@codesourcery.com>
1018
1019         * Make-lang.in (gfortranspec.o): Add dependency on $(TM_H).
1020
1021 2004-04-24  Feng Wang  <fengwang@nudt.edu.cn>
1022
1023         PR 14817
1024         * arith.c (gfc_arith_divide): Fix complex divide.
1025
1026 2004-04-23  Andrew Pinski  <pinskia@physics.uc.edu>
1027
1028         * gfortranspec.c: Include the target headers.
1029
1030 2004-04-18  Feng Wang  <fengwang@nudt.edu.cn>
1031
1032         PR fortran/14921
1033         PR fortran/14540
1034         * arith.c (arctangent2): New function.
1035         * arith.h (arctangent2): Add function prototype.
1036         * simplify.c (gfc_simplify_atan2): Use it.
1037         (gfc_simplify_log): Use it.
1038
1039 2004-04-12  Diego Novillo  <dnovillo@redhat.com>
1040
1041         * fortran/f95-lang.c (gfc_expand_stmt): Remove.
1042         (LANG_HOOKS_RTL_EXPAND_STMT): Remove.
1043
1044 2004-04-11  Bud Davis  <bdavis9659@comcast.net>
1045
1046         PR fortran/14872
1047         * trans-io.c (build_dt): Change REC to value.
1048
1049 2004-04-11  Feng Wang  <fengwang@nudt.edu.cn>
1050
1051         PR 14394 
1052         * trans-const.c (gfc_conv_mpf_to_tree): Loosen the maximum digits of
1053         the real value when converting mpf to string.
1054
1055 2004-04-11  Feng Wang  <fengwang@nudt.edu.cn>
1056
1057         PR 14395
1058         * trans-intrinsic.c (gfc_conv_intrinsic_cmplx): Fix the imag part of
1059         the result.
1060
1061 2004-04-11  Feng Wang  <fengwang@nudt.edu.cn>
1062
1063         PR fortran/14377
1064         * simplify.c (simplify_min_max): Convert the type of the result.
1065
1066 2004-04-11  Paul Brook  <paul@codesourcery.com>
1067
1068         * gfortran.texi: Use full target triplet.
1069
1070 2004-04-11  Paul Brook  <paul@codesourcery.com>
1071
1072         * Make-lang.in (GFORTRAN_TEXI): Set it.
1073         (fortran/dfortran.dvi): Use it.  Add fortran to include paths.
1074         (fortran/gfortran.info): Ditto. 
1075         * gfortran.texi: Major update.
1076         * invoke.texi: New file.
1077
1078 2004-04-10  Paul Brook  <paul@codesourcery.com>
1079
1080         * trans-array.c (gfc_trans_allocate_temp_array,
1081         gfc_conv_tmp_array_ref): Don't use GFC_DECL_STRING.
1082         * trans-decl.c (gfc_build_dummy_array_decl,
1083         gfc_get_symbol_decl, gfc_build_function_decl,
1084         gfc_create_module_variable): Ditto.
1085         * trans-expr.c (gfc_conv_variable): Ditto.
1086         * trans-intrinsic.c (gfc_conv_intrinsic_len): Ditto.
1087         * trans.h (GFC_DECL_STRING): Remove.
1088         (GFC_DECL_PACKED_ARRAY, GFC_DECL_PARTIAL_PACKED_ARRAY,
1089         GFC_DECL_ASSIGN): Renumber flags.
1090
1091 2004-04-05  Paul Brook  <paul@codesourcery.com>
1092
1093         PR 13252
1094         PR 14081
1095         * f95-lang.c (gfc_init_builtin_functions): Add stack_alloc, stack_save
1096         and stack_restore.
1097         * gfortran.h (struct gfc_charlen): Add backend_decl.
1098         * trans-array.c (gfc_trans_allocate_temp_array,
1099         gfc_conv_temp_array_ref, gfc_conv_resolve_dependencies,
1100         (gfc_conv_loop_setup, gfc_array_allocate, gfc_conv_array_init_size):
1101         Remove old, broken string handling.
1102         (gfc_trans_auto_array_allocation, gfc_trans_g77_array,
1103         gfc_trans_dummy_array_bias, gfc_conv_expr_descriptor,
1104         gfc_trans_deferred_array): Handle character arrays.
1105         * trans-const.c (gfc_conv_const_charlen): New function.
1106         * trans-const.h (gfc_conv_const_charlen): Add prototype.
1107         * trans-decl.c (gfc_finish_var_decl): Don't mark automatic variables
1108         as static.
1109         (gfc_build_dummy_array_decl): Handle arrays with unknown element size.
1110         (gfc_create_string_length): New function.
1111         (gfc_get_symbol_decl): Create lengths for character variables.
1112         (gfc_get_fake_result_decl): Ditto.
1113         (gfc_build_function_decl): Only set length for assumed length
1114         character arguments.
1115         (gfc_trans_dummy_character): New function.
1116         (gfc_trans_auto_character_variable): Rewrite.
1117         (gfc_trans_deferred_vars): Handle more types of character variable.
1118         (gfc_create_module_variable): String lengths have moved.
1119         (gfc_generate_function_code): Initialize deferred var chain earlier.
1120         * trans-expr.c (gfc_conv_init_string_length): Rename ...
1121         (gfc_trans_init_string_length):  ... to this.
1122         (gfc_conv_component_ref, gfc_conv_variable, gfc_conv_concat_op,
1123         gfc_conv_function_call): Update to new format for character variables.
1124         (gfc_conv_string_length): Remove.
1125         (gfc_conv_string_parameter): Update assertion.
1126         * trans-intrinsic.c (gfc_conv_intrinsic_len): Use new location.
1127         * trans-io.c (set_string): Use new macro names.
1128         * trans-stmt.c (gfc_trans_label_assign. gfc_trans_goto): Ditto.
1129         * trans-types.c (gfc_get_character_type): Use existing length expr.
1130         (gfc_is_nodesc_array): Make public.
1131         (gfc_get_dtype_cst): Rename ...
1132         (gfc_get_dtype): ... to this.  Handle unknown size arrays.
1133         (gfc_get_nodesc_array_type): Use new name.
1134         (gfc_sym_type): New character variable code.
1135         (gfc_get_derived_type): Ditto.
1136         (gfc_get_function_type): Evaluate character variable lengths.
1137         * trans-types.h (gfc_strlen_kind): Define.
1138         (gfc_is_nodesc_array): Add prototype.
1139         * trans.h: Update prototypes.
1140         (struct lang_type): Update comments.
1141         (GFC_DECL_STRING_LEN): New name for GFC_DECL_STRING_LENGTH.
1142         (GFC_KNOWN_SIZE_STRING_TYPE): Remove.
1143
1144 2004-04-04  Paul Brook  <paul@codesourcery.com>
1145
1146         * gfortran.h (struct gfc_option_t): Remove flag_g77_calls.
1147         * options.c (gfc_init.options, gfc_handle_option): Ditto.
1148         * trans-expr.c (gfc_conv_function_call): Ditto.
1149         * trans-types.c (gfc_is_nodesc_array): Ditto
1150         * lang.opt (fg77-calls): Remove.
1151
1152 2004-04-04  Paul Brook  <paul@codesourcery.com>
1153
1154         * trans-array.c (OFFSET_FIELD): Rename from BASE_FIELD.
1155         (gfc_conv_descriptor_base): Rename ...
1156         (gfc_conv_descriptor_offset): ... to this.
1157         (gfc_trans_allocate_array_storage): Set offset to zero.
1158         (gfc_conv_array_base): Rename ...
1159         (gfc_conv_array_offset): ... to this.
1160         (gfc_conv_array_index_ref): Add offset parameter.
1161         (gfc_conv_array_ref): Include offset.
1162         (gfc_trans_preloop_setup): Use existing offset.
1163         (gfc_trans_allocate_temp_array,  gfc_array_allocate,
1164         gfc_trans_auto_array_allocation, gfc_trans_g77_array,
1165         gfc_trans_dummy_array_bias, gfc_conv_expr_descriptor,
1166         gfc_conf_ss_descriptor): Set offset.
1167         * trans-array.h: Rename prototypes.
1168         * trans-const.h (gfc_index_zero_node): Define.
1169         * trans-decl.c (gfc_build_qualified_array): Change base to offset.
1170         * trans-types.c (gfc_get_array_type_bounds): Ditto.
1171         (gfc_get_nodesc_array_type): Calculate offset before upper bound.
1172
1173 2004-03-25  Diego Novillo  <dnovillo@redhat.com>
1174
1175         * convert.c (convert): Don't handle WITH_RECORD_EXPR.
1176
1177 2004-03-24  Bud Davis  <bdavis9659@comcast.net>
1178
1179         PR 14055
1180         * arith.c (gfc_convert_integer,gfc_convert_real):  Removed leading '+'
1181         before conversion by gmp library call.
1182
1183 2004-03-24  Bud Davis  <bdavis9659@comcast.net>
1184
1185         PR 12921
1186         * trans-io.c (gfc_trans_open): Change RECL= to a value parameter.
1187
1188 2004-02-24  Richard Henderson  <rth@redhat.com>
1189
1190         * trans-array.c (gfc_trans_dummy_array_bias): Fix typo.
1191
1192 2004-02-19  Loren J. Rittle  <ljrittle@acm.org>
1193
1194         * Make-lang.in ($(srcdir)/fortran/gfortran.info): Move...
1195         (fortran/gfortran.info): ... to here.
1196         (f95.srcinfo): New.
1197
1198 2004-02-16  Richard Henderson  <rth@redhat.com>
1199
1200         * Make-lang.in (f95-lang.o, trans-decl.o): Depend on cgraph.h.
1201         * f95-lang.c (LANG_HOOKS_EXPAND_DECL): Remove.
1202         (LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): New.
1203         (gfc_expand_function): Rename from expand_function_body, make static,
1204         don't do anything except invoke tree_rest_of_compilation.
1205         (gfc_be_parse_file): Invoke cgraph.
1206         (gfc_expand_decl): Remove.
1207         (gfc_init_builtin_functions): Add __builtin_init_trampoline and
1208         __builtin_adjust_trampoline.
1209         * trans-decl.c (gfc_get_extern_function_decl): Don't set DECL_CONTEXT.
1210         (gfc_finalize): New.
1211         (gfc_generate_function_code): Use it.  Lower nested functions.
1212         * trans-expr.c (gfc_conv_function_call): Add static chain operand
1213         to call_expr.
1214         * trans.c (gfc_build_function_call): Likewise.
1215         * trans.h (expand_function_body): Remove.
1216
1217 2004-02-15  Victor Leikehman  <lei@il.ibm.com>
1218
1219         PR gfortran/13433
1220         * trans-decl.c (gfc_build_function_decl) For functions
1221         returning CHARACTER pass an extra length argument,
1222         following g77 calling conventions.
1223         * trans-types.c (gfc_get_function_type) Ditto.
1224         * trans-expr.c (gfc_conv_function_call) Ditto.
1225
1226 2004-02-14  Paul Brook  <paul@codesourcery.com>
1227
1228         * f95-lang.c (gfc_init_builtin_functions): Build chain properly.
1229
1230 2004-02-12  Paul Brook  <paul@nowt.org>
1231
1232         * BUGS: Remove.
1233
1234 2004-02-08  Steve Kargl  <sgk@troutmask.apl.washington.edu>
1235
1236         * gfortran.texi: Fix typos.
1237
1238 2004-02-07  Bud Davis  <bdavis9659@comcast.net>
1239  
1240         PR gfortran/13909
1241         * intrinsic.c (add_conversions) Use logical conversion instead
1242         of real.
1243         * trans-types.c (gfc_get_logical_type) implemented logical*1
1244         and logical*2.
1245
1246 2004-01-17  Paul Brook  <paul@codesourcery.com>
1247
1248         * lang-specs.h: Remove %<fixed-form.
1249
1250 2004-01-15  Toon Moene  <toon@moene.indiv.nluug.nl>
1251
1252         * lang-specs.h: Enable preprocessing of source files
1253         ending in .F, .fpp, .FPP, .F90 and .F95.
1254
1255 2004-01-13  Toon Moene  <toon@moene.indiv.nluug.nl>
1256
1257         PR fortran/12912
1258         * lang-specs.h: Enable compilation of files ending
1259         in .f, .for and .FOR.
1260
1261 2004-01-11  Paul Brook  <paul@codesourcery.com>
1262
1263         * trans-stmt.c (gfc_trans_if_1): New function.
1264         (gfc_trans_if): Use it.
1265
1266 2004-01-11  Erik Schnetter  <schnetter@uni-tuebingen.de>
1267
1268         * gfortran.h (GFC_MAX_SYMBOL_LEN): Increase.
1269         (gfc_option_t): Add max_identifier_length.
1270         * lang.opt: Add fmax-identifier-length.
1271         * match.c (parse_name): Use limit.
1272         * options.c (gfc_init_options): Set max_identifier_length.
1273         (gfc_handle_option): Ditto.
1274
1275 2004-01-11  Feng Wang  <fengwang@nudt.edu.cn>
1276
1277         * intrinsic.c (add_functions): Add resolve function to dcmplx.
1278         * intrinsic.h (gfc_resolve_dcmplx): Add prototype.
1279         * iresolve.c (gfc_resolve_dcmplx): New function.
1280
1281 2004-01-10  Paul Brook  <paul@codesourcery.com>
1282
1283         * trans-decl.c (gfc_get_symbol_decl): Don't set subroutine attr.
1284         * trans-types.c (gfc_sym_type): Handle external dummy procedures.
1285         (gfc_return_by_reference): Correct condition.
1286         (gfc_get_function_type): Ditto.
1287
1288 2004-01-10  Paul Brook  <paul@codesourcery.com>
1289
1290         * trans-intrinsic.c (gfc_conv_intrinsic_minmax): Convert mismatched
1291         types.
1292
1293 2004-01-10  Huang Chun  <chunhuang73@hotmail.com>
1294
1295         * iresolve.c: Use correct kind.
1296
1297 2004-01-10  Huang Chun  <chunhuang73@hotmail.com>
1298
1299         PR fortran/13467
1300         * trans-decl.c (gfc_create_module_variable):  Output array valued
1301         parameters.
1302
1303 2004-01-10  Paul Brook  <paul@codesourcery.com>
1304
1305         * resolve.c (resolve_branch): Get error message right way round.
1306
1307 2004-01-10  Canqun Yang <canqun@nudt.edu.cn>
1308
1309         * trans-array (gfc_conv_loop_setup): Adjust comment to track
1310         reality.
1311         (gfc_array_allocate): Don't count size of element twice.
1312
1313 2004-01-04  Paul Brook  <paul@codesourcery.com>
1314
1315         * lang.opt (i8, r8, std=*): Remove RejectNegative.
1316
1317 2004-01-04  Paul Brook  <paul@codesourcery.com>
1318
1319         * error.c (gfc_notify_std): New function.
1320         * gfortran.h (gfc_notify_std): Declare.
1321         (GFC_STD_*): Define.
1322         (gfc_option_t): Add warn_std and allow_std.
1323         * intrinsic.c (gfc_init_expr_extensions): Fix logic.
1324         (gfc_intrinsic_func_interface): Use gfc_notify_std.
1325         * check.c (check_rest): Use gfc_notify_std.
1326         * match.c (gfc_match_pause): Ditto.
1327         (gfc_match_assign): Ditto.
1328         (gfc_match_goto): Ditto.
1329         * resolve.c (resolve_branch): Ditto.
1330         * lang.opt: Add std=<foo> and w.
1331         * options.c (gfc_init_options): Set allow_std and warn_std.
1332         (gfc_handle_option): Handle OPT_std_* and OPT_w.
1333
1334 2004-01-01  Paul Brook  <paul@codesourcery.com>
1335
1336         * array.c (gfc_append_constructor): Take constructor, not expression.
1337         * data.c (struct gfc_expr_stack): Remove.
1338         (expr_stack): Remove.
1339         (find_con_by_offset): Rename from find_expr_in_con.
1340         (find_con_by_component): Rename from find_component_in_con.
1341         (gfc_get_expr_stack): Remove.
1342         (gfc_assign_data_value): Rewrite.
1343         (gfc_expr_push): Remove.
1344         (gfc_expr_pop): Remove.
1345         (gfc_advance_section): Rename from
1346         gfc_modify_index_and_calculate_offset.  Handle unbounded sections.
1347         (gfc_get_section_index): Handle unbounded sections.
1348         * gfortran.h: Update prototypes.
1349         * resolve.c (check_data_variable): Array section maight not be the
1350         last ref.
1351
1352 2004-01-01  Paul Brook  <paul@codesourcery.com>
1353
1354         PR fortran/13432
1355         * resolve.c (resolve_symbol): Allow assumed length function results.
1356
1357 2004-01-01  Steve Kargl  <sgk@troutmask.apl.washington.edu>
1358
1359         * match.c (gfc_match_pause): Fix spelling.
1360
1361 2004-01-01  Steven Bosscher  <stevenb@suse.de>
1362
1363         PR fortran/13251
1364         * trans-expr.c (gfc_conv_variable): Take the type kind of a substring
1365         reference from the expression.
1366
1367 2003-12-26  Feng Wang  <fengwang@nudt.edu.cn>
1368
1369         * dump-parse-tree.c (gfc_show_code_node): Add ASSIGN and ASSIGNED GOTO
1370         dumping.
1371         * gfortran.h (gfc_statement): New ST_LABEL_ASSIGNMENT.
1372         (gfc_exec_op): New EXEC_LABEL_ASSIGN.
1373         (symbol_attribute):New variable attribute: assign.
1374         * io.c (resolve_tag):Integer variable is allowed.
1375         (match_dt_format): Add ASSIGN statement. Set assign flag.
1376         * match.c (gfc_match_if): Change ST_NONE to ST_LABEL_ASSIGNMENT.
1377         (gfc_match_assign): Add ASSIGN statement. Set assign flag.
1378         (gfc_match_goto): Add ASSIGNED GOTO statement. Set assign flag.
1379         * parse.c (decode_statement): Add ST_LABEL_ASSIGNMENT.
1380         (next_statement): Add ST_LABEL_ASSIGNMENT.
1381         (gfc_ascii_statement): Add ST_LABEL_ASSIGNMENT.
1382         * resolve.c (resolve_code): Resolve ASSIGN and ASSIGNED GOTO statement.
1383         (resolve_blocks): Resolve ASSIGNED GOTO statement label list.
1384         * st.c (gfc_free_statement): Add EXEC_LABEL_ASSIGN.
1385         * trans-decl.c (gfc_get_symbol_decl): Create the shadow variable for
1386         assign.  Put them into the stuct lang_decl.
1387         * trans-io.c (set_string): Add the assign statement.
1388         * trans-stmt.c (gfc_trans_label_assign): New function.
1389         (gfc_trans_goto): Translate ASSIGNED GOTO statement.
1390         * trans-stmt.h (gfc_trans_label_assign): Added function prototype.
1391         * trans.c (gfc_trans_code): Add EXEC_LABEL_ASSIGN.
1392         * trans.h (lang_decl):Add shadow variable decl tree needed by assign.
1393         (GFC_DECL_ASSIGN_ADDR(node)): New macro to access this.
1394         (GFC_DECL_ASSIGN(node)): New macro to access flag.
1395
1396 2003-12-31  Huang Chun <chunhuang73@hotmail.com>
1397
1398         PR fortran/13434
1399         * trans-intrinsic.c (gfc_conv_intrinsic_minmaxval): Fixed bug in 
1400         minval/maxval.
1401
1402 2003-12-22  Toon Moene  <toon@moene.indiv.nluug.nl>
1403
1404         * options.c (gfc_init_options): Set flag_argument_noalias to 2, to indicate
1405         that arguments to subroutines/functions can't alias themselves, nor global
1406         memory.
1407
1408 2003-12-20  Steven Bosscher  <stevenb@suse.de>
1409
1410         * trans-expr.c (gfc_conv_expr_op): Fold the result expression.
1411         * trans.c (gfc_add_modify_expr, gfc_add_expr_to_block): Likewise.
1412
1413 2003-12-12  Huang Chun <chunhuang73@hotmail.com>
1414
1415         * primary.c (match_substring): Fix substring bug for start point
1416         or end point is NULL.
1417         * trans-expr.c (gfc_conv_substring): Ditto
1418         * trans-types.c (gfc_sym_type): Get correct type of scalar 
1419         character variables.
1420         * trans-intrinsic.c (gfc_conv_intrinsic_len): Handle character in 
1421         derived type.
1422
1423 2003-12-10  Richard Henderson  <rth@redhat.com>
1424
1425         * options.c (gfc_post_options): Don't ever use rtl inlining.
1426
1427 2003-12-05  Canqun Yang  <canqun@nudt.edu.cn>
1428
1429         * trans-common.c: Re-implement COMMON blocks and EQUIVALENCE lists.
1430         * trans-equivalence.c: Remove.
1431         * trans-decl.c (gfc_get_symbol_decl): Update to match.
1432         (gfc_generate_function_code): Ditto.
1433         * trans-array.c (gfc_conv_array_parameter): Ditto.
1434         * Make-lang.in (F95_OBJS): Remove fortran/trans-equivalence.o
1435         (F95_ADDITIONAL_OBJS): Add stor-layout.o
1436         * trans.h (gfc_trans_equivalence): Remove.
1437         * gfortran.h (struct gfc_equiv): Add used field.
1438         (struct gfc_symbol): Remove addr_base, addr_offset, equiv_ring,
1439         equiv_offset fields.
1440
1441 2003-12-05  Richard Henderson  <rth@redhat.com>
1442
1443         * trans.c (gfc_build_addr_expr): New.
1444         (gfc_build_indirect_ref, gfc_build_array_ref): New.
1445         * trans.h: Declare them.
1446         * trans-array.c, trans-expr.c, trans-intrinsic.c, trans-io.c,
1447         trans-stmt.c, trans.c (*): Use them.
1448
1449         * f95-lang.c (gfc_post_options): Remove dead prototype.
1450         * trans-array.c (gfc_trans_deferred_vars): Remove unused variable.
1451         * trans-stmt.c (gfc_evaluate_where_mask): Fix temporary_list
1452         allocation size.
1453
1454 2003-12-01  Feng Wang  <fengwang@nudt.edu.cn>
1455
1456         * io.c (gfc_match_format): Check for missing format label.
1457
1458 2003-11-30 Huang Chun <chunhuang73@hotmail.com>
1459
1460         PR fortran/13155
1461         * trans-decl.c (gfc_sym_mangled_function_id): Don't mangle symbols
1462         from interfaces in modules.
1463
1464 2003-11-30  Paul Brook  <paul@nowt.org>
1465
1466         * trans-array.c (gfc_trans_g77_array): Make non-static.
1467         (gfc_trans_assumed_size): Remove.
1468         (gfc_trans_dummy_array_bias): Explicitly free temporary.
1469         * trans-array.h (gfc_trans_g77_array): Add prototype.
1470         (gfc_trans_assumed_size): Remove.
1471         * trans-decls.c (gfor_fndecl_push_context): Remove.
1472         (gfor_fndecl_pop_context): Remove.
1473         (gfc_build_function)decls): Don't create them.
1474         (gfc_trans_deferred_vars): Update to match. Remove dead code.
1475         * trans-stmt.c (gfc_trans_pointer_assign_need_temp): Free temp.
1476
1477 2003-11-30  Kejia Zhao  <kejia_zh@nudt.edu.cn>
1478
1479         * trans-array.c (gfc_conv_array_parameter): Simplify
1480         array argument passing for array name actual argument.
1481         * trans-expr.c (gfc_conv_function_call): Ditto
1482         * trans-types.c (gfc_is_nodesc_array):Ditto.
1483
1484 2003-11-30  Paul Brook  <paul@nowt.org>
1485
1486         * f95-lang.c (gfc_post_options): Move ...
1487         * options.c (gfc_post_options): .. to here.  Handle inlining options.
1488         * gfortran.h (gfc_post_options): Add prototype.
1489
1490 2003-11-28  Richard Henderson  <rth@redhat.com>
1491
1492         * trans.c (gfc_create_var_np): Use create_tmp_var_raw.
1493
1494 2003-11-28 Huang Chun <chunhuang73@hotmail.com>
1495
1496         * trans.h (has_alternate_specifier): New global variable.
1497         * match.c (gfc_match_call): Handle actual arguments associated with
1498         alternate return indicators.
1499         * trans-expr.c (gfc_conv_function_call): Ditto
1500         * trans-stmt.c (gfc_trans_call): Ditto
1501         (gfc_trans_return): Handle return statement with value.
1502         * trans-decl.c (gfc_generate_function_code): Handle functions with
1503         asterisk dummy.
1504         (gfc_get_fake_result_decl): Ditto
1505         * trans-types.c (gfc_get_function_type): Ditto
1506         * resolve.c (resolve_actual_arglist): Check alternate return indicators.
1507         (resolve_formal_arglist): Check asterisk dummy.
1508
1509 2003-11-27  Paul Brook  <paul@nowt.org>
1510
1511         * trans-array.c (gfc_tran_allocate_array_storage): Use new memory
1512         allocation interface.
1513         (gfc_conv_ array_parameter): Ditto.
1514         (gfc_trans_auto_array_allocation): Ditto. Also free the memory.
1515         * trans-array.c: Update prototype.
1516         * trans-decl.c (gfc_build_builtin_function_decls): Update prototypes.
1517         (gfc_trans_auto_character_variable): Use new memory alloc interface.
1518         * trans-expr.c (gfc_conv_string_tmp): Ditto.
1519         (gfc_conv_function_call): Use gfc_conv_string_tmp.
1520         * trans-stmt.c (gfc_do_allocate):  Use new memory alloc interface.
1521         * trans-intrinsic.c (gfc_conv_intrinsic_trim): Ditto.
1522         * trans.h (gfc_ss_info): Remove unused pdata field.
1523         * trans.c (gfc_create_var_np): Change T to V.
1524
1525 2003-11-26  Richard Henderson  <rth@redhat.com>
1526
1527         * mathbuiltins.def: Move acos, asin, cosh, log10, sinh, tanh from ...
1528         * trans-intrinsic.c (gfc_intrinsic_map): ... here.  Add SCALE,
1529         FRACTION, NEAREST, SET_EXPONENT.
1530         (gfc_intrinsic_map_t): Add libm_name, complex_available, is_constant.
1531         Fix GTY marking.  Remove unnecessary const's.
1532         (LIBM_FUNCTION): Rename from I_LIB.
1533         (LIBF_FUNCTION): New.
1534         (gfc_get_intrinsic_lib_fndecl): Handle libm and libgfortran naming
1535         conventions.  Assume the expr signature is correct.  Mark const.
1536         (gfc_conv_intrinsic_exponent): Use library functions.
1537         (gfc_conv_intrinsic_set_exponent): Remove.
1538         (gfc_conv_intrinsic_scale): Remove.
1539         (gfc_conv_intrinsic_nearest): Remove.
1540         (gfc_conv_intrinsic_fraction): Remove.
1541         (gfc_conv_intrinsic_function): Update.
1542         * trans-decl.c (gfor_fndecl_math_exponent4): New.
1543         (gfor_fndecl_math_exponent8): New.
1544         (gfc_build_intrinsic_function_decls): Set them.
1545         * trans.h: Declare them.
1546
1547 2003-11-25  Canqun Yang  <canqun@nudt.edu.cn>
1548
1549         * trans-common.c (gfc_layout_global_equiv): Locate the error for
1550         underflow COMMON block.
1551         (gfc_trans_one_common): Fix bug for size of COMMON block containing
1552         EQUIVALENCE object. Also fix typo in an error message.
1553
1554 2003-11-25  Diego Novillo  <dnovillo@redhat.com>
1555
1556         * Make-lang.in: Add check-gfortran to lang_checks.
1557         (check-f95): Alias for check-gfortran.
1558
1559 2003-11-25  Jason Merrill  <jason@redhat.com>
1560
1561         * Make-lang.in (f95.tags): Create TAGS.sub files in each
1562         directory and TAGS files that include them for each front end.
1563
1564 2003-11-24  Paul Brook  <paul@nowt.org>
1565
1566         PR fortran/13154
1567         * trans-decl.c (gfc_greate_module_variable): Skip COMMON blocks.
1568
1569 2003-11-24  Paul Brook  <paul@nowt.org>
1570
1571         * expr.c (simplify_const_ref): Return SUCCESS for things we don't
1572         handle.
1573         * resolve.c (gfc_resolve_expr): Resolve contents before rank/shape.
1574
1575 2003-11-24  Paul Brook  <paul@nowt.org>
1576
1577         PR fortran/13105
1578         * array.c (gfc_array_ref_shape): Handle elemental dimensions.
1579         * trans-array.c (gfc_trans_preloop_setup): Use correct dim lookup.
1580
1581 2003-11-20  Richard Henderson  <rth@redhat.com>
1582
1583         * trans-array.c (gfc_trans_allocate_array_storage): Use convert.
1584         (gfc_conv_array_base): Likewise.
1585         * trans-decl.c (gfc_trans_auto_character_variable): Likewise.
1586         * trans-expr.c (gfc_conv_string_tmp): Likewise.
1587         * trans-intrinsic.c (gfc_conv_intrinsic_trim): Likewise.
1588         * trans-stmt.c (gfc_trans_character_select): Likewise.
1589
1590 2003-11-13  Paul Brook  <paul@nowt.org>
1591
1592         * trans-decl.c (gfc_sym_mangled_function_id): Dont mangle externals.
1593
1594 2003-11-13  Canqun Yang  <canqun@nudt.edu.cn>
1595
1596         * resolve.c (gfc_resolve): Also resolve EQUIVALENCE objects.
1597         (resolve_equivalence): New function.
1598         (resolve_equivalence_derived): New function.
1599
1600 2003-11-12  Richard Henderson  <rth@redhat.com>
1601
1602         * trans.c (gfc_trans_code): Use annotate_with_locus instead of
1603         annotate_all_with_locus.
1604
1605 2003-11-11  Canqun Yang  <canqun@nudt.edu.cn>
1606  
1607         * options.c (gfc_init_options): Set flag_max_stack_var_size as 32768.
1608         * trans-decl.c (gfc_finish_var_decl): Modified.
1609
1610 2003-11-08  Paul Brook  <paul@nowt.org>
1611
1612         PR fortran/12704
1613         * trans-intrinsic.c (gfc_conv_intrinsics_minmaxloc): Handle zero-size
1614         arrays.
1615
1616 2003-11-06  Paul Brook  <paul@nowt.org>
1617
1618         * trans-intrinsic.c (gfc_conv_intrinsics_minmaxloc): Initialize pos.
1619
1620 2003-11-02  Canqun Yang  <canqun@nudt.edu.cn>
1621
1622         * match.c (gfc_match_stopcode): Assign '0' to stop_code.
1623
1624 2003-10-27  Anthony Green  <green@redhat.com>
1625
1626         * Make-lang.in (f95.stageprofile): Use tabs, not spaces.
1627         (f95.stagefeedback): Ditto.
1628
1629 2003-10-27  Andrew Pinski  <pinskia@physics.uc.edu>
1630
1631         PR fortran/12682
1632         * Make-lang.in (f95.stageprofile): Add.
1633         (f95.stagefeedback): Add.
1634
1635 2003-10-23  Richard Henderson  <rth@redhat.com>
1636
1637         * f96-lang.c (gfc_gimplify_expr): Remove.
1638         (LANG_HOOKS_GIMPLIFY_EXPR): Remove.
1639         (LANG_HOOKS_GIMPLE_BEFORE_INLINING): New.
1640
1641 2003-10-23  Richard Henderson  <rth@redhat.com>
1642
1643         * f95-lang.c (gfc_gimplify_expr): Return gimplify_status.
1644
1645 2003-10-20  Paul Brook  <paul@nowt.org>
1646
1647         * trans-expr.c (gfc_conv_integer_power): Use boolean_type_node.
1648         * trans-stmt.c (gfc_trans_do_while): Ditto.
1649
1650 2003-10-17  Paul Brook  <paul@nowt.org>
1651
1652         * simplify.c (gfc_simplify_shape): Use gfc_array_dimen_size.
1653
1654 2003-10-17  Paul Brook  <paul@nowt.org>
1655
1656         * trans-io.c (gfc_build_io_library_fndecls): Set TREE_PUBLIC.
1657
1658 2003-10-17  Feng Wang  <wf_cs@yahoo.com>
1659
1660         * iresolve.c (gfc_resolve_maxloc): Change the result's kind and type.
1661         (gfc_resolve_minloc): Ditto.
1662         * trans-intrinsic.c (gfc_conv_intrinsic_minmaxloc): Use correct types.
1663         Return the value after subtracting the lower bound.
1664
1665 2003-10-16  Richard Henderson  <rth@redhat.com>
1666
1667         * f95-lang.c (expand_function_body): Don't check flag_disable_gimple.
1668
1669 2003-10-16  Steven Bosscher  <steven@gcc.gnu.org>
1670
1671         * lang.c: Remove -M option for now, it's in the way for C.
1672
1673 2003-10-14  Jason Merrill  <jason@redhat.com>
1674
1675         * Make-lang.in (f95.tags): New rule.
1676
1677 2003-10-13  Richard Henderson  <rth@redhat.com>
1678
1679         * trans.c (gfc_trans_code): Use annotate_all_with_locus.
1680
1681 2003-10-13  Paul Brook  <paul@nowt.org>
1682
1683         * trans-decl.c (generate_local_decl): Don't create junk variables.
1684
1685 2003-10-13  Paul Brook  <paul@nowt.org>
1686
1687         * resolve.c (resolve_formal_arglist): Use function result decl in
1688         preference to function decl.
1689
1690 2003-10-12  Richard Henderson  <rth@redhat.com>
1691
1692         * f95-lang.c (gfc_define_builtin): New const_p argument.  Set
1693         TREE_READONLY.  Update all callers.
1694
1695 2003-10-12  Feng Wang  <wf_cs@yahoo.com>
1696
1697         * iresolve.c (gfc_resolve_cshift): Change to match implementation.
1698         * trans-intrinsic.c (gfc_conv_intrinsic_function): Remove CSHIFT.
1699         (gfc_is_intrinsic_libcall): Add CSHIFT.
1700
1701 2003-10-12  Richard Henderson  <rth@redhat.com>
1702
1703         * trans-array.c (gfc_trans_static_array_pointer): Set TREE_INVARIANT.
1704         (gfc_trans_array_constructor_value): Likewise.
1705         (gfc_conv_array_initializer): Likewise.
1706         * trans-stmt.c (gfc_trans_character_select): Likewise.
1707
1708 2003-11-12  Kejia Zhao  <kejia_zh@yahoo.com.cn>
1709
1710         * trans-intrinsic.c (integer_kind_info, real_kind_info): Remove.
1711
1712 2003-10-11  Huang Chun  <jiwang@mail.edu.cn>
1713
1714         * check.c (gfc_check_repeat): Check arguments are scalar.
1715         (gfc_check_trim): New function.
1716         * intrinsic.h (gfc_check_trim): Add prototype.
1717         * intrinsic.c (add_functions): Use it.
1718         * trans.h (gfor_fndecl_string_trim, gfor_fndecl_string_repeat):
1719         Decalare.
1720         * trans-decl.c: Ditto.
1721         (gfc_build_intrinsic_fucntion_decls): Set them.
1722         * trans-intrinsic.c (gfc_conv_intrinsic_len): Handle result vars.
1723         (gfc_conv_intrinsic_trim): New function.
1724         (gfc_conv_intrinsic_repeat): New function.
1725         (gfc_conv_intrinsic_function): Use them.
1726
1727 2003-10-11  Huang Chun  <jiwang@mail.edu.cn>
1728
1729         * trans-types.c (gfc_sym_type): Handle result variables.
1730
1731 2003-10-11  Huang Chun  <jiwang@mail.edu.cn>
1732
1733         * trans-intrinsic.c (gfc_conv_intrinsic_char): Don't use
1734         gfc_get_character_type.
1735
1736 2003-10-11  Feng Wang  <wf_cs@yahoo.com>
1737
1738         * trans-expr.c (gfc_conv_variable): Check sym->ts, not the decl.
1739
1740 2003-10-11  Paul Brook  <paul@nowt.org>
1741
1742         * iresolve.c (gfc_resolve_dint, gfc_resolve_dnint): New functions.
1743         (gfc_resolve_dprod): New function.
1744         (gfc_resolve_aint, gfc_resolve_anint): Only base name on arg type.
1745         * intrinsic.h (gfc_resolve_dint, gfc_resolve_dnint): Declare.
1746         (gfc_resolve_dprod): Declare.
1747         * intrinsic.c (add_functions): Use them.
1748         * trans-decl.c (gfc_get_extern_function_decl): Only pass one arg.
1749
1750 2003-10-06  Richard Henderson  <rth@redhat.com>
1751
1752         * f95-lang.c (gfc_init_builtin_functions): Add clzll.
1753         * trans-intrinsic.c (call_builtin_clz): Use it.
1754
1755 2003-10-05  Paul Brook  <paul@nowt.org>
1756
1757         * f95-lang.c (expand_function_body): Call (push|pop)_function_context.
1758         * trans-decl.c (gfc_generate_function_code): Set
1759         cfun->function_end_locus.
1760
1761 2003-09-24  Jason Merrill  <jason@redhat.com>
1762
1763         * f95-lang.c, trans-decl.c: Use DECL_SOURCE_LOCATION instead of
1764         TREE_LOCUS.
1765
1766 2003-09-21  Lifang Zeng  <zlf605@hotmail.com>
1767         Paul Brook  <paul@nowt.org>
1768
1769         * Make-lang.in (F95_OBJS): Add fortran/data.o.
1770         * array.c (gfc_inser_constructor): New function.
1771         (gfc_get_constructor): New function.
1772         (gfc_free_constructor): Initialize offset and repeat.
1773         (iterator_stack): Remove.
1774         (expand_info): Add offset, component and repeat fields.
1775         (expand_constructor): Set them.
1776         (expand): Set new fields.
1777         (gfc_copy_constructor): Ditto. Avoid recursion.
1778         * gfortran.h: Add prototypes for new functions.
1779         (gfc_constructor): Add offset, component and repeat.
1780         (iteratio_stack): Move to here.
1781         * resolve.c (check_data_variable): Convert data values into variable
1782         initializers.
1783         (traverse_data_list): Build implicit loop chain.
1784         (gfc_resolve): Ditto.
1785         * trans-array.c (gfc_conv_array_intializer): Handle repeat count.
1786         * trans-decl.c (gfc_get_symbol_decl): Use gfc_conv_structure.
1787         * trans-expr.c (gfc_conv_structure): Handle array initializers.
1788         (gfc_conv_expr): Update to match.
1789         * trans.h (gfc_conv_structure): Declare.
1790         * data.c: New file.
1791
1792 2003-09-20  Kejia Zhao  <kejia_zh@yahoo.com.cn>
1793  
1794         * trans.h: Add declarations for gfor_fndecl_si_kind and
1795         gfor_fndecl_sr_kind.
1796         * trans-decl.c (g95_build_intrinsic_function_decls): Build them.
1797         * trans-intrinsic.c (g95_conv_intrinsic_si_kind): New function.
1798         (g95_conv_intrinsic_sr_kind): New function.
1799         (g95_conv_intrinsic_function): Add SELECTED_INT_KIND and
1800         SELECTED_REAL_KIND.
1801
1802 2003-09-17  Lars Segerlund  <Lars.Segerlund@comsys.se>
1803
1804         * iresolve.c (gfc_resolve_random_number): Generate _r4 & _r8
1805         instead of _4 and _8 as postfix for libgfortran calls.
1806
1807 2003-09-16  Paul Brook  <paul@nowt.org>
1808
1809         * array.c (compare_bounds): New function.
1810         (gfc_compare_array_spec): Use it.
1811
1812 2003-09-14  Paul Brook  <paul@nowt.org>
1813
1814         * primary.c (gfc_match_rvalue): Make sure sym->result is set.
1815         * trans-expr.c (gfc_conv_string_parameter): Also allow PRAM_DECLs.
1816
1817 2003-09-14  Paul Brook  <paul@nowt.org>
1818
1819         * check.c (dim_rank_check): Allow assumed bounds if requested.
1820         (gfc_check_lbound): Call it.
1821         (gfc_check_ubound): Ditto.
1822         (gfc_check_size): Change to match.
1823         * simplify.c (gfc_simplify_bound): New function.
1824         (gfc_simplify_lbound): New function.
1825         (gfc_simplify_ubound): New function.
1826         * intrinsic.h: Declare them.
1827         * intrinsic.c (add_functions): Use them.
1828
1829 2003-09-14  Paul Brook  <paul@nowt.org>
1830
1831         * io.c (format_lex): Initialize negative_flag.
1832         (check_format): Intialize repeat.
1833         * trans-io.c (gfc_new_nml_name_expr): Declare static.
1834         (gfc_new_var_expr): Ditto.
1835
1836 2003-09-14  Paul Brook  <paul@nowt.org>
1837
1838         * trans-array.c (gfc_conv_array_initializer): Handle derived types.
1839         * trans-decl.c (gfc_get_symbol_decl): Only do local scalar values.
1840
1841 2003-09-12  Paul Brook  <paul@nowt.org>
1842
1843         * trans-intrinsic.c (gfc_conv_intrinsic_sign): Call fold.
1844
1845 2003-09-12  Zdenek Dvorak  <rakdver@atrey.karlin.mff.cuni.cz>
1846
1847         * fortran/trans.c (gfc_finish_block): Call rationalize_compound_expr
1848         for a correct expression.
1849
1850 2003-09-10  Kejia Zhao  <kejia_zh@yahoo.com.cn>
1851
1852         * trans-intrinsic.c (real_compnt_info): New struct.
1853         (prepare_arg_info): New function.
1854         (gfc_conv_intrinsic_set_exponent): New function.
1855         (gfc_conv_intrinsic_scale): New function.
1856         (gfc_conv_intrinsic_nearest): New function.
1857         (gfc_conv_intrinsic_fraction): New function.
1858         (gfc_conv_intrinsic_exponent): New function.
1859         (gfc_conv_intrinsic_spacing): New function.
1860         (gfc_conv_intrinsic_rrspacing): New function.
1861         (gfc_conv_intrinsic_function): Use them.
1862
1863 2003-08-24 XiaoQiang Zhang  (zhangapache@yahoo.com>
1864
1865         * trans-const.c (gfc_conv_mpz_to_tree): Fix bug, parameter for 
1866         build_int_2 changed from (high, low) to (low, high).
1867         * trans-io.c (ioparm_namelist_name, ioparm_namelist_name_len,
1868         ioparm_namelist_read_mode, iocall_set_nml_val_int,
1869         iocall_set_nml_val_float, iocall_set_nml_val_char,
1870         iocall_set_nml_val_complex, iocall_set_nml_val_log): New declaration.
1871         (gfc_build_io_library_fndecls): Add variable initialization.
1872         (gfc_new_nml_name_expr, get_new_var_expr): New function.
1873         (build_dt): Add namelist support.
1874         * io.c (value): New variable.
1875         (check_format): Support FMT_H now.
1876
1877 2003-09-07  Paul Brook  <paul@nowt.org>
1878
1879         * io.c (gfc_resolve_dt): Error if format label is not defined.
1880
1881 2003-09-07  Kejia Zhao  <kejia_zh@yahoo.com.cn>
1882
1883         * trans-intrinsic.c (gfc_conv_intrinsic_aint): Fix two bugs. One is 
1884         about case_switch's break. The other is about building the condition 
1885         statement tree, which judges the argument in the range of the 
1886         corresponding integer type.
1887         * trans-intrinsic.c (gfc_conv_intrinsic_mod): MOD and MODULO can work
1888         for the large values.
1889  
1890 2003-09-05  Paul Brook  <paul@nowt.org>
1891
1892         * f95-lang.c (expand_function_body): Gimplify the function.
1893
1894 2003-09-04  Jeff Law  <law@redhat.com>
1895
1896         * f95-lang.c (DEFINE_MATH_BUILTIN): C arrays start at
1897         index zero!
1898
1899 2003-09-04  Paul Brook  <paul@nowt.org>
1900
1901         * f95-lang.c (gfc_define_builtin): Also set implicit_built_in_decls.
1902         (gfc_expand_stmt): New function.
1903         (LANG_HOOKS_RTL_EXPAND_STMT): Define.
1904         (expand_function_body): Use tree_rest_of_compilation.
1905         * trans-decl.c (gfc_generate_function_code): Don't free cfun.
1906
1907 2003-09-03  Jeff Law  <law@redhat.com>
1908
1909         * f95-lang.c (gfc_init_builtin_functions): C arrays start at
1910         index zero!
1911
1912 2003-08-30  Paul Brook  <paul@nowt.org>
1913
1914         * f95-lang.c (builtin_function): Remove #if 0 code.
1915         (gfc_define_builtin): New function.
1916         (gfc_init_builtin_functions): Use mathbuiltins.def not ../builtins.def.
1917         * mathbuiltins.def: New file.
1918         * trans-intrinsic.c (gfc_intrinsic_map_t): Add builtin code fields.
1919         (gfc_intrinsic_map): Use mathbuiltins.def.
1920         (gfc_intrinsic_builtin_t): Remove.
1921         (gfc_build_intrinsic_lib_fndecls): Update.
1922         * trans-types.c (gfc_init_types): Remove redundant initilaization of
1923         signed_size_type_node.
1924
1925 2003-08-29  Paul Brook  <paul@nowt.org>
1926
1927         * arith.c (gfc_real_kinds): Use correct minimum exponents.
1928
1929 2003-08-22  Kejia Zhao  <kejia_zh@yahoo.com.cn>
1930
1931         * trans-instinsic.c (gfc_conv_intrinsic_mod): Also do MODULO.
1932         (gfc_conv_intrinsic_function): Add MODULO.
1933
1934 2003-08-22  Jason Merrill  <jason@redhat.com>
1935
1936         * trans-array.c (gfc_conv_expr_descriptor): Update use of predicates.
1937
1938 2003-08-22  Andreas Jaeger  <aj@suse.de>
1939
1940         * Make-lang.in (f95.install-common): Add DESTDIR support.
1941         * (f95.install-info): Likewise.
1942         (f95.uninstall): Likewise.
1943
1944 2003-08-19  Diego Novillo  <dnovillo@redhat.com>
1945
1946         * trans-types.c (gfc_init_types): Initialize
1947         signed_size_type_node with size_type_node.
1948
1949 2003-08-18  Paul Brook  <paul@nowt.org>
1950
1951         * dependency.c (gfc_dependency): New enum.
1952         (check_another_array_ref): Remove.
1953         (gfc_get_array_from_component): Remove.
1954         (get_x): Remove.
1955         (get_range): Remove.
1956         (get_no_of_elements): Use mpz_t, not mpf_t.
1957         (transform_sections): New function.
1958         (gfc_check_range_range): Rename ...
1959         (gfc_check_section_vs_section): ... to this.  Use new function.
1960         (gfc_is_inside_range): Rewrite to match.
1961         (gfc_check_element_vs_section): Ditto.
1962         (gfc_check_element_vs_element): Ditto.
1963         (get_deps): Ditto.
1964         (gfc_dep_resolver): Ditto.  Remove unused parameter.
1965         * Dependency.h (gfc_check_range_range, gfc_check_element_vs_section,
1966         gfc_check_element_vs_element, gfc_is_inside_range,
1967         gfc_get_array_from_component): Remove prototypes for static functions.
1968         (gfc_dep_resolver): Update prototype.
1969         * trans-array.c (gfc_conv_resolve_dependencies): Change to match.
1970
1971 2003-08-15  Paul Brook  <paul@nowt.org>
1972
1973         * trans-decl.c (gfc_build_qualified_array): Don't add symbols for
1974         return values to parent scope.
1975         (gfc_build_dummy_array_decl): Ditto.
1976
1977 2003-08-14  Paul Brook  <paul@nowt.org>
1978
1979         * trans-stmt.c (gfc_trans_allocate): Handle NULL refs. Allocate the
1980         size of the type, not the pointer.
1981         * resolve.c (resolve_symbol): Give more accurate error message.
1982
1983 2003-08-10  Paul Brook  <paul@nowt.org>
1984
1985         * trans-decl.c (gfc_build_function_decl): Only mangle global symbols.
1986
1987 2003-08-10  Paul Brook  <paul@nowt.org>
1988
1989         * trans-stmt.c (gfc_trans_allocate): Correctly handle non-array derived
1990         type components.
1991
1992 2003-08-10  Chun Huang  <compiler@sohu.com>
1993  
1994         * resolve.c (resolve_formal_arglist): Resolve STATEMENT function.
1995         (resolve_symbol): Ditto.
1996         * trans-expr.c (gfc_conv_statement_function): New function.
1997         (gfc_conv_function_expr): Use it.
1998
1999 2003-08-10  Paul Brook  <paul@nowt.org>
2000
2001         * trans-array.c (gfc_conv_ss_startstride): Handle functions.
2002         (walk_function_expr): Set section rank.
2003         * trans-intrinsic.c (gfc_walk_intrinsic_libfunc): Ditto.
2004
2005 2003-08-10  Paul Brook  <paul@nowt.org>
2006
2007         * intrinsic.c (add_sym): Prefix names with correct string.
2008         (add_sym_0s): New function.
2009         (add_subroutines): Register abort.
2010
2011 2003-08-10  Erik Schnetter  <schnetter@uni-tuebingen.de>
2012
2013         * gfortran.h: Introduce options to control the mangling.
2014         * lang.opt: Likewise.
2015         * options.c (gfc_init_options): Handle the options.
2016         * trans-common.c (gfc_sym_mangled_common_id): New function.
2017         (gfc_build_common_decl): Call it.
2018         * trans-decl.c (gfc_sym_mangled_function_id): New function.
2019         (gfc_get_extern_function_decl, gfc_build_function_decl): Call it.
2020
2021 2003-08-09  Paul Brook  <paul@nowt.org>
2022
2023         * module.c (mio_symbol): Always ouput a namespace for formal args.
2024         (load_needed): Namespace now belong to their proper symbol.
2025         (gfc_dump_module): Change G95=>GFORTRAN.
2026
2027 2003-08-05  Paul Brook  <paul@nowt.org>
2028
2029         * options.c: Force -fg77-calls.
2030
2031 2003-08-02  Paul Brook  <paul@nowt.org>
2032
2033         * Makelang.in: Rename G95_* to GFORTRAN_*.
2034         * All sources: Rename G95_* to GFC_*.
2035
2036 2003-08-01  Paul Brook  <paul@nowt.org>
2037
2038         * fortran/Make-lang.in: Use GMPLIBS.
2039         * fortran/config-lang.in: Set need_gmp.
2040         * trans-expr.c (gfc_conv_variable): Remove incorrect assertion.
2041
2042 2003-07-27  Andreas Jaeger  <aj@suse.de>
2043
2044         * trans-decl.c (gfc_generate_constructors): Convert prototype to
2045         ISO C90.
2046         * trans-const.c (gfc_init_constants): Likewise.
2047         * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Likewise.
2048
2049         * gfortranspec.c: Convert to ISO C90.
2050         (lang_specific_driver): Correct copyright, remove ALT_LIBM usage.
2051
2052 2003-07-26  Paul Brook  <paul@nowt.org>
2053
2054         * lang.opt: Add -fdump-parse-tree.
2055         * options.c (gfc_handle_option): Ditto.
2056         * resolve.c (resolve_forall_iterators): Convert to proper type.
2057         * trans-stmt.c (gfc_trans_forall_1): Create temp var with correct type.
2058
2059 2003-07-26  Paul Brook  <paul@nowt.org>
2060
2061         * Makefile.in: Add build dependencies on files common with rest of gcc.
2062
2063 2003-07-26  Lifang Zeng  <zlf605@hotmail.com>
2064
2065         * trans.h: Declare g95_trans_pointer_assignment.
2066         * trans-expr.c (g95_trans_pointer_assignment): New function.
2067         (g95_trans_pointer_assign): Use it.
2068         * trans-stmt.c (g95_trans_forall_1): Handle pointer assignment.
2069         (g95_trans_pointer_assign_need_temp): New function.
2070
2071 2003-07-26  Paul Brook  <paul@nowt.org>
2072
2073         * gfortran.texi: Replace references to g95.
2074
2075 2003-07-26  Paul Brook  <paul@nowt.org>
2076
2077         Rename g95_* to gfc_*.
2078
2079 2003-07-25  Paul Brook  <paul@nowt.org>
2080         
2081         * gfortran.h: Rename from g95.h.
2082         * trans-types.c (boolean_type_node, booelan_true_node,
2083         boolean_false_node): Remove.
2084         * trans-types.h: Ditto.
2085
2086 2003-07-25  Chun Huang  <compiler@sohu.com>
2087
2088         * parse.c (accept_statement): Implement BLOCK DATA statement.
2089         * trans-expr.c (g95_conv_variable): Fix bug for dereference pointer
2090         variables.
2091
2092 2003-07-24  Lifang Zeng  <zlf605@hotmail.com>
2093
2094         * trans-stmt.c (temporary_list): Define.
2095         (g95_trans_assign_need_temp): New function.
2096         (g95_trans_forall_1): Modified for WHERE.
2097         (g95_trans_where_assign): Modified.
2098         (g95_trans_where_2): Modified.
2099         (g95_evaluate_where_mask): Modified.
2100         (g95_trans_where): Modified.
2101         (g95_get_temp_expr): Removed.
2102         (g95_add_to_where_stmt_list): Removed.
2103         (compute_overall_iter_number): Modified for WHERE.
2104         * trans.h: Remove where_stmt_list.
2105
2106 2003-07-24  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2107
2108         * lang.opt: Correct description of options -J and -M.
2109
2110 2003-07-23  Steven Bosscher   <steven@gcc.gnu.org>
2111
2112         * lang.opt: Move help text to here.
2113         * lang-options.h: Remove.
2114
2115 2003-07-23  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2116         * iresolve.c (g95_resolve_transpose): Proper variable in switch.
2117         * simplify.c (g95_simplify_nearest): Fix typo and use a correct test
2118         on kind.
2119
2120 2003-07-22  Steven Bosscher  <steven@gcc.gnu.org>
2121         Paul Brook  <paul@nowt.org>
2122
2123         * check.c (check_rest): Use global pedantic flag.
2124         * io.c (data_desc): Ditto.
2125         * error.c (g95_warning, g95_warning_now): Use global flag.
2126         * f95-lang.c (LANG_HOOKS_HANDLE_OPTION): Rename from DECODE.
2127         (expand_function_body): Update to new prototypes.
2128         (g95_init): Use new option names.
2129         * g95.h (g95_option_t): Standardize names.
2130         (g95_init_options, g95_handle_option): Update prototypes.
2131         * interface.c: Use new option names.
2132         * match.c: Ditto.
2133         * module.c: Ditto.
2134         * parse.c: Ditto.
2135         * primary.c: Ditto.
2136         * resolve.c: Ditto.
2137         * scanner.c: Ditto.
2138         * simplify.c: Ditto.
2139         * symbol.c: Ditto.
2140         * trans-array.c: Ditto.
2141         * trans-expr.c: Ditto.
2142         * trans-types.c: Ditto.
2143         * trans-decl.c: Ditto.
2144         (g95_build_library_function_decl): Remove obsolete VPARAMS.
2145         * trans.h: Ditto.
2146         * options.c (g95_display_help): Remove.
2147         (g95_init_options): Convert to new scheme.
2148         (set_Wall): Ditto
2149         (g95module_option): Ditto, rename from g95_parse_arg.
2150         (g95_handle_module_path_options): New function.
2151         * trans-equivalence.c: Fix error message.
2152         * lang.opt: Corrections.
2153
2154 2003-07-21  Steven Bosscher  <steven@gcc.gnu.org>
2155
2156         * lang.opt: New file.
2157
2158 2003-07-21  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2159
2160         * decl.c (match_attr_spec): Set colon_seen.
2161
2162 2003-07-14  Paul Brook  <paul@nowt.org>
2163
2164         * trans-array.c: Update comment.
2165         (g95_trans_array_constructor_subarray): Cleanup loopinfo data.
2166         * trans-intrinsic.c (g95_conv_intrinsic_anyall,count,arith,
2167         minmaxloc,minmaxval): Ditto.
2168         * trans-io.c (g95_trans_transfer): Ditto.
2169         * trans-stmt.c: Remove unneeded prototypes.
2170         (generate_loop_for_lhs_to_rhs): Rename vars. Add loop post chain.
2171         (generate_loop_for_rhs_to_temp): Rename vars. Don't share loopinfo.
2172         (compute_inner_temp_size): Remove bits of dead code. Add comments.
2173         Don't share loopinfo.
2174         (compute_overall_iter_number): Declare as static.
2175         (allocate_temp_for_forall_nest): Ditto.
2176         (g95_trans_forall_1): Don't pass shared loopinfo.
2177         * trans.c (g95_start_block): Expand comment.
2178
2179 2003-07-12  Paul Brook  <paul@nowt.org>
2180
2181         * arith.c (g95_index_integer_kind): Remove unused initializer.
2182         * trans-stmt.c (generate_loop_for_temp_to_lhs): Don't multiply array
2183         index by size of element.
2184         (generate_loop_for_rhs_to_temp): Ditto.
2185         (allocate_temp_for_forall_nest): Use element size, not index size.
2186
2187 2003-07-11  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2188
2189         * arith.c (g95_index_integer_kind): Add a TODO.
2190         * simplify.c (g95_simplify_nearest): Add a TODO.
2191
2192 2003-07-09  Chun Huang  <compiler@sohu.com>
2193
2194         * trans.h: Add declarations for gfor_fndecl_string_scan and
2195         gfor_fndecl_string_verify.
2196         * trans-decl.c (g95_build_intrinsic_function_decls): Build them.
2197         * trans-intrinsic.c (g95_conv_intrinsic_scan): New function.
2198         (g95_conv_intrinsic_verify): New function.
2199         (g95_conv_intrinsic_function): Add SCAN and VERIFY.
2200         * simplify.c (g95_simplify_scan, g95_simplify_verify): Fix bug in case
2201         of parameter 'BACK=.TRUE.'
2202
2203 2003-07-05  Lifang Zeng  <zlf605@hotmail.com>
2204
2205         * trans-stmt.c (iter_info, forall_info): Define.
2206         (g95_trans_forall_block): Remove.
2207         (g95_trans_forall_loop): Use forall info blocks.
2208         (g95_trans_nested_forall_loop): New function.
2209         (g95_do_allocate): Handle things other than logical masks.
2210         (generate_loop_for_temp_to_lhs): New function.
2211         (generate_loop_for_rsh_to_temp): New function.
2212         (compute_inner_temp_size): New function.
2213         (compute_overall_iter_number): New function.
2214         (allocate_temp_for_forall_nest): New function.
2215         (g95_trans_forall): Move body ...
2216         (g95_trans_forall_1): ... to here.  Handle loops with temporaries.
2217
2218 2003-07-02  Paul Brook  <paul@nowt.org>
2219
2220         * trans-decl.c (create_index_var, g95_build_qualified_array): Put vars
2221         in correct scope.  Change callers to match.
2222         * trans-types.c (g95_get_dtype_cst): Allow rank 7 arrays.
2223         * iresolve.c (g95_resolve_reshape): Only use constant shapes.
2224
2225 2003-07-02  Paul Brook  <paul@nowt.org>
2226
2227         * trans-array.c (g95_conv_loop_setup): Remove dead var.  Use
2228         expression shape for all expressions.
2229         * trans-decl.c (g95_symbol_init): Allow adding at very end of list.
2230
2231 2003-07-03  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2232
2233         * g95.h (g95_option_t), lang-options.h, options.c (g95_init_options,
2234         g95_parse_arg), intrinsic.c (g95_convert_type): support of
2235         -Wconversion.
2236         * intrinsic.c, g95.h: Add g95_convert_type_warn,
2237         * resolve.c (g95_resolve_index): Call it.
2238
2239 2003-07-02  Paul Brook  <paul@nowt.org>
2240
2241         * iresolve.c (g95_resolve_reshape): Set expression shape.
2242         (g95_resolve_shape): Ditto.
2243         * simplify.c (g95_simplify_shape): Move common code outside condition.
2244         * trans-array.c (g95_conv_array_initializer): Teach it how to count.
2245
2246 2003-07-01  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2247
2248         * array.c (g95_array_dimen_size): Deal with EXPR_ARRAY to improve
2249         conformance checks.
2250
2251 2003-06-29  Paul Brook  <paul@nowt.org>
2252
2253         * array.c (g95_simplify_iterator_var): Don't bother with return value.
2254         * expr.c (find_array_element, find_component_ref): New functions.
2255         (remove_subobject_ref): New function.
2256         (simplify_const_ref): Use them.  Rename from simplify_component_ref.
2257         (simplify_ref_chain): New function.
2258         (g95_simplify_expr): Use it.  Simplify parameter variable subobjects.
2259         (g95_specification_expr): Simplify the expression.
2260         * resolve.c (resolve_operator): Check simplifications return code.
2261         (g95_resolve_expr): Ditto.
2262
2263 2003-06-26  Paul Brook  <paul@nowt.org>
2264
2265         * expr.c (simplify_component_ref): New function.
2266         (g95_simplify_expr): Use it.
2267         * resolve.c (resolve_structure_cons): Handle references.
2268
2269 2003-06-25  Paul Brook  <paul@nowt.org>
2270
2271         * trans-io.c (build_dt): Handle internal units.
2272
2273 2003-06-25  Canqun Yang  <canqun@yahoo.com.cn>
2274
2275         * trans-common.c (g95_build_common_decl): Array index range starts at 0.
2276         (g95_build_common_decl, g95_layout_global_equiv, g95_trans_one_common):
2277         Use g95_array_index_type instead of integer_type_node.
2278         (g95_build_common_decl, g95_set_common_master_type): Use
2279         g95_character1_type_node instead of char_type_node.
2280         * trans-equivalence.c (g95_layout_local_equiv): As above.
2281
2282 2003-06-24  Steven G. Kargl  <kargls@attbi.com>
2283
2284         * g95.h (g95_option_t), options.c (g95_init_options, g95_parse_arg):
2285         remove last remains of -fquiet.
2286
2287 2003-06-22  Paul Brook  <paul@nowt.org>
2288
2289         * resolve.c (resolve_operator): Don't fail if we can't simplify.
2290         (g95_resolve_expr): Ditto.
2291         (resolce_code): Mark as static.
2292         * trans-stmt.c (g95_trans_chaaracter_select): Mark labels because the
2293         gimplifer doesn't (yet).
2294
2295 2003-06-20  Paul Brook  <paul@nowt.org>
2296
2297         * g95.h: Add ST_PAUSE and EXEC_PAUSE.
2298         * match.c (g95_match_if): Add ST_PAUSE.
2299         (g95_match_stopcode): New function.
2300         (g95_match_pause, g95_match_stop): Use it.
2301         * parse.c (g95_ascii_statement): Handle ST_PAUSE.
2302         (decode_stmt, next_statement, parse_executable): Ditto.
2303         * resolve.c (resolve_code): Ditto.
2304         * st.c (g95_free_statement): Ditto.
2305         * trans-stmt.c (g95_trans_pause): New function.
2306         * trans-stmt.h: Declare it.
2307         * trans.c (g95_trans_code): Use it.
2308         * trans-decl.c (gfor_fndecl_pause_numeric, gfor_fndecl_pause_string):
2309         Declare.
2310         (g95_build_builtin_function_decls): Initialize them.
2311         * trans.h: Ditto.
2312         * dump-parse-tree.c (g95_show_code_node): Handle EXEC_PAUSE.
2313
2314 2003-06-18  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2315
2316         * io.c (g95_match_open , g95_match_close, g95_match_inquire,
2317         match_filepos): Fix error handling.
2318
2319 2003-06-18  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2320
2321         * array.c (spec_dimen_size, ref_dimen_size, g95_array_dimen_size):
2322         Add assertions on arguments.
2323         * resolve.c (expression_shape): Remove useless &.
2324         * simplify.c (get_kind, g95_simplify_bit_size, g95_simplify_digits,
2325         g95_simplify_ibclr, g95_simplify_ibits, g95_simplify_ibset,
2326         g95_simplify_ishft,g95_simplify_ishftc, g95_simplify_maxexponent,
2327         g95_simplify_minexponent, g95_simplify_radix, g95_simplify_range
2328         g95_simplify_rrspacing, g95_simplify_scale, g95_simplify_spacing,
2329         g95_simplify_tan, g95_simplify_tiny): Clean predicates and assertions.
2330         (g95_simplify_not, g95_simplify_scale): Add assertions.
2331
2332 2003-06-15  Paul Brook  <paul@nowt.org>
2333
2334         Clean up stuff to work with the ssa optimizers.
2335         * convert.c (convert): Handle BOOLEAN_TYPEs.
2336         * f95-lang.c (g95_truthvalue_conversion): Implement.
2337         * trans-array.c (g95_trans_array_constructor_value): Group multiple
2338         scalar values.
2339         * trans.h (g95_truthvalue_conversion): Declare.
2340         * trans-intrinsic.c (g95_conv_intrinsic_anyall): Use bool constants.
2341         * trans-stmt.c (g95_trans_character_select): Don't create array
2342         assignments.  Mark labels as indirect jump targets.
2343         * trans-types.h (g95_init_types): Use BOOLEAN_TYPE nodes.
2344         (g95_get_dtype_cst): Handle LOGICAL types.
2345
2346 2003-06-14  Paul Brook  <paul@nowt.org>
2347
2348         * f95-lang.c (g95_gimplify_expr): New function.
2349         * trans-array.c (g95_trans_array_constructor_value): Don't create
2350         array assignments.
2351         (g95_conv_expr_descriptor): Rename simple->gimple.
2352         * trans-expr.c (conv_expr_op): Use proper logical operators.
2353         * trans-intrinsic.c (build_fixbound_expr): New function.
2354         (build_fix_expr): Ditto.
2355         (g95_conv_intinsic_aint): Use them. Use builtin functions.
2356         (g95_conv_intrinsic_function): Add FLOOR and CEILING.
2357
2358 2003-06-10  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2359
2360         * array.c (g95_compare_array_spec): Remove unreachable code.
2361         * expr.c (g95_copy_expr): Likewise.
2362         * intrinsic.c (g95_convert_type): Likewise.
2363         * misc.c (g95_code2string): Likewise.
2364         * simplify.c (g95_simplify_ishft, g95_simplify_real,
2365         g95_simplify_reshape, g95_simplify_sign, g95_simplify_sqrt): Likewise.
2366         * trans-stmt.c (g95_trans_select): Likewise.
2367         * primary.c (extend_ref): Add an assertion.
2368         * simplify.c (g95_convert_constant): Add const.
2369         * intrinsic.h: Remove g95_check_x_ni.
2370         * f95-lang.c (g95_finish): Call g95_release_include_path.
2371
2372 2003-06-10  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2373
2374         * resolve.c (resolve_contained_functions): Fix typo introduced on
2375         2003-01-13.
2376
2377 2003-06-09  Paul Brook  <paul@nowt.org>
2378
2379         * g95.h: Include system.h not hwint.h.
2380         * many: use safe-ctype.h not ctype.h.  Change isalpha -> ISALPHA, etc.
2381         * misc.c (g95_getmem): Use xmalloc/memset instead of calloc.
2382
2383 2003-06-09  Paul Brook  <paul@nowt.org>
2384
2385         * g95.h (g95_symbol): Add fields for COMMON and EQUIVALENCE variables.
2386         * Make-lang.in (F95_OBJS): Add files for COMMON and EQUIVALENCE.
2387         * trans-decl.c (g95_add_decl_to_functions): Make non-static.
2388         (g95_get_symbol_decl): Handle COMMON and EQUIVALENCE objects.
2389         (g95_generate_function_code): Translate COMMON and EQUIVALENCE
2390         objects.
2391         * trans.h (g95_trans_equivalence, g95_trans_common,
2392         g95_add_decl_to_function): Declare.
2393         * trans-common.c, trans-equivalence.c: New files.
2394
2395 2003-06-08  Steven Bosscher  <steven@gcc.gnu.org>
2396
2397         * intrinsic.c (g95_intrinsic_extension): Remove.
2398         (add_functions): Substitute g95_check_x for g95_check_x_ni
2399         everywhere.
2400         (g95_init_expr_extensions): New function.
2401         (g95_intrinsic_func_interface): Use it.
2402         * intrinsic.h: Remove extern decl for g95_intrinsic_extension.
2403         * check.c (g95_check_digit, g95_check_huge, g95_check_kind,
2404         g95_check_precision, g95_check_present, g95_check_radix,
2405         g95_check_range, g95_check_selected_real_kind): Do not set
2406         g95_intrinsic_extension.
2407         (g95_check_x_ni): Remove now duplicate of g95_check_x.
2408
2409         * expr.c (check_inquiry): Add FIXME, fixup some code style.
2410
2411 2003-06-06  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2412
2413         * g95.h (ref_type): Name this type explicitly.
2414         * module.c (MIO_NAME): Add specialisations of mio_name.
2415         (mio_symbol_attribute, mio_typespec, mio_array_ref,
2416         mio_array_spec, mio_ref, mio_expr, mio_symbol): Use them.
2417         (ab_attribute): Name this type explicitly.
2418         (mio_symbol_attribute, mio_expr): Add cast to call to find_enum.
2419
2420 2003-06-05  Kejia Zhao  <kejia_zh@yahoo.com.cn>
2421
2422         * trans-intrinsic.c (g95_conv_allocated): New function.
2423         (g95_conv_intrinsic_function): Make G95_ISYM_ALLOCATED work.
2424
2425 2003-06-05  Steven Bosscher  <steven@gcc.gnu.org>
2426
2427         * f95-lang.c: Don't include g95-support.h
2428         (g95_mark_addressable): Add prototype.
2429         (g95_init_decl_processing): Remove C front end hack.
2430         * f95-tree.c: Remove file.
2431         * support.c: Remove file.
2432         * g95-support.h: Remove file.
2433         * trans-types.c (g95_init_types): Set up boolean
2434         type related tree nodes.
2435         * Make-lang.in: Remove rules for dead files and
2436         dependencies on them.
2437
2438 2003-06-05  Steven Bosscher  <steven@gcc.gnu.org>
2439
2440         * Make-lang.in (F95_ADDITIONAL_OBJS): Remove the final
2441         C front end dependency.  Also, convert.c does not depend on
2442         g95-support.h anymore.
2443         * convert.c: Don't include c-common.h and g95-support.h
2444         * f95-lang.c: Don't inlude c-common.h and c-common.def (3x).
2445         (g95_stmt_tree, g95_scope_stmt_stack, anon_aggr_type_p,
2446         stmts_are_full_exprs_p, current_stmt_tree,
2447         current_scope_stmt_stack): Remove.
2448         * g95-support.h (unsigned_conversion_warning): Kill proto.
2449         (boolean_type_node, boolean_true_node, boolean_false_node):
2450         Don't define here.  Instead, make then true tree nodes in
2451         trans-types.
2452         * support.c (c_global_trees): Die, C front end, die!!!
2453         (g95_init_c_decl_hacks): Don't touch intmax_type_node,
2454         uintmax_type_node, string_type_node and const_string_type_node.
2455         (decl_constant_value, overflow_warning): Make static functions.
2456         They are in death row too, though.
2457         (default_conversion, c_expand_asm_operands): Remove.
2458         * trans-array.c, trans-expr.c, trans-intrinsic.c, trans-stmt.c,
2459         trans.c: Don't include c-common.h.
2460         * trans-types.c (boolean_type_node, boolean_true_node,
2461         boolean_false_node): Make them real tree nodes.
2462         * trans-types.h (intmax_type_node, string_type_node,
2463         const_string_type_node): Hack to work around C dependencies
2464         in builtin-types.def.
2465
2466 2003-06-04  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2467
2468         * decl.c (decl_types): Add some iterators-like sentinels.
2469         * decl.c (match_attr_spec): Use them.
2470         Use "decl_types" instead of "int".
2471         Add cast in call to g95_match_strings.
2472         * dump-parse-tree.c (g95_show_namespace):  Use "g95_intrinsic_op"
2473         instead of "int".
2474         * g95.h (g95_intrinsic_op): Add some iterators-like sentinels.
2475         (g95_interface_info): Use "g95_intrinsic_op".
2476         * dump-parse-tree.c (g95_show_namespace): Use them.
2477         * interface.c (g95_check_interfaces): Use them.
2478         * module.c (read_module, write_module): Use them.
2479         * symbol.c (g95_get_namespace, g95_free_namespace): Use them.
2480         Use "g95_intrinsic_op".
2481         * interface.c (check_operator_interface): Use "g95_intrinsic_op".
2482         Add a default case in switch statement.
2483         * intrinsic.h (g95_generic_isym_id): Moved to...
2484         * g95.h (g95_generic_isym_id): here.
2485         (g95_intrinsic_sym): Use "g95_generic_isym_id".
2486         * intrinsic.c (make_generic): Use "g95_generice_isym_id".
2487         * trans-intrinsic.c (g95_intrinsic_map_t,
2488          g95_conv_intrinsic_lib_funtion): Use "g95_generice_isym_id".
2489         * match.c (g95_match_intrinsic_op): Add cast in call to
2490         g95_match_strings.
2491
2492 2003-06-03  Steven Bosscher  <steven@gcc.gnu.org>
2493
2494         * support.c (skip_evaluation, warn_conversion, lvalue_p,
2495         lvalue_or_else, pedantic_lvalue_warning, warn_for_assignment,
2496         constant_fits_type_p, convert_and_check,
2497         unsigned_conversion_warning): Remove these ugly remnants
2498         we inherited from the C front end.
2499         (function_types_compatible): Remove '#if 0'-edcode.
2500         (build_modify_expr): Likewise.
2501         (convert_for_assignment): Don't use the deceased functions.
2502         The parameter fundecl is now unused.
2503         (decl_constant_value): Always just return decl.  In fact
2504         this function is not used at present, but it might be in
2505         the future, when we start using the tree inliner.
2506         (overflow_warning, default_conversion, c_expand_asm_operands):
2507         Abort when these are called, they are part of the C type
2508         checking implementation and therefore poison to Fortran.
2509
2510 2003-06-04  Steven Bosscher  <steven@gcc.gnu.org>
2511
2512         * Make-lang.in (F95_ADDITIONAL_OBJS): Don't depend on
2513         c-pretty-print.o and c-dump.o.  Add a comment on why we
2514         depend on c-semantics.c.
2515         * f95-lang.c (LANG_HOOKS_TREE_DUMP_DUMP_TREE_FN):
2516         Don't use the C front end tree dumper hook to dump the
2517         language specific tree representation -- we don't have
2518         one.  So instead, inherit the default langhook.
2519
2520 2003-06-02  Paul Brook  <paul@nowt.org>
2521
2522         * trans-expr.c (g95_conv_variable): Remove incorrent assertion.
2523
2524 2003-06-02  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2525
2526         * check.c (g95_check_associated): Use proper types.  Remove
2527         extraneous argument in call to g95_error().
2528
2529 2003-06-02  Kejia Zhao  <kejia_zh@yahoo.com.cn>
2530
2531         * resolve.c (resolve_operator): Make logical operands convert to the
2532         type with higher kind.
2533
2534 2003-06-02  Kejia Zhao  <kejia_zh@yahoo.com.cn>
2535
2536         * check.c (g95_check_associated): Make sure both pointer and target has
2537         the same type and rank. Null pointer or array section with vector
2538         subscript as target are not allowed.
2539         * trans.h: Declare gfor_fndecl_associated.
2540         * trans-decl.c: (g95_build_builtin_function_decls): Initialize
2541         gfor_fndecl_associated.
2542         * trans-intrinsic.c (g95_conv_associated): New function.
2543         (g95_conv_intrinsic_function): Make G95_ISYM_ASSOCIATED work.
2544
2545 2003-06-02  Kejia Zhao  <kejia_zh@yahoo.com.cn>
2546
2547         * trans-array.c (g95_conv_expr_descriptor): Set the base of POINTER
2548         according to POINTER itself rather than TARGET.
2549         (g95_conv_expr_descriptor): Make lbound start at 1.
2550         * trans-expr.c (g95_trans_pointer_assign): Fix a bug for Nullify.
2551
2552 2003-06-01  Paul Brook  <paul@nowt.org>
2553
2554         * expr.c (g95_type_convert_binary): Make it match the standard.
2555         * g95.texi: Remove dead link.
2556
2557 2003-06-01  Steven Bosscher  <steven@gcc.gnu.org>
2558
2559         * g95.texi: Cleanup somewhat in preparation for inclusion
2560         in GCC CVS.
2561
2562 2003-05-23  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2563             Canqun Yang  <canqun@yahoo.com.cn>
2564
2565         * resolve.c (compare_bound_int, resolve_where_shape): Proper return
2566         type.
2567         (g95_find_forall_index): Return proper value.
2568         (g95_resolve_assign_in_forall, g95_resolve_forall): Use proper type to
2569         compare the return value from g95_find_forall_index.
2570
2571 2003-05-23  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2572         * g95.h, io.c (g95_st_label): Remove "length".
2573         (g95_symtree): Remove "link".
2574         (g95_case): Remove "code".
2575         * arith.c, arith.h (g95_compare_string, g95_convert_integer,
2576         g95_convert_real): Make an argument pointer to const.
2577         * decl.c (colon_seen): Add a TODO.
2578         * interface.c (g95_compare_types): Fix typo.
2579         * interface.c (compare_interfaces): Preserve value of "p".
2580         * intrinsic.c (sort_actual): Remove "i".
2581         * match.c (g95_match_assign): Proper type in call to g95_match().
2582         * parse.c (next_free): Avoid duplicate call due to macro.
2583         * parse.c (check_statement_label): wrong type in call to g95_error.
2584         * primary.c (match_real_constant): Add a TODO.
2585         * resolve.c (resolve_select):  Remove useless conditional.
2586         * simplify.c (g95_simplify_repeat): Proper assignment to
2587         "value.character.string".
2588         * simplify.c (g95_simplify_reshape): Wrong variable in call to
2589         g95_error.
2590
2591 2003-05-20  Canqun Yang  <canqun@yahoo.com.cn>
2592
2593         * trans-stmt.c: Remove unnecessary include file defaults.h.
2594
2595 2003-05-19  Lifang Zeng  <zlf605@hotmail.com>
2596
2597         * trans-stmt.c (g95_trans_forall_loop): Handle FORALL with negative
2598         stride.
2599         (g95_trans_forall): Allow arbitrary number of FORALL indexes and
2600         actual variables used as FORALL indexes.
2601
2602 2003-05-15  Paul Brook  <paul@nowt.org>
2603
2604         * trans-array.c (g95_trans_static_array_pointer): Use
2605         null_pointer_node.
2606         (g95_trans_deferred_array): Initialize static array pointers.
2607         * trans-expr.c (g95_conv_function_call): Use formal arglist to
2608         correctly pass POINTER and absent CHARACTER arguments.
2609
2610 2003-05-14  Lifang Zeng  <zlf605@hotmail.com>
2611
2612         * resolve.c (g95_resolve_forall): Resolve FORALL construct/statement.
2613         (g95_resolve_forall_body): Resolve FORALL body.
2614         (g95_resolve_where_code_in_forall): Resolve WHERE inside FORALL.
2615         (g95_resolve_assign_in_forall): Resolve assignment inside FORALL.
2616         (g95_find_forall_index): Check whether the FORALL index appears in
2617         the expression or not.
2618         (resolve_code): Modified.
2619
2620 2003-05-14  Paul Brook  <paul@nowt.org>
2621
2622         * iresolve.c (g95_resolve_spread): Convert ncopies to index_type.
2623
2624 2003-05-13  Paul Brook  <paul@nowt.org>
2625
2626         * trans-types.c (g95_max_array_element_size): Now a tree node.
2627         (g95_init_types): Work out max size properly.
2628         (g95_get_dtype_cst): Modify to match.
2629
2630 2003-05-11  Paul Brook  <paul@nowt.org>
2631
2632         * trans-io.c (add_case): Create a label decl for case labels.
2633
2634 2003-05-11  Paul Brook  <paul@nowt.org>
2635
2636         * arith.c (g95_integer_index_kind): New variable.
2637         * f95-lang.c (g95_init): Move frontend initialization here ...
2638         (g95_post_options): ... from here.
2639         * g95.h (g95_index_integer_kind, g95_resolve_index): Declare.
2640         * intrinsic.c (add_functions): Use index kinds.
2641         * iresolve.c: Convert to index_kind where needed.
2642         * resolve.c (g95_resolve_index): Make public, use index_kind.
2643         (resolve_array_ref): Adjust to match.
2644         * trans-array.c: Rename g95_array_index_kind to g95_index_integer_kind.
2645         * trans-stmt.c: Ditto.
2646         * trans-types.c: Ditto.
2647         * trans-types.h (g95_array_index_kind): Remove declaration.
2648         * trans-expr.c (g95_conv_expr_present): Use null_pointer_node.
2649
2650 2003-05-07  Paul Brook  <paul@nowt.org>
2651
2652         * trans-const.c (g95_conv_mpz_to_tree): Typecast constant.
2653         * trans-intrinsic.c (g95_conv_intrinsic_bound): Convert type
2654         of bound indices.
2655
2656 2003-05-07  Paul Brook  <paul@nowt.org>
2657
2658         * trans-array.c (trans_static_array_pointer,
2659         g95_trans_array_constructor_value, g95_conv_array_initializer,
2660         g95_conv_structure): CONSTRUCTOR nodes only have one operand.
2661         (g95_add_loop_ss_code): Convert subscripts to the correct type.
2662         * trans-stmt.c (g95_trans_character_select): Ditto.
2663         * trans-types.c (g95_init_types): Ditto.
2664
2665 2003-05-07  Steven Bosscher  <steven@gcc.gnu.org>
2666
2667         * f95-lang.c (expand_function_body): Use input_line, not lineno.
2668         * trans-decl.c (g95_generate_function_code,
2669         g95_generate_constructors): Likewise.
2670         * trans.c (g95_trans_runtime_check, g95_add_block_to_block,
2671         g95_get_backend_locus, g95_set_backend_locus, g95_trans_code):
2672         Likewise.
2673
2674 2003-05-07  Kejia Zhao  <kejia_zh@yahoo.com.cn>
2675         * trans-types.c (g95_get_derived_type): Fix bug for DERIVED type
2676         with components point to the DERIVED type itself, and two DERIVED
2677         type with components point to each other.
2678         * trans-expr.c (g95_conv_componet_ref): Modified
2679
2680 2003-05-07  Kejia Zhao  <kejia_zh@yahoo.com.cn>
2681         * trans-expr.c (g95_conv_expr): Translate EXPR_NULL into
2682         null_pointer_node.
2683         (g95_trans_pointer_assign): Implement Nullify.
2684
2685 2003-05-01  Paul Brook  <paul@nowt.org>
2686
2687         * trans-array.c (g95_walk_function_expr): Cope with NULL esym.
2688         * trans-decl.c (g95_get_symbol_decl): Don't mangle dummy functions.
2689
2690 2003-05-01  Paul Brook  <paul@nowr.org>
2691
2692         * trans-array.c, trans.c, trans-expr.c, trans-intrinsic.c,
2693         trans-stmt.c: Replace empty_stmt_node with build_empty_stmt () and
2694         IS_EMPTY_STMT.
2695
2696 2003-05-01  Canqun Yang  <canqun@yahoo.com.cn>
2697
2698         * trans-stmt.c (g95_trans_integer_select): Add a parameter to build
2699         CASE_LABEL_EXPR.
2700
2701 2003-04-28  Paul Brook  <paul@nowt.org>
2702
2703         * iresolve.c (g95_resolve_transpose): COMPLEX types are twice as big
2704         as their kind suggests.
2705         (g95_resolve_reshape): Ditto.
2706
2707 2003-04-28  Chun Huang  <compiler@sohu.com>
2708
2709         * trans-expr.c (g95_conv_substring_expr): New function.
2710         (g95_conv_expr): Use it.
2711
2712 2003-04-28  Paul Brook  <paul@nowt.org>
2713
2714         * iresolve.c (g95_resolve_transpose): Make it match the
2715         implementation.
2716         * trans-intrinsic.c (g95_is_intrinsic_libcall): Add TRANSPOSE.
2717
2718 2003-04-18  Steven Bosscher  <steven@gcc.gnu.org>
2719
2720         * trans-types.c (g95_add_field_to_struct): New function to
2721         add a field to a UNION_TYPE or RECORD_TYPE.
2722         * trans-types.h (g95_add_field_to_struct): Prototype.
2723         (g95_get_derived_type): Use g95_add_field_to_struct to add
2724         components.
2725         * trans-io.c (g95_add_field): Remove.
2726         (ADD_FIELD): Use new g95_add_field_to_struct function.
2727         (ADD_STRING): Likewise.
2728         * trans-stmt.c (g95_trans_select): Likewise.
2729         (g95_add_field): Remove duplicated function.
2730
2731 2003-04-18  Canqun Yang  <canqun@yahoo.com.cn>
2732
2733         Port implementation for CHARACTER SELECT from Andy's tree.
2734         * trans-stmt.c (g95_trans_character_select): Implement character
2735         select. (g95_add_field): New function.
2736         * trans-decl.c: Declare 'gfor_gndecl_select_string'.
2737         (g95_build_builtin_function_decls): Add 'gfor_fndecl_select_string'.
2738         * g95.h (struct g95_case): Add field 'int n'.
2739         * trans.h: Declare 'gfor_fndecl_select_string'.
2740
2741 2003-04-18  Steven Bosscher  <steven@gcc.gnu.org>
2742
2743         * bbt.c (duplicate_key, g95_insert_bbt_with_overlap): Remove.
2744         (g95_insert_bbd): Die on duplicates.
2745         * g95.h (g95_insert_bbt_with_overlap): Delete prototype.
2746
2747 2003-04-14  Steven Bosscher  <steven@gcc.gnu.org>
2748
2749         * g95.texi: Require GMP 4.0 -- like we actually
2750         do.  Explain the testsuite and what-goes-where.
2751         Don't use undefined texinfo symbol.  Break very
2752         long line.  Remove finished item from the list
2753         of open projects.
2754
2755 2003-04-11  Canqun Yang  <canqun@yahoo.com.cn>
2756
2757         * trans-stmt.c (g95_evaluate_where_mask): Give mask temporaries
2758         LOGICAL type.
2759
2760 2003-04-10  Canqun Yang  <canqun@yahoo.com.cn>
2761
2762         * trans-stmt.c (g95_trans_forall): Implement WHERE inside FORALL.
2763         (g95_trans_forall_body): New function.
2764
2765 2003-04-10  Canqun Yang  <canqun@yahoo.com.cn>
2766
2767         * resolve.c (resove_where): New function.
2768         (resolve_where_shape): New function.
2769         (resolve_code): Add call to 'resolve_where'
2770         * trans-stmt.c (g95_trans_where): Modified.
2771         (g95_trans_where_2): New function.
2772         (g95_trans_where_assign): New function.
2773         (g95_evaluate_where_mask): New function.
2774         (g95_add_to_stmt_list): New function.
2775         (g95_get_temp_expr): New function.
2776         * trans.h (where_stmt_list): New structure.
2777
2778 2003-04-10  Paul Brook  <paul@nowt.org>
2779
2780         * g95spec.c (DEFAULT_SWITCH_TAKES_ARG): Remove.
2781         (DEFAULT_WORD_SWITCH_TAKES_ARG): Ditto.
2782
2783 2003-04-10  Steven Bosscher  <steven@gcc.gnu.org>
2784
2785         Update after mainline -> tree-ssa-branch merge.
2786         * f95-lang.c (g95_mark_addressable): Update put_var_into_stack
2787         call.
2788         (g95_init): Update for new lang_hooks definition.
2789         (g95_post_options): New langhook.
2790         (LANG_HOOK_POST_OPTIONS): Clear, then define to g95_post_options.
2791         * scanner.c (g95_new_file): Comment update.
2792
2793 2003-04-09  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2794
2795         * g95.h, lang-options.h: Add -Wimplicit-interface.
2796         * options.c (g95_init_options, g95_parse_arg): Set it.
2797         * interface.c (check_intents): Warn about call with implicit
2798         interface.
2799         * resolve.c (resolve_unknown_f, resolve_unknown_s): Call
2800         g95_procedure_use.
2801
2802 2003-04-05  Paul Brook  <paul@nowt.org>
2803
2804         * iresolve.c (g95_resolve_spread): Don't resole based on type.
2805         * trans-intrinsic.c (g95_is_intrinsic_libcall): Add G95_ISYM_SPREAD.
2806
2807 2003-03-29  Paul Brook  <paul@nowt.org>
2808
2809         * iresolve.c (g95_resolve_pack): Don't bother resolving based on type.
2810         (g95_resolve_unpack): Ditto.
2811         * trans-intrinsic.c (g95_conv_intrinsic_merge): New Function.
2812         (g95_conv_intrinsic_function): Use it.  Remove PACK and UNPACK.
2813         (g95_is_intrinsic_libcall): Add PACK and UNPACK.
2814
2815 2003-03-25  Paul Brook  <paul@nowt.org>
2816
2817         * arith.c (g95_unary_user, g95_user): Remove dead functions.
2818         * arith.h: Ditto.
2819         * array.c (g95_free_array_ref): Ditto.
2820         * g95.h: Ditto.
2821         * symbol.c (g95_use_derived_tree): Ditto.
2822         * intrinsic.c (add_functions): Use simplification for SCALE.
2823         * primary.c (g95_match_rvalue): Test sym, not symtree.
2824
2825 2003-03-25  Paul Brook  <paul@nowt.org>
2826
2827         * trans-decl.c (build_function_decl): Add parameter before it gets
2828         turned into a constant.
2829         * iresolve.c (g95_resolve_eoshift): Resolve to a useful name.
2830         * trans-intrinsic.c (g95_is_intrinsic_libcall): Add G95_ISYM_EOSHIFT.
2831         * trans-decl.c (g95_create_module_variable): Don't pushdecl constants.
2832
2833 2003-03-22  Paul Brook  <paul@nowt.org>
2834
2835         * trans-array.c (g95_conv_array_initializer): Allow scalar
2836         expressions.
2837         * trans-decl.c (g95_finish_var_decl): Result variables are not
2838         module variables.
2839         * trans-intrinsic.c (g95_conv_intrinsic_transfer): New function.
2840         (g95_conv_intrinsic_function): Use it.
2841         * trans-types.h (g95_type_spec): Remove dead declaration.
2842
2843 2003-03-21  Paul Brook  <paul@nowt.org>
2844
2845         * trans-decl.c (g95_build_function_decl): Mark string parameters.
2846
2847 2003-03-20  Paul Brook  <paul@nowt.org>
2848
2849         * trans-decl.c (g95_build_function_decl): Put character length
2850         parameters at the end of the function declaration.
2851         * trans-expr.c (g95_conv_function_call): Ditto.
2852         * trans-types.c (g95_get_function_type): Ditto.
2853
2854 2003-03-20  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2855
2856         * resolve.c (resolve_formal_arglist): Don't impose intent for
2857         procedure arguments of pure functions.
2858         (resolve_select): Remove redundant assignment.
2859
2860 2003-03-19  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
2861
2862         * arith.c (validate_logical), g95.h, options.c (g95_init_options):
2863         Remove option l1.
2864         * g95.h, intrinsic.c(g95_get_intrinsic_sub_symbol): Add const.
2865         * iresolve.c(g95_resolve_cpu_time, g95_resolve_random_number): Add
2866         const.
2867         * lang-options.h: Remove -finline-repack-arrays. Add -fg77-calls.
2868         Order list.
2869         * symbol.c (g95_add_type): Fix typo in comment.
2870
2871
2872 2003-03-16  Paul Brook  <paul@nowt.org>
2873
2874         * dump-parse-tree.c (g95_show_code_node): Print resolved sym name.
2875         * expr.c (g95_build_call): Remove.
2876         * f95-lang.c (puchdecl_top_level): New function.
2877         * g95.h (g95_code): Store resolved symbol, not just the name.
2878         * intrinsic.c (g95_intrinsic_namespace): New global namespace.
2879         (g95_intirinsic_init_1, g95_intrinsic_done_1): Use it.
2880         (g95_get_intrinsic_sub_symbol): New function.
2881         * iresolve.c (g95_resolve_cpu_time): Use it.
2882         (g95_resolve_random_number): Ditto.
2883         * resolve.c: Set code->resolved_sym instead of code->sub_name.
2884         * trans-decl.c (g95_get_extern_function_decl): Give external decls
2885         the correct DECL_CONTEXT.  Add global symbold to the global scope.
2886         * trans-stmt.c (g95_trans_code): Remove hacks now the fronted is
2887         fixed.
2888
2889 2003-03-16  Paul Brook  <paul@nowt.org>
2890
2891         * g95.h (g95_option_t): Add g77_calls. Remove inline_repack_arrays.
2892         * options.c (g95_parse_arg): Ditto.
2893         * module.c (mio_symbol_attribute): Handle the always_explicit bit.
2894         * resolve.c (resolve_formal_arglist): The always_explicit sould be set
2895         for the procedure, not the parameter.
2896         * trans-array.c (g95_trans_g77_array): New function.
2897         (g95_trans_assumed_size): Use it.
2898         (g95_trans_dummy_array_bias): Ditto.
2899         (g95_conv_array_parameter): Handle g77 arrays. Move existing body ...
2900         (g95_conv_expr_descriptor): ... to here.  Update callers.
2901         * trans-decl.c (g95_build_dummy_array_decl): Handle g77 arrays.
2902         (g95_get_symbol_decl): Avoid processing g77 arrays multiple times.
2903         * trans-expr.c (g95_conv_function_call): Handle g77 arrays.
2904         * trans-intrinsic.c (g95_get_symbol_for_expr): Never use g77 arrays.
2905         * trans-types.c (g95_is_nodesc_array): Handle g77 arrays.
2906         (g95_sym_type): Ditto.
2907
2908 2003-03-15  Paul Brook  <paul@nowt.org>
2909
2910         * trans-array.c (g95_walk_elemental_function_args): Don't amputate the
2911         first chain.
2912         * trans-expr.c (g95_conv_function_call): Use the resolved symbol.
2913
2914 2003-03-14  Paul Brook  <paul@nowt.org>
2915
2916         * trans-array.c (g95_array_is_packed): Remove.
2917         (g95_conv_array_base): Correctly handle all descriptorless cases.
2918         (g95_conv_array_stride): Use descriptorless strides.
2919         (g95_trans_dummy_array_bias): Don't always repack the array.
2920         (g95_build_dummy_array_decl): Automatic dummy arrays are only partial
2921         packed.
2922         * trans-types.c (g95_get_nodesc_array_type): Differentiate between
2923         dummy and non-dummy arrays...
2924         (g95_sym_type, g95_get_derived_type): ... like these.
2925         (g95_get_array_type_bounds): Allow discontiguous arrays.
2926
2927 2003-03-12  Paul Brook  <paul@nowt.org>
2928
2929         * array.c (g95_resolve_array_spec): Fix comment.
2930         * g95.h (symbol_attributes): New flag always_explicit.
2931         * resolve.c (resolve_formal_arglist): Set it always_explicit.
2932         * iresolve.c (g95_resolve_lbound, g95_resolve_ubound): Simplify.
2933         * trans-array.c (g95_conv_descriptor_dimension): Remove dead assert.
2934         (g95_trans_array_bounds): Allow assumed shape arrays.
2935         (g95_trans_repack_array): Remove.
2936         (g95_trans_dummy_array_bias): Rewite to use descriptorless arrays.
2937         * trans-decl.c (g95_build_qualified_array): Only ignore absent
2938         bounds for assumed size arrays.
2939         (g95_build_dummy_array_decl): Use descriptorless arrays.
2940         * trans-expr.c (g95_conv_expr_present): Allow descriptorless arrays.
2941         (g95_trans_pointer_assign): Fix typo.
2942         * trans-intrinsic.c (g95_conv_intrinsic_function_args): Remove dead
2943         code.
2944         (g95_conv_intrinsic_bound): Rewrite to handle descriptorless arrays.
2945         * trans-types.c (g95_get_nodesc_array_type): Allow non-packed arrays.
2946         Also modify callers.
2947         * trans-types.h (g95_get_nodesc_array_type): Modify prototype.
2948
2949 2003-03-08  Paul Brook  <paul@nowt.org>
2950
2951         * trans-array.c (g95_walk_elemental_functions): Don't reverse the SS.
2952         (g95_conv_array_ubound): Provide dummy value for assumed size arrays.
2953         * resolve.c (compare_spec_to_ref): Allow full array sections.
2954
2955 2003-03-08  Paul Brook  <paul@nowt.org>
2956
2957         * expr.c (g95_simplify_expr): Also simplify array index and
2958         substring expressions.
2959         * resolve.c (compare_spec_to_ref): Check for assumed size bounds.
2960         * trans-array.c (g95_trans_array_bounds): New function.
2961         (g95_trans_auto_array_allocation): Use it.
2962         (g95_trans_assumed_size): Rewrite.
2963         * trans-decl.c (gfor_fndecl_in_pack, gfor_fndecl_in_unpack): Declare.
2964         (gfor_fndecl_repack): Remove.
2965         (g95_build_qualified_array): Handle absent upper bounds.
2966         (g95_build_dummy_array_decl): Assumed shape arrays are descriptorless.
2967         (g95_get_symbol_decl): Update.
2968         (g95_build_intrinsic_function_decls): Initialize new decls.
2969         * trans.h (gfor_fndecl_in_pack, gfor_fndecl_in_unpack): Declare.
2970         (gfor_fndecl_repack): Remove.
2971         * trans-io.c (g95_build_io_library_fndecls): Correct prototypes.
2972         * trans-types.c: (g95_build_array_type): Merge duplicated code..
2973         (g95_get_nodesc_array_type): Handle absent bounds.
2974         * trans-types.h (g95_get_nodesc_array_type): Declare.
2975
2976 2003-03-04  Paul Brook  <paul@nowt.org>
2977
2978         * f95-lang.c (DEF_FUNCTION_TYPE_VAR_3): Define before including
2979         builtin-types.def.
2980
2981 2003-03-02  Paul Brook  <paul@nowt.org>
2982
2983         * options.c (g95_init_options): Drfault to 1.
2984         (g95_pasrse_arg): Add -frepack-arrays, use strcmp.
2985         * trans-array.c (g95_conv_array_data, g95_conv_array_base,
2986         g95_conv_array_stride,g95_conv_array_lbound, g95_conv_array_ubound):
2987         Handle non-constant size automatic arrays.
2988         (g95_conv_section_upper_bound, g95_conv_section_startstride): Use
2989         generic bound functions.
2990         (g95_trans_auto_array_allocation): Don't create a descriptor.
2991         (g95_trans_assumed_size): New function (broken).
2992         (g95_trans_dummy_array_bias): Remove unused var.
2993         * trans-array.h (g95_trans_assumed_size): Declare.
2994         * trans-decl.c (create_index_var): New fuction.
2995         (g95_build_qualified_array): New function.
2996         (g95_get_symbol_decl): Use it.
2997         (g95_trans_deferred_vars): Handle assumed shape seperately.
2998         * trans-types.c (get_element_type): Handle heap allocated arrays.
2999         (g95_is_nodesc_array): Include non-const size arrays.
3000         (g95_get_nodesc_array_type): Ditto.
3001
3002 2003-02-23  Paul Brook  <paul@nowt.org>
3003
3004         * trans-array.c (g95_array_init_size): Should use stride, not size of
3005         last dimension.
3006
3007 2003-02-18  Paul Brook  <paul@nowt.org>
3008
3009         * trans-expr.c (g95_trans_arrayfunc_assign): Nove elemental check
3010         after intrinsic function check.
3011
3012 2003-02-18  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
3013
3014         * io.c (match_io): Fix missing return value and remove useless
3015         assignment.
3016         * match.c (g95_match): Remove useless assignment.
3017         * module.c (parse_string):  Remove useless post increment.
3018         * simplify.c (g95_simplify_verify): Remove useless assignment.
3019
3020 2003-02-15  Paul Brook  <paul@nowt.org>
3021
3022         * expr.c (restricted_intrinsic): Handle bad values gracefully.
3023         * g95.h (symbol_attribute): Add referenced member.
3024         (g95_symbol): Add dummy_order member.
3025         (g95_set_sym_referenced): Declare.
3026         * match.c (g95_match_assignment, g95_match_call): Use it
3027         * primary.c (match_actual_arg, g95_match_rvalue,
3028         g95_match_variable): Ditto.
3029         * symbol.c (next_dummy_order): New variable.
3030         (g95_set_sym_referenced): New function.
3031         (check_done): New function.
3032         (g95_add_*): Use it.
3033         * trans-decl.c: Make formatting conform to GCC standards.
3034         (g95_defer_symbol_init): Add dummy variables in the right order.
3035         (g95_get_symbol_decl): Only accept referenced variables.
3036         (g95_create_module_variable): Module variables are always required.
3037         (generatr_local_decls): New function.
3038         (generate_local_vars): New function.
3039         (g95_generate_function_code): Use it.
3040
3041 2003-02-13  Paul Brook  <paul@nowt.org>
3042
3043         * trans-decl.c (g95_conv_struct_cons): Remove.
3044         (g95_get_symbol_decl): Use g95_conv_expr for structure initializers.
3045         * trans-expr.c (g95_conv_structure): New function.
3046         (g95_conv_expr): Use it.
3047
3048 2003-02-09  Paul Brook  <paul@nowt.org>
3049
3050         * trans-array.c (g95_array_init_size): Don't evaluate the linit
3051         expressions multiple times.
3052         (g95_trans_auto_arry_allocation): Use pointer not tmp.
3053
3054 2003-02-08  Paul Brook  <paul@nowt.org>
3055
3056         * module.c (mio_symtree_ref): Declare as static.
3057         (mio_expr): Remove dead code.
3058         (read_module): Set the symtree link for fixups.
3059         * trans-intrinsic.c (g95_conv_intrinsic_round): Rename...
3060         (build_round_expr): ... to this.
3061         (g95_conv_intrinsic_aint): New function.
3062         (g95_conv_intrinsic_function): Use it.
3063
3064 2003-02-08  Paul Brook  <paul@nowt.org>
3065
3066         * trans-array.c (g95_trans_array_constructor_value): Use the acutal
3067         offset after modificaton, not the increment expression.
3068         * dependency.c: Kill excess whitespace.
3069
3070 2003-02-07  Sanjiv Gupta  <sanjivg@noida.hcltech.com>
3071
3072         * dependency.h: Remove some function declarations.
3073         * dependency.c (get_no_of_elements): Change this function not to
3074         return int.
3075         * other: Add comments for all modified functions.
3076
3077 2003-02-06  Paul Brook  <paul@nowt.org>
3078
3079         * g95spec.c (lang_specific_functions): Fix initializer warning.
3080         * dump-parse-tree.c (g95_show_expr): Use typespec instead of symtree
3081         for structure type names.
3082         * trans-decl.c (g95_cons_structure_cons): New function.
3083         (g95_get_symbol_decl): Use it.
3084         * trans-expr.c (g95_conv_component_ref): Remove duplicate pointer
3085         referencing code.
3086
3087 2003-02-06  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
3088
3089         * resolve.c (compare_cases): Add const to casts.
3090
3091 2003-01-30  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
3092
3093         * g95.h (g95_check_f): Change a1 to f1m.
3094         * intrinsic.c (add_sym_1m, check_specific,
3095         g95_intrinsic_func_interface): Use it.
3096
3097         * module.c (init_pi_tree): Remove useless cast.
3098         (fp2): Fix argument type.
3099
3100         * parse.c (parse_select_block): Add comment.
3101
3102 2003-02-05  Toon Moene  <toon@moene.indiv.nluug.nl>
3103
3104         * lang-options.h: Fix warning involving C90 concatenated
3105         strings.
3106
3107 2003-02-06  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3108             Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
3109
3110         * io.c (format_asterisk): Complete initializer to kill warning.
3111         * arith.c (DEF_G95_INTEGER_KIND, DEF_G95_LOGICAL_KIND,
3112         DEF_G95_REAL_KIND, MPZ_NULL, MPF_NULL): New #defines.
3113         (g95_integer_kinds, g95_logical_kinds, g95_real_kinds): Use the
3114         new defines to complete initializers.  Kills all warnings.
3115
3116         * Make-lang.in: Comment cleanup.
3117
3118 2003-02-05  Paul Brook  <paul@nowt.org>
3119
3120         * array.c (g95_free_constructor): Handle NULL expressions.
3121         * resolve.c (resolve_structure_cons): Ditto.
3122         * decl.c (g95_match_null): New Function.
3123         (variable_decl): Use it.
3124         * module.c (mio_expr): Don't bother saving symtree for EXPR_STRUCTURE.
3125         * primary.c (g95_match_runtime): Don't use symtree for EXPR_STRUCTURE.
3126         * trans-types.c (g95_set_decl_attributes): Remove empty function.
3127
3128 2003-02-05  Paul Brook  <paul@nowt.org>
3129
3130         * trans.h (build1_v): New macro.
3131         (build_v): Remove pointless and incorrect prototype.
3132         * various: Use build1_v for GOTO_EXPR and LABEL_EXPRs.
3133         * f95-lang.c (g95_init_builtin_decls): DEF_BUILTIN takes 10 args.
3134
3135 2003-02-01  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3136
3137         * Make-lang.in (F95_OBJS): Remove one more dead file.
3138
3139 2003-02-01  Paul Brook  <paul@nowt.org>
3140
3141         * lang-specs.h: Don't pass -ffixed-form to the linker.
3142         * trans-decl.c (g95_generate_function_code): Clear saved decl chain.
3143
3144 2003-02-01  Paul Brook  <paul@nowt.org>
3145
3146         * Make-lang.in (F95_OBJS): Remove dead files.
3147         * trans-array.c (g95_array_init_size): Do the right thing when
3148         ubound=NULL.
3149         * trans-decl.c (g95_generate_function_code): Initialize deffered
3150         symbol list before translating contained subroutines.
3151         * trans-expr.c (g95_conv_expr, g95_conv_expr_reference): Substitute
3152         scalar invariant values here...
3153         (g95_conv_variable, g95_conv_function_call): ... instead of here ...
3154         * trans-intrinsic.c (g95_conv_intrinsic_function_args): .. and here.
3155
3156 2003-01-29  Paul Brook  <paul@nowt.org>
3157
3158         * trans-array.c (g95_add_loop_code): Put pre code in the right block.
3159         (g95_walk_elemental_function_args): Reverse chains before adding.
3160         (g95_reverse_ss): Move about a bit.
3161         * trans-expr.c (g95_conv_function_call): Handle scalar intrinsic
3162         function arguments.
3163
3164 2003-01-28  Paul Brook  <paul@nowt.org>
3165
3166         * intrinsic.c (resolve_intrinsic): Use correct union member.
3167         * trans-array.c (g95_trans_dummy_array_bias): Don't touch absent
3168         parameters.
3169         * trans-decl.c (g95_get_symbol_decl): Don't translate initializers for
3170         use associated variables.
3171         * trans-intrinsic.c (g95_conv_intrinsic_present): Move body ...
3172         * trans-expr.c (g95_conv_expr_present): ... to here.
3173         * trans.h: Declare it.
3174         * trans-types.c (g95_sym_type): Assume subroutine if not specified.
3175
3176 2003-01-28  Arnaud Desitter  <arnaud.desitter@geography.oxford.ac.uk>
3177
3178         * array.c (expand_iterator): Suppress useless assignment.
3179         * decl.c (match_char_spec): Ditto.
3180         * io.c (match_io_iterator): Ditto.
3181         * primary.c (match_real_constant): Ditto.
3182         * interface.c (fold_unary, g95_free_interface, g95_extend_expr):
3183         Ditto.  Also, use g95_intrinsic_op not int for intrinsic operators.
3184         * matchexp.c (match_add_operand, match_level_5): Likewise.
3185         * module.c (parse_atom, find_enum): Likewise.
3186         * resolve.c: move #include <string.h>
3187         (resolve_select): Fix serious typo.
3188
3189 2003-01-28  Steven Bosscher  <s.bosscher@student.tudelft.n>
3190
3191         * Make-lang.in: Don't build with broken tree-ssa-pre.
3192
3193 2003-01-28  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3194
3195         * resolve.c (resolve_index): Add a TODO.
3196         * symbol.c: Remove useless "#include <ctype.h>".
3197
3198 2003-01-27  Paul Brook  <paul@nowt.org>
3199
3200         * check.c (check_rest): Allow different type kinds as an extension.
3201         * g95.h (g95_resolve_f): Add f1m.
3202         * intrinsic.c (add_sym_1m, resolve_intrinsic): Use it.
3203         * intrinsic.h: Chenge prototypes for MIN and MAX.
3204         * iresolve.c (g95_resolve_minmax): New function.
3205         (g95_resolve_min, g95_resolve_max): Use it.
3206         * trans-intrinsic.c (g95_trans_intrinsic_minmax): Only evaluate
3207         arguments once.
3208         (g95_conv_intrinsic_present): Fix logic.
3209
3210 2003-01-27  Steven Bossche  <s.bosscher@student.tudelft.nl>
3211
3212         * g95.h (g95_case): Don't be a tree, be a double linked list.
3213         * match.c (match_case_selector): Remove redundant semantics check.
3214         Clean up a few goto's to make it a tiny little bit faster.
3215         * resolve.c (case_tree): Die.
3216         (compare_cases): Accept and compare unbounded cases too.
3217         (check_case_overlap): Don't build a tree.  Instead, merge-sort the
3218         whole list of g95_cases passed from resolve_select.
3219         (sane_logical_select): Die.
3220         (check_case_expr): Return FAILURE if a CASE label is of the wrong
3221         type kind.
3222         (resolve_select): Fixup case expression for computed GOTOs, put it
3223         in expr, not expr2, for easier handing in the parse tree dumper and
3224         the code generator.  Rewrite the rest of the function: Kill
3225         unreachable case labels and unreachable case blocks.
3226         * dump-parse-tree.c (g95_show_code_node): Always dump expr for
3227         an EXEC_SELECT, not case2 anymore.
3228         * trans-const.c (g95_conv_constant_to_tree): New function.
3229         (g95_conv_constant): Use it.
3230         * trans-const.h: Declare prototype for the new function.
3231         * trans-stmt.c (g95_trans_integer_select, g95_trans_logical_select,
3232         g95_trans_character_select): New static functions.
3233         (g95_trans_select): Rewrite.
3234
3235 2003-01-26  Paul Brook  <paul@nowt.org>
3236
3237         * intrinsic.c (add_fnctions): Properly add dreal.
3238         * trans-intrinsic.c (g95_conv_intrinsic_present): New function.
3239         (g95_conv_intrinsic_function): Use it.
3240         * trans-io.c (build_dt): Abort on internal files (unimplemented).
3241
3242 2003-01-26  Paul Brook  <paul@nowt.org>
3243
3244         Widespread changes to the handling of symbols in expressions.  These
3245         are now linked via g95_symtree nodes.
3246         * parse.c (g95_fixup_sibling symbols): New function.
3247         (parse_contained): Use it.
3248         * g95.h (symbol_attribute): Add contained.  Indicates a symbol is a
3249         contained procedure that has bee correctly fixed up.
3250         (g95_code, g95_expr): Point to a g95_symtree, not a g95_symbol.
3251
3252 2003-01-24  Paul Brook  <paul@nowt.org>
3253
3254         * trans-array.c (g95_walk_expr): Function result attributes are in
3255         sym->result.
3256         * trans-expr.c (g95_conv_function_call,
3257         g95_trans_arrayfunc_assign): Ditto.
3258         * trans-decl.c (g95_get_symbol_for_expr): Set sym->result.
3259
3260 2003-01-23  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3261
3262         * expr.c (check_restricted): Fix error message.
3263         * symbol.c (free_st_labels): Plug memleak.
3264
3265 2003-01-22  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3266
3267         * arith.c (reduce_unary, reduce_binary_ac, reduce_binary_ca,
3268         reduce_binary_aa, reduce_binary, eval_intrinsic,
3269         eval_intrinsic_f2): Use typesafe prototypes for eval functions.
3270         * g95.h (g95_check_f, g95_simplify_f, g95_resolve_f): New unions
3271         for typesafe intrinsics helper functions.
3272         (g95_intrinsic_sym): Use them.
3273         * intrinsic.c (do_check, add_sym, add_sym_0, add_sym_1,
3274         add_sym_1s, add_sym_1m, add_sym_2, add_sym_3, add_sym_4,
3275         add_sym_5, add_conv, resolve_intrinsic, do_simplify,
3276         check_specific, g95_intrinsic_func_interface,
3277         g95_intrinsic_sub_interface): Adjust all calls to intrinsics
3278         helper functions.
3279         * trans-decl.c (g95_get_extern_function_decl): Likewise.
3280         * Make-lang.in: Don't disable warnings for strict prototypes
3281         any longer, everything is typesafe now.
3282
3283 2003-01-22  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3284
3285         * bbt.c (duplicate_node): Make static.
3286         * module.c (module_name): Make static.
3287         * scanner.c (include_dirs): Make static.
3288
3289 2003-01-20  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3290
3291         Hard coded _gfor_'s should not show up anymore.
3292         * g95.h (PREFIX): New macro.
3293         * iresolve.c (g95_resolve_cpu_time): Use PREFIX, not
3294         hard-coded "_gfor".
3295         (g95_resolve_random_number): Likewise.
3296         * trans-decl.c (g95_build_intrinsic_function_decls): Likewise.
3297         * trans-io.c: Remove 'prefix' macro.  Replace all uses with
3298         the new PREFIX macro from g95.h.
3299
3300 2003-01-20  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3301
3302         The troubles of forking... Andy implemented this just now too.
3303         Let's stick to that and keep the trees close.
3304         * g95.h (g95_st_label): 'format' member is now a g95_expr.
3305         * io.c: Revert previous changes.
3306         (g95_match_format): Match the format string as a character
3307         literal expression.
3308         * match.h (g95_statement_label): Declare external.
3309         * parse.c: Revert previous changes.
3310         * symbol.c (g95_free_st_label): Free a g95_expr instead
3311         if a 'char *'.
3312         * trans-io.c: Revert previous changes.
3313         (build_dt): Use set_string to set the format string.
3314
3315 2003-01-20  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3316
3317         * io.c (format_string): Make non-static.
3318         (g95_match_format): Remember the format string.
3319         (terminate_io): Add I/O termination for empty I/O lists.
3320         * match.h: Declare external format_string.
3321         * parse.c (check_statement_label): Attack the format string
3322         to a format label for FORMAT statements.
3323         * trans-io.c (g95_add_field): Define prefix macro.  Replace
3324         all uses of PREFIX define with a use of this macro.
3325         (build_dt): Implement formatted I/O for format labels.
3326
3327 2003-01-20  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3328
3329         * lang-options.h: Kill "-std=F".
3330         * options.c: Remove unimplemented "-std=F".  Modify
3331         web address.
3332         * misc.c (g95_terminal_width): New function.
3333         * error.c (g95_error_init_1): Use g95_terminal_width.
3334         * g95.h: Add prototype for g95_terminal_width, remove
3335         fmode flag.
3336
3337 2003-01-19  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3338
3339         * Make-lang.in: Fix typo.
3340
3341 2003-01-18  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3342
3343         * g95.h (struct g95_case): Remove unused cruft, new member
3344         'where' to keep track of the locus of the default case.
3345         * match.c (g95_match_case): Add locus to the current case.
3346         (match_case_selector): Likewise.
3347         * parse.c (parse_select_block): Move semantics check for
3348         multiple DEFAULT cases out of here to...
3349         * resolve.c (check_case_overlap): ...here.  Return sooner
3350         when possible.
3351         (check_case_expr): Take two g95_cases now, use to sure the
3352         expression kinds are the same.
3353         (resolve_select): Cleanup.
3354
3355 2003-01-18  Paul Brook  <paul@nowt.org>
3356
3357         * trans-io.c: Fix typos in ported IO work (set_fla[tg]).
3358         * trans-decl.c (g95_set_symbol_decl): Handle non-array result
3359         variables.
3360         (g95_get_extern_function_decl): Put decls in the correct context.
3361
3362 2003-01-18  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3363
3364         * trans-io.c: Port changes from Andy to set ERR flag.
3365
3366 2003-01-17  Paul Brook  <paul@nowt.org>
3367
3368         * trans-array.c: Add various comments.
3369         (g95_ss_terminator): Declare as const.
3370         (g95_walk_expr): Remove first parameter and update all callers.
3371         (g95_walk_op_expr): Initialize scalar SS properly.
3372         * trans-array.h (g95_walk_expr): Update prototype.
3373         * trans-expr.c: Update for new g95_walk_expr.
3374         * trans-intrinsic.c: Ditto.
3375         * trans-io.c: Ditto.
3376         * trans.h: Various comments for SS chains.
3377
3378 2003-01-17  Paul Brook  <paul@nowt.org>
3379
3380         * intrinsic.h (g95_generic_isym_id): Add G95_ISYM_S?_KIND, SPACING
3381         and RRSPACING.
3382         * intrinsic.c (add_functions): Use them.
3383         * trans-intrinsic.c (g95_conv_intrinsic_function): Ditto.
3384         * trans-expr.c (g95_conv_expr_lhs): Abort on impossible error.
3385
3386 2003-01-17  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3387
3388         Fallout of a small merge conflict:
3389         * intrinsic.c: Un-revert lost patch (G95_ISYM_SCALE).
3390
3391 2003-01-17  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3392
3393         * initrinsic.c: New add_sym_* functions for strong typing.
3394         (add_conv): Make prototype strict.
3395         * dump-parse-tree.c, dependency.c: Include config.h
3396         * resolve.c, trans-io.c: Fix typos.
3397
3398 2003-01-17  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3399
3400         * dump-parse-tree.c (g95_show_code_node): Show the
3401         condition for a computed GOTO that was transformed
3402         to a SELECT CASE construct.
3403         * resolve.c (check_case_overlap): Revert previous switch
3404         to treaps, it was too slow and didn't catch all trouble.
3405         (resolve_symbol): Be more flexible about module procedures.
3406         * symbol.c (check_conflict): Point to relevant section in
3407         the standard for dubious conflict.  Allow procedure
3408         dummy arguments to be optional again.
3409         * trans-io (add_field): Rename to g95_add_field.  Change
3410         all callers.
3411         * trans-stmt (trans_select): Handle unbounded cases for
3412         integer SELECT CASE constructs.  Fix/add more comment.
3413
3414 2003-01-17  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3415
3416         * g95.h: Uses GCC's function attribute macros.
3417         * error.c, module.c, parse.c, g95.h: More function attributes.
3418
3419 2003-01-16  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3420         Forgot a file...
3421         * trans-decl.c (get_label_decl): Use TREE_LINENO instead
3422         of DECL_SOURCE_LINE, and TREE_FILENAME instead of
3423         DECL_SOURCE_FILE.
3424
3425 2003-01-16  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3426
3427         * f95-lang.c (pushdecl): Use TREE_LINENO instead of
3428         DECL_SOURCE_LINE.
3429         * trans.c (g95_trans_code): Use annotate_all_with_file_line
3430         instead of nowdead wrap_all_with_wfl.
3431
3432 2003-01-14  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3433
3434         * parse.c (g95_parse_file): In verbose mode, dump the parse tree
3435         before generating code, so we can still see it even if the code
3436         generation phase dies.
3437
3438 2003-01-14  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3439
3440         * decl.c (build_sym): Split out initialization expression parts...
3441         (add_init_expr_to_sym): ...to here.
3442         (variable_decl): Add the symbol following an attribute list to the
3443         symbol tree before parsing the optional initialization expression
3444         if the symbol is not of a derived type.
3445         * primary.c (g95_match_rvalue): Don't assume a symbol always has
3446         a value if it is a PARAMETER.
3447
3448 2003-01-14  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3449
3450         * misc.c: Don't #include <mcheck.h>
3451         * module.c: Ditto.  Kill uses of mtrace, muntrace.  If there
3452         ever was a glibc bug, then either this was never reported to
3453         glibc people, or it has been fixed for so long that there's
3454         no information you can find about it, anywhere.
3455
3456 2003-01-14  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3457
3458         Fix warnings:
3459         * module.c (attr_bits, bt_types, array_spec_types):
3460         Switch 'const' and 'static'.
3461         * iresolve.c (g95_resolve_reshape): Make __resolve0 non-'const'.
3462
3463         GNU'ify source code:
3464         * trans-io.c: Numerous fixes, one fixed warning and a few
3465         TODO markers so that we don't forget about them.
3466
3467 2003-01-13  Paul Brook  <paul@nowt.org>
3468
3469         * intrinsic.c (add_functions): Add G95_ISYM_SCALE.
3470         * intrinsic.h (g95_generic_isym_id): Remove bogus G95_ISYM_ANINIT.
3471         Add G95_ISYM_SCALE.
3472         * trans-intrinsic.c (g95_conv_intrinsic_function): Ditto
3473         * match.c (g95_match_stop): Fix dumb == -> != error.
3474
3475 2003-01-13  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3476
3477         * dump-parse-tree.c (show_indent): Add line breaks.  This
3478         whole dumping process needs cleanups.
3479         * f95-lang.c (g95_mark_addressable): Fix prototype to match
3480         the langhook.  Fix 'return's accordingly.
3481         * g95-support.h: Adjust prototype.
3482         * g95.h: Add 'no_backend' member to 'g95_option_t' struct.
3483         * lang-options.h: Add '-fsyntax-only'.
3484         * options.c (g95_init_options): Init 'no_backend'.
3485         (g95_parse_arg): Deal with '-fsyntax-only'.
3486         * parse.c (g95_parse_file): Do not generate code if 'no_backend'
3487         is set.
3488
3489 2003-01-13  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3490         Patch from Arnaud
3491         * resolve.c (resolve_symbol): Assumed shape arrays must be dummy
3492         arguments.  Also make sure that if a symbol is marked INTRINSIC,
3493         an intrinsic with the symbol's name actually exists.
3494         (check_conflict): Make EXTERNAL and DIMENSION attributes conflict.
3495         Do not allow PROCEDURES to have the SAVE, POINTER, TARGET,
3496         ALLOCATABLE, RESULT, IN_NAMESPACE, OPTIONAL or FUNCTION attribute.
3497
3498 2003-01-13  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3499
3500         * resolve.c (resolve_contained_functions): Fix condition, don't
3501         throw internal_error if a child namespace has no name.  Apparently
3502         this can be the case?
3503
3504 2003-01-11  Paul Brook  <paul@nowt.org>
3505
3506         Port changes from Andy's tree:
3507         * g95.h (g95_code): Add stop_code.
3508         * match.c (g95_match_stop): Detter syntax checking.
3509         * resolve.c (resolve_generic_f0): Return match type.
3510         (resolve_generic_f): Remove dead/duplicated code.
3511         (resolve_specific_f): Ditto.
3512         * dump-parse-tree.c (g95_show_code_node): Handle new STOP format.
3513         * trans-decl.c (gfor_fndel_stop_*): New fndecl nodes.
3514         * trans-stmt.c (g95_trans_stop): Handle new STOP format.
3515
3516 2003-01-11  Paul Brook  <paul@nowt.org>
3517
3518         * trans-array.c: Various documentation/comment changes.
3519         * trans-stmt.c: Ditto.
3520
3521
3522 2003-01-10  Paul Brook  <paul@nowt.org>
3523
3524         * options.c/h: Add -fdump-parse-tree as alias of -v.
3525
3526 2003-01-10  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3527
3528         * dump-parse-tree.c (g95_show_namespace): Fixed another
3529         typo.  Sorry, it's Friday...
3530
3531 2003-01-10  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3532
3533         Spotted by Tobi:
3534         * trans-array.c, trans-array.h, trans.c, trans-const.c,
3535         trans-const.h, trans-decl.c, trans-expr.c, trans.h
3536         trans-intrinsic.c, trans-io.c, trans-stmt.c, trans-stmt.h
3537         trans-types.c: Fix bogus copyright years, add 2003.
3538         * trans-types.h: Give copyright header.
3539
3540 2003-01-10  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3541
3542         * dump-parse-tree.c (g95_show_namespace): Fixed typo.
3543         * expr.c, options.c, scanner.c: Add some more 'const' markers.
3544         * intrinsic.c: Some constant strings moved to read-only memory.
3545         * io.c (format_asterisk): Move to...
3546         * g95.h: ...here.
3547
3548 2003-01-10  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3549
3550         * dump-parse-tree.c (g95_show_namespace): Dump implicit
3551         types for ranges instead of per-letter.  Indent the
3552         'CONTAINS' just like everything else.
3553         * resolve.c (resolve_contained_functions): Clarify comment.
3554         Explain non-obvious conditional expression.  Improve
3555         diagnostics if tyoe cannot be resolved.
3556         Port semi-fix from Andy's tree:
3557         (was_declared): Move up before first use.
3558         (generic_sym, specific_sym): New functions.  Code moved
3559         out if procedure_kind.
3560         (procedure_kind): Simplify using new functions.
3561         (resolve_generic_f): Make sure the functions we find in
3562         a parent namespace is generic.
3563         (resolve_specific_f): Ditto for specific functions.
3564
3565 2003-01-10  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3566
3567         * trans-stmt.c, trans.c: Fix some code style issues. Add
3568         some more comment (but still not enough!).
3569
3570 2003-01-10  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3571
3572         * symbol.c (flavors, procedures, intents, acces_types,
3573         access_types, ifsrc_types): Make const.
3574         * misc.c (g95_string2code): Make 'm' param 'const'.
3575         * module.c (find_enum, write_atom, mio_name): Make
3576         'm' param 'const'.
3577         (attr_bits, bt_types, array_spec_types, array_ref_types,
3578         ref_types, expr_types): Make const.
3579         * g95.h: Adjust external decls.
3580
3581 2003-01-09  Paul Brook  <paul@nowt.org>
3582
3583         * Testsuite: Add a load of new cases.
3584
3585 2003-01-08  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3586
3587         * Make-file.in: Add dependency on back end header files;
3588         a parallel build should work now.
3589         * f95-lang-c (lang_identifier): Remove bogus comment.
3590         (g95_be_parse_file): Fix prototype.
3591         (g95_init): Make static.
3592         (g95_finish): Make static.
3593         * error.c (g95_syntax_error): Kill. Make define in...
3594         * g95.h (g95_syntax_error): Define.
3595         (g95.options): Make 'source' member 'const'.
3596         * interface.c (g95_match_interface): Explain
3597         hard-to-read condition.
3598         (g95_match_end_interface): Ditto.
3599         * trans_const.c (g95_build_string_const): Make 's' parameter
3600         'const'.
3601         * trans_const.h: Adjust protoype accordingly.
3602         * trans-decl.c: Include tree-dump.h
3603         (g95_generate_function_code): Build fixes for recent changes
3604         in the tree-ssa branch.
3605
3606 2003-01-08  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3607
3608         * format.c: Kill, move code from here...
3609         * io.c: ...to here.
3610         * Make-lang.in: Adjust.
3611         * MANIFEST: Ditto.
3612         * match.h: Ditto.
3613         * BUGS: Mention where to submit bugs.  Move old content...
3614         * TODO: ...to here.  New file.
3615
3616 2003-01-08  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3617         Fix most warnings, and suppress the ones we can't fix for now.
3618         * Make-lang.in: Suppress warnings about bad proto's in g95.h,
3619         these warnings just clutter the screen and there's not much
3620         we can do about them for now anyway.
3621         * check.c, iresolve.c: Mark unused function parameters.
3622         * dump-parse-tree.c (g95_show_array_spec): Punt on AS_UNKNOWN,
3623         they should be resolved before they get here.
3624         * error.c: Remove unused FILE *status_out.
3625         * f95-lang.c (g95_init): Remove bogus cast.
3626         * Many files: Make things 'const' where required.
3627         * g95.h: Fix prototypes for all modified functions above.
3628         (g95_options): Remove 'object' member.
3629
3630 2003-01-07  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3631
3632         * Make-file.in: Cleanup bogus targets.  Add more comment.
3633         * lang-options.h: New option '-w'.
3634         * g95.h: add no_options field to struct g95_options.
3635         * options.c (g95_init_options): Default no_warnings to off.
3636         (g95_parse_arg): Recognise the '-w' switch and its alias,
3637         '-fno-warnings'.
3638         * error.c (g95_warning, g95_warning_now): Don't emit warning if
3639         no_warning option is set.
3640         * iresolve.c (g95_resolve_shape): Fix warning.
3641
3642 2003-01-07  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3643
3644         * primary.c (g95_next_string_char): Rename next_string_char, and
3645         make static.  Adjust callers accordingly.
3646         * resolve.c (resolve_generic_f0): Return try, not match.  Adjust
3647         callers accordingly.
3648         * g95.h: Split out all g95_match* functions to...
3649         * match.h: ...here. New file.
3650         * array.c, decl.c, expr.c, format.c, interface.c, io.c, match.c,
3651         matchexp.c, module.c, parse.c, primary.c: Inlcude match.h
3652
3653 2003-01-07  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3654
3655         * symbol.c (g95_clear_new_implicit, g95_add_new_implicit_range,
3656         g95_merge_new_implicit): New functions.
3657         (g95_match_implicit_none, g95_match_implicit): Move from here...
3658         * match.c (g95_match_implicit_none, g95_match_implicit): ... to here.
3659         Modify to use the new functions in symbol.c.
3660         * g95.h: Add and move prototypes.
3661
3662 2003-01-06  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3663
3664         * bbt.c (insert): Use a typedef'ed compare_fn prototype for the
3665         node compare function.
3666         (g95_insert_bbt): Likewise.
3667         (g95_insert_bbt_with_overlap): Likewise.
3668         (g95_delete_bbt): Likewise.
3669         (delete_treap): Likewise. Also fix a potential bug when calling it.
3670         * module.c (compare_pointers): Change proto to compare_fn.
3671         (compare_integers): Likewise.
3672         (compare_true_names): Likewise.
3673         (find_true_name): Adjust call to compare_true_names to match proto.
3674         (require_atom, write_atom, mio_name): Fix 'const' warnings.
3675         (init_pi_tree): Make compare a compare_fn instead of (int *).
3676         * resolve.c (compare_cases): Change proto to compare_fn.
3677         * symbol.c (g95_compare_symtree): Change proto to compare_fn, make
3678         it static, and rename to compare_symtree.
3679         (delete_symtree, g95_undo_symbols, g95_new_symtree): Use renamed
3680         function.
3681         * g95.h: Kill g95_compare_symtree prototype. Adjust prototypes
3682         of g95_insert_bbt, g95_insert_bbt_with_overlap, and g95_delete_bbt.
3683
3684 2003-01-06  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3685         * Make-lang.in: Fix spaces/tabs issues from previous patch.
3686         * patch.options: Blow away Paul's checkin mistake :-)
3687         * io.c (terminate_io): Fix memory leak (Arnaud).
3688
3689 2003-01-06  Steven Bosscher  <s.bosscher@student.tudelft.nl>
3690
3691         * Make-lang.in: Teach about building DVI, info manual.
3692         * g95.texi: New file.
3693
3694 2003-01-02  Paul Brook  <paul@nowt.org>
3695
3696         * trans-array.c (g95_reverse_ss): Make static and don't use.
3697         (g95_conv_ss_descriptor): Don't use g95_loopinfo
3698         (g95_conv_array_parameters): Modify for pointer assignments.
3699         (g95_walk_subexpr): New function.
3700         (g95_walk_expr*): Use it.
3701         * trans-array.h (g95_reverse_ss): Remove prototype.
3702         * trans-expr.c (g95_trans_pointer_assign): Implement.
3703         (Many): Set se.want_pointer before calling g95_conv_array_parameter.
3704         * trans-intrinsic.c: Sync with scalarizer changes.
3705         * trans-io.c: Ditto.
3706
3707 2002-12-29  Paul Brook  <paul@nowt.org>
3708
3709         * trans-array.c: Document calling convention for arrays.
3710
3711 2002-12-19  Paul Brook  <paul@nowt.org>
3712
3713         * trans-intrinsic.c (g95_conv_intrsinsic_function): Remove incorrect
3714         assertion. Remove intrinsic subroutine G95_ISYM_* cases. Always pass
3715         optional parameters for some intrinsics.
3716         (g95_is_intrinsic_libcall): Add G95_ISYM_RESHAPE.
3717         * trans-expr.c (g95_conv_function_call): Pass NULL for absent
3718         optional parameters.
3719         * trans.h (g95_se): Add ignore_optional flag.
3720
3721 2002-12-15  Paul Brook  <paul@nowt.org>
3722
3723         * trans-array.c (g95_conv_array_parameter): Fix partial rank sections.
3724         * trans-decl.c (g95_generate_function_code): Use TDI_original.
3725
3726 2002-12-14  Paul Brook  <paul@nowt.org>
3727
3728         * trans-stmt.c (g95_trans_call): Use resolved symbol name.
3729
3730 2002-12-12  Paul Brook  <paul@nowt.org>
3731
3732         * trans-array.c (g95_trans_array_constructor_subarray): Fully
3733         initialize the scalarizer.
3734         (various): Update to new format of g95_expr->value.constructor.
3735
3736 2002-12-08  Paul Brook  <paul@nowt.org>
3737
3738         * trans-array.c (g95_put_offset_into_var): New function.
3739         (g95_trans_array_constructor_subarray): New function.
3740         (g95_trans_array_constructor_value): Use it.
3741         (g95_array_cons_size): Don't abort() on array components.
3742
3743 2002-12-08  Paul Brook  <paul@nowt.org>
3744
3745         * Make-lang.in (F95_ADDITIONAL_OBJS): Remove tree-dchain.o.
3746         * support.c: Update #includes.
3747         (statement_code_p, c_size_in_bytes, s_size_type_node): Remove.
3748         * trans-array.c: Update #includes.
3749         * trans.c: Ditto.
3750         * trans-const.c: Ditto.
3751         * trans-io.c: Ditto.
3752         * trans-types.c: Ditto.
3753         (g95_init_types): Set size_type_node.
3754         * trans-decl.c: Update #includes.
3755         (gfor_fndecl_adjust{l,r}): Declare and initialize.
3756         * trans-stmt.c: Update #includes.
3757         (g95_trans_do_while): Generate LABEL_EXPR, not GOTO_EXPR.
3758         (g95_trans_select): Fix check for unbounded ranges.
3759         * trans-expr.c: Update #includes.
3760         (g95_conv_string_tmp): New function.
3761         (g95_conv_concat_op): Use it.
3762         * trans.h (g95_conv_string_tmp, gfor_fndecl_adjust{l,r}): Declare.
3763         * Trans-intrisic.c: Update #includes.
3764         (g95_conv_intrinsic_strcmp): New function.
3765         (g95_conv_intrinsic_adjust): Ditto.
3766         (g95_conv_intrinsic_function: Use them.
3767
3768 2002-11-30  Paul Brook  <paul@nowt.org>
3769
3770         * trans-array.c (g95_walk_function_expr): Handle non-array return by
3771         reference.
3772         * trans-dec.c (g95_build_function_decl): Handle character return
3773         parammeters.
3774         (g95_get_fake_result_decl): Ditto.
3775         (g95_trans_deferred_vars): Ditto.
3776         * trans-expr.c (g95_conv_function_call): Ditto.
3777         (g95_trans_arrayfunc_assign) Limit to array valued functions.
3778         * trans-intrinsic.c (g95_conv_intrinsic_char): New function.
3779         (g95_conv_intrinsic_function): Use it.
3780         * trans-types.c (g95_sym_type): Handle functions returning strings.
3781         (g95_return_by_reference): Ditto.
3782         (g95_get_function_type): Ditto.
3783
3784 2002-11-18  Paul Brook  <paul@nowt.org>
3785
3786         * trans-stmt.c (g95_trans_if): Fix IF statements when the condition
3787         requires a temporary.
3788         (g95_trans_select): Handle computed gotos.
3789         * trans-types.c (g95_build_array_type): Warn about non-functional
3790         assumed shape arrays.
3791         * trans-expr.c (g95_trans_scalar_assign): Correctly handle post
3792         blocks.
3793         * trans-intrinsic.c (g95_conv_intrinsic_round): New function.
3794         (g95_conv_intrinsic_int): New function.
3795         (g95_conv_intrinsic_mod): New function.
3796         (g95_conv_intrinsic_ichar): New function.
3797         (g95_conv_intrinsic_function): Use them.
3798         (g95_conv_intrinsic_dim): Use g95_evaluate_now.
3799
3800 2002-11-17  Toon Moene  <toon@moene.indiv.nluug.nl>
3801
3802         * trans-types.c (g95_build_array_type): Assumed
3803         sized arrays can have rank > 1.
3804         * trans.c (g95_trans_code): Remove erroneous
3805         warning about CONTINUE.
3806         * trans-expr.c (g95_conv_variable): Remove
3807         erroneous assert.
3808
3809 2002-11-15  Paul Brook  <paul@nowt.org>
3810
3811         * trans-array.c (g95_conv_array_parameter): Check for NULL stride.
3812
3813 2002-10-31  Paul Brook  <paul@nowt.org>
3814
3815         * f95-tree.c: Remove tree copying stuff that's now in gimple.c
3816         * trans-expr.c (g95_conv_component_ref): Handle character string
3817         components.
3818         (g95_conv_string_parameter): Ditto.
3819         * trans-types.c (g95_get_derived_type): Add length decl to caracter
3820         string components.
3821
3822 2002-10-10  Paul Brook  <paul@nowt.org>
3823
3824         * trans-decl.c (gfor_fndecl_size?): Declare and initialize.
3825         * trans-expr.c (g95_conv_function_call): Remove unreliable return value
3826         check.
3827         * trans-intrinsic.c (g95_conv_intrinsic_size): New function.
3828         (g95_conv_intrinsic_function): Handle size and shape intrinsics.
3829         (g95_is_intrinsic_libcall): Add G95_ISYM_SHAPE.
3830         * trans-types.c (pvoid_type_node): Declare and initialize.
3831         * trans-array.c: Fix typo COMPONENT_REF->REF_COMPONENT
3832         (g95_array_allocate): Fix when base==data.
3833         (g95_conv_array_parameter): Correctly handle reduced rank sections.
3834         * trans-io.c (g95_trans_write): Correctly handle string modifiers.
3835
3836 2002-10-09  Paul Brook  <paul@nowt.org>
3837
3838         * (g95_conv_expr_reference): Handle character strings correctly.
3839
3840 2002-10-07  Paul Brook  <paul@nowt.org>
3841
3842         (g95_expand_decl): Rename from f95_expand_decl_stmt and use as
3843         langhook.
3844         * trans-array.c (g95_build_array_initializer): Remove.
3845         (g95_conv_array_initializer): New Function.
3846         (g95_trans_auto_arry_allocation): Cleanup.
3847         (g95_trans_init_character_array): Remove.
3848         * g95spec.c: Link in libgforbegin.
3849         * trans.c (g95_generate_code): Rename main function to MAIN__.
3850         (g95_create_var): New function.
3851         (g95_create_var_np): New function.
3852         (g95_evaluate_now): New function.
3853         (g95_start_block): New function.
3854         (g95_finish_block): New function.
3855         (g95_add_expr_to_block): New function.
3856         (g95_add_block_to_block): New function.
3857         * trans-expr.c (g95_conv_componen_ref): New function.
3858         * Make-lang.in (F95_ADDITIONAL_OBJS): Add gimplify.o.
3859         (F95_OBJS): Add dependency.o.
3860         * f95-lang.c (g95_is_simple_stmt): Remove.
3861         * f95-tree.c (mark_not_simple): New function.
3862         (unshare_all_trees): New function.
3863         (create_tmp_var, create_tmp_alias_var): Remove.
3864         * support.c (declare_tmp_vars, tree_last_decl): Remove.
3865         * trans*: Convert to new IR using GENERIC trees.  Don't bother about
3866         SIMPLE/GIMPLE rules, this is now done by Lang-independant code.
3867
3868 2002-10-01  Paul Brook  <paul@nowt.org>
3869
3870         * trans-array.c: Add support for descriptorless arrays.
3871         (g95_conv_array_data): New function.
3872         (g95_conv_array_base): New function.
3873         * trans-array.h: Declare these here.
3874         * trans-decl.c(g95_create_mopdule_variable): Perform variable
3875         initialization and creation here.
3876         (g95_create_module_vars): Instead of here.
3877         * trans.h (G95_TYPE_ARRAY_*: Rename from G95_TYPE_DESCRIPTOR_*.
3878         * trans-intrinsic.c: Ditto.
3879         * trans-types.c (g95_is_nodesc_array): New function.
3880         (g95_get_nodesc_array_type): New function.
3881         (g95_sym_type, g95_get_derived_type): Use them.
3882         * trans-const.c (g95_conv_mpf_to_tree): Remove workaround.
3883
3884 2002-09-28  Paul Brook  <paul@nowt.org>
3885
3886         * trans-const.c (g95_conv_mpf_to_tree): Work around backend bug.
3887         * trans-intrinsic.c (g95_conv_intrinsic_abs): Correctly detect complex
3888         parameters.
3889
3890 2002-09-24  Paul Brook  <paul@nowt.org>
3891
3892         * f95-lang.c (listify): Remove declaration.
3893         (expand_function_body): Use optimize >=1 instead of flag_tree_saa.
3894         (listify)
3895         * f95-tree.c (get_name): New function.
3896         * trans.c (module_namespace): Remove.
3897         * trans-decl.c: Use g95_chainon_list rather than chainon(listify()).
3898         * trans-types.c: Ditto.
3899
3900 2002-09-19  Paul Brook  <paul@nowt.org>
3901
3902         * trans-array.c (g95_get_array_cons_size): New Function.
3903         (g95_con_ss_startstride): Handle Array constructors.
3904         (g95_conv_loop_setup): Ditto.
3905         (g95_conv_array_parameter): Ditto.
3906         * tras-decl.c (g95_finish_var_decl): Make initializes variables
3907         static.
3908
3909 2002-09-19  Paul Brook  <paul@nowt.org>
3910
3911         * trans.c (g95_simple_fold_tmp): Detect variables inside
3912         NON_LVALUE_EXPR.
3913         * trans-stmt.c (g95_trans_arithmetic_if): Implement this.
3914
3915 2002-09-18  Steven Bosscher <s.bosscher@student.tudelft.nl>
3916
3917         * Make-lang.in (F95_ADDITIONAL_OBJS): Add tree-ssa-dce.o
3918
3919 2002-09-14  Paul Brook  <paul@nowt.org>
3920
3921         * trans.c (g95_create_module_variable): Move to trans-decl.c.
3922         * trans-const.c (g95_conv_string_init): New Function.
3923         * trans-const.h: Declare it.
3924         * trans-decl.c (g95_get_symbol_decl): Handle initializers for static
3925         variables. Don't bail on intrinsic symbols.
3926         (get_extern_function_decl): Handle specific intrinsic functions.
3927         * trans-types.c (g95_sym_type): Dummy functions don't return
3928         reference types.
3929         * trans-array.c (g95_build_array_initializer): New Function.
3930         (g95_trans_auto_array_allocation): Build initializer for static decls.
3931         Don't use mpz_addmul, it's GMP4 only.
3932
3933 2002-09-12  Paul Brook  <paul@nowt.org>
3934
3935         * trans-decl.c (g95_generate_code): Fix thinko with return variable.
3936         (g95_get_extern_function_decl, g95_build_function_decl): Mangle
3937         assembler names for module procedures.
3938
3939 2002-09-11  Tobias Schlueter  <Tobias.Schlueter@physik.uni-muenchen.de>
3940
3941         * trans-array.c,h trans-expr.c, trans-stmt.c: Correct spelling of
3942         dependency/
3943
3944 2002-09-10  Paul Brook  <paul@nowt.org>
3945
3946         * trans-array.c: Change format of G95_SS_TEMP strictures.
3947         (g95_check_fncall_dependancy): New function.
3948         (trans_dummy_array_bias): stride[n], not stride[n-1]. for calculating
3949         offsets.
3950         * trans-decl.c (g95_get_symbol_decl): move assertion after handling of
3951         result variables.
3952         (g95_build_function_decl): Don't assume result arrays are packed.
3953         (g95_trans-deferred-vars): Handle array result variables.
3954         (g95_generate_fuction_code): Clear saved_function_decls.
3955         * trans-expr.c (g95_conv_fnction_call): Handle direct array return by
3956         reference.
3957         (g95_trans_arrayfunc_assign): New function.
3958         (g95_trans_assignment): Use it.
3959         * trans.h (g95_ss): Add temp struct for G95_SS_TEMP.
3960         (g95_se): Add direct_byref.
3961         * trans-types.c: Use sym->result rather than sym where appropriate.
3962         * trans-intrinsic.c (g95_conv_intrinsic_funcall): New function.
3963         Update other functions to use this.
3964         (g95_is_intrinsic_libcall): New function.
3965         (g95_conv_intrinsic_function): Add MATMUL and PRODUCT intrinsics.
3966         (g95_walk_intrinsic_function): Ditto.
3967
3968 2002-09-08  Paul Brook  <paul@nowt.org>
3969
3970         * trans-types.c: Change rank field to dtype field in array descriptor.
3971         * trans-array.c: Implement filling of dtype array descriptor field.
3972         * trans-intrinsic.c: Fix broken LEN intrinsic.
3973
3974 2002-09-07  Paul Brook  <paul@nowt.org>
3975
3976         * trans-intrinsic.c: Remove outdated todo intrinsic list.
3977         (g95_get_symbol_for_expr): Remove hack for fortran based intrinsics.
3978         (g95_walk_intrinsic_function): Add MINLOC and MAXLOC.
3979
3980 2002-09-06  Paul Brook  <paul@nowt.org>
3981
3982         * Make-lang.in (F95_ADDITIONAL_OBJS): Add tree_alias_comon.o.
3983         (gt-f95-trans-types.h): Add dependancy information.
3984         * config-lang.in (gtfiles): Add trans-types.c
3985         * f95-lang.c (g95_be_parse_file): Pass error and warning counts
3986         back to top-level code.
3987         * trans-array.c, trans-types.c: Change format of array descriptor.
3988         (g95_conv_descriptor_dimension): New function.
3989         * trans-types.h (g95_conv_descriptor_rank): define.
3990         * trans-intrinsic.c: Implement PRODUCT, COUNT. MINLOC and MAXLOC
3991         intrinsics.
3992
3993 2002-09-02  Steven Bosscher <s.bosscher@student.tudelft.nl>
3994
3995         * trans-array.c, trans-types.c: Add rank information to descriptor.
3996
3997 2002-09-06  Tobias Schlueter  <Tobias.Schlueter@physik.uni-muenchen.de>
3998
3999         * trans-stmt.c (g95_trans_allocate): Fix when ref==NULL.
4000
4001 2002-09-04  Paul Brook  <paul@nowt.org>
4002
4003         * f95-lang.c (g95_create_decls): New function.
4004         (g95_init):  Move initialization of external decls to above, and call
4005         from g95_be_parse_file.
4006         * trans.c (g95_finish_stmt): Don't amputate the decl chain.
4007         * trans-types.c (g95_init_types): Always name integer and char types.
4008         (g95_get_array_type_bounds): TYPE_NAME may be a TYPE_DECL.
4009
4010 2002-09-02  Steven Bosscher <s.bosscher@student.tudelft.nl>
4011
4012         * Make-lang.in: Add options.c to F95_PARSER_OBJS
4013
4014 2002-09-02  Paul Brook  <paul@nowt.org>
4015
4016         * g95_generate_code: Clear the attr for __fortran_main.
4017         * trans-types.c (g95_finish_type): New function.
4018         * g95_init_io_state_type: Use g95_finish_type.
4019         * g95_conv_intrinsic_anyall: Fix thinko in result initialization.
4020
4021 2002-09-01  Paul Brook  <paul@nowt.org>
4022
4023         * README.backend: Warn about the dangers of extra config.h files.
4024         Remove obsolete libgfor stuff.
4025         * config-lang.in: Add target-libgfor dependancy.
4026         * g95_conv_mpf_to_tree: Use & free allocated buffer p rather than buff.
4027
4028 2002-09-01  Toon Moene  <toon@moene.indiv.nluug.nl>
4029
4030         * g95_conv_mpz_to_tree: Free storage pointed to by q,
4031         not by buff.
4032
4033 2002-08-30  Paul Brook  <paul@nowt.org>
4034
4035         * trans-intrinsic.c (g95_conv_intrinsic_function,
4036         g95_walk_intrinsic_function): Added ANY and ALL.
4037         (g95_conv_intrinsic_anyall): New function.
4038         * iresolve.c (g95_resolve_any, g95_resolve_all): Include rank in
4039         mangled name
4040