1 2008-07-17 Tobias Burnus <burnus@net-b.de>
5 * array.c (gfc_match_array_spec): Fix array-rank check.
6 * resolve.c (resolve_fl_derived): Fix constentness check
7 for the array dimensions.
9 2008-07-14 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11 * Make-lang.in (gfortranspec.o): Fix dependencies.
13 2008-07-13 Jerry DeLisle <jvdelisle@gcc.gnu.org>
16 * io.c: Add error check for g0 edit descriptor followed by '.'.
18 2008-07-12 Daniel Kraft <d@domob.eu>
20 * resolve.c (resolve_fl_derived): Allow pointer components to empty
21 derived types fixing a missing part of PR fortran/33221.
23 2008-07-10 Daniel Kraft <d@domob.eu>
25 * gfc-internals.texi (section gfc_expr): Created documentation about
26 the gfc_expr internal data structure.
28 2008-07-07 Thomas Koenig <tkoenig@gcc.gnu.org>
31 * iresolve.c (gfc_resolve_product): Set shape of return
33 (gfc_resolve_sum): Likewise.
35 2008-07-07 Jakub Jelinek <jakub@redhat.com>
38 * f95-lang.c (poplevel): Don't ever add subblocks to
41 2008-07-02 Janus Weil <janus@gcc.gnu.org>
42 Tobias Burnus <burnus@net-b.de>
43 Paul Thomas <pault@gcc.gnu.org>
46 * gfortran.h (struct gfc_symbol): New member "proc_pointer".
47 * check.c (gfc_check_associated,gfc_check_null): Implement
49 * decl.c (match_procedure_decl): Ditto.
50 * expr.c (gfc_check_pointer_assign,gfc_check_assign_symbol): Ditto.
51 * interface.c (compare_actual_formal): Ditto.
53 * match.c (gfc_match_pointer_assignment): Ditto.
54 * parse.c (parse_interface): Ditto.
55 * primary.c (gfc_match_rvalue,match_variable): Ditto.
56 * resolve.c (resolve_fl_procedure): Ditto.
57 * symbol.c (check_conflict,gfc_add_external,gfc_add_pointer,
58 gfc_copy_attr,gen_fptr_param,build_formal_args): Ditto.
59 * trans-decl.c (get_proc_pointer_decl,gfc_get_extern_function_decl,
60 create_function_arglist): Ditto.
61 * trans-expr.c (gfc_conv_variable,gfc_conv_function_val,
62 gfc_conv_function_call,gfc_trans_pointer_assignment): Ditto.
64 2008-07-02 Thomas Koenig <tkoenig@gcc.gnu.org>
68 * iresolve.c (resolve_mask_arg): Don't convert mask to
69 kind=1 logical if it is of that type already.
71 2008-06-29 Thomas Koenig <tkoenig@gcc.gnu.org>
74 * iresolve.c (gfc_resolve_matmul): Copy shapes
77 2008-06-29 Jerry DeLisle <jvdelisle@gcc.gnu.org>
79 * invoke.texi: Add documentation for runtime behavior of
82 2008-06-28 Daniel Kraft <d@domob.eu>
84 * gfc-internals.texi (section gfc_code): Extended documentation about
85 gfc_code in the internal datastructures chapter including details about
86 how IF, DO and SELECT blocks look like and an example for how the
89 2008-06-25 Paul Thomas <pault@gcc.gnu.org>
92 * interface.c (check_intents): Correct error where the actual
93 arg was checked for a pointer argument, rather than the formal.
95 2008-06-24 Paul Thomas <pault@gcc.gnu.org>
98 * expr.c (gfc_check_assign): Change message and locus for
99 error when conform == 0.
101 2008-06-23 Jakub Jelinek <jakub@redhat.com>
104 * cpp.c (cpp_define_builtins): Change _OPENMP value to 200805.
106 2008-06-20 Laurynas Biveinis <laurynas.biveinis@gmail.com>
107 Tobias Burnus <burnus@net-b.de>
111 * scanner.c (preprocessor_line): do not call gfc_free for
112 current_file->filename if it differs from filename.
114 2008-06-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
116 * arith.c (hollerith2representation): Fix for -Wc++-compat.
117 * array.c (gfc_get_constructor): Likewise.
118 * decl.c (gfc_get_data_variable, gfc_get_data_value, gfc_get_data,
119 create_enum_history, gfc_match_final_decl): Likewise.
120 * error.c (error_char): Likewise.
121 * expr.c (gfc_get_expr, gfc_copy_expr): Likewise.
122 * gfortran.h (gfc_get_charlen, gfc_get_array_spec,
123 gfc_get_component, gfc_get_formal_arglist, gfc_get_actual_arglist,
124 gfc_get_namelist, gfc_get_omp_clauses, gfc_get_interface,
125 gfc_get_common_head, gfc_get_dt_list, gfc_get_array_ref,
126 gfc_get_ref, gfc_get_equiv, gfc_get_case, gfc_get_iterator,
127 gfc_get_alloc, gfc_get_wide_string): Likewise.
128 * interface.c (count_types_test): Likewise.
129 * intrinsic.c (add_char_conversions, gfc_intrinsic_init_1):
131 * io.c (gfc_match_open, gfc_match_close, match_filepos, match_io,
132 gfc_match_inquire, gfc_match_wait): Likewise.
133 * match.c (gfc_match, match_forall_iterator): Likewise.
134 * module.c (gfc_get_pointer_info, gfc_get_use_rename, add_fixup,
135 add_true_name, parse_string, write_atom, quote_string,
136 mio_symtree_ref, mio_gmp_real, write_common_0): Likewise.
137 * options.c (gfc_post_options): Likewise.
138 * primary.c (match_integer_constant, match_hollerith_constant,
139 match_boz_constant, match_real_constant,
140 gfc_get_structure_ctor_component, gfc_match_structure_constructor): Likewise.
141 * scanner.c (gfc_widechar_to_char, add_path_to_list,
142 add_file_change, load_line, get_file, preprocessor_line,
143 load_file, unescape_filename, gfc_read_orig_filename): Likewise.
144 * simplify.c (gfc_simplify_ibits, gfc_simplify_ishft,
145 gfc_simplify_ishftc): Likewise.
146 * symbol.c (gfc_get_st_label, gfc_get_namespace, gfc_new_symtree,
147 gfc_get_uop, gfc_new_symbol, save_symbol_data, gfc_get_gsymbol):
149 * target-memory.c (gfc_target_interpret_expr): Likewise.
150 * trans-const.c (gfc_build_wide_string_const): Likewise.
151 * trans-expr.c (gfc_add_interface_mapping): Likewise.
152 * trans-intrinsic.c (gfc_conv_intrinsic_conversion,
153 gfc_conv_intrinsic_int, gfc_conv_intrinsic_lib_function,
154 gfc_conv_intrinsic_cmplx, gfc_conv_intrinsic_ctime,
155 gfc_conv_intrinsic_fdate, gfc_conv_intrinsic_ttynam,
156 gfc_conv_intrinsic_minmax, gfc_conv_intrinsic_minmax_char,
157 gfc_conv_intrinsic_ishftc, gfc_conv_intrinsic_index_scan_verify,
158 gfc_conv_intrinsic_merge, gfc_conv_intrinsic_trim): Likewise.
159 * trans.c (gfc_get_backend_locus): Likewise.
160 * trans.h (gfc_get_ss): Likewise.
162 2008-06-18 Daniel Kraft <d@domob.eu>
164 PR fortran/36517, fortran/36492
165 * array.c (gfc_resolve_character_array_constructor): Call
166 gfc_set_constant_character_len with changed length-chec argument.
167 * decl.c (gfc_set_constant_character_len): Changed array argument to
168 be a generic length-checking argument that can be used for correct
169 checking with typespec and in special cases where the should-be length
170 is different from the target length.
171 (build_struct): Call gfc_set_constant_character_len with changed length
172 checking argument and introduced additional checks for exceptional
173 conditions on invalid code.
174 (add_init_expr_to_sym), (do_parm): Call gfc_set_constant_character_len
175 with changed argument.
176 * match.h (gfc_set_constant_character_len): Changed third argument to
177 int for the should-be length rather than bool.
179 2008-06-17 Daniel Kraft <d@domob.eu>
182 * array.c (gfc_resolve_character_array_constructor): Check that all
183 elements with constant character length have the same one rather than
184 fixing it if no typespec is given, emit an error if they don't. Changed
185 return type to "try" and return FAILURE for the case above.
186 (gfc_resolve_array_constructor): Removed unneeded call to
187 gfc_resolve_character_array_constructor in this function.
188 * gfortran.h (gfc_resolve_character_array_constructor): Returns try.
189 * trans-array.c (get_array_ctor_strlen): Return length of first element
190 rather than last element.
191 * resolve.c (gfc_resolve_expr): Handle FAILURE return from
192 gfc_resolve_character_array_constructor.
194 2008-06-17 Paul Thomas <pault@gcc.gnu.org>
197 * resolve.c (add_dt_to_dt_list): New function.
198 (resolve_fl_derived): Call new function for pointer components
199 and when derived type resolved.
201 2008-06-15 Jerry DeLisle <jvdelisle@gcc.gnu.org>
204 * trans-decl.c (gfc_generate_function_code): Add range_check to options
207 2008-06-15 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
209 * gfc-internals.texi: Expand TABs, drop indentation outside examples.
210 * gfortran.texi: Likewise.
211 * intrinsic.texi: Likewise.
212 * invoke.texi: Likewise.
214 2008-06-13 Jerry DeLisle <jvdelisle@gcc.gnu.org>
217 * trans-io.c (gfc_build_io_library_fndecls): Build declaration for
218 transfer_character_wide which includes passing in the character kind to
219 support wide character IO. (transfer_expr): If the kind == 4, create the
220 argument and build the call.
221 * gfortran.texi: Fix typo.
223 2008-06-13 Tobias Burnus <burnus@net-b.de>
226 * decl.c (do_parm): Handle init expression for len=*.
228 2008-06-12 Tobias Burnus <burnus@net-b.de>
231 * trans-intrinsic.c (gfc_conv_intrinsic_index_scan_verify):
232 Fix passing of the BACK= argument.
234 2008-06-10 Jerry DeLisle <jvdelisle@gcc.gnu.org>
236 * cpp.c: Add copyright notice.
237 * cpp.h: Add copyright notice.
239 2008-06-08 Janus Weil <janus@gcc.gnu.org>
242 * decl.c (match_procedure_decl): Correctly recognize if the interface
243 is an intrinsic procedure.
245 2008-06-08 Tobias Burnus <burnus@net-b.de>
248 * resolve.c (resolve_symbol): Copy more attributes for
249 PROCEDUREs with interfaces.
251 2008-06-07 Jerry DeLisle <jvdelisle@gcc.gnu.org>
255 * io.c (check_format): Add new error message for zero width.
256 Use new error message for FMT_A and with READ, FMT_G. Allow
257 FMT_G with WRITE except when -std=F95 and -std=F2003.
259 2008-06-07 Tobias Burnus <burnus@net-b.de>
262 * intrinsic.c (add_functions): Implement c_sizeof.
263 * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Do not
264 create unneeded variable in the scalar case.
265 * intrinsic.texi: Add C_SIZEOF documentation.
267 2008-06-06 Tobias Burnus <burnus@net-b.de>
269 * intrinsic.texi (BESSEL_J1): Fix BES(S)EL_J1 typo.
271 2008-06-06 Jakub Jelinek <jakub@redhat.com>
273 * scanner.c (skip_free_comments, skip_fixed_comments): Handle tabs.
274 * parse.c (next_free): Allow tab after !$omp.
275 (decode_omp_directive): Handle !$omp task, !$omp taskwait
277 (case_executable): Add ST_OMP_TASKWAIT.
278 (case_exec_markers): Add ST_OMP_TASK.
279 (gfc_ascii_statement): Handle ST_OMP_TASK, ST_OMP_END_TASK and
281 (parse_omp_structured_block, parse_executable): Handle ST_OMP_TASK.
282 * gfortran.h (gfc_find_sym_in_expr): New prototype.
283 (gfc_statement): Add ST_OMP_TASK, ST_OMP_END_TASK and ST_OMP_TASKWAIT.
284 (gfc_omp_clauses): Add OMP_SCHED_AUTO to sched_kind,
285 OMP_DEFAULT_FIRSTPRIVATE to default_sharing. Add collapse and
287 (gfc_exec_op): Add EXEC_OMP_TASK and EXEC_OMP_TASKWAIT.
288 * f95-lang.c (LANG_HOOKS_OMP_CLAUSE_COPY_CTOR,
289 LANG_HOOKS_OMP_CLAUSE_ASSIGN_OP, LANG_HOOKS_OMP_CLAUSE_DTOR,
290 LANG_HOOKS_OMP_PRIVATE_OUTER_REF): Define.
291 * trans.h (gfc_omp_clause_default_ctor): Add another argument.
292 (gfc_omp_clause_copy_ctor, gfc_omp_clause_assign_op,
293 gfc_omp_clause_dtor, gfc_omp_private_outer_ref): New prototypes.
294 * types.def (BT_ULONGLONG, BT_PTR_ULONGLONG,
295 BT_FN_BOOL_ULONGLONGPTR_ULONGLONGPTR,
296 BT_FN_BOOL_BOOL_ULL_ULL_ULL_ULLPTR_ULLPTR,
297 BT_FN_BOOL_BOOL_ULL_ULL_ULL_ULL_ULLPTR_ULLPTR,
298 BT_FN_VOID_PTR_PTR, BT_PTR_FN_VOID_PTR_PTR,
299 BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT): New.
300 (BT_BOOL): Use integer type with BOOL_TYPE_SIZE rather
301 than boolean_type_node.
302 * dump-parse-tree.c (gfc_show_omp_node): Handle EXEC_OMP_TASK,
303 EXEC_OMP_TASKWAIT, OMP_SCHED_AUTO, OMP_DEFAULT_FIRSTPRIVATE,
304 untied and collapse clauses.
305 (gfc_show_code_node): Handle EXEC_OMP_TASK and EXEC_OMP_TASKWAIT.
306 * trans.c (gfc_trans_code): Handle EXEC_OMP_TASK and
308 * st.c (gfc_free_statement): Likewise.
309 * resolve.c (gfc_resolve_blocks, resolve_code): Likewise.
310 (find_sym_in_expr): Rename to...
311 (gfc_find_sym_in_expr): ... this. No longer static.
312 (resolve_allocate_expr, resolve_ordinary_assign): Adjust caller.
313 * match.h (gfc_match_omp_task, gfc_match_omp_taskwait): New
315 * openmp.c (resolve_omp_clauses): Allow allocatable arrays in
316 firstprivate, lastprivate, reduction, copyprivate and copyin
318 (omp_current_do_code): Made static.
319 (omp_current_do_collapse): New variable.
320 (gfc_resolve_omp_do_blocks): Compute omp_current_do_collapse,
321 clear omp_current_do_code and omp_current_do_collapse on return.
322 (gfc_resolve_do_iterator): Handle collapsed do loops.
323 (resolve_omp_do): Likewise, diagnose errorneous collapsed do loops.
324 (OMP_CLAUSE_COLLAPSE, OMP_CLAUSE_UNTIED): Define.
325 (gfc_match_omp_clauses): Handle default (firstprivate),
326 schedule (auto), untied and collapse (n) clauses.
327 (OMP_DO_CLAUSES): Add OMP_CLAUSE_COLLAPSE.
328 (OMP_TASK_CLAUSES): Define.
329 (gfc_match_omp_task, gfc_match_omp_taskwait): New functions.
330 * trans-openmp.c (gfc_omp_private_outer_ref): New function.
331 (gfc_omp_clause_default_ctor): Add outer argument. For allocatable
332 arrays allocate them with the bounds of the outer var if outer
334 (gfc_omp_clause_copy_ctor, gfc_omp_clause_assign_op,
335 gfc_omp_clause_dtor): New functions.
336 (gfc_trans_omp_array_reduction): If decl is allocatable array,
337 allocate it with outer var's bounds in OMP_CLAUSE_REDUCTION_INIT
338 and deallocate it in OMP_CLAUSE_REDUCTION_MERGE.
339 (gfc_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
340 for assumed-size arrays.
341 (gfc_trans_omp_do): Add par_clauses argument. If dovar is
342 present in lastprivate clause and do loop isn't simple,
343 set OMP_CLAUSE_LASTPRIVATE_STMT. If dovar is present in
344 parallel's lastprivate clause, change it to shared and add
345 lastprivate clause to OMP_FOR_CLAUSES. Handle collapsed do loops.
346 (gfc_trans_omp_directive): Adjust gfc_trans_omp_do callers.
347 (gfc_trans_omp_parallel_do): Likewise. Move collapse clause to
348 OMP_FOR from OMP_PARALLEL.
349 (gfc_trans_omp_clauses): Handle OMP_SCHED_AUTO,
350 OMP_DEFAULT_FIRSTPRIVATE, untied and collapse clauses.
351 (gfc_trans_omp_task, gfc_trans_omp_taskwait): New functions.
352 (gfc_trans_omp_directive): Handle EXEC_OMP_TASK and
355 2008-06-04 Janus Weil <janus@gcc.gnu.org>
359 * resolve.c (resolve_symbol): Correctly copy the interface for a
360 PROCEDURE declaration.
362 2008-06-02 Janus Weil <janus@gcc.gnu.org>
365 * symbol.c (gfc_add_allocatable,gfc_add_dimension,
366 gfc_add_explicit_interface): Added checks.
367 * decl.c (attr_decl1): Added missing "var_locus".
368 * parse.c (parse_interface): Checking for errors.
370 2008-06-02 Daniel Kraft <d@domob.eu>
372 * gfortran.h: New statement-type ST_FINAL for FINAL declarations.
373 (struct gfc_symbol): New member f2k_derived.
374 (struct gfc_namespace): New member finalizers, for use in the above
375 mentioned f2k_derived namespace.
376 (struct gfc_finalizer): New type defined for finalizers linked list.
377 * match.h (gfc_match_final_decl): New function header.
378 * decl.c (gfc_match_derived_decl): Create f2k_derived namespace on
379 constructed symbol node.
380 (gfc_match_final_decl): New function to match a FINAL declaration line.
381 * parse.c (decode_statement): match-call for keyword FINAL.
382 (parse_derived): Parse CONTAINS section and accept FINAL statements.
383 * resolve.c (gfc_resolve_finalizers): New function to resolve (that is
384 in this case, check) a list of finalizer procedures.
385 (resolve_fl_derived): Call gfc_resolve_finalizers here.
386 * symbol.c (gfc_get_namespace): Initialize new finalizers to NULL.
387 (gfc_free_namespace): Free finalizers list.
388 (gfc_new_symbol): Initialize new f2k_derived to NULL.
389 (gfc_free_symbol): Free f2k_derived namespace.
390 (gfc_free_finalizer): New function to free a single gfc_finalizer node.
391 (gfc_free_finalizer_list): New function to free a linked list of
394 2008-06-02 Daniel Franke <franke.daniel@gmail.com>
398 * cpp.c (gfc_cpp_init): Do not initialize builtins if
399 processing already preprocessed input.
400 (gfc_cpp_preprocess): Finalize output with newline.
402 2008-05-31 Jerry DeLisle <jvdelisle@gcc.gnu.org>
404 * intrinsic.texi: Revert wrong commit.
406 2008-05-31 Steven G. Kargl <kargls@comcast.net>
408 * arith.c (gfc_arith_init_1): Remove now unused r and c variables.
409 Cleanup numerical inquiry function initialization.
410 (gfc_arith_done_1): Replace multiple mpfr_clear() invocations with
411 a single mpfr_clears().
412 (gfc_check_real_range): Re-arrange logic to eliminate multiple
413 unnecessary branching and assignments.
414 (gfc_arith_times): Use mpfr_clears() in preference to multiple
416 (gfc_arith_divide): Ditto.
417 (complex_reciprocal): Eliminate now unused variables a, re, im.
418 Cleanup the mpfr abuse. Use mpfr_clears() in preference to
419 multiple mpfr_clear().
420 (complex_pow): Fix comment whitespace. Use mpfr_clears() in
421 preference to multiple mpfr_clear().
422 * simplify.c (gfc_simplify_and): Remove blank line.
423 (gfc_simplify_atan2): Move error checking earlier to eliminate
424 a now unnecessay gfc_free_expr().
425 (gfc_simplify_bessel_j0): Remove unnecessary gfc_set_model_kind().
426 (gfc_simplify_bessel_j1): Ditto.
427 (gfc_simplify_bessel_jn): Ditto.
428 (gfc_simplify_bessel_y0): Ditto.
429 (gfc_simplify_bessel_y1): Ditto.
430 (gfc_simplify_bessel_yn): Ditto.
431 (only_convert_cmplx_boz): Eliminate unnecessary duplicate code, and
432 combine nested if statement rational expressions.
433 (gfc_simplify_cos): Use mpfr_clears() in preference to multiple
435 (gfc_simplify_exp): Ditto.
436 (gfc_simplify_fraction): Move gfc_set_model_kind() to after the
437 special case of 0. Use mpfr_clears() in preference to multiple
439 (gfc_simplify_gamma): Eliminate unnecessary gfc_set_model_kind().
440 (gfc_simplify_lgamma): Ditto.
441 (gfc_simplify_log10): Ditto.
442 (gfc_simplify_log): Move gfc_set_model_kind () inside switch
443 statement. Use mpfr_clears() in preference to multiple mpfr_clear().
444 (gfc_simplify_mod): Eliminate now unused variables quot, iquot,
445 and term. Simplify the mpfr magic.
446 (gfc_simplify_modulo): Ditto.
447 (gfc_simplify_nearest): Eliminate unnecessary gfc_set_model_kind().
448 (gfc_simplify_scale): Use mpfr_clears() in preference to multiple
450 (gfc_simplify_sin): Ditto
451 (gfc_simplify_sqrt): Ditto
452 (gfc_simplify_set_exponent): Move gfc_set_model_kind() to after the
453 special case of 0. Use mpfr_clears() in preference to multiple
456 2008-05-29 Daniel Franke <franke.daniel@gmail.com>
459 * Make-lang.in (F95_OBJS): Added dependency on FORTRAN_TARGET_OBJS.
461 2008-05-29 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
463 * scanner.c (load_line): Add first_char argument. Don't call ungetc.
464 (gfc_read_orig_filename): Adjust call to load_line. Don't call
466 (load_file): Adjust call to load_line.
468 2008-05-28 Janus Weil <janus@gcc.gnu.org>
472 * interface.c (gfc_procedure_use): Enable argument checking for
473 external procedures with explicit interface.
474 * symbol.c (check_conflict): Fix conflict checking for externals.
475 (copy_formal_args): Fix handling of arrays.
476 * resolve.c (resolve_specific_f0, resolve_specific_s0): Fix handling
478 * parse.c (parse_interface): Non-abstract INTERFACE statement implies
481 2008-05-28 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
484 * intrinsic.c (gfc_convert_chartype): Don't mark conversion
486 * trans-array.c (gfc_trans_array_ctor_element): Divide element
487 size by the size of one character to obtain length.
488 * iresolve.c (gfc_resolve_cshift): Call the _char4 variant when
490 (gfc_resolve_eoshift): Likewise.
491 * trans-intrinsic.c (gfc_conv_intrinsic_ctime): Minor beautification.
492 (gfc_conv_intrinsic_fdate): Minor beautification.
493 (gfc_conv_intrinsic_ttynam): Minor beautification.
494 (gfc_conv_intrinsic_minmax_char): Allow all character kinds.
495 (size_of_string_in_bytes): New function.
496 (gfc_conv_intrinsic_size): Call size_of_string_in_bytes for
497 character expressions.
498 (gfc_conv_intrinsic_sizeof): Likewise.
499 (gfc_conv_intrinsic_array_transfer): Likewise.
500 (gfc_conv_intrinsic_trim): Allow all character kinds. Minor
502 (gfc_conv_intrinsic_repeat): Fix comment typo.
503 * simplify.c (gfc_convert_char_constant): Take care of conversion
504 of array constructors.
506 2008-05-27 Tobias Burnus <burnus@net-b.de>
509 * trans-array.c (gfc_set_loop_bounds_from_array_spec):
510 Add missing fold_convert.
512 2008-05-26 Daniel Franke <franke.daniel@gmail.com>
514 * fortran/cpp.c (cpp_define_builtins): Remove usage of TARGET_* macros,
517 2008-05-26 Daniel Franke <franke.daniel@gmail.com>
520 * lang.opt (A, C, CC, D, E, H, P, U, cpp, d, fworking-directory,
521 imultilib, iprefix, iquote, isysroot, isystem, nocpp, nostdinc,
522 o, undef, v): New options.
523 * options.c (gfc_init_options): Also initialize preprocessor
525 (gfc_post_options): Also handle post-initialization of preprocessor
527 (gfc_handle_option): Check if option is a preprocessor option.
528 If yes, let gfc_cpp_handle_option() handle the option.
529 * lang-specs.h: Reorganized to handle new options.
530 * scanner.c (gfc_new_file): Read temporary file instead of
531 input source if preprocessing is enabled.
532 * f95-lang.c (gfc_init): Initialize preprocessor.
533 (gfc_finish): Clean up preprocessor.
536 * Make-lang.in: Added new objects and dependencies.
537 * gfortran.texi: Updated section "Preprocessing and
538 conditional compilation".
539 * invoke.texi: Added new section "Preprocessing Options",
540 listed and documented the preprocessing options handled
543 2008-05-25 Tobias Burnus <burnus@net-b.de>
546 * trans-expr.c (gfc_conv_function_call): Remove library
547 call for c_f_pointer with scalar Fortran pointers and for
550 2008-05-21 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
553 * iresolve.c (check_charlen_present): Don't force the rank to 1.
555 2008-05-19 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
558 * trans-expr.c (gfc_conv_string_tmp): Pick the correct type for
559 the temporary variable.
561 2008-05-19 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
563 * simplify.c (gfc_simplify_dble, gfc_simplify_real): Initialize
564 result variable to avoid warnings.
566 2008-05-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
568 * intrinsic.c (char_conversions, ncharconv): New static variables.
569 (find_char_conv): New function.
570 (add_functions): Add simplification functions for ADJUSTL and
571 ADJUSTR. Don't check the kind of their argument. Add checking for
572 LGE, LLE, LGT and LLT.
573 (add_subroutines): Fix argument type for SLEEP. Fix argument name
575 (add_char_conversions): New function.
576 (gfc_intrinsic_init_1): Call add_char_conversions.
577 (gfc_intrinsic_done_1): Free char_conversions.
578 (check_arglist): Use kind == 0 as a signal that we don't want
579 the kind value to be checked.
580 (do_simplify): Also simplify character functions.
581 (gfc_convert_chartype): New function
582 * trans-array.c (gfc_trans_array_ctor_element): Don't force the
583 use of default character type.
584 (gfc_trans_array_constructor_value): Likewise.
585 (get_array_ctor_var_strlen): Use integer kind to build an integer
586 instead of a character kind!
587 (gfc_build_constant_array_constructor): Don't force the use of
588 default character type.
589 (gfc_conv_loop_setup): Likewise.
590 * trans-expr.c (gfc_conv_string_tmp): Don't force the use of
591 default character type. Allocate enough memory for wide strings.
592 (gfc_conv_concat_op): Make sure operand kind are the same.
593 (string_to_single_character): Remove gfc_ prefix. Reindent.
594 Don't force the use of default character type.
595 (gfc_conv_scalar_char_value): Likewise.
596 (gfc_build_compare_string): Call string_to_single_character.
597 (fill_with_spaces): New function
598 (gfc_trans_string_copy): Add kind arguments. Use them to deal
599 with wide character kinds.
600 (gfc_conv_statement_function): Whitespace fix. Call
601 gfc_trans_string_copy with new kind arguments.
602 (gfc_conv_substring_expr): Call gfc_build_wide_string_const
603 instead of using gfc_widechar_to_char.
604 (gfc_conv_string_parameter): Don't force the use of default
606 (gfc_trans_scalar_assign): Pass kind args to gfc_trans_string_copy.
607 * intrinsic.h (gfc_check_lge_lgt_lle_llt, gfc_convert_char_constant,
608 gfc_resolve_adjustl, gfc_resolve_adjustr): New prototypes.
609 * decl.c (gfc_set_constant_character_len): Don't assert the
610 existence of a single character kind.
611 * trans-array.h (gfc_trans_string_copy): New prototype.
612 * gfortran.h (gfc_check_character_range, gfc_convert_chartype):
614 * error.c (print_wide_char_into_buffer): New function lifting
615 code from gfc_print_wide_char. Fix order to output '\x??' instead
617 (gfc_print_wide_char): Call print_wide_char_into_buffer.
618 (show_locus): Call print_wide_char_into_buffer with buffer local
620 * trans-const.c (gfc_build_wide_string_const): New function.
621 (gfc_conv_string_init): Deal with wide characters strings
623 (gfc_conv_constant_to_tree): Call gfc_build_wide_string_const.
624 * trans-stmt.c (gfc_trans_label_assign): Likewise.
625 (gfc_trans_character_select): Deal with wide strings.
626 * expr.c (gfc_check_assign): Allow conversion between character
628 * trans-const.h (gfc_build_wide_string_const): New prototype.
629 * trans-types.c (gfc_get_character_type_len_for_eltype,
630 gfc_get_character_type_len): Create too variants of the old
631 gfc_get_character_type_len, one getting kind argument and the
632 other one directly taking a type tree.
633 * trans.h (gfor_fndecl_select_string_char4,
634 gfor_fndecl_convert_char1_to_char4,
635 gfor_fndecl_convert_char4_to_char1): New prototypes.
636 * trans-types.h (gfc_get_character_type_len_for_eltype): New
638 * resolve.c (resolve_operator): Exit early when kind mismatches
639 are detected, because that makes us issue an error message later.
640 (validate_case_label_expr): Fix wording of error message.
641 * iresolve.c (gfc_resolve_adjustl, gfc_resolve_adjustr): New
643 (gfc_resolve_pack): Call _char4 variants of library function
644 when dealing with wide characters.
645 (gfc_resolve_reshape): Likewise.
646 (gfc_resolve_spread): Likewise.
647 (gfc_resolve_transpose): Likewise.
648 (gfc_resolve_unpack): Likewise.
649 * target-memory.c (size_character): Take character kind bit size
650 correctly into account (not that it changes anything for now, but
652 (gfc_encode_character): Added gfc_ prefix. Encoding each
653 character of a string by calling native_encode_expr for the
654 corresponding unsigned integer.
655 (gfc_target_encode_expr): Add gfc_ prefix to encode_character.
656 * trans-decl.c (gfc_build_intrinsic_function_decls): Build
657 gfor_fndecl_select_string_char4, gfor_fndecl_convert_char1_to_char4
658 and gfor_fndecl_convert_char4_to_char1.
659 * target-memory.h (gfc_encode_character): New prototype.
660 * arith.c (gfc_check_character_range): New function.
661 (eval_intrinsic): Allow non-default character kinds.
662 * check.c (gfc_check_access_func): Only allow default
663 character kind arguments.
664 (gfc_check_chdir): Likewise.
665 (gfc_check_chdir_sub): Likewise.
666 (gfc_check_chmod): Likewise.
667 (gfc_check_chmod_sub): Likewise.
668 (gfc_check_lge_lgt_lle_llt): New function.
669 (gfc_check_link): Likewise.
670 (gfc_check_link_sub): Likewise.
671 (gfc_check_symlnk): Likewise.
672 (gfc_check_symlnk_sub): Likewise.
673 (gfc_check_rename): Likewise.
674 (gfc_check_rename_sub): Likewise.
675 (gfc_check_fgetputc_sub): Likewise.
676 (gfc_check_fgetput_sub): Likewise.
677 (gfc_check_stat): Likewise.
678 (gfc_check_stat_sub): Likewise.
679 (gfc_check_date_and_time): Likewise.
680 (gfc_check_ctime_sub): Likewise.
681 (gfc_check_fdate_sub): Likewise.
682 (gfc_check_gerror): Likewise.
683 (gfc_check_getcwd_sub): Likewise.
684 (gfc_check_getarg): Likewise.
685 (gfc_check_getlog): Likewise.
686 (gfc_check_hostnm): Likewise.
687 (gfc_check_hostnm_sub): Likewise.
688 (gfc_check_ttynam_sub): Likewise.
689 (gfc_check_perror): Likewise.
690 (gfc_check_unlink): Likewise.
691 (gfc_check_unlink_sub): Likewise.
692 (gfc_check_system_sub): Likewise.
693 * primary.c (got_delim): Perform correct character range checking
695 * trans-intrinsic.c (gfc_conv_intrinsic_conversion): Generate
696 calls to library functions convert_char4_to_char1 and
697 convert_char1_to_char4 for character conversions.
698 (gfc_conv_intrinsic_char): Allow all character kings.
699 (gfc_conv_intrinsic_strcmp): Fix whitespace.
700 (gfc_conv_intrinsic_repeat): Take care of all character kinds.
701 * intrinsic.texi: For all GNU intrinsics accepting character
702 arguments, mention that they're restricted to the default kind.
703 * simplify.c (simplify_achar_char): New function.
704 (gfc_simplify_achar, gfc_simplify_char): Call simplify_achar_char.
705 gfc_simplify_ichar): Don't error out for wide characters.
706 (gfc_convert_char_constant): New function.
708 2008-05-18 Steven G. Kargl <kargls@comcast.net>
711 * symbol.c (check_conflict): Issue errors for abuse of PUBLIC, PRIVATE,
713 * resolve.c (gfc_verify_binding_labels): Fix NULL pointer dereference.
715 2008-05-17 Tobias Burnus <burnus@net-b.de>
717 * intrinsic.texi: Correct description of GET_COMMAND_ARGUMENT
718 and GET_ENVIRONMENT_VARIABLE; fix keyword= name for GETENV,
719 GETLOG, GMTIME, HOSTNM, IRAND, ITIME, KILL.
720 Move LOG_GAMMA after LOG10.
722 2008-05-17 Tobias Burnus <burnus@net-b.de>
724 * intrinsic.c (add_functions): Change FLUSH(C) to FLUSH(UNIT).
725 * intrinsic.texi: Change INTEGER(*) to INTEGER; fix keyword= name for
726 ABS, ADJUSTL, AINT, ALLOCATED, ANINT, ASSOCIATED, C_ASSOCIATED,
727 CEILING, DBLE, DFLOAT, DOT_PRODUCT, DREAL, FLOAT, FLOOR, GET_COMMAND.
729 2008-05-16 Paul Thomas <pault@gcc.gnu.org>
733 * trans-stmt.c (gfc_trans_where): Tighten up the dependency
734 check for calling gfc_trans_where_3.
737 * trans-stmt.c (gfc_trans_where_2): Set the mask size to zero
738 if it is calculated to be negative.
741 * trans-stmt.c (gfc_trans_where_3, gfc_trans_where_assign): Set
742 ss->where for scalar right hand sides.
743 * trans-array.c (gfc_add_loop_ss_code): If ss->where is set do
744 not evaluate scalars outside the loop. Clean up whitespace.
745 * trans.h : Add a bitfield 'where' to gfc_ss.
747 2008-05-16 Tobias Burnus <burnus@net-b.de>
749 * libgfortran.h: Increase GFC_MAX_DIMENSIONS to 15.
750 * array.c (gfc_match_array_spec): Error with -std=f2003 if rank > 7.
752 2008-04-16 Daniel Kraft <d@domob.eu>
755 * gfortran.h: Added field "length_from_typespec" to gfc_charlength.
756 * aray.c (gfc_match_array_constructor): Added code to parse typespec.
757 (check_element_type, check_constructor_type, gfc_check_constructor_type):
758 Extended to support explicit typespec on constructor.
759 (gfc_resolve_character_array_constructor): Pad strings correctly for
760 explicit, constant character length.
761 * trans-array.c: New static global variable "typespec_chararray_ctor"
762 (gfc_trans_array_constructor): New code to support explicit but dynamic
765 2008-05-16 Jerry DeLisle <jvdelisle@gcc.gnu.org>
768 * decl.c (match_attr_spec): Check for matching pairs of parenthesis.
769 * expr.c (gfc_specification_expr): Supplement the error message with the
771 * resolve.c (gfc_resolve_index): Likewise.
772 * match.c (gfc_match_parens): Clarify error message with "at or before".
773 (gfc_match_do): Check for matching pairs of parenthesis.
775 2008-05-16 Tobias Burnus <burnus@net-b.de
777 * intrinsic.texi: Write Fortran 77/90/95 instead of F77/90/95;
778 add missing KIND argument to ACHAR and NINT; and state that
779 the KIND argument is a F2003 extension for ACHAR, COUNT, IACHAR,
780 ICHAR, INDEX, LBOUND, LEN, LEN_TRIM, SCAN, SIZE, UBOUND, VERIFY.
782 2008-05-16 Daniel Kraft <d@domob.eu>
784 * primary.c: New private structure "gfc_structure_ctor_component".
785 (gfc_free_structure_ctor_component): New helper function.
786 (gfc_match_structure_constructor): Extended largely to support named
787 arguments and default initialization for structure constructors.
789 2008-05-15 Steven G. Kargl <kargls@comcast.net>
791 * simplify.c (gfc_simplify_dble, gfc_simplify_float,
792 simplify_bound, gfc_simplify_nearest, gfc_simplify_real): Plug
793 possible memory leaks.
794 (gfc_simplify_reshape): Plug possible memory leaks and dereferencing
797 2008-05-15 Steven G. Kargl <kargls@comcast.net>
800 * simplify.c (gfc_simplify_int, gfc_simplify_intconv): Replaced hand
801 rolled integer conversion with gfc_int2int, gfc_real2int, and
803 (gfc_simplify_intconv): Renamed to simplify_intconv.
805 2008-05-15 Steven G. Kargl, <kargl@comcast.net>
806 * gfortran.dg/and_or_xor.f90: New test
808 * fortran/simplify.c (gfc_simplify_and, gfc_simplify_or,
809 gfc_simplify_xor): Don't range check logical results.
811 2008-05-15 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
813 * trans-expr.c (gfc_conv_concat_op): Take care of nondefault
815 (gfc_build_compare_string): Add kind argument and use it.
816 (gfc_conv_statement_function): Fix indentation.
817 * gfortran.h (gfc_character_info): New structure.
818 (gfc_character_kinds): New array.
819 * trans-types.c (gfc_character_kinds, gfc_character_types,
820 gfc_pcharacter_types): New array.
821 (gfc_init_kinds): Fill character kinds array.
822 (validate_character): Take care of nondefault character kinds.
823 (gfc_build_uint_type): New function.
824 (gfc_init_types): Take care of nondefault character kinds.
825 (gfc_get_char_type, gfc_get_pchar_type): New functions.
826 (gfc_get_character_type_len): Use gfc_get_char_type.
827 * trans.h (gfc_build_compare_string): Adjust prototype.
828 (gfor_fndecl_compare_string_char4, gfor_fndecl_concat_string_char4,
829 gfor_fndecl_string_len_trim_char4, gfor_fndecl_string_index_char4,
830 gfor_fndecl_string_scan_char4, gfor_fndecl_string_verify_char4,
831 gfor_fndecl_string_trim_char4, gfor_fndecl_string_minmax_char4,
832 gfor_fndecl_adjustl_char4, gfor_fndecl_adjustr_char4): New
834 * trans-types.h (gfc_get_char_type, gfc_get_pchar_type): New
836 * trans-decl.c (gfor_fndecl_compare_string_char4,
837 gfor_fndecl_string_len_trim_char4, gfor_fndecl_string_index_char4,
838 gfor_fndecl_string_scan_char4, gfor_fndecl_string_verify_char4,
839 gfor_fndecl_string_trim_char4, gfor_fndecl_string_minmax_char4,
840 gfor_fndecl_adjustl_char4, gfor_fndecl_adjustr_char4,
841 gfor_fndecl_concat_string_char4): New function decls.
842 (gfc_build_intrinsic_function_decls): Define new *_char4 function
844 * trans-intrinsic.c (gfc_conv_intrinsic_minmax_char,
845 gfc_conv_intrinsic_len_trim, gfc_conv_intrinsic_ichar,
846 gfc_conv_intrinsic_strcmp, gfc_conv_intrinsic_trim,
847 gfc_conv_intrinsic_function): Deal with nondefault character kinds.
849 2008-05-15 Sa Liu <saliu@de.ibm.com>
851 * iso-c-binding.def: Add standard parameter to macro NAMED_INTCST.
852 All existing NAMED_INTCST definitions has standard GFC_STD_F2003,
853 c_int128_t, c_int_least128_t and c_int_fast128_t are added as
855 * iso-fortran-evn.def: Add standard parameter GFC_STD_F2003
856 to macro NAMED_INTCST.
857 * symbol.c (std_for_isocbinding_symbol): New helper function to
858 return the standard that supports this isocbinding symbol.
859 (generate_isocbinding_symbol): Do not generate GNU extension symbols
860 if std=f2003. Add new parameter to NAMED_INTCST.
861 * module.c (use_iso_fortran_env_module): Add new parameter to
862 NAMED_INTCST and new field standard to struct intmod_sym.
863 * gfortran.h: Add new parameter to NAMED_INTCST.
864 * trans-types.c (init_c_interop_kinds): Add new parameter to
866 * intrinsic.texi: Documented new types C_INT128_T, C_INT_LEASE128_T
869 2008-05-14 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
872 * trans-decl.c (gfc_build_dummy_array_decl): Don't repack
873 arrays that have the TARGET attribute.
875 2008-05-14 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
878 * simplify.c (only_convert_cmplx_boz): New function.
879 (gfc_simplify_cmplx, gfc_simplify_complex, gfc_simplify_dcmplx):
880 Call only_convert_cmplx_boz.
882 2008-05-14 Paul Thomas <pault@gcc.gnu.org>
885 * interface.c (compare_actual_formal): Do not check sizes if the
886 actual is BT_PROCEDURE.
888 2008-05-14 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
891 * trans-array.c (gfc_conv_ss_startstride): Any negative size is
892 the same as zero size.
893 (gfc_conv_loop_setup): Fix size calculation.
895 2008-05-14 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
898 * trans-intrinsic.c (gfc_conv_intrinsic_bound): Correctly
899 handle zero-size sections.
901 2008-05-14 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
904 * scanner.c (preprocessor_line): Allocate enough memory for a
907 2008-05-12 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
910 * target-memory.c (gfc_target_expr_size): Correctly treat
912 (gfc_target_encode_expr): Likewise.
913 (gfc_interpret_complex): Whitespace change.
915 2008-05-11 Thomas Koenig <tkoenig@gcc.gnu.org>
918 * trans.c (gfc_call_malloc): If size equals zero, allocate one
919 byte; don't return a null pointer.
921 2008-05-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
924 * module.c (quote_string): Fix sprintf format.
926 2008-05-09 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
929 * module.c (quote_string, unquote_string,
930 mio_allocated_wide_string): New functions.
931 (mio_expr): Call mio_allocated_wide_string where needed.
933 2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com>
935 * trans-decl.c (gfc_get_extern_function_decl, build_function_decl):
936 Rename DECL_IS_PURE to DECL_PURE_P.
938 2008-05-06 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
940 * arith.c: (gfc_arith_concat, gfc_compare_string,
941 gfc_compare_with_Cstring, hollerith2representation,
942 gfc_hollerith2int, gfc_hollerith2real, gfc_hollerith2complex,
943 gfc_hollerith2character, gfc_hollerith2logical): Use wide
944 characters for character constants.
945 * data.c (create_character_intializer): Likewise.
946 * decl.c (gfc_set_constant_character_len): Likewise.
947 * dump-parse-tree.c (show_char_const): Correctly dump wide
949 error.c (print_wide_char): Rename into gfc_print_wide_char.
950 (show_locus): Adapt to new prototype of gfc_print_wide_char.
951 expr.c (free_expr0): Representation is now disjunct from
952 character string value, so we always free it.
953 (gfc_copy_expr, find_substring_ref, gfc_simplify_expr): Adapt
954 to wide character strings.
955 * gfortran.h (gfc_expr): Make value.character.string a wide string.
956 (gfc_wide_toupper, gfc_wide_strncasecmp, gfc_wide_memset,
957 gfc_widechar_to_char, gfc_char_to_widechar): New prototypes.
958 (gfc_get_wide_string): New macro.
959 (gfc_print_wide_char): New prototype.
960 * io.c (format_string): Make a wide string.
961 (next_char, gfc_match_format, compare_to_allowed_values,
962 gfc_match_open): Deal with wide strings.
963 * module.c (mio_expr): Convert between wide strings and ASCII ones.
964 * primary.c (match_hollerith_constant, match_charkind_name):
966 * resolve.c (build_default_init_expr): Likewise.
967 * scanner.c (gfc_wide_toupper, gfc_wide_memset,
968 gfc_char_to_widechar): New functions.
969 (wide_strchr, gfc_widechar_to_char, gfc_wide_strncasecmp):
970 Changes in prototypes.
971 (gfc_define_undef_line, load_line, preprocessor_line,
972 include_line, load_file, gfc_read_orig_filename): Handle wide
974 * simplify.c (gfc_simplify_achar, gfc_simplify_adjustl,
975 gfc_simplify_adjustr, gfc_simplify_char, gfc_simplify_iachar,
976 gfc_simplify_ichar, simplify_min_max, gfc_simplify_new_line,
977 gfc_simplify_repeat): Handle wide strings.
978 (wide_strspn, wide_strcspn): New helper functions.
979 (gfc_simplify_scan, gfc_simplify_trim, gfc_simplify_verify):
981 * symbol.c (generate_isocbinding_symbol): Likewise.
982 * target-memory.c (size_character, gfc_target_expr_size,
983 encode_character, gfc_target_encode_expr, gfc_interpret_character,
984 gfc_target_interpret_expr): Handle wide strings.
985 * trans-const.c (gfc_conv_string_init): Lower wide strings to
987 (gfc_conv_constant_to_tree): Likewise.
988 * trans-expr.c (gfc_conv_substring_expr): Handle wide strings.
989 * trans-io.c (gfc_new_nml_name_expr): Likewise.
990 * trans-stmt.c (gfc_trans_label_assign): Likewise.
992 2008-05-06 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
994 * simplify.c (gfc_simplify_bessel_j0,gfc_simplify_bessel_j1,
995 gfc_simplify_bessel_jn,gfc_simplify_bessel_y0,
996 gfc_simplify_bessel_y1,gfc_simplify_bessel_yn): Mark arguments
997 with ATTRIBUTE_UNUSED.
999 2008-05-06 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1001 * check.c (gfc_check_sizeof): Switch to ATTRIBUTE_UNUSED.
1002 * simplify.c (gfc_simplify_lgamma): Likewise.
1004 2008-05-06 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1006 * openmp.c (gfc_match_omp_eos): Use gfc_next_ascii_char and
1007 gfc_peek_ascii_char.
1008 * decl.c (gfc_match_kind_spec, gfc_match_type_spec,
1009 gfc_match_implicit_none, match_implicit_range, gfc_match_implicit,
1010 match_string_p, match_attr_spec, gfc_match_suffix,
1011 match_procedure_decl, gfc_match_entry, gfc_match_subroutine):
1013 * gfortran.h (gfc_char_t): New type.
1014 (gfc_linebuf): Make line member a gfc_char_t.
1015 (locus): Make nextc member a gfc_char_t.
1016 (gfc_wide_is_printable, gfc_wide_is_digit, gfc_wide_fits_in_byte,
1017 gfc_wide_tolower, gfc_wide_strlen, gfc_next_ascii_char,
1018 gfc_peek_ascii_char, gfc_check_digit): New prototypes.
1019 * error.c (print_wide_char): New function.
1020 (show_locus): Use print_wide_char and gfc_wide_strlen.
1021 * io.c (next_char): Use gfc_char_t type.
1022 (match_io): Use gfc_peek_ascii_char and gfc_next_ascii_char.
1023 * match.c (gfc_match_parens, gfc_match_eos,
1024 gfc_match_small_literal_int, gfc_match_name, gfc_match_name_C,
1025 gfc_match_intrinsic_op, gfc_match_char, gfc_match_return,
1026 gfc_match_common): Likewise.
1027 * match.h (gfc_match_special_char): Change prototype.
1028 * parse.c (decode_specification_statement, decode_statement,
1029 decode_omp_directive, next_free, next_fixed): Use
1030 gfc_peek_ascii_char and gfc_next_ascii_char.
1031 * primary.c (gfc_check_digit): Change name.
1032 (match_digits, match_hollerith_constant, match_boz_constant,
1033 match_real_constant, next_string_char, match_charkind_name,
1034 match_string_constant, match_logical_constant_string,
1035 match_complex_constant, match_actual_arg, match_varspec,
1036 gfc_match_rvalue, match_variable): Use gfc_peek_ascii_char and
1037 gfc_next_ascii_char.
1038 * scanner.c (gfc_wide_fits_in_byte, wide_is_ascii,
1039 gfc_wide_is_printable, gfc_wide_tolower, gfc_wide_is_digit,
1040 gfc_wide_is_digit, wide_atoi, gfc_wide_strlen, wide_strcpy,
1041 wide_strchr, widechar_to_char, wide_strncmp, wide_strncasecmp,
1042 gfc_next_ascii_char, gfc_peek_ascii_char):
1044 (next_char, gfc_define_undef_line, skip_free_comments,
1045 gfc_next_char_literal, gfc_next_char, gfc_peek_char,
1046 gfc_error_recovery, load_line, preprocessor_line, include_line,
1047 load_file, gfc_read_orig_filename): Use gfc_char_t for source
1048 characters and the {gfc_,}wide_* functions to manipulate wide
1051 2008-05-06 Tobias Burnus <burnus@net-b.de>
1054 * intrinsic.c (add_functions): Call gfc_simplify_bessel_*.
1055 * intrinsic.h: Add prototypes for gfc_simplify_bessel_*.
1056 * simplify.c (gfc_simplify_bessel_j0,gfc_simplify_bessel_j1,
1057 gfc_simplify_bessel_jn,gfc_simplify_bessel_y0,
1058 gfc_simplify_bessel_y1,gfc_simplify_bessel_yn): New.
1060 2008-05-03 Janus Weil <jaydub66@gmail.com>
1062 * misc.c (gfc_clear_ts): Set interface to NULL.
1064 2008-05-03 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1067 * gfortran.h: Add extra_comma pointer to gfc_dt structure. Add iokind to
1068 gfc_expr value union. Add io_kind enum to here from io.c.
1069 * io.c (gfc_free_dt): Free extra_comma.
1070 (gfc_resolve_dt): If an extra comma was encountered and io_unit is type
1071 BT_CHARACTER, resolve to format_expr and set default unit. Error if
1072 io_kind is M_WRITE. (match_io): Match the extra comma and set new
1073 pointer, extra_comma.
1075 2008-05-01 Bud Davis <bdavis9659@sbcglobal.net>
1078 * simplify.c (gfc_simplify_index): Check for direction argument
1081 2008-05-01 Janus Weil <jaydub66@gmail.com>
1083 * gfortran.h (struct gfc_symbol): Moving "interface" member to
1084 gfc_typespec (plus fixing a small docu error).
1085 * interface.c (gfc_procedure_use): Ditto.
1086 * decl.c (match_procedure_decl): Ditto.
1087 * resolve.c (resolve_specific_f0,
1088 resolve_specific_f0, resolve_symbol): Ditto.
1090 2008-04-30 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1092 * intrinsic.c (add_functions): Add SELECTED_CHAR_KIND intrinsic.
1093 * intrinsic.h (gfc_check_selected_char_kind,
1094 gfc_simplify_selected_char_kind): New prototypes.
1095 * gfortran.h (gfc_isym_id): Add GFC_ISYM_SC_KIND.
1096 * trans.h (gfor_fndecl_sc_kind): New function decl.
1097 * trans-decl.c (gfor_fndecl_sc_kind): Build new decl.
1098 * arith.c (gfc_compare_with_Cstring): New function.
1099 * arith.h (gfc_compare_with_Cstring): New prototype.
1100 * check.c (gfc_check_selected_char_kind): New function.
1101 * primary.c (match_string_constant, match_kind_param): Mark
1102 symbols used as literal constant kind param as referenced.
1103 * trans-intrinsic.c (gfc_conv_intrinsic_sc_kind): New function.
1104 (gfc_conv_intrinsic_function): Call gfc_conv_intrinsic_sc_kind.
1105 * intrinsic.texi (SELECTED_CHAR_KIND): Document new intrinsic.
1106 * simplify.c (gfc_simplify_selected_char_kind): New function.
1108 2008-04-28 Paul Thomas <pault@gcc.gnu.org>
1111 * module.c (find_symbol): Do not return a result for a symbol
1112 that has been renamed in another module.
1114 2008-04-26 George Helffrich <george@gcc.gnu.org>
1118 * trans-common.c (create_common): Add decl to function
1119 chain (if inside one) to preserve identifier scope in debug output.
1121 2008-04-25 Jan Hubicka <jh@suse.cz>
1123 * trans-decl.c (trans_function_start): Update.
1125 2008-04-25 Tobias Burnus <burnus@net-b.de>
1126 Daniel Franke <franke.daniel@gmail.com>
1129 * gfortranspec.c (lang_specific_driver): Deprecate
1130 -M option; fix ICE when "-M" is last argument and
1131 make "-M<dir>" work.
1132 * options.c (gfc_handle_module_path_options):
1133 Use -J instead of -M in error messages.
1134 * invoke.texi: Mark -M as depecated.
1136 2008-04-23 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1137 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1140 * trans-instrinsic.c (gfc_conv_intrinsic_minmaxloc): Correctly adjust
1141 loop counter offset.
1143 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
1145 * trans-expr.c (gfc_conv_structure): Don't set TREE_INVARIANT.
1146 * trans-array.c (gfc_build_null_descriptor): Don't set TREE_INVARIANT.
1147 (gfc_trans_array_constructor_value): Don't set TREE_INVARIANT.
1148 (gfc_build_constant_array_constructor): Don't set TREE_INVARIANT.
1149 (gfc_conv_array_initializer): Don't set TREE_INVARIANT.
1150 * trans-common.c (get_init_field): Don't set TREE_INVARIANT.
1151 (create_common): Don't set TREE_INVARIANT.
1152 * trans-stmt.c (gfc_trans_character_select): Don't set TREE_INVARIANT.
1153 * trans-decl.c (gfc_generate_function_code): Don't set TREE_INVARIANT.
1155 2008-04-21 Steve Ellcey <sje@cup.hp.com>
1157 * f95-lang.c (gfc_init_decl_processing): use ptr_mode instead of Pmode.
1159 2008-04-21 Daniel Franke <franke.daniel@gmail.com>
1162 * gfortranspec.c (lookup_option): Properly handle separated arguments
1163 in -J option, print missing argument message when necessary.
1165 2008-04-20 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1168 * scanner.c (skip_fixed_comments): Update continue_line when comment is
1169 detected. (gfc_next_char_literal): Likewise.
1171 2008-04-19 Paul Thomas <pault@gcc.gnu.org>
1176 * trans_array.c (gfc_trans_array_constructor): Temporarily
1177 realign loop, if loop->from is not zero, before creating
1178 the temporary array and provide an offset.
1181 * trans-decl.c (gfc_init_default_dt): Add gfc_ prefix to name
1182 and allow for NULL body. Change all references from
1183 init_default_dt to gfc_init_default_dt.
1184 * trans.h : Add prototype for gfc_init_default_dt.
1185 * trans-array.c (gfc_trans_deferred_vars): After nullification
1186 call gfc_init_default_dt for derived types with allocatable
1189 2008-04-18 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1192 * trans-common.c (create_common): Revert patch causing regression.
1194 2008-04-16 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1197 * iresolve.c (gfc_resolve_eoshift): Check for NULL symtree in test for
1198 optional argument attribute.
1200 2008-04-16 Paul Thomas <pault@gcc.gnu.org>
1203 * trans-intrinsic.c (gfc_conv_intrinsic_char): Even though KIND
1204 is not used, the argument must be converted.
1206 2008-04-16 Jakub Jelinek <jakub@redhat.com>
1209 * f95-lang.c (gfc_init_builtin_functions): Make sure
1210 BUILT_IN_SINCOS{,F,L} types aren't varargs.
1212 2008-04-15 Paul Thomas <pault@gcc.gnu.org>
1215 * expr.c (scalarize_intrinsic_call): Reorder identification of
1216 array argument so that if one is not found a segfault does not
1217 occur. Return FAILURE if all scalar arguments.
1219 2008-04-13 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1220 Tobias Burnus <burnus@net-b.de>
1223 * options.c (gfc_init_options): Set the default maximum continuation
1224 lines to 255 for both free and fixed form source for warnings.
1225 (gfc_handle_option): Set -std=f95 fixed form max continuations to 19 and
1226 the -std=f95 free form max continuations to 39 for warnings.
1227 * scanner.c (gfc_next_char_literal): Adjust the current_line number only
1228 if it is less than the current locus.
1230 2008-04-07 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1232 PR fortran/25829 28655
1233 * io.c (io_tag): Add new tags for decimal, encoding, asynchronous,
1234 round, sign, and id. (match_open_element): Match new tags.
1235 (gfc_resolve_open): Resolve new tags. (gfc_match_open): Enable encoding
1236 for DEFAULT only. Update error messages. (match_dt_element): Fix match
1237 tag for asynchronous. Update error messages. (gfc_free_inquire): Free
1238 new expressions. (match_inquire_element): Match new tags.
1239 (gfc_match_inquire): Add constraint for ID and PENDING.
1240 (gfc_resolve_inquire): Resolve new tags.
1241 * trans-io.c (gfc_trans_inquire): Clean up whitespace and fix setting of
1242 mask for ID parameter.
1243 * ioparm.def: Fix order of parameters for pending, round, and sign.
1244 NOTE: These must line up with the definitions in libgfortran/io/io.h. or
1247 2008-04-06 Paul Thomas <pault@gcc.gnu.org>
1250 * expr.c (scalarize_intrinsic_call): Identify which argument is
1251 an array and use that as the template.
1252 (check_init_expr): Remove tests that first argument is an array
1253 in the call to scalarize_intrinsic_call.
1255 2008-04-06 Tobias Schlüter <tobi@gcc.gnu.org>
1258 * io.c (io_tag): Add field 'value'. Split 'spec' field in
1260 (match_etag, match_vtag, match_ltag): Split parsing in two steps
1261 to give better error messages.
1263 2008-04-06 Tobias Burnus <burnus@net-b.de>
1265 * io.c (check_io_constraints): Add constrains. ID= requires
1266 asynchronous= and asynchronous= must be init expression.
1268 2008-04-06 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1270 * f95-lang.c: Set LANG_HOOKS_NAME to "GNU Fortran".
1272 2008-04-06 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1274 * dump-parse-tree.c: Use fprintf, fputs and fputc instead of
1275 gfc_status and gfc_status_char. Remove gfc_ prefix of the gfc_show_*
1276 functions and make them static. Add new gfc_dump_parse_tree
1278 * gfortran.h (gfc_option_t): Rename verbose into dump_parse_tree.
1279 (gfc_status, gfc_status_char): Delete prototypes.
1280 * error.c (gfc_status, gfc_status_char): Remove functions.
1281 * scanner.c (gfc_new_file): Use printf instead of gfc_status.
1282 * options.c (gfc_init_options): Rename verbose into dump_parse_tree.
1283 (gfc_handle_module_path_options): Use gfc_fatal_error instead of
1284 gfc_status and exit.
1285 (gfc_handle_option): Rename verbose into dump_parse_tree.
1286 * parse.c (gfc_parse_file): Use gfc_dump_parse_tree.
1288 2008-04-05 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1289 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1291 PR fortran/25829 28655
1292 * dump-parse-tree.c (gfc_show_code_node): Show new I/O parameters.
1293 * gfortran.h (gfc_statement): Add ST_WAIT enumerator.
1294 (gfc_open): Add pointers for decimal, encoding, round, sign,
1295 asynchronous. (gfc_inquire): Add pointers for asynchronous, decimal,
1296 encoding, pending, round, sign, size, id.
1297 (gfc_wait): New typedef struct. (gfc_dt): Add pointers for id, pos,
1298 asynchronous, blank, decimal, delim, pad, round, sign.
1299 (gfc_exec_op): Add EXEC_WAIT enumerator. (gfc_code): Add pointer for
1300 wait. (gfc_free_wait), (gfc_resolve_wait): New function prototypes.
1301 * trans-stmt.h (gfc_trans_wait): New function prototype.
1302 * trans.c (gfc_trans_code): Add case for EXEC_WAIT.
1303 * io.c (io_tag): Add new tags for DECIMAL, ENCODING, ROUND, SIGN,
1304 ASYCHRONOUS, ID. (match_open_element): Add matchers for new tags.
1305 (gfc_free_open): Free new pointers. (gfc_resolve_open): Resolve new
1306 tags. (gfc_resolve_open): Remove comment around check for allowed
1307 values and ASYNCHRONOUS, update it. Likewise for DECIMAL, ENCODING,
1308 ROUND, and SIGN. (match_dt_element): Add matching for new tags.
1309 (gfc_free_wait): New function. (gfc_resolve_wait): New function.
1310 (match_wait_element): New function. (gfc_match_wait): New function.
1311 * resolve.c (gfc_resolve_blocks): Add case for EXEC_WAIT.
1312 (resolve_code): Add case for EXEC_WAIT.
1313 * st.c (gfc_free_statement): Add case for EXEC_WAIT.
1314 * trans-io.c (ioparam_type): Add IOPARM_ptype_wait. (gfc_st_parameter):
1315 Add "wait" entry. (iocall): Add IOCALL_WAIT enumerator.
1316 (gfc_build_io_library_fndecls): Add function declaration for st_wait.
1317 (gfc_trans_open): Add mask bits for new I/O tags.
1318 (gfc_trans_inquire): Add mask bits for new I/O tags.
1319 (gfc_trans_wait): New translation function.
1320 (build_dt): Add mask bits for new I/O tags.
1321 * match.c (gfc_match_if) Add matcher for "wait".
1322 * match.h (gfc_match_wait): Prototype for new function.
1323 * ioparm.def: Add new I/O parameter definitions.
1324 * parse.c (decode_statement): Add match for "wait" statement.
1325 (next_statement): Add case for ST_WAIT. (gfc_ascii_statement): Same.
1327 2008-04-03 Jakub Jelinek <jakub@redhat.com>
1330 * openmp.c (resolve_omp_clauses): Diagnose if a clause symbol
1333 2008-04-03 Tom Tromey <tromey@redhat.com>
1335 * Make-lang.in (fortran_OBJS): New variable.
1337 2008-04-03 Paolo Bonzini <bonzini@gnu.org>
1339 * f95-lang.c (insert_block): Kill.
1341 2008-04-01 George Helffrich <george@gcc.gnu.org>
1343 PR fortran/35154, fortran/23057
1344 * trans-common.c (create_common): Add decl to function
1345 chain to preserve identifier scope in debug output.
1347 2008-04-01 Joseph Myers <joseph@codesourcery.com>
1349 * gfortran.texi: Include gpl_v3.texi instead of gpl.texi
1350 * Make-lang.in (GFORTRAN_TEXI): Include gpl_v3.texi instead of
1353 2008-03-30 Paul Thomas <pault@gcc.gnu.org>
1356 * resolve.c (resolve_function, resolve_call): If the procedure
1357 is elemental do not look for noncopying intrinsics.
1359 2008-03-29 Paul Thomas <pault@gcc.gnu.org>
1362 * trans-array.c (gfc_array_init_size): Set 'size' zero if
1363 negative in one dimension.
1366 * trans-expr.c (gfc_trans_string_copy): Only assign a char
1367 directly if the lhs and rhs types are the same.
1369 2008-03-28 Daniel Franke <franke.daniel@gmail.com>
1370 Paul Richard Thomas <paul.richard.thomas@gmail.com>
1373 * primary.c (match_variable): Improved matching of function
1375 * resolve.c (resolve_allocate_deallocate): Removed checks if
1376 the actual argument for STAT is a variable.
1378 2008-03-28 Tobias Burnus <burnus@net-b.de>
1380 * symbol.c (gfc_get_default_type): Fix error message; option
1381 -fallow_leading_underscore should be -fallow-leading-underscore
1383 2008-03-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1386 * iresolve.c (gfc_resolve_cshift): Check for NULL symtree in test for
1387 optional argument attribute.
1389 2008-03-27 Tom Tromey <tromey@redhat.com>
1391 * Make-lang.in: Revert automatic dependency patch.
1393 2008-03-25 Tom Tromey <tromey@redhat.com>
1395 * Make-lang.in: Remove .o targets.
1396 (fortran_OBJS): New variable.
1397 (fortran/gfortranspec.o): Move to fortran/. Reduce to variable
1399 (GFORTRAN_D_OBJS): Update.
1400 (GFORTRAN_TRANS_DEPS): Remove.
1402 2008-03-24 Paul Thomas <pault@gcc.gnu.org>
1405 * resolve.c (resolve_structure_cons): It is an error to assign
1406 NULL to anything other than a pointer or allocatable component.
1409 * resolve.c (resolve_symbol): If the symbol is a derived type,
1410 resolve the derived type. If the symbol is a derived type
1411 function, ensure that the derived type is visible in the same
1412 namespace as the function.
1414 2008-03-23 Tobias Schlüter <tobi@gcc.gnu.org>
1416 * trans.h: Use fold_build in build1_v, build2_v and build3_v
1418 * trans-openmp.c (gfc_trans_omp_critical, gfc_trans_omp_single):
1419 Don't use build2_v macro.
1421 2008-03-19 Daniel Franke <franke.daniel@gmail.com>
1424 * interface.c (gfc_procedure_use): Check for keyworded arguments in
1425 procedures without explicit interfaces.
1427 2008-03-16 Paul Thomas <pault@gcc.gnu.org>
1430 * resolve.c (check_assumed_size_reference): Only visit the
1431 first reference and look directly at the highest dimension.
1433 2008-03-15 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1436 * trans-array.c (gfc_conv_array_index_offset): Remove unnecessary
1439 2008-03-15 Daniel Franke <franke.daniel@gmail.com>
1442 * resolve.c (resolve_branch): Less strict and pessimistic warning
1445 2008-03-11 Paolo Bonzini <bonzini@gnu.org>
1447 * f95-lang.c (LANG_HOOKS_CLEAR_BINDING_STACK): Delete.
1448 (gfc_be_parse_file): Call clear_binding_stack from here.
1449 (gfc_clear_binding_stack): Rename to clear_binding_stack.
1451 2008-03-09 Paul Thomas <pault@gcc.gnu.org>
1454 * module.c (mio_symtree_ref): After providing a symbol for a
1455 missing equivalence member, resolve and NULL the fixups.
1457 2008-03-09 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1459 * invoke.texi (Error and Warning Options): Document
1462 2008-03-08 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1465 * trans-array.c (gfc_conv_ss_startstride): Fix the logic to avoid
1466 checking bounds of absent optional arguments.
1468 2008-03-06 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1471 * intrinsic.c (add_functions): Add simplification routines for
1472 ERF, DERF, ERFC and DERFC.
1473 * decl.c (gfc_match_suffix, gfc_match_subroutine): Change GNU
1474 extensions into Fortran 2008 features.
1475 * intrinsic.h (gfc_simplify_erf, gfc_simplify_erfc): New
1477 * simplify.c (gfc_simplify_erf, gfc_simplify_erfc): New functions.
1479 2008-03-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1482 * intrinsic.c (add_functions): Modify intrinsics ACOSH, ASINH,
1483 ATANH, ERF, ERFC and GAMMA. Add intrinsics BESSEL_{J,Y}{0,1,N},
1484 ERFC_SCALED, LOG_GAMMA and HYPOT.
1485 * intrinsic.h (gfc_check_hypot, gfc_simplify_hypot,
1486 gfc_resolve_hypot): New prototypes.
1487 * mathbuiltins.def: Add HYPOT builtin. Make complex versions of
1488 ACOSH, ASINH and ATANH available.
1489 * gfortran.h (GFC_ISYM_ERFC_SCALED, GFC_ISYM_HYPOT): New values.
1490 * lang.opt: Add -std=f2008 option.
1491 * libgfortran.h: Define GFC_STD_F2008.
1492 * lang-specs.h: Add .f08 and .F08 file suffixes.
1493 * iresolve.c (gfc_resolve_hypot): New function.
1494 * parse.c (parse_contained): Allow empty CONTAINS for Fortran 2008.
1495 * check.c (gfc_check_hypot): New function.
1496 * trans-intrinsic.c (gfc_intrinsic_map): Define ERFC_SCALE builtin.
1497 * options.c (set_default_std_flags): Allow Fortran 2008 by default.
1498 (form_from_filename): Add .f08 suffix.
1499 (gfc_handle_option): Handle -std=f2008 option.
1500 * simplify.c (gfc_simplify_hypot): New function.
1501 * gfortran.texi: Document Fortran 2008 status and file extensions.
1502 * intrinsic.texi: Document new BESSEL_{J,Y}{0,1,N} intrinsics,
1503 as well as HYPOT and ERFC_SCALED. Update documentation of ERF,
1504 ERFC, GAMMA, LGAMMA, ASINH, ACOSH and ATANH.
1505 * invoke.texi: Document the new -std=f2008 option.
1507 2008-03-02 Jakub Jelinek <jakub@redhat.com>
1509 * gfortranspec.c (lang_specific_driver): Update copyright notice
1512 2008-02-29 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1515 * expr.c (find_array_element): Modify traversing the constructor to
1516 avoid trying to access NULL memory pointed to by next for the
1517 last element. (find_array_section): Exit while loop if cons->next is
1519 * trans-expr.c (gfc_conv_scalar_char_value): Initialize gfc_typespec.
1520 (gfc_conv_function_call): Same.
1521 * decl.c (gfc_match_implicit): Same.
1522 * trans-intrinsic.c (gfc_conv_intrinsic_sr_kind): Same.
1524 2008-02-28 Daniel Franke <franke.daniel@gmail.com>
1529 * lang.opt: Added -Wreturn-type.
1530 * options.c (gfc_handle_option): Recognize -Wreturn-type.
1531 * trans-decl.c (gfc_trans_deferred_vars): Emit warnings for funtions
1532 where the result value is not set.
1533 (gfc_generate_function_code): Likewise.
1534 (generate_local_decl): Emit warnings for funtions whose RESULT
1535 variable is not set.
1537 2008-02-28 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1540 * trans-expr.c (gfc_conv_variable): Don't build indirect
1541 references when explicit interface is mandated.
1542 * resolve.c (resolve_formal_arglist): Set attr.always_explicit
1543 on the result symbol as well as the procedure symbol.
1545 2008-02-27 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1548 * trans.h: Remove prototypes for gfor_fndecl_math_exponent4,
1549 gfor_fndecl_math_exponent8, gfor_fndecl_math_exponent10 and
1550 gfor_fndecl_math_exponent16.
1551 * f95-lang.c (build_builtin_fntypes): Add new function types.
1552 (gfc_init_builtin_functions): Add new builtins for nextafter,
1553 frexp, ldexp, fabs, scalbn and inf.
1554 * iresolve.c (gfc_resolve_rrspacing): Don't add hidden arguments.
1555 (gfc_resolve_scale): Don't convert type of second argument.
1556 (gfc_resolve_set_exponent): Likewise.
1557 (gfc_resolve_size): Don't add hidden arguments.
1558 * trans-decl.c: Remove gfor_fndecl_math_exponent4,
1559 gfor_fndecl_math_exponent8, gfor_fndecl_math_exponent10 and
1560 gfor_fndecl_math_exponent16.
1561 * trans-intrinsic.c (gfc_intrinsic_map): Remove intrinsics
1562 for scalbn, fraction, nearest, rrspacing, set_exponent and
1564 (gfc_conv_intrinsic_exponent): Directly call frexp.
1565 (gfc_conv_intrinsic_fraction, gfc_conv_intrinsic_nearest,
1566 gfc_conv_intrinsic_spacing, gfc_conv_intrinsic_rrspacing,
1567 gfc_conv_intrinsic_scale, gfc_conv_intrinsic_set_exponent): New
1569 (gfc_conv_intrinsic_function): Use the new functions above.
1571 2008-02-26 Tobias Burnus <burnus@net-b.de>
1574 * interface.c (check_operator_interface): Show better line for error
1575 messages; fix constrains for user-defined assignment operators.
1576 (gfc_extend_assign): Fix constrains for user-defined assignment
1579 2008-02-26 Tom Tromey <tromey@redhat.com>
1581 * trans-io.c (set_error_locus): Remove old location code.
1582 * trans-decl.c (gfc_set_decl_location): Remove old location code.
1583 * f95-lang.c (gfc_init): Remove test of USE_MAPPED_LOCATION.
1584 * scanner.c (gfc_gobble_whitespace): Remove old location code.
1585 (get_file): Likewise.
1586 (preprocessor_line): Likewise.
1587 (load_file): Likewise.
1588 (gfc_new_file): Likewise.
1589 * trans.c (gfc_trans_runtime_check): Remove old location code.
1590 (gfc_get_backend_locus): Likewise.
1591 (gfc_set_backend_locus): Likewise.
1592 * data.c (gfc_assign_data_value): Remove old location code.
1593 * error.c (show_locus): Remove old location code.
1594 * gfortran.h (gfc_linebuf): Remove old location code.
1595 (gfc_linebuf_linenum): Remove old-location variant.
1597 2008-02-25 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1600 * trans-const.c (gfc_build_string_const): Don't call gettext.
1601 (gfc_build_localized_string_const): New function.
1602 * trans-const.h (gfc_build_localized_string_const): New prototype.
1603 * trans.c (gfc_trans_runtime_check): Use
1604 gfc_build_localized_string_const instead of gfc_build_string_const.
1605 (gfc_call_malloc): Likewise.
1606 (gfc_allocate_with_status): Likewise.
1607 (gfc_allocate_array_with_status): Likewise.
1608 (gfc_deallocate_with_status): Likewise.
1609 (gfc_call_realloc): Likewise.
1610 * trans-io.c (gfc_trans_io_runtime_check): Likewise.
1612 2008-02-24 Tobias Schlüter <tobi@gcc.gnu.org>
1614 * arith.c: Update copyright years.
1615 * arith.h: Likewise.
1616 * array.c: Likewise.
1618 * check.c: Likewise.
1622 * dependency.c: Likewise.
1623 * dependency.h: Likewise.
1624 * dump-parse-tree.c: Likewise.
1625 * error.c: Likewise.
1627 * gfc-internals.texi: Likewise.
1628 * gfortran.h: Likewise.
1629 * gfortran.texi: Likewise.
1630 * gfortranspec.c: Likewise.
1631 * interface.c: Likewise.
1632 * intrinsic.c: Likewise.
1633 * intrinsic.h: Likewise.
1634 * intrinsic.texi: Likewise.
1635 * invoke.texi: Likewise.
1637 * iresolve.c: Likewise.
1638 * iso-c-binding.def: Likewise.
1639 * iso-fortran-env.def: Likewise.
1640 * lang-specs.h: Likewise.
1641 * lang.opt: Likewise.
1642 * libgfortran.h: Likewise.
1643 * match.c: Likewise.
1644 * match.h: Likewise.
1645 * matchexp.c: Likewise.
1647 * module.c: Likewise.
1648 * openmp.c: Likewise.
1649 * options.c: Likewise.
1650 * parse.c: Likewise.
1651 * parse.h: Likewise.
1652 * primary.c: Likewise.
1653 * resolve.c: Likewise.
1654 * scanner.c: Likewise.
1655 * simplify.c: Likewise.
1657 * symbol.c: Likewise.
1658 * target-memory.c: Likewise.
1659 * target-memory.h: Likewise.
1660 * trans-array.h: Likewise.
1661 * trans-const.h: Likewise.
1662 * trans-stmt.h: Likewise.
1663 * trans-types.c: Likewise.
1664 * trans-types.h: Likewise.
1665 * types.def: Likewise.
1667 2008-02-24 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1670 * simplify.c (gfc_simplify_ibclr), (gfc_simplify_ibits),
1671 (gfc_simplify_ibset): Remove call to range_check.
1672 (simplify_cmplx), (gfc_simplify_dble), (gfc_simplify_float)
1673 (gfc_simplify_real): Add call gfc_clear_ts to initialize the
1674 temporary gfc_typspec variable.
1676 2008-02-24 Tobias Schlüter <tobi@gcc.gnu.org>
1678 * trans-array.c (gfc_conv_descriptor_data_get,
1679 gfc_conv_descriptor_data_set_internal,
1680 gfc_conv_descriptor_data_addr, gfc_conv_descriptor_offset,
1681 gfc_conv_descriptor_dtype, gfc_conv_descriptor_dimension,
1682 gfc_conv_descriptor_stride, gfc_conv_descriptor_lbound,
1683 gfc_conv_descriptor_ubound, gfc_trans_create_temp_array,
1684 gfc_conv_array_transpose, gfc_grow_array,
1685 gfc_trans_array_constructor_subarray,
1686 gfc_trans_array_constructor_value, gfc_trans_scalarized_loop_end,
1687 gfc_array_init_size, gfc_array_allocate, gfc_array_deallocate,
1688 gfc_conv_array_initializer, gfc_trans_array_bounds,
1689 gfc_trans_auto_array_allocation, gfc_trans_dummy_array_bias,
1690 gfc_get_dataptr_offset, gfc_conv_array_parameter,
1691 gfc_trans_dealloc_allocated, get_full_array_size,
1692 gfc_duplicate_allocatable, structure_alloc_comps): Use fold_buildN
1694 * trans-expr.c (gfc_conv_expr_present, gfc_conv_missing_dummy,
1695 gfc_conv_component_ref, gfc_conv_cst_int_power,
1696 gfc_conv_function_call, gfc_trans_structur_assign): Likewise.
1697 * trans-common.c (create_common): Likewise.
1698 * trans-openmp.c (gfc_trans_omp_atomic, gfc_trans_omp_do):
1700 * trans-const.c (gfc_conv_constant_to_tree): Likewise.
1701 * trans-stmt.c (gfc_trans_goto, gfc_trans_return, gfc_trans_do,
1702 gfc_trans_integer_select, gfc_trans_character_select,
1703 gfc_trans_forall_loop, compute_overall_iter_number,
1704 gfc_trans_forall_1, gfc_evaluate_where_mask, gfc_trans_allocate,
1705 gfc_trans_deallocate): Likewise.
1706 * trans.c (gfc_build_addr_expr, gfc_trans_runtime_check,
1707 gfc_allocate_with_status, gfc_allocate_array_with_status,
1708 gfc_deallocate_with_status): Likewise.
1709 * f95-lang.c (gfc_truthvalue_conversion): Likewise.
1710 * trans-io.c (set_parameter_const, set_parameter_value,
1711 set_parameter_ref, set_string, set_internal_unit, io_result,
1712 set_error_locus, nml_get_addr_expr, transfer_expr): Likewise.
1713 * trans-decl.c (gfc_build_qualified_array, build_entry_thunks,
1714 gfc_get_fake_result_decl, gfc_trans_auto_character_variable,
1715 gfc_generate_function_code): Likewise.
1716 * convert.c (convert): Likewise.
1717 * trans-intrinsic.c (gfc_conv_intrinsic_conversion,
1718 build_fixbound_expr, build_fix_expr, gfc_conv_intrinsic_aint,
1719 gfc_conv_intrinsic_int, gfc_conv_intrinsic_imagpart,
1720 gfc_conv_intrinsic_conjg, gfc_conv_intrinsic_abs,
1721 gfc_conv_intrinsic_cmplx, gfc_conv_intrinsic_mod,
1722 gfc_conv_intrinsic_dim, gfc_conv_intrinsic_dprod,
1723 gfc_conv_intrinsic_ctime, gfc_conv_intrinsic_fdate,
1724 gfc_conv_intrinsic_ttynam, gfc_conv_intrinsic_minmax,
1725 gfc_conv_intrinsic_minmax_char, gfc_conv_intrinsic_count,
1726 gfc_conv_intrinsic_arith, gfc_conv_intrinsic_dot_product,
1727 gfc_conv_intrinsic_minmaxloc, gfc_conv_intrinsic_minmaxval,
1728 gfc_conv_intrinsic_btest, gfc_conv_intrinsic_not,
1729 gfc_conv_intrinsic_ibits, gfc_conv_intrinsic_ishft,
1730 gfc_conv_intrinsic_ichar, gfc_conv_intrinsic_size,
1731 gfc_conv_intrinsic_array_transfer, gfc_conv_intrinsic_transfer,
1732 gfc_conv_allocated, gfc_conv_associated, gfc_conv_intrinsic_trim,
1733 gfc_conv_intrinsic_repeat): Likewise.
1735 2008-02-23 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1738 * trans-expr.c (gfc_conv_power_op): Use BUILT_IN_CPOW{F,,L}.
1739 * f95-lang.c (gfc_init_builtin_functions): Define BUILT_IN_CPOW{F,,L}.
1740 * trans.h (gfor_fndecl_math_cpow, gfor_fndecl_math_cpowf,
1741 gfor_fndecl_math_cpowl10, gfor_fndecl_math_cpowl16): Remove.
1742 * trans-decl.c: Likewise.
1744 2008-02-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1747 * expr.c (find_array_element): Modify traversing the constructor to
1748 avoid trying to access NULL memory pointed to by next for the
1749 last element. (find_array_section): Exit while loop if cons->next is
1752 2008-02-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1755 * iresolve.c (resolve_mask_arg): Add gfc_clear_ts to initialize
1757 (gfc_resolve_aint): Likewise.
1758 (gfc_resolve_anint): Likewise.
1759 (gfc_resolve_besn): Likewise.
1760 (gfc_resolve_cshift): Likewise.
1761 (gfc_resolve_ctime): Likewise.
1762 (gfc_resolve_eoshift): Likewise.
1763 (gfc_resolve_index_func): Likewise.
1764 (gfc_resolve_isatty): Likewise.
1765 (gfc_resolve_malloc): Likewise.
1766 (gfc_resolve_rrspacing): Likewise.
1767 (gfc_resolve_scale): Likewise.
1768 (gfc_resolve_set_exponent): Likewise.
1769 (gfc_resolve_spacing): Likewise.
1770 (gfc_resolve_spacing): Likewise.
1771 (gfc_resolve_fgetc): Likewise.
1772 (gfc_resolve_fputc): Likewise.
1773 (gfc_resolve_ftell): Likewise.
1774 (gfc_resolve_ttynam): Likewise.
1775 (gfc_resolve_alarm_sub): Likewise.
1776 (gfc_resolve_mvbits): Likewise.
1777 (gfc_resolve_getarg): Likewise.
1778 (gfc_resolve_signal_sub): Likewise.
1779 (gfc_resolve_exit): Likewise.
1780 (gfc_resolve_flush): Likewise.
1781 (gfc_resolve_free): Likewise.
1782 (gfc_resolve_ctime_sub): Likewise.
1783 (gfc_resolve_fgetc_sub): Likewise.
1784 (gfc_resolve_fputc_sub): Likewise.
1785 (gfc_resolve_fseek_sub): Likewise.
1786 (gfc_resolve_ftell_sub): Likewise.
1787 (gfc_resolve_ttynam_sub): Likewise.
1789 2008-02-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1791 * gfc-internals.texi: Fix typos and markup nits.
1792 * gfortran.texi: Likewise.
1793 * intrinsic.texi: Likewise.
1795 2008-02-21 Richard Guenther <rguenther@suse.de>
1797 * trans-expr.c (gfc_conv_expr_op): Expand INTRINSIC_PARENTHESES
1798 as unary PAREN_EXPR for real and complex typed expressions.
1799 (gfc_conv_unary_op): Fold the built tree.
1801 2008-02-20 Tobias Burnus <burnus@net-b.de>
1804 * match.c (gfc_match_name): Improve error message for '$'.
1806 2008-02-19 Daniel Franke <franke.daniel@gmail.com>
1809 * expr.c (gfc_check_pointer_assign): Add type and kind information
1810 to type-mismatch message.
1811 (gfc_check_assign): Unify error messages.
1813 2008-02-16 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1816 * gfortran.texi: Create new section for unimplemented extensions.
1817 Add "STRUCTURE and RECORD" and "ENCODE and DECODE statements".
1818 Remove "smaller projects" list. Fix a few typos.
1820 2008-02-15 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1822 * intrinsic.texi: Rename INDEX node to avoid clashing with
1823 index.html on case-insensitive systems.
1825 2008-02-15 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1828 * trans-expr.c (gfc_conv_function_call): Force evaluation of
1831 2008-02-10 Daniel Franke <franke.daniel@gmail.com>
1834 * lang.opt: Allow '-J<dir>' next to '-J <dir>',
1835 likewise '-I <dir>' and '-I<dir>'.
1837 2008-02-06 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1840 * Make-lang.in (f951): Add $(GMPLIBS).
1842 2008-02-05 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1845 * trans-common.c (build_field): Mark fields as volatile when needed.
1847 2008-02-05 Tobias Burnus <burnus@net-b.de>
1850 * data.c (gfc_assign_data_value): Only free "size" if
1851 it has not already been freed.
1853 2008-02-05 Paul Thomas <pault@gcc.gnu.org>
1856 * array.c (match_array_element_spec): Remove check for negative
1858 (gfc_resolve_array_spec): Add check for negative size.
1860 2008-02-05 Paul Thomas <pault@gcc.gnu.org>
1863 * data.c (gfc_assign_data_value): Add bounds check for array
1866 2008-02-04 Daniel Franke <franke.daniel@gmail.com>
1868 * resolve.c (resolve_where): Fix typo.
1869 (gfc_resolve_where_code_in_forall): Likewise.
1871 2008-02-03 Paul Thomas <pault@gcc.gnu.org>
1874 * resolve.c (resolve_allocate_deallocate): New function.
1875 (resolve_code): Call it for allocate and deallocate.
1876 * match.c (gfc_match_allocate, gfc_match_deallocate) : Remove
1877 the checking of the STAT tag and put in above new function.
1878 * primary,c (match_variable): Do not fix flavor of host
1879 associated symbols yet if the type is not known.
1881 2008-01-31 Paul Thomas <pault@gcc.gnu.org>
1884 * expr.c (gfc_check_assign): It is an error to assign
1885 to a sibling procedure.
1887 2008-01-30 Paul Thomas <pault@gcc.gnu.org>
1890 * symbol.c (gfc_delete_symtree, gfc_undo_symbols): Rename
1891 delete_symtree to gfc_delete_symtree.
1892 * gfortran.h : Add prototype for gfc_delete_symtree.
1893 * module.c (load_generic_interfaces): Transfer symbol to a
1894 unique symtree and delete old symtree, instead of renaming.
1895 (read_module): The rsym and the found symbol are the same, so
1896 the found symtree can be deleted.
1899 * decl.c (match_char_spec): Remove the constraint on deferred
1900 matching of functions and free the length expression.
1901 delete_symtree to gfc_delete_symtree.
1902 (gfc_match_type_spec): Whitespace.
1903 (gfc_match_function_decl): Defer characteristic association for
1904 all types except BT_UNKNOWN.
1905 * parse.c (decode_specification_statement): Only derived type
1906 function matching is delayed to the end of specification.
1908 2008-01-28 Tobias Burnus <burnus@net-b.de>
1911 * simplify.c (gfc_simplify_shape): Simplify rank zero arrays.
1913 2008-01-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1916 * array.c (gfc_check_constructor_type): Revert clearing the expression.
1918 2008-01-26 Tobias Burnus <burnus@net-b.de>
1921 * trans-expr.c (gfc_conv_function_call): Don't call
1922 gfc_add_interface_mapping if the expression is NULL.
1924 2008-01-26 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1927 * trans-array.c (gfc_trans_create_temp_array): Remove call to
1928 gcc_assert (integer_zerop (loop->from[n])).
1930 2008-01-25 Daniel Franke <franke.daniel@gmail.com>
1933 * resolve.c (resolve_where): Added check if user-defined assignment
1934 operator is an elemental subroutine.
1935 (gfc_resolve_where_code_in_forall): Likewise.
1937 2008-01-24 Daniel Franke <franke.daniel@gmail.com>
1941 * gfortran.h: Revert changes from 2008-01-17.
1942 * match.c: Likewise.
1943 * symbol.c: Likewise.
1944 (gfc_undo_symbols): Undo namespace changes related to common blocks.
1946 2008-01-24 Daniel Franke <franke.daniel@gmail.com>
1949 * data.c (formalize_structure_cons): Skip formalization on
1952 2008-01-24 Daniel Franke <franke.daniel@gmail.com>
1954 * gfortran.texi (OpenMP): Extended existing documentation.
1955 (contributors): Added major contributors of 2008 that were
1957 (proposed extensions): Removed implemented items.
1959 2008-01-24 Paul Thomas <pault@gcc.gnu.org>
1962 * parse.c (next_statement) : If ST_GET_FCN_CHARACTERISTICS is
1963 seen, check for a statement label and, if present, delete it
1964 and set the locus to the start of the statement.
1966 2008-01-22 Paul Thomas <pault@gcc.gnu.org>
1969 * trans-io.c (gfc_trans_transfer): If the array reference in a
1970 read has a vector subscript, use gfc_conv_subref_array_arg to
1971 copy back the temporary.
1973 2008-01-22 Tobias Burnus <burnus@net-b.de>
1976 * interface.c (compare_actual_formal): Fix adding type
1977 to missing_arg_type for absent optional arguments.
1979 2008-01-22 Tobias Burnus <burnus@net-b.de>
1982 * parse.c (parse_spec): Change = into ==.
1984 2008-01-22 Daniel Franke <franke.daniel@gmail.com>
1987 * expr.c (check_elemental): Fix check for valid data types.
1989 2008-01-22 Tobias Burnus <burnus@net-b.de>
1992 * scanner.c (load_line): Support <tab><digit> continuation lines.
1993 * invoke.texi (-Wtabs): Document this.
1995 2008-01-22 Paul Thomas <pault@gcc.gnu.org>
1998 * module.c (read_module): Set use_rename attribute.
2000 2007-01-21 Tobias Burnus <burnus@net-b.de>
2003 * interface.c (compare_parameter): Improved error message
2004 for arguments of same type and mismatched kinds.
2006 2008-01-20 Paul Thomas <pault@gcc.gnu.org>
2009 * resolve.c (resolve_entries): Do not do an array bounds check
2010 if the result symbols are the same.
2013 * module.c (read_module) : Hide the symtree of the previous
2014 version of the symbol if this symbol is renamed.
2016 2008-01-20 Paul Thomas <pault@gcc.gnu.org>
2019 * array.c (gfc_check_constructor_type): Clear the expression ts
2020 so that the checking starts from the deepest level of array
2022 * primary.c (match_varspec): If an unknown type is changed to
2023 default character and the attempt to match a substring fails,
2024 change it back to unknown.
2027 * trans-array.c (gfc_add_loop_ss_code) : If ss->string_length is
2028 NULL for an array constructor, use the cl.length expression to
2030 (gfc_conv_array_parameter): Change call to gfc_evaluate_now to
2033 2008-01-19 Thomas Koenig <tkoenig@gcc.gnu.org>
2037 * iresolve.c (gfc_resolve_all): Remove conversion of mask
2038 argument to kind=1 by removing call to resolve_mask_arg().
2039 (gfc_resolve_any): Likewise.
2041 2008-01-19 Tobias Burnus <burnus@net-b.de>
2044 * primary.c (match_variable): Handle FL_UNKNOWN without
2045 uneducated guessing.
2046 (match_variable): Improve error message.
2048 2008-01-18 Tobias Burnus <burnus@net-b.de>
2051 * interface.c (get_expr_storage_size): Return storage size
2052 for array element designators.
2053 (compare_actual_formal): Reject unequal string sizes for
2054 assumed-shape dummy arguments. And fix error message for
2055 array-sections with vector subscripts.
2057 2008-01-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2060 * simplify.c (is_constant_array_expr): New static function that returns
2061 true if the given expression is an array and is constant.
2062 (gfc_simplify_reshape): Use new function.
2064 2008-01-17 H.J. Lu <hongjiu.lu@intel.com>
2067 * symbol.c (free_common_tree): Renamed to ...
2068 (gfc_free_common_tree): This. Remove static.
2069 (gfc_free_namespace): Updated.
2071 * gfortran.h (gfc_free_common_tree): New.
2073 * match.c (gfc_match_common): Call gfc_free_common_tree () with
2074 gfc_current_ns->common_root and set gfc_current_ns->common_root
2075 to NULL on syntax error.
2077 2008-01-18 Richard Sandiford <rsandifo@nildram.co.uk>
2080 * trans-expr.c (gfc_conv_function_call): Use proper
2081 type for returned character pointers.
2083 2008-01-17 Paul Thomas <pault@gcc.gnu.org>
2088 * decl.c : Remove gfc_function_kind_locus and
2089 gfc_function_type_locus. Add gfc_matching_function.
2090 (match_char_length): If matching a function and the length
2091 does not match, return MATCH_YES and try again later.
2092 (gfc_match_kind_spec): The same.
2093 (match_char_kind): The same.
2094 (gfc_match_type_spec): The same for numeric and derived types.
2095 (match_prefix): Rename as gfc_match_prefix.
2096 (gfc_match_function_decl): Except for function valued character
2097 lengths, defer applying kind, type and charlen info until the
2098 end of specification block.
2099 gfortran.h (gfc_statement): Add ST_GET_FCN_CHARACTERISTICS.
2100 parse.c (decode_specification_statement): New function.
2101 (decode_statement): Call it when a function has kind = -1. Set
2102 and reset gfc_matching function, as function statement is being
2104 (match_deferred_characteristics): Simplify with a single call
2105 to gfc_match_prefix. Do appropriate error handling. In any
2106 case, make sure that kind = -1 is reset or corrected.
2107 (parse_spec): Call above on seeing ST_GET_FCN_CHARACTERISTICS.
2108 Throw an error if kind = -1 after last specification statement.
2109 parse.h : Prototype for gfc_match_prefix.
2111 2008-01-16 Tobias Burnus <burnus@net-b.de>
2114 * interface.c (compare_parameter): Allow AS_DEFERRED array
2115 elements and reject attr.pointer array elemenents.
2116 (get_expr_storage_size): Return storage size of elements of
2117 assumed-shape and pointer arrays.
2119 2008-01-15 Sebastian Pop <sebastian.pop@amd.com>
2121 * f95-lang.c (gfc_init_builtin_functions): Initialize GOMP builtins
2122 for flag_tree_parallelize_loops.
2124 2008-01-15 Thomas Koenig <tkoenig@gcc.gnu.org>
2127 * iresolve.c (gfc_resolve_all): Call resolve_mask_arg.
2128 (gfc_resolve_any): Likewise.
2129 (gfc_resolve_count): Likewise. Don't append kind of
2130 argument to function name.
2132 2008-01-13 Tobias Burnus <burnus@net-b.de>
2135 * resolve.c (resolve_actual_arglist): For expressions,
2136 also check for assume-sized arrays.
2137 * interface.c (compare_parameter): Move F2003 character checks
2138 here, print error messages here, reject elements of
2139 assumed-shape array as argument to dummy arrays.
2140 (compare_actual_formal): Update for the changes above.
2142 2008-01-13 Tobias Burnus <burnus@net-b.de>
2145 * decl.c (contained_procedure): Only check directly preceeding state.
2147 2008-01-13 Tobias Burnus <burnus@net-b.de>
2150 * check.c (gfc_check_shape): Accept array ranges of
2151 assumed-size arrays.
2153 2008-01-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2156 * match.c (gfc_match_name): Don't error if leading character is a '(',
2157 just return MATCH_NO.
2159 2008-01-11 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2162 * trans-io.c (create_dummy_iostat): Commit the symbol.
2164 2008-01-11 Paul Thomas <pault@gcc.gnu.org>
2167 * simplify.c (gfc_simplify_transfer): Return NULL if the size
2168 of the element is unavailable and only assign character length
2169 to the result, if 'mold' is constant.
2171 2008-01-10 Paul Thomas <pault@gcc.gnu.org>
2174 * trans-array.c (gfc_trans_array_ctor_element): Use gfc_trans_string_copy
2175 to assign strings and perform bounds checks on the string length.
2176 (get_array_ctor_strlen): Remove bounds checking.
2177 (gfc_trans_array_constructor): Initialize string length checking.
2178 * trans-array.h : Add prototype for gfc_trans_string_copy.
2180 2008-01-08 Richard Guenther <rguenther@suse.de>
2183 PR tree-optimization/34683
2184 * trans-types.c (gfc_get_array_type_bounds): Use an array type
2185 with known size for accesses if that is known.
2187 2008-01-08 Paul Thomas <pault@gcc.gnu.org>
2190 * expr.c (find_array_element): Check that the array bounds are
2191 constant before using them. Use lower, as well as upper bound.
2192 (check_restricted): Allow implied index variable.
2194 2008-01-08 Paul Thomas <pault@gcc.gnu.org>
2197 * trans_array.c (gfc_trans_deferred_array): Do not null the
2198 data pointer on entering scope, nor deallocate it on leaving
2199 scope, if the symbol has the 'save' attribute.
2202 * trans_decl.c (gfc_finish_var_decl): Derived types with
2203 allocatable components and an initializer must be TREE_STATIC.
2205 2008-01-07 Paul Thomas <pault@gcc.gnu.org>
2208 * module.c (write_generic): Rewrite completely.
2209 (write_module): Change call to write_generic.
2211 2008-01-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2214 * scanner.c (load_line): Do not count ' ' as printable when checking for
2217 2008-01-06 Paul Thomas <pault@gcc.gnu.org>
2220 * module.c (load_needed): If the namespace has no proc_name
2221 give it the module symbol.
2223 2008-01-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2226 * trans-expr.c (gfc_conv_missing_dummy): Use a temporary to type convert
2227 the dummy variable expression, test for NULL, and pass the variable
2228 address to the called function.
2230 2007-01-06 Tobias Burnus <burnus@net-b.de>
2233 * match.c (gfc_match_common): Remove blank common in
2235 * resolve.c (resolve_common_vars): New function.
2236 (resolve_common_blocks): Move checks to resolve_common_vars
2237 and invoke that function.
2238 (resolve_types): Call resolve_common_vars for blank commons.
2240 2008-01-06 Tobias Burnus <burnus@net-b.de>
2243 * resolve.c (resolve_equivalence_derived): Reject derived types with
2244 default initialization if equivalenced with COMMON variable.
2246 2008-01-06 Tobias Burnus <burnus@net-b.de>
2249 * io.c (check_io_constraints): Disallow unformatted I/O for
2252 2008-01-06 Tobias Burnus <burnus@net-b.de>
2255 * resolve.c (resolve_formal_arglist): Reject dummy procedure in
2256 ELEMENTAL functions.
2258 2008-01-06 Tobias Burnus <burnus@net-b.de>
2261 * interface.c (compare_actual_formal): Reject parameter
2262 actual to intent(out) dummy.
2264 2008-01-04 Tobias Burnus <burnus@net-b.de>
2267 * primary.c (match_varspec): Gobble whitespace before