OSDN Git Service

2008-06-08 Tobias Burnus <burnus@net-b.de>
[pf3gnuchains/gcc-fork.git] / gcc / fortran / ChangeLog
1 2008-06-08  Tobias Burnus  <burnus@net-b.de>
2
3         PR fortran/35830
4         * resolve.c (resolve_symbol): Copy more attributes for
5         PROCEDUREs with interfaces.
6
7 2008-06-07  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
8
9         PR fortran/36420
10         PR fortran/36422
11         * io.c (check_format): Add new error message for zero width.
12         Use new error message for FMT_A and with READ, FMT_G.  Allow
13         FMT_G with WRITE except when -std=F95 and -std=F2003.
14
15 2008-06-07  Tobias Burnus  <burnus@net-b.de>
16
17         PR fortran/36437
18         * intrinsic.c (add_functions): Implement c_sizeof.
19         * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Do not
20         create unneeded variable in the scalar case.
21         * intrinsic.texi: Add C_SIZEOF documentation.
22
23 2008-06-06  Tobias Burnus  <burnus@net-b.de>
24
25         * intrinsic.texi (BESSEL_J1): Fix BES(S)EL_J1 typo.
26
27 2008-06-06  Jakub Jelinek  <jakub@redhat.com>
28
29         * scanner.c (skip_free_comments, skip_fixed_comments): Handle tabs.
30         * parse.c (next_free): Allow tab after !$omp.
31         (decode_omp_directive): Handle !$omp task, !$omp taskwait
32         and !$omp end task.
33         (case_executable): Add ST_OMP_TASKWAIT.
34         (case_exec_markers): Add ST_OMP_TASK.
35         (gfc_ascii_statement): Handle ST_OMP_TASK, ST_OMP_END_TASK and
36         ST_OMP_TASKWAIT.
37         (parse_omp_structured_block, parse_executable): Handle ST_OMP_TASK.
38         * gfortran.h (gfc_find_sym_in_expr): New prototype.
39         (gfc_statement): Add ST_OMP_TASK, ST_OMP_END_TASK and ST_OMP_TASKWAIT.
40         (gfc_omp_clauses): Add OMP_SCHED_AUTO to sched_kind,
41         OMP_DEFAULT_FIRSTPRIVATE to default_sharing.  Add collapse and
42         untied fields.
43         (gfc_exec_op): Add EXEC_OMP_TASK and EXEC_OMP_TASKWAIT.
44         * f95-lang.c (LANG_HOOKS_OMP_CLAUSE_COPY_CTOR,
45         LANG_HOOKS_OMP_CLAUSE_ASSIGN_OP, LANG_HOOKS_OMP_CLAUSE_DTOR,
46         LANG_HOOKS_OMP_PRIVATE_OUTER_REF): Define.
47         * trans.h (gfc_omp_clause_default_ctor): Add another argument.
48         (gfc_omp_clause_copy_ctor, gfc_omp_clause_assign_op,
49         gfc_omp_clause_dtor, gfc_omp_private_outer_ref): New prototypes.
50         * types.def (BT_ULONGLONG, BT_PTR_ULONGLONG,
51         BT_FN_BOOL_ULONGLONGPTR_ULONGLONGPTR,
52         BT_FN_BOOL_BOOL_ULL_ULL_ULL_ULLPTR_ULLPTR,
53         BT_FN_BOOL_BOOL_ULL_ULL_ULL_ULL_ULLPTR_ULLPTR,
54         BT_FN_VOID_PTR_PTR, BT_PTR_FN_VOID_PTR_PTR,
55         BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT): New.
56         (BT_BOOL): Use integer type with BOOL_TYPE_SIZE rather
57         than boolean_type_node.
58         * dump-parse-tree.c (gfc_show_omp_node): Handle EXEC_OMP_TASK,
59         EXEC_OMP_TASKWAIT, OMP_SCHED_AUTO, OMP_DEFAULT_FIRSTPRIVATE,
60         untied and collapse clauses.
61         (gfc_show_code_node): Handle EXEC_OMP_TASK and EXEC_OMP_TASKWAIT.
62         * trans.c (gfc_trans_code): Handle EXEC_OMP_TASK and
63         EXEC_OMP_TASKWAIT.
64         * st.c (gfc_free_statement): Likewise.
65         * resolve.c (gfc_resolve_blocks, resolve_code): Likewise.
66         (find_sym_in_expr): Rename to...
67         (gfc_find_sym_in_expr): ... this.  No longer static.
68         (resolve_allocate_expr, resolve_ordinary_assign): Adjust caller.
69         * match.h (gfc_match_omp_task, gfc_match_omp_taskwait): New
70         prototypes.
71         * openmp.c (resolve_omp_clauses): Allow allocatable arrays in
72         firstprivate, lastprivate, reduction, copyprivate and copyin
73         clauses.
74         (omp_current_do_code): Made static.
75         (omp_current_do_collapse): New variable.
76         (gfc_resolve_omp_do_blocks): Compute omp_current_do_collapse,
77         clear omp_current_do_code and omp_current_do_collapse on return.
78         (gfc_resolve_do_iterator): Handle collapsed do loops.
79         (resolve_omp_do): Likewise, diagnose errorneous collapsed do loops.
80         (OMP_CLAUSE_COLLAPSE, OMP_CLAUSE_UNTIED): Define.
81         (gfc_match_omp_clauses): Handle default (firstprivate),
82         schedule (auto), untied and collapse (n) clauses.
83         (OMP_DO_CLAUSES): Add OMP_CLAUSE_COLLAPSE.
84         (OMP_TASK_CLAUSES): Define.
85         (gfc_match_omp_task, gfc_match_omp_taskwait): New functions.
86         * trans-openmp.c (gfc_omp_private_outer_ref): New function.
87         (gfc_omp_clause_default_ctor): Add outer argument.  For allocatable
88         arrays allocate them with the bounds of the outer var if outer
89         var is allocated.
90         (gfc_omp_clause_copy_ctor, gfc_omp_clause_assign_op,
91         gfc_omp_clause_dtor): New functions.
92         (gfc_trans_omp_array_reduction): If decl is allocatable array,
93         allocate it with outer var's bounds in OMP_CLAUSE_REDUCTION_INIT
94         and deallocate it in OMP_CLAUSE_REDUCTION_MERGE.
95         (gfc_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
96         for assumed-size arrays.
97         (gfc_trans_omp_do): Add par_clauses argument.  If dovar is
98         present in lastprivate clause and do loop isn't simple,
99         set OMP_CLAUSE_LASTPRIVATE_STMT.  If dovar is present in
100         parallel's lastprivate clause, change it to shared and add
101         lastprivate clause to OMP_FOR_CLAUSES.  Handle collapsed do loops.
102         (gfc_trans_omp_directive): Adjust gfc_trans_omp_do callers.
103         (gfc_trans_omp_parallel_do): Likewise.  Move collapse clause to
104         OMP_FOR from OMP_PARALLEL.
105         (gfc_trans_omp_clauses): Handle OMP_SCHED_AUTO,
106         OMP_DEFAULT_FIRSTPRIVATE, untied and collapse clauses.
107         (gfc_trans_omp_task, gfc_trans_omp_taskwait): New functions.
108         (gfc_trans_omp_directive): Handle EXEC_OMP_TASK and
109         EXEC_OMP_TASKWAIT.
110
111 2008-06-04  Janus Weil  <janus@gcc.gnu.org>
112
113         PR fortran/36322
114         PR fortran/36275
115         * resolve.c (resolve_symbol): Correctly copy the interface for a
116         PROCEDURE declaration.
117
118 2008-06-02  Janus Weil  <janus@gcc.gnu.org>
119
120         PR fortran/36361
121         * symbol.c (gfc_add_allocatable,gfc_add_dimension,
122         gfc_add_explicit_interface): Added checks.
123         * decl.c (attr_decl1): Added missing "var_locus".
124         * parse.c (parse_interface): Checking for errors.
125
126 2008-06-02  Daniel Kraft  <d@domob.eu>
127
128         * gfortran.h:  New statement-type ST_FINAL for FINAL declarations.
129         (struct gfc_symbol):  New member f2k_derived.
130         (struct gfc_namespace):  New member finalizers, for use in the above
131         mentioned f2k_derived namespace.
132         (struct gfc_finalizer):  New type defined for finalizers linked list.
133         * match.h (gfc_match_final_decl):  New function header.
134         * decl.c (gfc_match_derived_decl):  Create f2k_derived namespace on
135         constructed symbol node.
136         (gfc_match_final_decl):  New function to match a FINAL declaration line.
137         * parse.c (decode_statement):  match-call for keyword FINAL.
138         (parse_derived):  Parse CONTAINS section and accept FINAL statements.
139         * resolve.c (gfc_resolve_finalizers):  New function to resolve (that is
140         in this case, check) a list of finalizer procedures.
141         (resolve_fl_derived):  Call gfc_resolve_finalizers here.
142         * symbol.c (gfc_get_namespace):  Initialize new finalizers to NULL.
143         (gfc_free_namespace):  Free finalizers list.
144         (gfc_new_symbol):  Initialize new f2k_derived to NULL.
145         (gfc_free_symbol):  Free f2k_derived namespace.
146         (gfc_free_finalizer):  New function to free a single gfc_finalizer node.
147         (gfc_free_finalizer_list):  New function to free a linked list of
148         gfc_finalizer nodes.
149
150 2008-06-02  Daniel Franke  <franke.daniel@gmail.com>
151
152         PR fortran/36375
153         PR fortran/36377
154         * cpp.c (gfc_cpp_init): Do not initialize builtins if
155         processing already preprocessed input.
156         (gfc_cpp_preprocess): Finalize output with newline.
157
158 2008-05-31  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
159
160         * intrinsic.texi: Revert wrong commit.
161
162 2008-05-31  Steven G. Kargl  <kargls@comcast.net>
163
164         * arith.c (gfc_arith_init_1): Remove now unused r and c variables.
165         Cleanup numerical inquiry function initialization.
166         (gfc_arith_done_1): Replace multiple mpfr_clear() invocations with
167         a single mpfr_clears().
168         (gfc_check_real_range): Re-arrange logic to eliminate multiple
169         unnecessary branching and assignments.
170         (gfc_arith_times): Use mpfr_clears() in preference to multiple
171         mpfr_clear().
172         (gfc_arith_divide): Ditto.
173         (complex_reciprocal): Eliminate now unused variables a, re, im.
174         Cleanup the mpfr abuse.  Use mpfr_clears() in preference to
175         multiple mpfr_clear().
176         (complex_pow): Fix comment whitespace.  Use mpfr_clears() in
177         preference to multiple mpfr_clear().
178         * simplify.c (gfc_simplify_and): Remove blank line.
179         (gfc_simplify_atan2): Move error checking earlier to eliminate
180         a now unnecessay gfc_free_expr().
181         (gfc_simplify_bessel_j0): Remove unnecessary gfc_set_model_kind().
182         (gfc_simplify_bessel_j1): Ditto.
183         (gfc_simplify_bessel_jn): Ditto.
184         (gfc_simplify_bessel_y0): Ditto.
185         (gfc_simplify_bessel_y1): Ditto.
186         (gfc_simplify_bessel_yn): Ditto. 
187         (only_convert_cmplx_boz): Eliminate unnecessary duplicate code, and
188         combine nested if statement rational expressions.
189         (gfc_simplify_cos): Use mpfr_clears() in preference to multiple
190         mpfr_clear().
191         (gfc_simplify_exp): Ditto.
192         (gfc_simplify_fraction): Move gfc_set_model_kind() to after the
193         special case of 0.  Use mpfr_clears() in preference to multiple
194         mpfr_clear().
195         (gfc_simplify_gamma): Eliminate unnecessary gfc_set_model_kind().
196         (gfc_simplify_lgamma): Ditto.
197         (gfc_simplify_log10): Ditto.
198         (gfc_simplify_log): Move gfc_set_model_kind () inside switch
199         statement. Use mpfr_clears() in preference to multiple mpfr_clear().
200         (gfc_simplify_mod):  Eliminate now unused variables quot, iquot,
201         and term.  Simplify the mpfr magic.
202         (gfc_simplify_modulo): Ditto.
203         (gfc_simplify_nearest): Eliminate unnecessary gfc_set_model_kind().
204         (gfc_simplify_scale): Use mpfr_clears() in preference to multiple
205         mpfr_clear().
206         (gfc_simplify_sin): Ditto
207         (gfc_simplify_sqrt): Ditto
208         (gfc_simplify_set_exponent):  Move gfc_set_model_kind() to after the
209         special case of 0.  Use mpfr_clears() in preference to multiple
210         mpfr_clear().
211
212 2008-05-29  Daniel Franke  <franke.daniel@gmail.com>
213
214         PR target/36348
215         * Make-lang.in (F95_OBJS): Added dependency on FORTRAN_TARGET_OBJS.
216
217 2008-05-29  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
218
219         * scanner.c (load_line): Add first_char argument. Don't call ungetc.
220         (gfc_read_orig_filename): Adjust call to load_line. Don't call
221         ungetc.
222         (load_file): Adjust call to load_line.
223
224 2008-05-28  Janus Weil  <janus@gcc.gnu.org>
225
226         PR fortran/36325
227         PR fortran/35830
228         * interface.c (gfc_procedure_use): Enable argument checking for
229         external procedures with explicit interface.
230         * symbol.c (check_conflict): Fix conflict checking for externals.
231         (copy_formal_args): Fix handling of arrays.
232         * resolve.c (resolve_specific_f0, resolve_specific_s0): Fix handling
233         of intrinsics.
234         * parse.c (parse_interface): Non-abstract INTERFACE statement implies
235         EXTERNAL attribute.
236
237 2008-05-28  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
238
239         PR fortran/36319
240         * intrinsic.c (gfc_convert_chartype): Don't mark conversion
241         function as pure.
242         * trans-array.c (gfc_trans_array_ctor_element): Divide element
243         size by the size of one character to obtain length.
244         * iresolve.c (gfc_resolve_cshift): Call the _char4 variant when
245         appropriate.
246         (gfc_resolve_eoshift): Likewise.
247         * trans-intrinsic.c (gfc_conv_intrinsic_ctime): Minor beautification.
248         (gfc_conv_intrinsic_fdate): Minor beautification.
249         (gfc_conv_intrinsic_ttynam): Minor beautification.
250         (gfc_conv_intrinsic_minmax_char): Allow all character kinds.
251         (size_of_string_in_bytes): New function.
252         (gfc_conv_intrinsic_size): Call size_of_string_in_bytes for
253         character expressions.
254         (gfc_conv_intrinsic_sizeof): Likewise.
255         (gfc_conv_intrinsic_array_transfer): Likewise.
256         (gfc_conv_intrinsic_trim): Allow all character kinds. Minor
257         beautification.
258         (gfc_conv_intrinsic_repeat): Fix comment typo.
259         * simplify.c (gfc_convert_char_constant): Take care of conversion
260         of array constructors.
261
262 2008-05-27  Tobias Burnus  <burnus@net-b.de>
263
264         PR fortran/36316
265         * trans-array.c (gfc_set_loop_bounds_from_array_spec):
266         Add missing fold_convert.
267
268 2008-05-26  Daniel Franke  <franke.daniel@gmail.com>
269
270         * fortran/cpp.c (cpp_define_builtins): Remove usage of TARGET_* macros,
271         added FIXME instead.
272
273 2008-05-26  Daniel Franke  <franke.daniel@gmail.com>
274
275         PR fortran/18428
276         * lang.opt (A, C, CC, D, E, H, P, U, cpp, d, fworking-directory,
277         imultilib, iprefix, iquote, isysroot, isystem, nocpp, nostdinc,
278         o, undef, v): New options.
279         * options.c (gfc_init_options): Also initialize preprocessor
280         options.
281         (gfc_post_options): Also handle post-initialization of preprocessor
282         options.
283         (gfc_handle_option): Check if option is a preprocessor option.
284         If yes, let gfc_cpp_handle_option() handle the option.
285         * lang-specs.h: Reorganized to handle new options.
286         * scanner.c (gfc_new_file): Read temporary file instead of
287         input source if preprocessing is enabled.
288         * f95-lang.c (gfc_init): Initialize preprocessor.
289         (gfc_finish): Clean up preprocessor.
290         * cpp.c: New.
291         * cpp.h: New.
292         * Make-lang.in: Added new objects and dependencies.
293         * gfortran.texi: Updated section "Preprocessing and
294         conditional compilation".
295         * invoke.texi: Added new section "Preprocessing Options",
296         listed and documented the preprocessing options handled
297         by gfortran.
298
299 2008-05-25  Tobias Burnus  <burnus@net-b.de>
300
301         PR fortran/32600
302         * trans-expr.c (gfc_conv_function_call): Remove library
303         call for c_f_pointer with scalar Fortran pointers and for
304         c_f_procpointer.
305
306 2008-05-21  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
307
308         PR fortran/36257
309         * iresolve.c (check_charlen_present): Don't force the rank to 1.
310
311 2008-05-19  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
312
313         PR fortran/36265
314         * trans-expr.c (gfc_conv_string_tmp): Pick the correct type for
315         the temporary variable.
316
317 2008-05-19  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
318
319         * simplify.c (gfc_simplify_dble, gfc_simplify_real): Initialize
320         result variable to avoid warnings.
321
322 2008-05-18  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
323
324         * intrinsic.c (char_conversions, ncharconv): New static variables.
325         (find_char_conv): New function.
326         (add_functions): Add simplification functions for ADJUSTL and
327         ADJUSTR. Don't check the kind of their argument. Add checking for
328         LGE, LLE, LGT and LLT.
329         (add_subroutines): Fix argument type for SLEEP. Fix argument name
330         for SYSTEM.
331         (add_char_conversions): New function.
332         (gfc_intrinsic_init_1): Call add_char_conversions.
333         (gfc_intrinsic_done_1): Free char_conversions.
334         (check_arglist): Use kind == 0 as a signal that we don't want
335         the kind value to be checked.
336         (do_simplify): Also simplify character functions.
337         (gfc_convert_chartype): New function
338         * trans-array.c (gfc_trans_array_ctor_element): Don't force the
339         use of default character type.
340         (gfc_trans_array_constructor_value): Likewise.
341         (get_array_ctor_var_strlen): Use integer kind to build an integer
342         instead of a character kind!
343         (gfc_build_constant_array_constructor): Don't force the use of
344         default character type.
345         (gfc_conv_loop_setup): Likewise.
346         * trans-expr.c (gfc_conv_string_tmp): Don't force the use of
347         default character type. Allocate enough memory for wide strings.
348         (gfc_conv_concat_op): Make sure operand kind are the same.
349         (string_to_single_character): Remove gfc_ prefix. Reindent.
350         Don't force the use of default character type.
351         (gfc_conv_scalar_char_value): Likewise.
352         (gfc_build_compare_string): Call string_to_single_character.
353         (fill_with_spaces): New function
354         (gfc_trans_string_copy): Add kind arguments. Use them to deal
355         with wide character kinds.
356         (gfc_conv_statement_function): Whitespace fix. Call
357         gfc_trans_string_copy with new kind arguments.
358         (gfc_conv_substring_expr): Call gfc_build_wide_string_const
359         instead of using gfc_widechar_to_char.
360         (gfc_conv_string_parameter): Don't force the use of default
361         character type.
362         (gfc_trans_scalar_assign): Pass kind args to gfc_trans_string_copy.
363         * intrinsic.h (gfc_check_lge_lgt_lle_llt, gfc_convert_char_constant,
364         gfc_resolve_adjustl, gfc_resolve_adjustr): New prototypes.
365         * decl.c (gfc_set_constant_character_len): Don't assert the
366         existence of a single character kind.
367         * trans-array.h (gfc_trans_string_copy): New prototype.
368         * gfortran.h (gfc_check_character_range, gfc_convert_chartype):
369         New prototypes.
370         * error.c (print_wide_char_into_buffer): New function lifting
371         code from gfc_print_wide_char. Fix order to output '\x??' instead
372         of 'x\??'.
373         (gfc_print_wide_char): Call print_wide_char_into_buffer.
374         (show_locus): Call print_wide_char_into_buffer with buffer local
375         to this function.
376         * trans-const.c (gfc_build_wide_string_const): New function.
377         (gfc_conv_string_init): Deal with wide characters strings
378         constructors.
379         (gfc_conv_constant_to_tree): Call gfc_build_wide_string_const.
380         * trans-stmt.c (gfc_trans_label_assign): Likewise.
381         (gfc_trans_character_select): Deal with wide strings.
382         * expr.c (gfc_check_assign): Allow conversion between character
383         kinds on assignment.
384         * trans-const.h (gfc_build_wide_string_const): New prototype.
385         * trans-types.c (gfc_get_character_type_len_for_eltype,
386         gfc_get_character_type_len): Create too variants of the old
387         gfc_get_character_type_len, one getting kind argument and the
388         other one directly taking a type tree.
389         * trans.h (gfor_fndecl_select_string_char4,
390         gfor_fndecl_convert_char1_to_char4,
391         gfor_fndecl_convert_char4_to_char1): New prototypes.
392         * trans-types.h (gfc_get_character_type_len_for_eltype): New
393         prototype.
394         * resolve.c (resolve_operator): Exit early when kind mismatches
395         are detected, because that makes us issue an error message later.
396         (validate_case_label_expr): Fix wording of error message.
397         * iresolve.c (gfc_resolve_adjustl, gfc_resolve_adjustr): New
398         functions.
399         (gfc_resolve_pack): Call _char4 variants of library function
400         when dealing with wide characters.
401         (gfc_resolve_reshape): Likewise.
402         (gfc_resolve_spread): Likewise.
403         (gfc_resolve_transpose): Likewise.
404         (gfc_resolve_unpack): Likewise.
405         * target-memory.c (size_character): Take character kind bit size
406         correctly into account (not that it changes anything for now, but
407         it's more generic).
408         (gfc_encode_character): Added gfc_ prefix. Encoding each
409         character of a string by calling native_encode_expr for the
410         corresponding unsigned integer.
411         (gfc_target_encode_expr): Add gfc_ prefix to encode_character.
412         * trans-decl.c (gfc_build_intrinsic_function_decls): Build
413         gfor_fndecl_select_string_char4, gfor_fndecl_convert_char1_to_char4
414         and gfor_fndecl_convert_char4_to_char1.
415         * target-memory.h (gfc_encode_character): New prototype.
416         * arith.c (gfc_check_character_range): New function.
417         (eval_intrinsic): Allow non-default character kinds.
418         * check.c (gfc_check_access_func): Only allow default
419         character kind arguments.
420         (gfc_check_chdir): Likewise.
421         (gfc_check_chdir_sub): Likewise.
422         (gfc_check_chmod): Likewise.
423         (gfc_check_chmod_sub): Likewise.
424         (gfc_check_lge_lgt_lle_llt): New function.
425         (gfc_check_link): Likewise.
426         (gfc_check_link_sub): Likewise.
427         (gfc_check_symlnk): Likewise.
428         (gfc_check_symlnk_sub): Likewise.
429         (gfc_check_rename): Likewise.
430         (gfc_check_rename_sub): Likewise.
431         (gfc_check_fgetputc_sub): Likewise.
432         (gfc_check_fgetput_sub): Likewise.
433         (gfc_check_stat): Likewise.
434         (gfc_check_stat_sub): Likewise.
435         (gfc_check_date_and_time): Likewise.
436         (gfc_check_ctime_sub): Likewise.
437         (gfc_check_fdate_sub): Likewise.
438         (gfc_check_gerror): Likewise.
439         (gfc_check_getcwd_sub): Likewise.
440         (gfc_check_getarg): Likewise.
441         (gfc_check_getlog): Likewise.
442         (gfc_check_hostnm): Likewise.
443         (gfc_check_hostnm_sub): Likewise.
444         (gfc_check_ttynam_sub): Likewise.
445         (gfc_check_perror): Likewise.
446         (gfc_check_unlink): Likewise.
447         (gfc_check_unlink_sub): Likewise.
448         (gfc_check_system_sub): Likewise.
449         * primary.c (got_delim): Perform correct character range checking
450         for all kinds.
451         * trans-intrinsic.c (gfc_conv_intrinsic_conversion): Generate
452         calls to library functions convert_char4_to_char1 and
453         convert_char1_to_char4 for character conversions.
454         (gfc_conv_intrinsic_char): Allow all character kings.
455         (gfc_conv_intrinsic_strcmp): Fix whitespace.
456         (gfc_conv_intrinsic_repeat): Take care of all character kinds.
457         * intrinsic.texi: For all GNU intrinsics accepting character
458         arguments, mention that they're restricted to the default kind.
459         * simplify.c (simplify_achar_char): New function.
460         (gfc_simplify_achar, gfc_simplify_char): Call simplify_achar_char.
461         gfc_simplify_ichar): Don't error out for wide characters.
462         (gfc_convert_char_constant): New function.
463
464 2008-05-18  Steven G. Kargl  <kargls@comcast.net>
465
466         PR fortran/36251
467         * symbol.c (check_conflict): Issue errors for abuse of PUBLIC, PRIVATE,
468         and BIND(C).
469         * resolve.c (gfc_verify_binding_labels): Fix NULL pointer dereference.
470
471 2008-05-17  Tobias Burnus  <burnus@net-b.de>
472
473         * intrinsic.texi: Correct description of GET_COMMAND_ARGUMENT
474         and GET_ENVIRONMENT_VARIABLE; fix keyword= name for GETENV,
475         GETLOG, GMTIME, HOSTNM, IRAND, ITIME, KILL.
476         Move LOG_GAMMA after LOG10.
477
478 2008-05-17  Tobias Burnus  <burnus@net-b.de>
479
480         * intrinsic.c (add_functions): Change FLUSH(C) to FLUSH(UNIT).
481         * intrinsic.texi: Change INTEGER(*) to INTEGER; fix keyword= name for
482         ABS, ADJUSTL, AINT, ALLOCATED, ANINT, ASSOCIATED, C_ASSOCIATED,
483         CEILING, DBLE, DFLOAT, DOT_PRODUCT, DREAL, FLOAT, FLOOR, GET_COMMAND.
484
485 2008-05-16  Paul Thomas  <pault@gcc.gnu.org>
486
487         PR fortran/35756
488         PR fortran/35759
489         * trans-stmt.c (gfc_trans_where): Tighten up the dependency
490         check for calling gfc_trans_where_3.
491
492         PR fortran/35743
493         * trans-stmt.c (gfc_trans_where_2): Set the mask size to zero
494         if it is calculated to be negative.
495
496         PR fortran/35745
497         * trans-stmt.c (gfc_trans_where_3, gfc_trans_where_assign): Set
498         ss->where for scalar right hand sides.
499         * trans-array.c (gfc_add_loop_ss_code): If ss->where is set do
500         not evaluate scalars outside the loop.  Clean up whitespace.
501         * trans.h : Add a bitfield 'where' to gfc_ss.
502
503 2008-05-16  Tobias Burnus  <burnus@net-b.de>
504
505         * libgfortran.h: Increase GFC_MAX_DIMENSIONS to 15.
506         * array.c (gfc_match_array_spec): Error with -std=f2003 if rank > 7.
507
508 2008-04-16  Daniel Kraft  <d@domob.eu>
509
510         PR fortran/27997
511         * gfortran.h:  Added field "length_from_typespec" to gfc_charlength.
512         * aray.c (gfc_match_array_constructor):  Added code to parse typespec.
513         (check_element_type, check_constructor_type, gfc_check_constructor_type):
514         Extended to support explicit typespec on constructor.
515         (gfc_resolve_character_array_constructor):  Pad strings correctly for
516         explicit, constant character length.
517         * trans-array.c:  New static global variable "typespec_chararray_ctor"
518         (gfc_trans_array_constructor):  New code to support explicit but dynamic
519         character lengths.
520
521 2008-05-16  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
522
523         PR fortran/34325
524         * decl.c (match_attr_spec): Check for matching pairs of parenthesis.
525         * expr.c (gfc_specification_expr): Supplement the error message with the
526         type that was found.
527         * resolve.c (gfc_resolve_index): Likewise.
528         * match.c (gfc_match_parens): Clarify error message with "at or before".
529         (gfc_match_do): Check for matching pairs of parenthesis.
530
531 2008-05-16  Tobias Burnus  <burnus@net-b.de
532
533         * intrinsic.texi: Write Fortran 77/90/95 instead of F77/90/95;
534         add missing KIND argument to ACHAR and NINT; and state that
535         the KIND argument is a F2003 extension for ACHAR, COUNT, IACHAR,
536         ICHAR, INDEX, LBOUND, LEN, LEN_TRIM, SCAN, SIZE, UBOUND, VERIFY.
537
538 2008-05-16  Daniel Kraft  <d@domob.eu>
539
540         * primary.c:  New private structure "gfc_structure_ctor_component".
541         (gfc_free_structure_ctor_component):  New helper function.
542         (gfc_match_structure_constructor):  Extended largely to support named
543         arguments and default initialization for structure constructors.
544
545 2008-05-15  Steven G. Kargl  <kargls@comcast.net>
546
547         * simplify.c (gfc_simplify_dble, gfc_simplify_float,
548         simplify_bound, gfc_simplify_nearest, gfc_simplify_real): Plug
549         possible memory leaks.
550         (gfc_simplify_reshape): Plug possible memory leaks and dereferencing
551         of NULL pointers.
552
553 2008-05-15  Steven G. Kargl  <kargls@comcast.net>
554
555         PR fortran/36239
556         * simplify.c (gfc_simplify_int, gfc_simplify_intconv): Replaced hand
557         rolled integer conversion with gfc_int2int, gfc_real2int, and
558         gfc_complex2int.
559         (gfc_simplify_intconv): Renamed to simplify_intconv.
560         
561 2008-05-15  Steven G. Kargl,   <kargl@comcast.net>
562         * gfortran.dg/and_or_xor.f90: New test
563
564         * fortran/simplify.c (gfc_simplify_and, gfc_simplify_or,
565         gfc_simplify_xor): Don't range check logical results.
566
567 2008-05-15  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
568
569         * trans-expr.c (gfc_conv_concat_op): Take care of nondefault
570         character kinds.
571         (gfc_build_compare_string): Add kind argument and use it.
572         (gfc_conv_statement_function): Fix indentation.
573         * gfortran.h (gfc_character_info): New structure.
574         (gfc_character_kinds): New array.
575         * trans-types.c (gfc_character_kinds, gfc_character_types,
576         gfc_pcharacter_types): New array.
577         (gfc_init_kinds): Fill character kinds array.
578         (validate_character): Take care of nondefault character kinds.
579         (gfc_build_uint_type): New function.
580         (gfc_init_types): Take care of nondefault character kinds.
581         (gfc_get_char_type, gfc_get_pchar_type): New functions.
582         (gfc_get_character_type_len): Use gfc_get_char_type.
583         * trans.h (gfc_build_compare_string): Adjust prototype.
584         (gfor_fndecl_compare_string_char4, gfor_fndecl_concat_string_char4,
585         gfor_fndecl_string_len_trim_char4, gfor_fndecl_string_index_char4,
586         gfor_fndecl_string_scan_char4, gfor_fndecl_string_verify_char4,
587         gfor_fndecl_string_trim_char4, gfor_fndecl_string_minmax_char4,
588         gfor_fndecl_adjustl_char4, gfor_fndecl_adjustr_char4): New
589         prototypes.
590         * trans-types.h (gfc_get_char_type, gfc_get_pchar_type): New
591         prototypes.
592         * trans-decl.c (gfor_fndecl_compare_string_char4,
593         gfor_fndecl_string_len_trim_char4, gfor_fndecl_string_index_char4,
594         gfor_fndecl_string_scan_char4, gfor_fndecl_string_verify_char4,
595         gfor_fndecl_string_trim_char4, gfor_fndecl_string_minmax_char4,
596         gfor_fndecl_adjustl_char4, gfor_fndecl_adjustr_char4,
597         gfor_fndecl_concat_string_char4): New function decls.
598         (gfc_build_intrinsic_function_decls): Define new *_char4 function
599         decls.
600         * trans-intrinsic.c (gfc_conv_intrinsic_minmax_char,
601         gfc_conv_intrinsic_len_trim, gfc_conv_intrinsic_ichar,
602         gfc_conv_intrinsic_strcmp, gfc_conv_intrinsic_trim,
603         gfc_conv_intrinsic_function): Deal with nondefault character kinds.
604
605 2008-05-15  Sa Liu  <saliu@de.ibm.com>
606
607         * iso-c-binding.def: Add standard parameter to macro NAMED_INTCST.
608         All existing NAMED_INTCST definitions has standard GFC_STD_F2003,
609         c_int128_t, c_int_least128_t and c_int_fast128_t are added as
610         GNU extensions.
611         * iso-fortran-evn.def: Add standard parameter GFC_STD_F2003
612         to macro NAMED_INTCST.
613         * symbol.c (std_for_isocbinding_symbol): New helper function to 
614         return the standard that supports this isocbinding symbol.
615         (generate_isocbinding_symbol): Do not generate GNU extension symbols
616         if std=f2003. Add new parameter to NAMED_INTCST.
617         * module.c (use_iso_fortran_env_module): Add new parameter to
618         NAMED_INTCST and new field standard to struct intmod_sym.
619         * gfortran.h: Add new parameter to NAMED_INTCST.
620         * trans-types.c (init_c_interop_kinds): Add new parameter to 
621         NAMED_INTCST.
622         * intrinsic.texi: Documented new types C_INT128_T, C_INT_LEASE128_T
623         and C_INT_FAST128_T.
624
625 2008-05-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
626
627         PR fortran/36059
628         * trans-decl.c (gfc_build_dummy_array_decl): Don't repack
629         arrays that have the TARGET attribute.
630
631 2008-05-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
632
633         PR fortran/36186
634         * simplify.c (only_convert_cmplx_boz): New function.
635         (gfc_simplify_cmplx, gfc_simplify_complex, gfc_simplify_dcmplx):
636         Call only_convert_cmplx_boz.
637
638 2008-05-14  Paul Thomas  <pault@gcc.gnu.org>
639
640         PR fortran/36233
641         * interface.c (compare_actual_formal): Do not check sizes if the
642         actual is BT_PROCEDURE.
643
644 2008-05-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
645
646         PR fortran/35682
647         * trans-array.c (gfc_conv_ss_startstride): Any negative size is
648         the same as zero size.
649         (gfc_conv_loop_setup): Fix size calculation.
650
651 2008-05-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
652
653         PR fortran/35685
654         * trans-intrinsic.c (gfc_conv_intrinsic_bound): Correctly
655         handle zero-size sections.
656
657 2008-05-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
658
659         PR fortran/36215
660         * scanner.c (preprocessor_line): Allocate enough memory for a
661         wide string.
662
663 2008-05-12  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
664
665         PR fortran/36176
666         * target-memory.c (gfc_target_expr_size): Correctly treat
667         substrings.
668         (gfc_target_encode_expr): Likewise.
669         (gfc_interpret_complex): Whitespace change.
670
671 2008-05-11  Thomas Koenig  <tkoenig@gcc.gnu.org>
672
673         PR fortran/35719
674         * trans.c (gfc_call_malloc): If size equals zero, allocate one
675         byte; don't return a null pointer.
676
677 2008-05-10  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
678
679         PR fortran/36197
680         * module.c (quote_string): Fix sprintf format.
681
682 2008-05-09  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
683
684         PR fortran/36162
685         * module.c (quote_string, unquote_string,
686         mio_allocated_wide_string): New functions.
687         (mio_expr): Call mio_allocated_wide_string where needed.
688
689 2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com>
690
691          * trans-decl.c (gfc_get_extern_function_decl, build_function_decl):
692          Rename DECL_IS_PURE to DECL_PURE_P.
693
694 2008-05-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
695
696         * arith.c: (gfc_arith_concat, gfc_compare_string,
697         gfc_compare_with_Cstring, hollerith2representation,
698         gfc_hollerith2int, gfc_hollerith2real, gfc_hollerith2complex,
699         gfc_hollerith2character, gfc_hollerith2logical): Use wide
700         characters for character constants.
701         * data.c (create_character_intializer): Likewise.
702         * decl.c (gfc_set_constant_character_len): Likewise.
703         * dump-parse-tree.c (show_char_const): Correctly dump wide
704         character strings.
705         error.c (print_wide_char): Rename into gfc_print_wide_char.
706         (show_locus): Adapt to new prototype of gfc_print_wide_char.
707         expr.c (free_expr0): Representation is now disjunct from
708         character string value, so we always free it.
709         (gfc_copy_expr, find_substring_ref, gfc_simplify_expr): Adapt
710         to wide character strings.
711         * gfortran.h (gfc_expr): Make value.character.string a wide string.
712         (gfc_wide_toupper, gfc_wide_strncasecmp, gfc_wide_memset,
713         gfc_widechar_to_char, gfc_char_to_widechar): New prototypes.
714         (gfc_get_wide_string): New macro.
715         (gfc_print_wide_char): New prototype.
716         * io.c (format_string): Make a wide string.
717         (next_char, gfc_match_format, compare_to_allowed_values, 
718         gfc_match_open): Deal with wide strings.
719         * module.c (mio_expr): Convert between wide strings and ASCII ones.
720         * primary.c (match_hollerith_constant, match_charkind_name): 
721         Handle wide strings.
722         * resolve.c (build_default_init_expr): Likewise.
723         * scanner.c (gfc_wide_toupper, gfc_wide_memset,
724         gfc_char_to_widechar): New functions.
725         (wide_strchr, gfc_widechar_to_char, gfc_wide_strncasecmp):
726         Changes in prototypes.
727         (gfc_define_undef_line, load_line, preprocessor_line,
728         include_line, load_file, gfc_read_orig_filename): Handle wide
729         strings.
730         * simplify.c (gfc_simplify_achar, gfc_simplify_adjustl,
731         gfc_simplify_adjustr, gfc_simplify_char, gfc_simplify_iachar,
732         gfc_simplify_ichar, simplify_min_max, gfc_simplify_new_line,
733         gfc_simplify_repeat): Handle wide strings.
734         (wide_strspn, wide_strcspn): New helper functions.
735         (gfc_simplify_scan, gfc_simplify_trim, gfc_simplify_verify):
736         Handle wide strings.
737         * symbol.c (generate_isocbinding_symbol): Likewise.
738         * target-memory.c (size_character, gfc_target_expr_size,
739         encode_character, gfc_target_encode_expr, gfc_interpret_character,
740         gfc_target_interpret_expr): Handle wide strings.
741         * trans-const.c (gfc_conv_string_init): Lower wide strings to
742         narrow ones.
743         (gfc_conv_constant_to_tree): Likewise.
744         * trans-expr.c (gfc_conv_substring_expr): Handle wide strings.
745         * trans-io.c (gfc_new_nml_name_expr): Likewise.
746         * trans-stmt.c (gfc_trans_label_assign): Likewise.
747
748 2008-05-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
749
750         * simplify.c (gfc_simplify_bessel_j0,gfc_simplify_bessel_j1,
751         gfc_simplify_bessel_jn,gfc_simplify_bessel_y0,
752         gfc_simplify_bessel_y1,gfc_simplify_bessel_yn): Mark arguments
753         with ATTRIBUTE_UNUSED.
754
755 2008-05-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
756
757         * check.c (gfc_check_sizeof): Switch to ATTRIBUTE_UNUSED.
758         * simplify.c (gfc_simplify_lgamma): Likewise.
759
760 2008-05-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
761
762         * openmp.c (gfc_match_omp_eos): Use gfc_next_ascii_char and
763         gfc_peek_ascii_char.
764         * decl.c (gfc_match_kind_spec, gfc_match_type_spec,
765         gfc_match_implicit_none, match_implicit_range, gfc_match_implicit,
766         match_string_p, match_attr_spec, gfc_match_suffix,
767         match_procedure_decl, gfc_match_entry, gfc_match_subroutine):
768         Likewise.
769         * gfortran.h (gfc_char_t): New type.
770         (gfc_linebuf): Make line member a gfc_char_t.
771         (locus): Make nextc member a gfc_char_t.
772         (gfc_wide_is_printable, gfc_wide_is_digit, gfc_wide_fits_in_byte,
773         gfc_wide_tolower, gfc_wide_strlen, gfc_next_ascii_char,
774         gfc_peek_ascii_char, gfc_check_digit): New prototypes.
775         * error.c (print_wide_char): New function.
776         (show_locus): Use print_wide_char and gfc_wide_strlen.
777         * io.c (next_char): Use gfc_char_t type.
778         (match_io): Use gfc_peek_ascii_char and gfc_next_ascii_char.
779         * match.c (gfc_match_parens, gfc_match_eos,
780         gfc_match_small_literal_int, gfc_match_name, gfc_match_name_C,
781         gfc_match_intrinsic_op, gfc_match_char,  gfc_match_return,
782         gfc_match_common): Likewise.
783         * match.h (gfc_match_special_char): Change prototype.
784         * parse.c (decode_specification_statement, decode_statement,
785         decode_omp_directive, next_free, next_fixed): Use
786         gfc_peek_ascii_char and gfc_next_ascii_char.
787         * primary.c (gfc_check_digit): Change name.
788         (match_digits, match_hollerith_constant, match_boz_constant,
789         match_real_constant, next_string_char, match_charkind_name,
790         match_string_constant, match_logical_constant_string,
791         match_complex_constant, match_actual_arg, match_varspec,
792         gfc_match_rvalue, match_variable): Use gfc_peek_ascii_char and
793         gfc_next_ascii_char.
794         * scanner.c (gfc_wide_fits_in_byte, wide_is_ascii,
795         gfc_wide_is_printable, gfc_wide_tolower, gfc_wide_is_digit,
796         gfc_wide_is_digit, wide_atoi, gfc_wide_strlen, wide_strcpy,
797         wide_strchr, widechar_to_char, wide_strncmp, wide_strncasecmp,
798         gfc_next_ascii_char, gfc_peek_ascii_char):
799         New functions.
800         (next_char, gfc_define_undef_line, skip_free_comments,
801         gfc_next_char_literal, gfc_next_char, gfc_peek_char,
802         gfc_error_recovery, load_line, preprocessor_line, include_line,
803         load_file, gfc_read_orig_filename): Use gfc_char_t for source
804         characters and the {gfc_,}wide_* functions to manipulate wide
805         strings.
806
807 2008-05-06  Tobias Burnus  <burnus@net-b.de>
808
809         PR fortran/36117
810         * intrinsic.c (add_functions): Call gfc_simplify_bessel_*.
811         * intrinsic.h: Add prototypes for gfc_simplify_bessel_*.
812         * simplify.c (gfc_simplify_bessel_j0,gfc_simplify_bessel_j1,
813         gfc_simplify_bessel_jn,gfc_simplify_bessel_y0,
814         gfc_simplify_bessel_y1,gfc_simplify_bessel_yn): New.
815
816 2008-05-03  Janus Weil  <jaydub66@gmail.com>
817
818         * misc.c (gfc_clear_ts): Set interface to NULL.
819
820 2008-05-03  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
821
822         PR fortran/33268
823         * gfortran.h: Add extra_comma pointer to gfc_dt structure. Add iokind to
824         gfc_expr value union. Add io_kind enum to here from io.c.
825         * io.c (gfc_free_dt): Free extra_comma.
826         (gfc_resolve_dt): If an extra comma was encountered and io_unit is type
827         BT_CHARACTER, resolve to format_expr and set default unit.  Error if
828         io_kind is M_WRITE. (match_io):  Match the extra comma and set new
829         pointer, extra_comma.
830
831 2008-05-01  Bud Davis  <bdavis9659@sbcglobal.net>
832
833         PR35940/Fortran
834         * simplify.c (gfc_simplify_index): Check for direction argument 
835         being a constant.
836
837 2008-05-01  Janus Weil  <jaydub66@gmail.com>
838
839         * gfortran.h (struct gfc_symbol): Moving "interface" member to
840         gfc_typespec (plus fixing a small docu error).
841         * interface.c (gfc_procedure_use): Ditto.
842         * decl.c (match_procedure_decl): Ditto.
843         * resolve.c (resolve_specific_f0,
844         resolve_specific_f0, resolve_symbol): Ditto.
845
846 2008-04-30  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
847
848         * intrinsic.c (add_functions): Add SELECTED_CHAR_KIND intrinsic.
849         * intrinsic.h (gfc_check_selected_char_kind,
850         gfc_simplify_selected_char_kind): New prototypes.
851         * gfortran.h (gfc_isym_id): Add GFC_ISYM_SC_KIND.
852         * trans.h (gfor_fndecl_sc_kind): New function decl.
853         * trans-decl.c (gfor_fndecl_sc_kind): Build new decl.
854         * arith.c (gfc_compare_with_Cstring): New function.
855         * arith.h (gfc_compare_with_Cstring): New prototype.
856         * check.c (gfc_check_selected_char_kind): New function.
857         * primary.c (match_string_constant, match_kind_param): Mark
858         symbols used as literal constant kind param as referenced.
859         * trans-intrinsic.c (gfc_conv_intrinsic_sc_kind): New function.
860         (gfc_conv_intrinsic_function): Call gfc_conv_intrinsic_sc_kind.
861         * intrinsic.texi (SELECTED_CHAR_KIND): Document new intrinsic.
862         * simplify.c (gfc_simplify_selected_char_kind): New function.
863
864 2008-04-28  Paul Thomas  <pault@gcc.gnu.org>
865
866         PR fortran/35997
867         * module.c (find_symbol): Do not return a result for a symbol
868         that has been renamed in another module.
869
870 2008-04-26  George Helffrich <george@gcc.gnu.org>
871
872         PR fortran/35892
873         PR fortran/35154
874         * trans-common.c (create_common):  Add decl to function
875         chain (if inside one) to preserve identifier scope in debug output.
876
877 2008-04-25  Jan Hubicka  <jh@suse.cz>
878
879         * trans-decl.c (trans_function_start): Update.
880
881 2008-04-25  Tobias Burnus  <burnus@net-b.de>
882             Daniel Franke <franke.daniel@gmail.com>
883
884         PR fortran/35156
885         * gfortranspec.c (lang_specific_driver): Deprecate
886         -M option; fix ICE when "-M" is last argument and
887         make "-M<dir>" work.
888         * options.c (gfc_handle_module_path_options): 
889         Use -J instead of -M in error messages.
890         * invoke.texi: Mark -M as depecated.
891
892 2008-04-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
893             Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
894
895         PR fortran/35994
896         * trans-instrinsic.c (gfc_conv_intrinsic_minmaxloc): Correctly adjust
897         loop counter offset.
898
899 2008-04-23  Paolo Bonzini  <bonzini@gnu.org>
900
901         * trans-expr.c (gfc_conv_structure): Don't set TREE_INVARIANT.
902         * trans-array.c (gfc_build_null_descriptor): Don't set TREE_INVARIANT.
903         (gfc_trans_array_constructor_value): Don't set TREE_INVARIANT.
904         (gfc_build_constant_array_constructor): Don't set TREE_INVARIANT.
905         (gfc_conv_array_initializer): Don't set TREE_INVARIANT.
906         * trans-common.c (get_init_field): Don't set TREE_INVARIANT.
907         (create_common): Don't set TREE_INVARIANT.
908         * trans-stmt.c (gfc_trans_character_select): Don't set TREE_INVARIANT.
909         * trans-decl.c (gfc_generate_function_code): Don't set TREE_INVARIANT.
910
911 2008-04-21  Steve Ellcey  <sje@cup.hp.com>
912
913         * f95-lang.c (gfc_init_decl_processing): use ptr_mode instead of Pmode.
914
915 2008-04-21  Daniel Franke  <franke.daniel@gmail.com>
916
917         PR fortran/35019
918         * gfortranspec.c (lookup_option): Properly handle separated arguments
919         in -J option, print missing argument message when necessary.
920
921 2008-04-20  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
922
923         PR fortran/35882
924         * scanner.c (skip_fixed_comments): Update continue_line when comment is
925         detected. (gfc_next_char_literal): Likewise.
926
927 2008-04-19  Paul Thomas  <pault@gcc.gnu.org>
928
929         PR fortran/35944
930         PR fortran/35946
931         PR fortran/35947
932         * trans_array.c (gfc_trans_array_constructor): Temporarily
933         realign loop, if loop->from is not zero, before creating
934         the temporary array and provide an offset.
935
936         PR fortran/35959
937         * trans-decl.c (gfc_init_default_dt): Add gfc_ prefix to name
938         and allow for NULL body.  Change all references from
939         init_default_dt to gfc_init_default_dt.
940         * trans.h : Add prototype for gfc_init_default_dt.
941         * trans-array.c (gfc_trans_deferred_vars): After nullification
942         call gfc_init_default_dt for derived types with allocatable
943         components.
944
945 2008-04-18  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
946
947         PR fortran/35892
948         * trans-common.c (create_common): Revert patch causing regression.
949
950 2008-04-16  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
951
952         PR fortran/35724
953         * iresolve.c (gfc_resolve_eoshift): Check for NULL symtree in test for
954         optional argument attribute.
955         
956 2008-04-16  Paul Thomas  <pault@gcc.gnu.org>
957
958         PR fortran/35932
959         * trans-intrinsic.c (gfc_conv_intrinsic_char): Even though KIND
960         is not used, the argument must be converted.
961
962 2008-04-16  Jakub Jelinek  <jakub@redhat.com>
963
964         PR target/35662
965         * f95-lang.c (gfc_init_builtin_functions): Make sure
966         BUILT_IN_SINCOS{,F,L} types aren't varargs.
967
968 2008-04-15  Paul Thomas  <pault@gcc.gnu.org>
969
970         PR fortran/35864
971         * expr.c (scalarize_intrinsic_call): Reorder identification of
972         array argument so that if one is not found a segfault does not
973         occur.  Return FAILURE if all scalar arguments.
974
975 2008-04-13  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
976             Tobias Burnus  <burnus@net-b.de>
977
978         PR fortran/35882
979         * options.c (gfc_init_options): Set the default maximum continuation
980         lines to 255 for both free and fixed form source for warnings.
981         (gfc_handle_option): Set -std=f95 fixed form max continuations to 19 and
982         the -std=f95 free form max continuations to 39 for warnings.
983         * scanner.c (gfc_next_char_literal): Adjust the current_line number only
984         if it is less than the current locus.
985
986 2008-04-07  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
987
988         PR fortran/25829 28655
989         * io.c (io_tag): Add new tags for decimal, encoding, asynchronous,
990         round, sign, and id. (match_open_element): Match new tags.
991         (gfc_resolve_open): Resolve new tags. (gfc_match_open): Enable encoding
992         for DEFAULT only. Update error messages. (match_dt_element): Fix match
993         tag for asynchronous. Update error messages. (gfc_free_inquire): Free
994         new expressions. (match_inquire_element): Match new tags.
995         (gfc_match_inquire): Add constraint for ID and PENDING.
996         (gfc_resolve_inquire): Resolve new tags.
997         * trans-io.c (gfc_trans_inquire): Clean up whitespace and fix setting of
998         mask for ID parameter.
999         * ioparm.def: Fix order of parameters for pending, round, and sign.
1000         NOTE: These must line up with the definitions in libgfortran/io/io.h. or
1001         things don't work.
1002
1003 2008-04-06  Paul Thomas  <pault@gcc.gnu.org>
1004
1005         PR fortran/35780
1006         * expr.c (scalarize_intrinsic_call): Identify which argument is
1007         an array and use that as the template.
1008         (check_init_expr): Remove tests that first argument is an array
1009         in the call to scalarize_intrinsic_call.
1010
1011 2008-04-06  Tobias Schlüter  <tobi@gcc.gnu.org>
1012
1013         PR fortran/35832
1014         * io.c (io_tag): Add field 'value'.  Split 'spec' field in
1015         existing io_tags.
1016         (match_etag, match_vtag, match_ltag): Split parsing in two steps
1017         to give better error messages.
1018
1019 2008-04-06  Tobias Burnus  <burnus@net-b.de>
1020
1021         * io.c (check_io_constraints): Add constrains. ID= requires
1022         asynchronous= and asynchronous= must be init expression.
1023
1024 2008-04-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1025
1026         * f95-lang.c: Set LANG_HOOKS_NAME to "GNU Fortran".
1027
1028 2008-04-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1029
1030         * dump-parse-tree.c: Use fprintf, fputs and fputc instead of
1031         gfc_status and gfc_status_char. Remove gfc_ prefix of the gfc_show_*
1032         functions and make them static. Add new gfc_dump_parse_tree
1033         function.
1034         * gfortran.h (gfc_option_t): Rename verbose into dump_parse_tree.
1035         (gfc_status, gfc_status_char): Delete prototypes.
1036         * error.c (gfc_status, gfc_status_char): Remove functions.
1037         * scanner.c (gfc_new_file): Use printf instead of gfc_status.
1038         * options.c (gfc_init_options): Rename verbose into dump_parse_tree.
1039         (gfc_handle_module_path_options): Use gfc_fatal_error instead of
1040         gfc_status and exit.
1041         (gfc_handle_option): Rename verbose into dump_parse_tree.
1042         * parse.c (gfc_parse_file): Use gfc_dump_parse_tree.
1043
1044 2008-04-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1045             Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1046
1047         PR fortran/25829 28655
1048         * dump-parse-tree.c (gfc_show_code_node): Show new I/O parameters.
1049         * gfortran.h (gfc_statement): Add ST_WAIT enumerator.
1050         (gfc_open): Add pointers for decimal, encoding, round, sign,
1051         asynchronous. (gfc_inquire): Add pointers for asynchronous, decimal,
1052         encoding, pending, round, sign, size, id.
1053         (gfc_wait): New typedef struct. (gfc_dt): Add pointers for id, pos,
1054         asynchronous, blank, decimal, delim, pad, round, sign.
1055         (gfc_exec_op): Add EXEC_WAIT enumerator. (gfc_code): Add pointer for
1056         wait. (gfc_free_wait), (gfc_resolve_wait): New function prototypes.
1057         * trans-stmt.h (gfc_trans_wait): New function prototype.
1058         * trans.c (gfc_trans_code): Add case for EXEC_WAIT.
1059         * io.c (io_tag): Add new tags for DECIMAL, ENCODING, ROUND, SIGN,
1060         ASYCHRONOUS, ID. (match_open_element): Add matchers for new tags.
1061         (gfc_free_open): Free new pointers. (gfc_resolve_open): Resolve new
1062         tags. (gfc_resolve_open): Remove comment around check for allowed
1063         values and ASYNCHRONOUS, update it.  Likewise for DECIMAL, ENCODING,
1064         ROUND, and SIGN. (match_dt_element): Add matching for new tags.
1065         (gfc_free_wait): New function. (gfc_resolve_wait): New function.
1066         (match_wait_element): New function. (gfc_match_wait): New function.
1067         * resolve.c (gfc_resolve_blocks): Add case for EXEC_WAIT.
1068         (resolve_code): Add case for EXEC_WAIT. 
1069         * st.c (gfc_free_statement): Add case for EXEC_WAIT.
1070         * trans-io.c (ioparam_type): Add IOPARM_ptype_wait. (gfc_st_parameter):
1071         Add "wait" entry. (iocall): Add IOCALL_WAIT enumerator.
1072         (gfc_build_io_library_fndecls): Add function declaration for st_wait.
1073         (gfc_trans_open): Add mask bits for new I/O tags.
1074         (gfc_trans_inquire): Add mask bits for new I/O tags.
1075         (gfc_trans_wait): New translation function.
1076         (build_dt): Add mask bits for new I/O tags.
1077         * match.c (gfc_match_if) Add matcher for "wait".
1078         * match.h (gfc_match_wait): Prototype for new function.
1079         * ioparm.def: Add new I/O parameter definitions.
1080         * parse.c (decode_statement): Add match for "wait" statement.
1081         (next_statement): Add case for ST_WAIT. (gfc_ascii_statement): Same.
1082
1083 2008-04-03  Jakub Jelinek  <jakub@redhat.com>
1084
1085         PR fortran/35786
1086         * openmp.c (resolve_omp_clauses): Diagnose if a clause symbol
1087         isn't a variable.
1088
1089 2008-04-03  Tom Tromey  <tromey@redhat.com>
1090
1091         * Make-lang.in (fortran_OBJS): New variable.
1092
1093 2008-04-03  Paolo Bonzini  <bonzini@gnu.org>
1094
1095         * f95-lang.c (insert_block): Kill.
1096
1097 2008-04-01  George Helffrich <george@gcc.gnu.org>
1098
1099         PR fortran/35154, fortran/23057
1100         * trans-common.c (create_common):  Add decl to function
1101         chain to preserve identifier scope in debug output.
1102
1103 2008-04-01  Joseph Myers  <joseph@codesourcery.com>
1104
1105         * gfortran.texi: Include gpl_v3.texi instead of gpl.texi
1106         * Make-lang.in (GFORTRAN_TEXI): Include gpl_v3.texi instead of
1107         gpl.texi.
1108
1109 2008-03-30  Paul Thomas  <pault@gcc.gnu.org>
1110
1111         PR fortran/35740
1112         * resolve.c (resolve_function, resolve_call): If the procedure
1113         is elemental do not look for noncopying intrinsics.
1114
1115 2008-03-29  Paul Thomas  <pault@gcc.gnu.org>
1116
1117         PR fortran/35698
1118         * trans-array.c (gfc_array_init_size): Set 'size' zero if
1119         negative in one dimension.
1120
1121         PR fortran/35702
1122         * trans-expr.c (gfc_trans_string_copy): Only assign a char
1123         directly if the lhs and rhs types are the same.
1124
1125 2008-03-28  Daniel Franke  <franke.daniel@gmail.com>
1126             Paul Richard Thomas <paul.richard.thomas@gmail.com>
1127
1128         PR fortran/34714
1129         * primary.c (match_variable): Improved matching of function 
1130         result variables.
1131         * resolve.c (resolve_allocate_deallocate): Removed checks if
1132         the actual argument for STAT is a variable.
1133
1134 2008-03-28  Tobias Burnus  <burnus@net-b.de>
1135
1136         * symbol.c (gfc_get_default_type): Fix error message; option
1137         -fallow_leading_underscore should be -fallow-leading-underscore
1138
1139 2008-03-27  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1140
1141         PR fortran/35724
1142         * iresolve.c (gfc_resolve_cshift): Check for NULL symtree in test for
1143         optional argument attribute.
1144
1145 2008-03-27  Tom Tromey  <tromey@redhat.com>
1146
1147         * Make-lang.in: Revert automatic dependency patch.
1148
1149 2008-03-25  Tom Tromey  <tromey@redhat.com>
1150
1151         * Make-lang.in: Remove .o targets.
1152         (fortran_OBJS): New variable.
1153         (fortran/gfortranspec.o): Move to fortran/.  Reduce to variable
1154         setting.
1155         (GFORTRAN_D_OBJS): Update.
1156         (GFORTRAN_TRANS_DEPS): Remove.
1157
1158 2008-03-24  Paul Thomas  <pault@gcc.gnu.org>
1159
1160         PR fortran/34813
1161         * resolve.c (resolve_structure_cons): It is an error to assign
1162         NULL to anything other than a pointer or allocatable component.
1163
1164         PR fortran/33295
1165         * resolve.c (resolve_symbol): If the symbol is a derived type,
1166         resolve the derived type.  If the symbol is a derived type
1167         function, ensure that the derived type is visible in the same
1168         namespace as the function.
1169
1170 2008-03-23  Tobias Schlüter  <tobi@gcc.gnu.org>
1171
1172         * trans.h: Use fold_build in build1_v, build2_v and build3_v
1173         macros.
1174         * trans-openmp.c (gfc_trans_omp_critical, gfc_trans_omp_single):
1175         Don't use build2_v macro.
1176
1177 2008-03-19  Daniel Franke  <franke.daniel@gmail.com>
1178
1179         PR fortran/35152
1180         * interface.c (gfc_procedure_use): Check for keyworded arguments in
1181         procedures without explicit interfaces.
1182
1183 2008-03-16  Paul Thomas  <pault@gcc.gnu.org>
1184
1185         PR fortran/35470
1186         * resolve.c (check_assumed_size_reference):  Only visit the
1187         first reference and look directly at the highest dimension.
1188
1189 2008-03-15  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1190
1191         PR fortran/35184
1192         * trans-array.c (gfc_conv_array_index_offset): Remove unnecessary
1193         assert.
1194
1195 2008-03-15  Daniel Franke  <franke.daniel@gmail.com>
1196
1197         PR fortran/35584
1198         * resolve.c (resolve_branch): Less strict and pessimistic warning
1199         message.
1200
1201 2008-03-11  Paolo Bonzini  <bonzini@gnu.org>
1202
1203         * f95-lang.c (LANG_HOOKS_CLEAR_BINDING_STACK): Delete.
1204         (gfc_be_parse_file): Call clear_binding_stack from here.
1205         (gfc_clear_binding_stack): Rename to clear_binding_stack.
1206                 
1207 2008-03-09  Paul Thomas  <pault@gcc.gnu.org>
1208
1209         PR fortran/35474
1210         * module.c (mio_symtree_ref): After providing a symbol for a
1211         missing equivalence member, resolve and NULL the fixups.
1212
1213 2008-03-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1214
1215         * invoke.texi (Error and Warning Options): Document
1216         -Wline-truncation.
1217
1218 2008-03-08  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1219
1220         PR fortran/34956
1221         * trans-array.c (gfc_conv_ss_startstride): Fix the logic to avoid
1222         checking bounds of absent optional arguments.
1223
1224 2008-03-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1225
1226         PR fortran/33197
1227         * intrinsic.c (add_functions): Add simplification routines for
1228         ERF, DERF, ERFC and DERFC.
1229         * decl.c (gfc_match_suffix, gfc_match_subroutine): Change GNU
1230         extensions into Fortran 2008 features.
1231         * intrinsic.h (gfc_simplify_erf, gfc_simplify_erfc): New
1232         prototypes.
1233         * simplify.c (gfc_simplify_erf, gfc_simplify_erfc): New functions.
1234
1235 2008-03-03  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1236
1237         PR fortran/33197
1238         * intrinsic.c (add_functions): Modify intrinsics ACOSH, ASINH,
1239         ATANH, ERF, ERFC and GAMMA. Add intrinsics BESSEL_{J,Y}{0,1,N},
1240         ERFC_SCALED, LOG_GAMMA and HYPOT.
1241         * intrinsic.h (gfc_check_hypot, gfc_simplify_hypot,
1242         gfc_resolve_hypot): New prototypes.
1243         * mathbuiltins.def: Add HYPOT builtin. Make complex versions of
1244         ACOSH, ASINH and ATANH available.
1245         * gfortran.h (GFC_ISYM_ERFC_SCALED, GFC_ISYM_HYPOT): New values.
1246         * lang.opt: Add -std=f2008 option.
1247         * libgfortran.h: Define GFC_STD_F2008.
1248         * lang-specs.h: Add .f08 and .F08 file suffixes.
1249         * iresolve.c (gfc_resolve_hypot): New function.
1250         * parse.c (parse_contained): Allow empty CONTAINS for Fortran 2008.
1251         * check.c (gfc_check_hypot): New function.
1252         * trans-intrinsic.c (gfc_intrinsic_map): Define ERFC_SCALE builtin.
1253         * options.c (set_default_std_flags): Allow Fortran 2008 by default.
1254         (form_from_filename): Add .f08 suffix.
1255         (gfc_handle_option): Handle -std=f2008 option.
1256         * simplify.c (gfc_simplify_hypot): New function.
1257         * gfortran.texi: Document Fortran 2008 status and file extensions.
1258         * intrinsic.texi: Document new BESSEL_{J,Y}{0,1,N} intrinsics,
1259         as well as HYPOT and ERFC_SCALED. Update documentation of ERF,
1260         ERFC, GAMMA, LGAMMA, ASINH, ACOSH and ATANH.
1261         * invoke.texi: Document the new -std=f2008 option.
1262
1263 2008-03-02  Jakub Jelinek  <jakub@redhat.com>
1264
1265         * gfortranspec.c (lang_specific_driver): Update copyright notice
1266         dates.
1267
1268 2008-02-29  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1269
1270         PR fortran/35059
1271         * expr.c (find_array_element): Modify traversing the constructor to
1272         avoid trying to access NULL memory pointed to by next for the
1273         last element. (find_array_section): Exit while loop if cons->next is
1274         NULL.
1275         * trans-expr.c (gfc_conv_scalar_char_value): Initialize gfc_typespec.
1276         (gfc_conv_function_call): Same.
1277         * decl.c (gfc_match_implicit): Same.
1278         * trans-intrinsic.c (gfc_conv_intrinsic_sr_kind): Same.
1279
1280 2008-02-28  Daniel Franke  <franke.daniel@gmail.com>
1281
1282         PR fortran/31463
1283         PR fortran/33950
1284         PR fortran/34296
1285         * lang.opt: Added -Wreturn-type.
1286         * options.c (gfc_handle_option): Recognize -Wreturn-type.
1287         * trans-decl.c (gfc_trans_deferred_vars): Emit warnings for funtions
1288         where the result value is not set.
1289         (gfc_generate_function_code): Likewise.
1290         (generate_local_decl): Emit warnings for funtions whose RESULT
1291         variable is not set.
1292
1293 2008-02-28  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1294
1295         PR fortran/34868
1296         * trans-expr.c (gfc_conv_variable): Don't build indirect
1297         references when explicit interface is mandated.
1298         * resolve.c (resolve_formal_arglist): Set attr.always_explicit
1299         on the result symbol as well as the procedure symbol.
1300
1301 2008-02-27  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1302
1303         PR fortran/33387
1304         * trans.h: Remove prototypes for gfor_fndecl_math_exponent4,
1305         gfor_fndecl_math_exponent8, gfor_fndecl_math_exponent10 and
1306         gfor_fndecl_math_exponent16.
1307         * f95-lang.c (build_builtin_fntypes): Add new function types.
1308         (gfc_init_builtin_functions): Add new builtins for nextafter,
1309         frexp, ldexp, fabs, scalbn and inf.
1310         * iresolve.c (gfc_resolve_rrspacing): Don't add hidden arguments.
1311         (gfc_resolve_scale): Don't convert type of second argument.
1312         (gfc_resolve_set_exponent): Likewise.
1313         (gfc_resolve_size): Don't add hidden arguments.
1314         * trans-decl.c: Remove gfor_fndecl_math_exponent4,
1315         gfor_fndecl_math_exponent8, gfor_fndecl_math_exponent10 and
1316         gfor_fndecl_math_exponent16.
1317         * trans-intrinsic.c (gfc_intrinsic_map): Remove intrinsics
1318         for scalbn, fraction, nearest, rrspacing, set_exponent and
1319         spacing.
1320         (gfc_conv_intrinsic_exponent): Directly call frexp.
1321         (gfc_conv_intrinsic_fraction, gfc_conv_intrinsic_nearest,
1322         gfc_conv_intrinsic_spacing, gfc_conv_intrinsic_rrspacing,
1323         gfc_conv_intrinsic_scale, gfc_conv_intrinsic_set_exponent): New
1324         functions.
1325         (gfc_conv_intrinsic_function): Use the new functions above.
1326
1327 2008-02-26  Tobias Burnus  <burnus@net-b.de>
1328
1329         PR fortran/35033
1330         * interface.c (check_operator_interface): Show better line for error
1331         messages; fix constrains for user-defined assignment operators.
1332         (gfc_extend_assign): Fix constrains for user-defined assignment
1333         operators.
1334
1335 2008-02-26  Tom Tromey  <tromey@redhat.com>
1336
1337         * trans-io.c (set_error_locus): Remove old location code.
1338         * trans-decl.c (gfc_set_decl_location): Remove old location code.
1339         * f95-lang.c (gfc_init): Remove test of USE_MAPPED_LOCATION.
1340         * scanner.c (gfc_gobble_whitespace): Remove old location code.
1341         (get_file): Likewise.
1342         (preprocessor_line): Likewise.
1343         (load_file): Likewise.
1344         (gfc_new_file): Likewise.
1345         * trans.c (gfc_trans_runtime_check): Remove old location code.
1346         (gfc_get_backend_locus): Likewise.
1347         (gfc_set_backend_locus): Likewise.
1348         * data.c (gfc_assign_data_value): Remove old location code.
1349         * error.c (show_locus): Remove old location code.
1350         * gfortran.h (gfc_linebuf): Remove old location code.
1351         (gfc_linebuf_linenum): Remove old-location variant.
1352
1353 2008-02-25  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1354
1355         PR fortran/34729
1356         * trans-const.c (gfc_build_string_const): Don't call gettext.
1357         (gfc_build_localized_string_const): New function.
1358         * trans-const.h (gfc_build_localized_string_const): New prototype.
1359         * trans.c (gfc_trans_runtime_check): Use
1360         gfc_build_localized_string_const instead of gfc_build_string_const.
1361         (gfc_call_malloc): Likewise.
1362         (gfc_allocate_with_status): Likewise.
1363         (gfc_allocate_array_with_status): Likewise.
1364         (gfc_deallocate_with_status): Likewise.
1365         (gfc_call_realloc): Likewise.
1366         * trans-io.c (gfc_trans_io_runtime_check): Likewise.
1367
1368 2008-02-24  Tobias Schlüter  <tobi@gcc.gnu.org>
1369
1370         * arith.c: Update copyright years.
1371         * arith.h: Likewise.
1372         * array.c: Likewise.
1373         * bbt.c: Likewise.
1374         * check.c: Likewise.
1375         * data.c: Likewise.
1376         * data.h: Likewise.
1377         * decl.c: Likewise.
1378         * dependency.c: Likewise.
1379         * dependency.h: Likewise.
1380         * dump-parse-tree.c: Likewise.
1381         * error.c: Likewise.
1382         * expr.c: Likewise.
1383         * gfc-internals.texi: Likewise.
1384         * gfortran.h: Likewise.
1385         * gfortran.texi: Likewise.
1386         * gfortranspec.c: Likewise.
1387         * interface.c: Likewise.
1388         * intrinsic.c: Likewise.
1389         * intrinsic.h: Likewise.
1390         * intrinsic.texi: Likewise.
1391         * invoke.texi: Likewise.
1392         * io.c: Likewise.
1393         * iresolve.c: Likewise.
1394         * iso-c-binding.def: Likewise.
1395         * iso-fortran-env.def: Likewise.
1396         * lang-specs.h: Likewise.
1397         * lang.opt: Likewise.
1398         * libgfortran.h: Likewise.
1399         * match.c: Likewise.
1400         * match.h: Likewise.
1401         * matchexp.c: Likewise.
1402         * misc.c: Likewise.
1403         * module.c: Likewise.
1404         * openmp.c: Likewise.
1405         * options.c: Likewise.
1406         * parse.c: Likewise.
1407         * parse.h: Likewise.
1408         * primary.c: Likewise.
1409         * resolve.c: Likewise.
1410         * scanner.c: Likewise.
1411         * simplify.c: Likewise.
1412         * st.c: Likewise.
1413         * symbol.c: Likewise.
1414         * target-memory.c: Likewise.
1415         * target-memory.h: Likewise.
1416         * trans-array.h: Likewise.
1417         * trans-const.h: Likewise.
1418         * trans-stmt.h: Likewise.
1419         * trans-types.c: Likewise.
1420         * trans-types.h: Likewise.
1421         * types.def: Likewise.
1422
1423 2008-02-24  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1424
1425         PR fortran/35223
1426         * simplify.c (gfc_simplify_ibclr), (gfc_simplify_ibits),
1427         (gfc_simplify_ibset): Remove call to range_check.
1428         (simplify_cmplx), (gfc_simplify_dble), (gfc_simplify_float)
1429         (gfc_simplify_real): Add call gfc_clear_ts to initialize the
1430         temporary gfc_typspec variable.
1431
1432 2008-02-24  Tobias Schlüter  <tobi@gcc.gnu.org>
1433
1434         * trans-array.c (gfc_conv_descriptor_data_get,
1435         gfc_conv_descriptor_data_set_internal,
1436         gfc_conv_descriptor_data_addr, gfc_conv_descriptor_offset,
1437         gfc_conv_descriptor_dtype, gfc_conv_descriptor_dimension,
1438         gfc_conv_descriptor_stride, gfc_conv_descriptor_lbound,
1439         gfc_conv_descriptor_ubound, gfc_trans_create_temp_array,
1440         gfc_conv_array_transpose, gfc_grow_array,
1441         gfc_trans_array_constructor_subarray,
1442         gfc_trans_array_constructor_value, gfc_trans_scalarized_loop_end,
1443         gfc_array_init_size, gfc_array_allocate, gfc_array_deallocate,
1444         gfc_conv_array_initializer, gfc_trans_array_bounds,
1445         gfc_trans_auto_array_allocation, gfc_trans_dummy_array_bias,
1446         gfc_get_dataptr_offset, gfc_conv_array_parameter,
1447         gfc_trans_dealloc_allocated, get_full_array_size,
1448         gfc_duplicate_allocatable, structure_alloc_comps): Use fold_buildN
1449         instead of buildN.
1450         * trans-expr.c (gfc_conv_expr_present, gfc_conv_missing_dummy,
1451         gfc_conv_component_ref, gfc_conv_cst_int_power,
1452         gfc_conv_function_call, gfc_trans_structur_assign): Likewise.
1453         * trans-common.c (create_common): Likewise.
1454         * trans-openmp.c (gfc_trans_omp_atomic, gfc_trans_omp_do):
1455         Likewise.
1456         * trans-const.c (gfc_conv_constant_to_tree): Likewise.
1457         * trans-stmt.c (gfc_trans_goto, gfc_trans_return, gfc_trans_do,
1458         gfc_trans_integer_select, gfc_trans_character_select,
1459         gfc_trans_forall_loop, compute_overall_iter_number,
1460         gfc_trans_forall_1, gfc_evaluate_where_mask, gfc_trans_allocate,
1461         gfc_trans_deallocate): Likewise.
1462         * trans.c (gfc_build_addr_expr, gfc_trans_runtime_check,
1463         gfc_allocate_with_status, gfc_allocate_array_with_status,
1464         gfc_deallocate_with_status): Likewise.
1465         * f95-lang.c (gfc_truthvalue_conversion): Likewise.
1466         * trans-io.c (set_parameter_const, set_parameter_value,
1467         set_parameter_ref, set_string, set_internal_unit, io_result,
1468         set_error_locus, nml_get_addr_expr, transfer_expr): Likewise.
1469         * trans-decl.c (gfc_build_qualified_array, build_entry_thunks,
1470         gfc_get_fake_result_decl, gfc_trans_auto_character_variable,
1471         gfc_generate_function_code): Likewise.
1472         * convert.c (convert): Likewise.
1473         * trans-intrinsic.c (gfc_conv_intrinsic_conversion,
1474         build_fixbound_expr, build_fix_expr, gfc_conv_intrinsic_aint,
1475         gfc_conv_intrinsic_int, gfc_conv_intrinsic_imagpart,
1476         gfc_conv_intrinsic_conjg, gfc_conv_intrinsic_abs,
1477         gfc_conv_intrinsic_cmplx, gfc_conv_intrinsic_mod,
1478         gfc_conv_intrinsic_dim, gfc_conv_intrinsic_dprod,
1479         gfc_conv_intrinsic_ctime, gfc_conv_intrinsic_fdate,
1480         gfc_conv_intrinsic_ttynam, gfc_conv_intrinsic_minmax,
1481         gfc_conv_intrinsic_minmax_char, gfc_conv_intrinsic_count,
1482         gfc_conv_intrinsic_arith, gfc_conv_intrinsic_dot_product,
1483         gfc_conv_intrinsic_minmaxloc, gfc_conv_intrinsic_minmaxval,
1484         gfc_conv_intrinsic_btest, gfc_conv_intrinsic_not,
1485         gfc_conv_intrinsic_ibits, gfc_conv_intrinsic_ishft,
1486         gfc_conv_intrinsic_ichar, gfc_conv_intrinsic_size,
1487         gfc_conv_intrinsic_array_transfer, gfc_conv_intrinsic_transfer,
1488         gfc_conv_allocated, gfc_conv_associated, gfc_conv_intrinsic_trim,
1489         gfc_conv_intrinsic_repeat): Likewise.
1490
1491 2008-02-23  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1492
1493         PR target/25477
1494         * trans-expr.c (gfc_conv_power_op): Use BUILT_IN_CPOW{F,,L}.
1495         * f95-lang.c (gfc_init_builtin_functions): Define BUILT_IN_CPOW{F,,L}.
1496         * trans.h (gfor_fndecl_math_cpow, gfor_fndecl_math_cpowf,
1497         gfor_fndecl_math_cpowl10, gfor_fndecl_math_cpowl16): Remove.
1498         * trans-decl.c: Likewise.
1499
1500 2008-02-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1501
1502         PR fortran/35059
1503         * expr.c (find_array_element): Modify traversing the constructor to
1504         avoid trying to access NULL memory pointed to by next for the
1505         last element. (find_array_section): Exit while loop if cons->next is
1506         NULL.
1507
1508 2008-02-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1509
1510         PR fortran/34907
1511         * iresolve.c (resolve_mask_arg): Add gfc_clear_ts to initialize
1512         structure.
1513         (gfc_resolve_aint): Likewise.
1514         (gfc_resolve_anint): Likewise.
1515         (gfc_resolve_besn): Likewise.
1516         (gfc_resolve_cshift): Likewise.
1517         (gfc_resolve_ctime): Likewise.
1518         (gfc_resolve_eoshift): Likewise.
1519         (gfc_resolve_index_func): Likewise.
1520         (gfc_resolve_isatty): Likewise.
1521         (gfc_resolve_malloc): Likewise.
1522         (gfc_resolve_rrspacing): Likewise.
1523         (gfc_resolve_scale): Likewise.
1524         (gfc_resolve_set_exponent): Likewise.
1525         (gfc_resolve_spacing): Likewise.
1526         (gfc_resolve_spacing): Likewise.
1527         (gfc_resolve_fgetc): Likewise.
1528         (gfc_resolve_fputc): Likewise.
1529         (gfc_resolve_ftell): Likewise.
1530         (gfc_resolve_ttynam): Likewise.
1531         (gfc_resolve_alarm_sub): Likewise.
1532         (gfc_resolve_mvbits): Likewise.
1533         (gfc_resolve_getarg): Likewise.
1534         (gfc_resolve_signal_sub): Likewise.
1535         (gfc_resolve_exit): Likewise.
1536         (gfc_resolve_flush): Likewise.
1537         (gfc_resolve_free): Likewise.
1538         (gfc_resolve_ctime_sub): Likewise.
1539         (gfc_resolve_fgetc_sub): Likewise.
1540         (gfc_resolve_fputc_sub): Likewise.
1541         (gfc_resolve_fseek_sub): Likewise.
1542         (gfc_resolve_ftell_sub): Likewise.
1543         (gfc_resolve_ttynam_sub): Likewise.
1544
1545 2008-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1546
1547         * gfc-internals.texi: Fix typos and markup nits.
1548         * gfortran.texi: Likewise.
1549         * intrinsic.texi: Likewise.
1550
1551 2008-02-21  Richard Guenther  <rguenther@suse.de>
1552
1553         * trans-expr.c (gfc_conv_expr_op): Expand INTRINSIC_PARENTHESES
1554         as unary PAREN_EXPR for real and complex typed expressions.
1555         (gfc_conv_unary_op): Fold the built tree.
1556
1557 2008-02-20  Tobias Burnus  <burnus@net-b.de>
1558
1559         PR fortran/34997
1560         * match.c (gfc_match_name): Improve error message for '$'.
1561
1562 2008-02-19  Daniel Franke  <franke.daniel@gmail.com>
1563
1564         PR fortran/35030
1565         * expr.c (gfc_check_pointer_assign): Add type and kind information
1566         to type-mismatch message.
1567         (gfc_check_assign): Unify error messages.
1568
1569 2008-02-16  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1570
1571         PR fortran/34952
1572         * gfortran.texi: Create new section for unimplemented extensions.
1573         Add "STRUCTURE and RECORD" and "ENCODE and DECODE statements".
1574         Remove "smaller projects" list. Fix a few typos.
1575
1576 2008-02-15  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1577
1578         * intrinsic.texi: Rename INDEX node to avoid clashing with
1579         index.html on case-insensitive systems.
1580
1581 2008-02-15  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1582
1583         PR fortran/35150
1584         * trans-expr.c (gfc_conv_function_call): Force evaluation of
1585         se->expr.
1586
1587 2008-02-10  Daniel Franke  <franke.daniel@gmail.com>
1588
1589         PR fortran/35019
1590         * lang.opt: Allow '-J<dir>' next to '-J <dir>', 
1591         likewise '-I <dir>' and '-I<dir>'.
1592
1593 2008-02-06  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
1594
1595         PR other/35107
1596         * Make-lang.in (f951): Add $(GMPLIBS).
1597
1598 2008-02-05  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1599
1600         PR fortran/35037
1601         * trans-common.c (build_field): Mark fields as volatile when needed.
1602
1603 2008-02-05  Tobias Burnus  <burnus@net-b.de>
1604
1605         PR fortran/35093
1606         * data.c (gfc_assign_data_value): Only free "size" if
1607         it has not already been freed.
1608
1609 2008-02-05  Paul Thomas  <pault@gcc.gnu.org>
1610
1611         PR fortran/34945
1612         * array.c (match_array_element_spec): Remove check for negative
1613         array size.
1614         (gfc_resolve_array_spec): Add check for negative size.
1615
1616 2008-02-05  Paul Thomas  <pault@gcc.gnu.org>
1617
1618         PR fortran/32315
1619         * data.c (gfc_assign_data_value): Add bounds check for array
1620         references.
1621
1622 2008-02-04  Daniel Franke  <franke.daniel@gmail.com>
1623
1624         * resolve.c (resolve_where): Fix typo.
1625         (gfc_resolve_where_code_in_forall): Likewise.
1626
1627 2008-02-03  Paul Thomas  <pault@gcc.gnu.org>
1628
1629         PR fortran/32760
1630         * resolve.c (resolve_allocate_deallocate): New function.
1631         (resolve_code): Call it for allocate and deallocate.
1632         * match.c (gfc_match_allocate, gfc_match_deallocate) : Remove
1633         the checking of the STAT tag and put in above new function.
1634         * primary,c (match_variable): Do not fix flavor of host
1635         associated symbols yet if the type is not known.
1636
1637 2008-01-31  Paul Thomas  <pault@gcc.gnu.org>
1638
1639         PR fortran/34910
1640         * expr.c (gfc_check_assign): It is an error to assign
1641         to a sibling procedure.
1642
1643 2008-01-30  Paul Thomas  <pault@gcc.gnu.org>
1644
1645         PR fortran/34975
1646         * symbol.c (gfc_delete_symtree, gfc_undo_symbols): Rename
1647         delete_symtree to gfc_delete_symtree.
1648         * gfortran.h : Add prototype for gfc_delete_symtree.
1649         * module.c (load_generic_interfaces): Transfer symbol to a
1650         unique symtree and delete old symtree, instead of renaming.
1651         (read_module): The rsym and the found symbol are the same, so
1652         the found symtree can be deleted.
1653
1654         PR fortran/34429
1655         * decl.c (match_char_spec): Remove the constraint on deferred
1656         matching of functions and free the length expression.
1657         delete_symtree to gfc_delete_symtree.
1658         (gfc_match_type_spec): Whitespace.
1659         (gfc_match_function_decl): Defer characteristic association for
1660         all types except BT_UNKNOWN.
1661         * parse.c (decode_specification_statement): Only derived type
1662         function matching is delayed to the end of specification.
1663
1664 2008-01-28  Tobias Burnus  <burnus@net-b.de>
1665
1666         PR libfortran/34980
1667         * simplify.c (gfc_simplify_shape): Simplify rank zero arrays.
1668
1669 2008-01-27  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1670
1671         PR fortran/34990
1672         * array.c (gfc_check_constructor_type): Revert clearing the expression.
1673
1674 2008-01-26  Tobias Burnus  <burnus@net-b.de>
1675
1676         PR fortran/34848
1677         * trans-expr.c (gfc_conv_function_call): Don't call
1678         gfc_add_interface_mapping if the expression is NULL.
1679
1680 2008-01-26  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1681
1682         PR fortran/31610
1683         * trans-array.c (gfc_trans_create_temp_array): Remove call to
1684         gcc_assert (integer_zerop (loop->from[n])).
1685
1686 2008-01-25  Daniel Franke  <franke.daniel@gmail.com>
1687
1688         PR fortran/34661
1689         * resolve.c (resolve_where): Added check if user-defined assignment 
1690         operator is an elemental subroutine.
1691         (gfc_resolve_where_code_in_forall): Likewise.
1692
1693 2008-01-24  Daniel Franke  <franke.daniel@gmail.com>
1694
1695         PR fortran/33375
1696         PR fortran/34858
1697         * gfortran.h: Revert changes from 2008-01-17.
1698         * match.c: Likewise.
1699         * symbol.c: Likewise.
1700         (gfc_undo_symbols): Undo namespace changes related to common blocks.
1701
1702 2008-01-24  Daniel Franke  <franke.daniel@gmail.com>
1703
1704         PR fortran/34202
1705         * data.c (formalize_structure_cons): Skip formalization on
1706         empty structures.
1707
1708 2008-01-24  Daniel Franke  <franke.daniel@gmail.com>
1709
1710         * gfortran.texi (OpenMP): Extended existing documentation.
1711         (contributors): Added major contributors of 2008 that were
1712         not listed yet.
1713         (proposed extensions): Removed implemented items.
1714
1715 2008-01-24  Paul Thomas  <pault@gcc.gnu.org>
1716
1717         PR fortran/34872
1718         * parse.c (next_statement) : If ST_GET_FCN_CHARACTERISTICS  is
1719         seen, check for a statement label and, if present, delete it
1720         and set the locus to the start of the statement.
1721
1722 2008-01-22  Paul Thomas  <pault@gcc.gnu.org>
1723
1724         PR fortran/34875
1725         * trans-io.c (gfc_trans_transfer): If the array reference in a
1726         read has a vector subscript, use gfc_conv_subref_array_arg to
1727         copy back the temporary.
1728
1729 2008-01-22  Tobias Burnus  <burnus@net-b.de>
1730
1731         PR fortran/34848
1732         * interface.c (compare_actual_formal): Fix adding type
1733         to missing_arg_type for absent optional arguments.
1734
1735 2008-01-22  Tobias Burnus  <burnus@net-b.de>
1736
1737         PR fortran/34907
1738         * parse.c (parse_spec): Change = into ==.
1739
1740 2008-01-22  Daniel Franke  <franke.daniel@gmail.com>
1741
1742         PR fortran/34915
1743         * expr.c (check_elemental): Fix check for valid data types.
1744
1745 2008-01-22  Tobias Burnus  <burnus@net-b.de>
1746
1747         PR fortran/34899
1748         * scanner.c (load_line): Support <tab><digit> continuation lines.
1749         * invoke.texi (-Wtabs): Document this.
1750
1751 2008-01-22  Paul Thomas  <pault@gcc.gnu.org>
1752
1753         PR fortran/34896
1754         * module.c (read_module): Set use_rename attribute.
1755
1756 2007-01-21  Tobias Burnus  <burnus@net-b.de>
1757
1758         PR fortran/34901
1759         * interface.c (compare_parameter): Improved error message
1760         for arguments of same type and mismatched kinds.
1761
1762 2008-01-20  Paul Thomas  <pault@gcc.gnu.org>
1763
1764         PR fortran/34861
1765         * resolve.c (resolve_entries): Do not do an array bounds check
1766         if the result symbols are the same.
1767
1768         PR fortran/34854
1769         * module.c (read_module) : Hide the symtree of the previous
1770         version of the symbol if this symbol is renamed.
1771
1772 2008-01-20  Paul Thomas  <pault@gcc.gnu.org>
1773
1774         PR fortran/34784
1775         * array.c (gfc_check_constructor_type): Clear the expression ts
1776         so that the checking starts from the deepest level of array
1777         constructor.
1778         * primary.c (match_varspec): If an unknown type is changed to
1779         default character and the attempt to match a substring fails,
1780         change it back to unknown.
1781
1782         PR fortran/34785
1783         * trans-array.c (gfc_add_loop_ss_code) : If ss->string_length is
1784         NULL for an array constructor, use the cl.length expression to
1785         build it.
1786         (gfc_conv_array_parameter): Change call to gfc_evaluate_now to
1787         a tree assignment.
1788
1789 2008-01-19  Thomas Koenig  <tkoenig@gcc.gnu.org>
1790
1791         PR fortran/34817
1792         PR fortran/34838
1793         * iresolve.c (gfc_resolve_all):  Remove conversion of mask
1794         argument to kind=1 by removing call to resolve_mask_arg().
1795         (gfc_resolve_any):  Likewise.
1796
1797 2008-01-19  Tobias Burnus  <burnus@net-b.de>
1798
1799         PR fortran/34760
1800         * primary.c (match_variable): Handle FL_UNKNOWN without
1801         uneducated guessing.
1802         (match_variable): Improve error message.
1803
1804 2008-01-18  Tobias Burnus  <burnus@net-b.de>
1805
1806         PR fortran/32616
1807         * interface.c (get_expr_storage_size): Return storage size
1808         for array element designators.
1809         (compare_actual_formal): Reject unequal string sizes for
1810         assumed-shape dummy arguments. And fix error message for
1811         array-sections with vector subscripts.
1812
1813 2008-01-17  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1814
1815         PR fortran/34556
1816         * simplify.c (is_constant_array_expr): New static function that returns
1817         true if the given expression is an array and is constant.
1818         (gfc_simplify_reshape): Use new function.
1819
1820 2008-01-17  H.J. Lu  <hongjiu.lu@intel.com>
1821
1822         PR fortran/33375
1823         * symbol.c (free_common_tree): Renamed to ...
1824         (gfc_free_common_tree): This.  Remove static.
1825         (gfc_free_namespace): Updated.
1826
1827         * gfortran.h (gfc_free_common_tree): New.
1828
1829         * match.c (gfc_match_common): Call gfc_free_common_tree () with
1830         gfc_current_ns->common_root and set gfc_current_ns->common_root
1831         to NULL on syntax error.
1832
1833 2008-01-18  Richard Sandiford  <rsandifo@nildram.co.uk>
1834
1835         PR fortran/34686
1836         * trans-expr.c (gfc_conv_function_call): Use proper
1837         type for returned character pointers.
1838
1839 2008-01-17  Paul Thomas  <pault@gcc.gnu.org>
1840
1841         PR fortran/34429
1842         PR fortran/34431
1843         PR fortran/34471
1844         * decl.c : Remove gfc_function_kind_locus and
1845         gfc_function_type_locus. Add gfc_matching_function.
1846         (match_char_length): If matching a function and the length
1847         does not match, return MATCH_YES and try again later.
1848         (gfc_match_kind_spec): The same.
1849         (match_char_kind): The same.
1850         (gfc_match_type_spec): The same for numeric and derived types.
1851         (match_prefix): Rename as gfc_match_prefix.
1852         (gfc_match_function_decl): Except for function valued character
1853         lengths, defer applying kind, type and charlen info until the
1854         end of specification block.
1855         gfortran.h (gfc_statement): Add ST_GET_FCN_CHARACTERISTICS.
1856         parse.c (decode_specification_statement): New function.
1857         (decode_statement): Call it when a function has kind = -1. Set
1858         and reset gfc_matching function, as function statement is being
1859         matched.
1860         (match_deferred_characteristics): Simplify with a single call
1861         to gfc_match_prefix. Do appropriate error handling. In any
1862         case, make sure that kind = -1 is reset or corrected.
1863         (parse_spec): Call above on seeing ST_GET_FCN_CHARACTERISTICS.
1864         Throw an error if kind = -1 after last specification statement.
1865         parse.h : Prototype for gfc_match_prefix.
1866
1867 2008-01-16  Tobias Burnus  <burnus@net-b.de>
1868
1869         PR fortran/34796
1870         * interface.c (compare_parameter): Allow AS_DEFERRED array
1871         elements and reject attr.pointer array elemenents.
1872         (get_expr_storage_size): Return storage size of elements of
1873         assumed-shape and pointer arrays.
1874
1875 2008-01-15  Sebastian Pop  <sebastian.pop@amd.com>
1876
1877         * f95-lang.c (gfc_init_builtin_functions): Initialize GOMP builtins
1878         for flag_tree_parallelize_loops.
1879
1880 2008-01-15  Thomas Koenig  <tkoenig@gcc.gnu.org>
1881
1882         PR libfortran/34671
1883         * iresolve.c (gfc_resolve_all):  Call resolve_mask_arg.
1884         (gfc_resolve_any):  Likewise.
1885         (gfc_resolve_count):  Likewise.  Don't append kind of
1886         argument to function name.
1887
1888 2008-01-13  Tobias Burnus  <burnus@net-b.de>
1889
1890         PR fortran/34665
1891         * resolve.c (resolve_actual_arglist): For expressions,
1892         also check for assume-sized arrays.
1893         * interface.c (compare_parameter): Move F2003 character checks
1894         here, print error messages here, reject elements of
1895         assumed-shape array as argument to dummy arrays.
1896         (compare_actual_formal): Update for the changes above.
1897
1898 2008-01-13  Tobias Burnus  <burnus@net-b.de>
1899
1900         PR fortran/34763
1901         * decl.c (contained_procedure): Only check directly preceeding state.
1902
1903 2008-01-13  Tobias Burnus  <burnus@net-b.de>
1904
1905         PR fortran/34759
1906         * check.c (gfc_check_shape): Accept array ranges of
1907         assumed-size arrays.
1908
1909 2008-01-12  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1910
1911         PR fortran/34432
1912         * match.c (gfc_match_name): Don't error if leading character is a '(',
1913         just return MATCH_NO.
1914
1915 2008-01-11  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1916
1917         PR fortran/34722
1918         * trans-io.c (create_dummy_iostat): Commit the symbol.
1919
1920 2008-01-11  Paul Thomas  <pault@gcc.gnu.org>
1921
1922         PR fortran/34537
1923         * simplify.c (gfc_simplify_transfer): Return NULL if the size
1924         of the element is unavailable and only assign character length
1925         to the result, if 'mold' is constant.
1926
1927 2008-01-10  Paul Thomas  <pault@gcc.gnu.org>
1928
1929         PR fortran/34396
1930         * trans-array.c (gfc_trans_array_ctor_element):  Use gfc_trans_string_copy
1931         to assign strings and perform bounds checks on the string length.
1932         (get_array_ctor_strlen): Remove bounds checking.
1933         (gfc_trans_array_constructor): Initialize string length checking.
1934         * trans-array.h : Add prototype for gfc_trans_string_copy.
1935
1936 2008-01-08  Richard Guenther  <rguenther@suse.de>
1937
1938         PR fortran/34706
1939         PR tree-optimization/34683
1940         * trans-types.c (gfc_get_array_type_bounds): Use an array type
1941         with known size for accesses if that is known.
1942
1943 2008-01-08  Paul Thomas  <pault@gcc.gnu.org>
1944
1945         PR fortran/34476
1946         * expr.c (find_array_element): Check that the array bounds are
1947         constant before using them.  Use lower, as well as upper bound.
1948         (check_restricted): Allow implied index variable.
1949
1950 2008-01-08  Paul Thomas  <pault@gcc.gnu.org>
1951
1952         PR fortran/34681
1953         * trans_array.c (gfc_trans_deferred_array): Do not null the
1954         data pointer on entering scope, nor deallocate it on leaving
1955         scope, if the symbol has the 'save' attribute.
1956
1957         PR fortran/34704
1958         * trans_decl.c (gfc_finish_var_decl): Derived types with
1959         allocatable components and an initializer must be TREE_STATIC.
1960
1961 2008-01-07  Paul Thomas  <pault@gcc.gnu.org>
1962
1963         PR fortran/34672
1964         * module.c (write_generic): Rewrite completely.
1965         (write_module): Change call to write_generic.
1966
1967 2008-01-06  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1968
1969         PR fortran/34659
1970         * scanner.c (load_line): Do not count ' ' as printable when checking for
1971         continuations.
1972
1973 2008-01-06  Paul Thomas  <pault@gcc.gnu.org>
1974
1975         PR fortran/34545
1976         * module.c (load_needed): If the namespace has no proc_name
1977         give it the module symbol.
1978
1979 2008-01-06  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1980
1981         PR fortran/34387
1982         * trans-expr.c (gfc_conv_missing_dummy): Use a temporary to type convert
1983         the dummy variable expression, test for NULL, and pass the variable
1984         address to the called function.
1985
1986 2007-01-06  Tobias Burnus  <burnus@net-b.de>
1987
1988         PR fortran/34658
1989         * match.c (gfc_match_common): Remove blank common in
1990         DATA BLOCK warning.
1991         * resolve.c (resolve_common_vars): New function.
1992         (resolve_common_blocks): Move checks to resolve_common_vars
1993         and invoke that function.
1994         (resolve_types): Call resolve_common_vars for blank commons.
1995
1996 2008-01-06  Tobias Burnus  <burnus@net-b.de>
1997
1998         PR fortran/34655
1999         * resolve.c (resolve_equivalence_derived): Reject derived types with
2000         default initialization if equivalenced with COMMON variable.
2001
2002 2008-01-06  Tobias Burnus  <burnus@net-b.de>
2003
2004         PR fortran/34654
2005         * io.c (check_io_constraints): Disallow unformatted I/O for
2006         internal units.
2007
2008 2008-01-06  Tobias Burnus  <burnus@net-b.de>
2009
2010         PR fortran/34660
2011         * resolve.c (resolve_formal_arglist): Reject dummy procedure in
2012         ELEMENTAL functions.
2013
2014 2008-01-06  Tobias Burnus  <burnus@net-b.de>
2015
2016         PR fortran/34662
2017         * interface.c (compare_actual_formal): Reject parameter
2018         actual to intent(out) dummy.
2019
2020 2008-01-04  Tobias Burnus  <burnus@net-b.de>
2021
2022         PR fortran/34557
2023         * primary.c (match_varspec): Gobble whitespace before
2024         checking for '('.