1 2010-09-23 Tobias Burnus <burnus@net-b.de>
3 * intrinsic.texi (OpenMP modules): Add named constants of
6 2010-09-23 Daniel Kraft <d@domob.eu>
11 * gfortran.h (gfc_check_vardef_context): New method.
12 (struct symbol_attribute): New flag `select_type_temporary'.
13 * primary.c (gfc_variable_attr): Clarify initialization of ref.
14 (match_variable): Remove PROTECTED check and assignment check
15 for PARAMETERs (this is now done later).
16 * match.c (gfc_match_iterator): Remove INTENT(IN) check.
17 (gfc_match_associate): Defer initialization of newAssoc->variable.
18 (gfc_match_nullify): Remove PURE definability check.
19 (select_type_set_tmp): Set new `select_type_temporary' flag.
20 * expr.c (gfc_check_assign): Remove INTENT(IN) check here.
21 (gfc_check_pointer_assign): Ditto (and other checks removed).
22 (gfc_check_vardef_context): New method.
23 * interface.c (compare_parameter_protected): Removed.
24 (compare_actual_formal): Use `gfc_check_vardef_context' for checks
25 related to INTENT([IN]OUT) arguments.
26 * intrinsic.c (check_arglist): Check INTENT for intrinsics.
27 * resolve.c (gfc_resolve_iterator): Use `gfc_check_vardef_context'.
28 (remove_last_array_ref): New method.
29 (resolve_deallocate_expr), (resolve_allocate_expr): Ditto.
30 (resolve_allocate_deallocate): Ditto (for STAT and ERRMSG).
31 (resolve_assoc_var): Remove checks for definability here.
32 (resolve_select_type): Handle resolving of code->block here.
33 (resolve_ordinary_assign): Remove PURE check.
34 (resolve_code): Do not resolve code->blocks for SELECT TYPE here.
35 Use `gfc_check_vardef_context' for assignments and pointer-assignments.
37 2010-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
39 * gfortran.texi (Argument list functions): Allow URL to wrap.
40 * intrinsic.texi (GETGID, GETPID, GETUID, IMAGE_INDEX)
41 (IS_IOSTAT_END, IS_IOSTAT_EOR, NUM_IMAGES, THIS_IMAGE)
42 (ISO_FORTRAN_ENV): Fix markup in index entries, and a couple of
43 code markups in the text.
44 * invoke.texi (Fortran Dialect Options)
45 (Error and Warning Options, Directory Options, Code Gen Options):
46 Likewise. Remove @code inside @smallexample.
48 2010-09-22 Joseph Myers <joseph@codesourcery.com>
50 * gfortranspec.c (lang_specific_driver): Handle OPT__version and
51 OPT__help instead of OPT_fversion and OPT_fhelp.
52 * lang.opt (-all-warnings, -assert, -assert=, -comments,
53 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
54 -dump, -dump=, -include-barrier, -include-directory,
55 -include-directory=, -include-directory-after,
56 -include-directory-after=, -include-prefix, -include-prefix=,
57 -no-line-commands, -no-standard-includes, -output, -output=,
58 -preprocess, -print-missing-file-dependencies, -trace-includes,
59 -undefine-macro, -undefine-macro=, -user-dependencies, -verbose,
60 -write-dependencies, -write-user-dependencies): New.
62 2010-09-21 Jason Blevins <jrblevin@sdf.org>
64 * intrinsics.texi (HYPOT, IMAGE_INDEX, BESSEL_JN, BESSEL_YN,
65 execute_command_line, IEOR, IOR, NORM2, NOT, NULL, PARITY):
68 2010-09-21 Mikael Morin <mikael@gcc.gnu.org>
71 * trans-array.c (gfc_conv_expr_descriptor): Calculate dim out of n and
75 * trans-array.c (gfc_conv_expr_descriptor): Unset full if we are
76 accessing dimensions in reversed order.
79 * trans-array.c (gfc_conv_expr_descriptor): Special case noncopying
80 intrinsic function call.
82 * trans-array.c (gfc_conv_expr_descriptor): Remove ss lookup.
83 Update asserts accordingly.
86 * trans.h (gfc_se): New field force_tmp.
87 * trans-expr.c (gfc_conv_procedure_call): Check for argument alias
88 and set parmse.force_tmp if some alias is found.
89 * trans-array.c (gfc_conv_expr_descriptor): Force a temporary creation
90 if se->force_tmp is set.
92 2010-09-20 Janus Weil <janus@gcc.gnu.org>
95 * trans-expr.c (gfc_conv_procedure_call): Fix pointer checking for
96 TBPs, PPCs and pointer/allocatable components.
98 2010-09-20 Paul Thomas <pault@gcc.gnu.org>
101 * simplify.c (is_constant_array_expr): Allow structure array
102 elements as well as constants.
103 (gfc_simplify_pack, gfc_simplify_reshape, gfc_simplify_spread,
104 gfc_simplify_transpose, gfc_simplify_unpack): Copy the derived
105 type of source to the result.
107 2010-09-19 Thomas Koenig <tkoenig@gcc.gnu.org>
109 * frontend-passes.c (gfc_expr_walker): Also
110 handle EXPR_SUBSTRING.
112 2010-09-19 Thomas Koenig <tkoenig@gcc.gnu.org>
114 * frontend-passes.c (gfc_expr_walker): Handle
115 constructors and references.
117 2010-09-16 Tobias Burnus <burnus@net-b.de>
120 * trans-types.c (create_fn_spec): New function.
121 (gfc_get_function_type): Call it.
123 2010-09-16 Jakub Jelinek <jakub@redhat.com>
125 * gfortran.h (walk_code_fn_t, walk_expr_fn_t): New types.
126 (gfc_expr_walker, gfc_code_walker): New prototypes.
127 * frontend-passes.c (gfc_expr_walker, gfc_code_walker): New functions.
128 (WALK_SUBEXPR, WALK_SUBEXPR_TAIL, WALK_SUBCODE): Define.
129 (optimize_namespace): Use gfc_code_walker.
130 (optimize_code, optimize_expr): Rewritten as gfc_code_walker hooks.
131 (optimize_expr_0, optimize_code_node,
132 optimize_actual_arglist): Removed.
133 (optimize_assignment): Don't call optimize_expr_0.
135 2010-09-16 Janus Weil <janus@gcc.gnu.org>
138 * interface.c (compare_parameter): Create vtab for actual argument,
139 instead of formal (if needed).
141 2010-09-15 Janus Weil <janus@gcc.gnu.org>
144 * resolve.c (resolve_allocate_expr): Do default initialization via
147 2010-09-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
149 * mathbuiltins.def: Do not defined huge_val built-in.
150 * trans-const.c (gfc_build_inf_or_huge): New function.
151 * trans-const.h (gfc_build_inf_or_huge): New prototype.
152 * f95-lang.c (gfc_init_builtin_functions): Don't defined
154 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): We don't
155 have functions of type (*) (void) anymore.
156 (gfc_conv_intrinsic_minmaxloc): Call gfc_build_inf_or_huge.
157 (gfc_conv_intrinsic_nearest): Call gfc_build_inf_or_huge instead
158 of generating a call to huge_val().
160 2010-09-11 Mikael Morin <mikael@gcc.gnu.org>
162 * gfortran.h (gfc_expr): Remove inline_noncopying_intrinsic attribute.
163 * dependency.c (gfc_check_dependency): Don't depend on
164 expr's inline_noncopying_intrinsic_attribute.
165 * dependency.c (gfc_check_argument_var_dependency,
166 gfc_check_argument_dependency): Ditto. Recursively check dependency
167 as NOT_ELEMENTAL in the non-copying (=transpose) case.
168 * trans-intrinsic.c (gfc_conv_intrinsic_function): Ditto.
169 * resolve.c (find_noncopying_intrinsics): Remove.
170 (resolve_function, resolve_call): Remove call to
171 find_noncopying_intrinsics.
173 * trans-array.c (gfc_conv_array_transpose): Remove.
174 (gfc_walk_subexpr): Make non-static. Move prototype...
175 * trans-array.h (gfc_walk_subexpr): ... here.
176 * trans-intrinsic.c (gfc_conv_intrinsic_function): Update transpose
178 (walk_inline_intrinsic_transpose, walk_inline_intrinsic_function,
179 gfc_inline_intrinsic_function_p): New.
180 (gfc_is_intrinsic_libcall): Return early in inline intrinsic case.
181 Remove transpose from the libcall list.
182 (gfc_walk_intrinsic_function): Special case inline intrinsic.
183 * trans.h (gfc_inline_intrinsic_function_p): New prototype.
185 2010-09-10 Mikael Morin <mikael@gcc.gnu.org>
187 * trans-expr.c (expr_is_variable): New function taking non-copying
188 intrinsic functions into account.
189 (gfc_trans_assignment_1): Use expr_is_variable.
191 2010-09-10 Mikael Morin <mikael@gcc.gnu.org>
193 * trans-array.c (gfc_conv_loop_setup): Access the shape along the
194 real array dimension instead of the scalarizer (loop) dimension.
196 2010-09-10 Mikael Morin <mikael@gcc.gnu.org>
198 * trans-array.c (gfc_conv_resolve_dependencies): Handle same-array
199 transposed references.
201 2010-09-10 Tobias Burnus <burnus@net-b.de>
204 * trans.h (build1_stat_loc, build2_stat_loc, build3_stat_loc,
205 build4_stat_loc): New inline functions.
206 (build1_loc, build2_loc, build3_loc, build4_loc): New macros.
207 (build1_v, build2_v, build3_v, build4_v): Use input_location
209 * trans-array.c (gfc_trans_scalarized_loop_end,
210 gfc_conv_array_parameter): Replace build[1-4] by build[1-4]_loc.
211 * trans.c (gfc_build_addr_expr, gfc_build_array_ref,
212 gfc_finish_wrapped_block): Ditto.
213 * trans-decl.c (gfc_init_default_dt, init_intent_out_dt): Ditto.
214 * trans-expr.c (gfc_conv_missing_dummy,
215 gfc_trans_alloc_subarray_assign, gfc_trans_zero_assign): Ditto.
216 * trans-openmp.c (gfc_omp_clause_default_ctor,
217 gfc_trans_omp_critical, gfc_trans_omp_parallel,
218 gfc_trans_omp_parallel_do, gfc_trans_omp_parallel_sections,
219 gfc_trans_omp_parallel_workshare, gfc_trans_omp_sections
220 gfc_trans_omp_single, gfc_trans_omp_task,
221 gfc_trans_omp_workshare): Ditto.
223 2010-09-09 Steven G. Kargl <kargl@gcc.gnu.org>
225 * fortran/expr.c (check_inquiry): OPTIONAL attribute is not allowed
226 for dummy argument that appears in a specification statement.
228 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
230 * trans-array.c (gfc_get_array_ref_dim): New function.
231 (gfc_trans_create_temp_array): Reconstruct array
232 bounds from loop bounds. Use array bounds instead of loop bounds.
234 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
236 * trans-array.c (gfc_set_loop_bounds_from_array_spec):
237 Get the array dimension from the dim array.
239 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
241 * trans-array.c (gfc_trans_preloop_setup): Unconditionally use the
242 dim array to get the stride in the innermost loop.
244 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
246 * trans-array.c (gfc_trans_create_temp_array): Don't set dim array.
247 (gfc_conv_loop_setup, gfc_walk_function_expr): Set dim array.
248 * trans-intrinsic.c (gfc_walk_intrinsic_libfunc): Ditto.
250 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
252 * trans-array.c (gfc_trans_create_temp_array): Assert loop dimension
253 and info dimension are the same. Loop over loop dimension.
254 * trans-stmt.c (gfc_conv_elemental_dependencies): Set loop dimension
256 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
258 * trans-array.c (gfc_conv_array_transpose): Change generated descriptor
261 2010-09-09 Tobias Burnus <burnus@net-b.de>
264 * intrincic.texi (FGET, FGETC, FPUT, FPUTC, FSTAT, GETCWD, KILL,
265 STAT): Show also syntax for the function version.
266 * intrinsic.c (add_sym_1s_intent, add_sym_2s_intent,
267 add_sym_3s_intent): Remove function.
268 (add_sym_1s, add_sym_2s, add_sym_3s): Take always the intent
270 (add_sym_2_intent): New function.
271 (add_functions): Set intent for functions which modify
272 the argument: fstat, fgetc, fget, hostnm, lstat, stat. Change
273 argument name of hostnm from "a" to "c"
274 (add_subroutines): Change add_sym_*s_intent to
275 add_sym_*s and add intent to the add_sym_*s calls.
277 2010-09-08 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
280 * intrinsic.c (add_functions): Add B{G,L}{E,T}, DSHIFT{L,R},
281 MASK{L,R}, MERGE_BITS and SHIFT{A,L,R}.
282 * gfortran.h: Define ISYM values for above intrinsics.
283 * intrinsic.h (gfc_check_bge_bgt_ble_blt, gfc_check_dshift,
284 gfc_check_mask, gfc_check_merge_bits, gfc_check_shift,
285 gfc_simplify_bge, gfc_simplify_bgt, gfc_simplify_ble,
286 gfc_simplify_blt, gfc_simplify_dshiftl, gfc_simplify_dshiftr,
287 gfc_simplify_lshift, gfc_simplify_maskl, gfc_simplify_maskr,
288 gfc_simplify_merge_bits, gfc_simplify_rshift,
289 gfc_simplify_shifta, gfc_simplify_shiftl, gfc_simplify_shiftr,
290 gfc_resolve_dshift, gfc_resolve_mask, gfc_resolve_merge_bits,
291 gfc_resolve_shift): New prototypes.
292 * iresolve.c (gfc_resolve_dshift, gfc_resolve_mask,
293 gfc_resolve_merge_bits, gfc_resolve_shift): New functions.
294 * check.c (gfc_check_bge_bgt_ble_blt, gfc_check_dshift,
295 gfc_check_mask, gfc_check_merge_bits, gfc_check_shift): New
297 * trans-intrinsic.c (gfc_conv_intrinsic_dshift,
298 gfc_conv_intrinsic_bitcomp, gfc_conv_intrinsic_shift,
299 gfc_conv_intrinsic_merge_bits, gfc_conv_intrinsic_mask): New
301 (gfc_conv_intrinsic_function): Call above static functions.
302 * intrinsic.texi: Document new intrinsics.
303 * simplify.c (gfc_simplify_bge, gfc_simplify_bgt, gfc_simplify_ble,
304 gfc_simplify_blt, gfc_simplify_dshiftl, gfc_simplify_dshiftr,
305 gfc_simplify_lshift, gfc_simplify_maskl, gfc_simplify_maskr,
306 gfc_simplify_merge_bits, gfc_simplify_rshift,
307 gfc_simplify_shifta, gfc_simplify_shiftl, gfc_simplify_shiftr):
310 2010-09-08 Jakub Jelinek <jakub@redhat.com>
312 * frontend-passes.c (optimize_code_node): Walk block chain by default.
315 * trans-openmp.c (gfc_trans_omp_do): Store exit/cycle labels on code
316 instead of code->block.
319 * openmp.c (resolve_omp_do): Report not enough do loops for
320 collapse even if block->next is NULL.
322 2010-09-07 Thomas Koenig <tkoenig@gcc.gnu.org>
325 * dependency.c (gfc_deb_compare_expr): Take missing optional
326 arguments into account.
328 2010-09-08 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
330 * trans.h (gfor_fndecl_clz128, gfor_fndecl_ctz128): Remove.
331 * trans-decl.c (gfor_fndecl_clz128, gfor_fndecl_ctz128): Remove.
332 (gfc_build_intrinsic_function_decls): Don't build the
333 gfor_fndecl_clz128 and gfor_fndecl_ctz128.
334 * trans-intrinsic.c (gfc_conv_intrinsic_leadz,
335 gfc_conv_intrinsic_trailz): Generate inline arithmetic instead
336 of calling clz128/ctz128 library functions.
338 2010-09-07 Jan Hubicka <jh@suse.cz>
340 * trans-expr.c (gfc_conv_initializer): Set STATIC flags for
343 2010-09-07 Tobias Burnus <burnus@net-b.de>
346 * intrinsic.texi (COS): Remove superfluous "n".
348 2010-09-07 Tobias Burnus <burnus@net-b.de>
351 * trans-array.c (gfc_conv_descriptor_data_get,
352 gfc_conv_descriptor_data_set, gfc_conv_descriptor_data_addr,
353 gfc_conv_descriptor_offset, gfc_conv_descriptor_dtype,
354 gfc_conv_descriptor_dimension, gfc_conv_descriptor_stride,
355 gfc_conv_descriptor_lbound, gfc_conv_descriptor_ubound,
356 gfc_conv_shift_descriptor_lbound,
357 gfc_set_loop_bounds_from_array_spec,
358 gfc_trans_allocate_array_storage, gfc_trans_create_temp_array,
359 gfc_conv_array_transpose, gfc_get_iteration_count,
360 gfc_grow_array, gfc_trans_array_ctor_element,
361 gfc_trans_array_constructor_subarray,
362 gfc_trans_array_constructor_value,
363 constant_array_constructor_loop_size, gfc_trans_array_constructor,
364 gfc_set_vector_loop_bounds, gfc_trans_array_bound_check,
365 gfc_conv_array_index_offset, gfc_conv_scalarized_array_ref,
366 gfc_conv_array_ref, gfc_trans_preloop_setup,
367 gfc_trans_scalarized_loop_end, gfc_conv_ss_startstride,
368 gfc_conv_loop_setup, gfc_conv_array_extent_dim,
369 gfc_conv_descriptor_size, gfc_array_init_size,
370 gfc_array_allocate, gfc_array_deallocate,
371 gfc_trans_array_bounds, gfc_trans_auto_array_allocation,
372 gfc_trans_dummy_array_bias, gfc_get_dataptr_offset,
373 get_array_charlen, gfc_conv_expr_descriptor,
374 array_parameter_size, gfc_conv_array_parameter,
375 gfc_trans_dealloc_allocated, get_full_array_size,
376 duplicate_allocatable,
377 structure_alloc_comps): Change fold_build[0-9] to
379 (duplicate_allocatable, structure_alloc_comps,
380 gfc_duplicate_allocatable): Add space after function name.
382 2010-09-07 Mikael Morin <mikael@gcc.gnu.org>
384 * trans-stmt.c (gfc_trans_character_select): Be conversion-safe while
385 checking string length value.
386 * trans-intrinsic.c (gfc_conv_intrinsic_char): Build integer using
387 gfc_charlen_type_node type.
390 * trans-intrinsic.c (gfc_conv_intrinsic_transfer): Convert string
391 length to gfc_charlen_type_node.
393 2010-09-06 Thomas Koenig <tkoenig@gcc.gnu.org>
396 * frontend-passes.c (optimize_binop_array_assignment): New
398 (optimize_assignment): Call it.
400 2010-09-06 Thomas Koenig <tkoenig@gcc.gnu.org>
403 * trans-expr.c (gfc_conv_substring): If start and end
404 of the string reference are equal, set the length to one.
406 2010-09-06 Tobias Burnus <burnus@net-b.de>
409 * dump-parse-tree.c (gfc_debug_expr): Use stderr instead of stdout.
411 2010-09-06 Tobias Burnus <burnus@net-b.de>
414 * dump-parse-tree.c (gfc_debug_expr): New function.
416 2010-09-06 Tobias Burnus <burnus@net-b.de>
419 * intrinsic.c (add_functions): Support IALL, IANY, IPARITY.
420 (check_specific): Special case for those intrinsics.
421 * gfortran.h (gfc_isym_id): Add new intrinsics
422 * intrinsic.h (gfc_check_transf_bit_intrins,
423 gfc_simplify_iall, gfc_simplify_iany, gfc_simplify_iparity,
424 gfc_resolve_iall, gfc_resolve_iany, gfc_resolve_iparity):
426 * iresolve.c (gfc_resolve_iall, gfc_resolve_iany,
427 gfc_resolve_iparity, resolve_transformational): New functions.
428 (gfc_resolve_product, gfc_resolve_sum,
429 gfc_resolve_parity): Use resolve_transformational.
430 * check.c (gfc_check_transf_bit_intrins): New function.
431 * simplify.c (gfc_simplify_iall, gfc_simplify_iany,
432 gfc_simplify_iparity, do_bit_any, do_bit_ior,
433 do_bit_xor, simplify_transformation): New functions.
434 (gfc_simplify_all, gfc_simplify_any, gfc_simplify_parity,
435 gfc_simplify_sum, gfc_simplify_product): Use simplify_transformation.
436 * trans-intrinsic.c (gfc_conv_intrinsic_arith,
437 gfc_conv_intrinsic_function, gfc_is_intrinsic_libcall):
438 Handle IALL, IANY and IPARITY intrinsics.
439 * intrinsic.texi (IMAGE_INDEX): Move up to fix alphabetic
441 (IALL, IANY, IPARITY): Document new intrinsics.
443 2010-09-05 Tobias Burnus <burnus@net-b.de>
446 * f95-lang.c (gfc_truthvalue_conversion): Use
447 fold_build[0-9]_loc instead of fold_build[0-9].
448 * convert.c (convert): Ditto.
449 * trans-intrinsic.c (gfc_conv_intrinsic_conversion,
450 build_fixbound_expr, build_fix_expr, gfc_conv_intrinsic_aint,
451 gfc_conv_intrinsic_int, gfc_conv_intrinsic_imagpart,
452 gfc_conv_intrinsic_conjg, gfc_trans_same_strlen_check,
453 gfc_conv_intrinsic_bound, gfc_conv_intrinsic_abs,
454 gfc_conv_intrinsic_cmplx, gfc_conv_intrinsic_mod,
455 gfc_conv_intrinsic_dim, gfc_conv_intrinsic_sign,
456 gfc_conv_intrinsic_dprod, gfc_conv_intrinsic_char,
457 gfc_conv_intrinsic_ctime, gfc_conv_intrinsic_fdate,
458 gfc_conv_intrinsic_ttynam, gfc_conv_intrinsic_minmax,
459 gfc_conv_intrinsic_minmax_char, gfc_conv_intrinsic_anyall,
460 gfc_conv_intrinsic_count, gfc_conv_intrinsic_arith,
461 gfc_conv_intrinsic_dot_product, gfc_conv_intrinsic_minmaxloc,
462 gfc_conv_intrinsic_minmaxval, gfc_conv_intrinsic_btest,
463 gfc_conv_intrinsic_bitop, gfc_conv_intrinsic_not,
464 gfc_conv_intrinsic_singlebitop, gfc_conv_intrinsic_ibits,
465 gfc_conv_intrinsic_rlshift, gfc_conv_intrinsic_ishft,
466 gfc_conv_intrinsic_ishftc, gfc_conv_intrinsic_leadz,
467 gfc_conv_intrinsic_trailz, gfc_conv_intrinsic_popcnt_poppar,
468 gfc_conv_intrinsic_ichar, gfc_conv_has_intvalue,
469 gfc_conv_intrinsic_merge, gfc_conv_intrinsic_spacing,
470 gfc_conv_intrinsic_rrspacing, gfc_conv_intrinsic_size,
471 size_of_string_in_bytes, gfc_conv_intrinsic_sizeof,
472 gfc_conv_intrinsic_storage_size, gfc_conv_intrinsic_strcmp,
473 gfc_conv_intrinsic_transfer, gfc_conv_allocated,
474 gfc_conv_associated, gfc_conv_same_type_as,
475 gfc_conv_intrinsic_trim, gfc_conv_intrinsic_repeat): Ditto.
477 2010-09-04 Tobias Burnus <burnus@net-b.de>
480 * resolve.c (resolve_fl_namelist): Change constraint checking
481 order to prevent endless loop.
483 2010-09-04 Janus Weil <janus@gcc.gnu.org>
486 * resolve.c (resolve_allocate_expr): Generate default initializers
487 already at this point, resolve them and put them into expr3, ...
488 * trans-stmt.c (gfc_trans_allocate): ... instead of waiting until
491 2010-09-03 Tobias Burnus <burnus@net-b.de>
494 * trans-intrinsic.c (gfc_conv_intrinsic_sign,
495 gfc_conv_intrinsic_leadz): Use build_call_expr_loc instead
497 * trans-expr.c (gfc_conv_expr_present, gfc_conv_missing_dummy,
498 gfc_conv_string_length, gfc_conv_substring,
499 gfc_conv_component_ref, gfc_conv_unary_op, gfc_conv_powi,
500 gfc_conv_cst_int_power, gfc_conv_string_tmp, gfc_conv_concat_op,
501 gfc_conv_expr_op, gfc_build_compare_string,
502 gfc_set_interface_mapping_bounds, gfc_conv_subref_array_arg,
503 gfc_conv_derived_to_class, conv_isocbinding_procedure,
504 gfc_conv_procedure_call, fill_with_spaces,
505 gfc_trans_string_copy, gfc_trans_alloc_subarray_assign,
506 gfc_trans_structure_assign, gfc_trans_pointer_assignment,
507 gfc_trans_scalar_assign, gfc_trans_zero_assign,
508 gfc_trans_array_copy, gfc_trans_array_constructor_copy): Change
509 fold_build[0-9] to fold_build[0-9]_loc.
510 * trans-io.c (set_parameter_const, set_parameter_value,
511 set_parameter_ref, gfc_convert_array_to_string, set_string,
512 set_internal_unit, io_result, set_error_locus,
513 nml_get_addr_expr, build_dt): Ditto.
514 * trans-openmp.c (gfc_omp_clause_default_ctor,
515 gfc_omp_clause_copy_ctor, gfc_omp_clause_assign_op,
516 gfc_trans_omp_array_reduction, gfc_trans_omp_atomic,
517 gfc_trans_omp_do): Ditto.
518 * trans.c (gfc_add_modify, gfc_build_addr_expr,
519 gfc_build_array_ref, gfc_trans_runtime_error_vararg,
520 gfc_trans_runtime_check, gfc_call_malloc,
521 gfc_allocate_with_status, gfc_allocate_array_with_status,
522 gfc_call_free, gfc_deallocate_with_status,
523 gfc_call_realloc): Ditto.
525 2010-09-03 Thomas Koenig <tkoenig@gcc.gnu.org>
528 * dependency.c (gfc_deb_compare_expr): Compare equal for equal
529 arglists for pure user functions, or for those intrinsic
530 functions which are also pure.
531 * intrinsics.c (add_conv): Mark conversion functions as pure.
532 (add_char_conversions): Likewise.
534 2010-09-03 Daniel Kraft <d@domob.eu>
537 * resolve.c (resolve_actual_arglist): Allow internal procedure
538 as actual argument with Fortran 2008.
540 2010-09-03 Daniel Kraft <d@domob.eu>
543 * gfortran.h (struct gfc_code): Renamed `whichloop' to
544 `which_construct' as this is no longer restricted to loops.
545 * parse.h (struct gfc_state_data): New field `construct'.
546 * match.c (match_exit_cycle): Handle EXIT from non-loops.
547 * parse.c (push_state): Set `construct' field.
548 * resolve.c (resolve_select_type): Extend comment.
549 * trans-stmt.c (gfc_trans_if): Add exit label.
550 (gfc_trans_block_construct), (gfc_trans_select): Ditto.
551 (gfc_trans_simple_do): Store exit/cycle labels on the gfc_code itself.
552 (gfc_trans_do), (gfc_trans_do_while): Ditto.
553 (gfc_trans_exit): Use new name `which_construct' instead of `whichloop'.
554 (gfc_trans_cycle): Ditto.
555 (gfc_trans_if_1): Use fold_build3_loc instead of fold_build3.
557 2010-09-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
559 * trans-intrinsic.c (gfc_conv_intrinsic_aint): Fix whitespace.
560 (gfc_conv_intrinsic_ishft): Only evaluate arguments once.
561 (gfc_conv_intrinsic_ishftc): Only evaluate arguments once.
562 * intrinsic.texi (RSHIFT): Fix documentation.
564 2010-09-02 Tobias Burnus <burnus@net-b.de>
567 * trans-common.c (create_common): Change build[0-9] to
569 * trans-const.c (gfc_conv_constant_to_tree,
570 gfc_conv_constant_to_tree): Ditto.
571 * trans-decl.c (gfc_build_qualified_array, build_entry_thunks,
572 gfc_get_fake_result_decl, gfc_trans_auto_character_variable,
573 add_argument_checking, create_main_function,
574 gfc_generate_return): Ditto.
575 * trans-types.c (gfc_get_dtype, gfc_get_array_type_bounds): Ditto.
576 * trans-stmt.c (allocate_temp_for_forall_nest_1,
577 compute_inner_temp_size, compute_overall_iter_number,
578 generate_loop_for_rhs_to_temp, generate_loop_for_temp_to_lhs,
579 gfc_conv_elemental_dependencies, gfc_do_allocate,
580 gfc_evaluate_where_mask, gfc_trans_allocate,
581 gfc_trans_arithmetic_if, gfc_trans_call,
582 gfc_trans_character_select, gfc_trans_deallocate,
583 gfc_trans_do, gfc_trans_do_while, gfc_trans_forall_1,
584 gfc_trans_forall_loop, gfc_trans_goto, gfc_trans_if_1,
585 gfc_trans_integer_select, gfc_trans_logical_select,
586 gfc_trans_pointer_assign_need_temp, gfc_trans_return,
587 gfc_trans_simple_do, gfc_trans_sync, gfc_trans_where_2,
588 gfc_trans_where_assign) Ditto.
590 2010-09-02 Janus Weil <janus@gcc.gnu.org>
593 * resolve.c (resolve_symbol): Correct check for attributes of CLASS
596 2010-09-02 Tobias Burnus <burnus@net-b.de>
599 * resolve.c (apply_default_init): Mark symbol as referenced,
600 if it is initialized.
601 (resolve_symbol): Change intialized check for BT_DERIVED such
602 that also function results get initialized; remove now obsolete
603 gfc_set_sym_referenced for BT_CLASS.
605 2010-09-01 Janus Weil <janus@gcc.gnu.org>
608 * class.c (gfc_find_derived_vtab): Add component '$def_init'.
609 * resolve.c (resolve_allocate_expr): Defer handling of default
610 initialization to 'gfc_trans_allocate'.
611 (apply_default_init,resolve_symbol): Handle polymorphic dummies.
612 (resolve_fl_derived): Suppress error messages for vtypes.
613 * trans-stmt.c (gfc_trans_allocate): Handle initialization via
614 polymorphic MOLD expression.
615 * trans-expr.c (gfc_trans_class_init_assign): Now only used for
616 dummy initialization.
618 2010-09-01 Tobias Burnus <burnus@net-b.de>
620 * gfortran.texi (preprocessing): Update URL to COCO.
622 2010-09-01 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
624 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Resize
625 array quad_decls. Remove unnecessary assignment.
627 2010-09-01 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
629 * trans-expr.c (gfc_conv_power_op): Handle floating-point types
630 other than long double.
631 * mathbuiltins.def: Add builtins from the POW and CPOW family.
632 * trans.h (gfc_builtin_decl_for_float_kind): New prototype.
633 * trans-intrinsic.c (gfc_builtin_decl_for_float_kind): Add gfc_
634 prefix to function name.
635 (gfc_build_intrinsic_lib_fndecls): Add cpow prototype.
636 (gfc_conv_intrinsic_aint): Use gfc_builtin_decl_for_float_kind
638 (gfc_conv_intrinsic_exponent): Likewise.
639 (gfc_conv_intrinsic_abs): Likewise.
640 (gfc_conv_intrinsic_mod): Likewise.
641 (gfc_conv_intrinsic_sign): Likewise.
642 (gfc_conv_intrinsic_arith): Likewise.
643 (gfc_conv_intrinsic_fraction): Likewise.
644 (gfc_conv_intrinsic_nearest): Likewise.
645 (gfc_conv_intrinsic_spacing): Likewise.
646 (gfc_conv_intrinsic_rrspacing): Likewise.
647 (gfc_conv_intrinsic_scale): Likewise.
648 (gfc_conv_intrinsic_set_exponent): Likewise.
650 2010-09-01 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
652 * intrinsic.c: Add EXECUTE_COMMAND_LINE intrinsic.
653 * intrinsic.h (gfc_resolve_execute_command_line): New function.
654 * iresolve.c (gfc_resolve_execute_command_line): New function.
655 * gfortran.h (GFC_ISYM_EXECUTE_COMMAND_LINE): New value.
656 * intrinsic.texi: Document EXECUTE_COMMAND_LINE.
658 2010-08-31 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
661 * f95-lang.c (gfc_init_builtin_functions): Define popcount{,l,ll}
662 and parity{,l,ll} builtins.
663 * trans-intrinsic.c (gfc_conv_intrinsic_popcnt_poppar): New function.
664 (gfc_conv_intrinsic_function): Call above new functions.
665 * simplify.c (gfc_simplify_popcnt, gfc_simplify_poppar): New
667 * intrinsic.texi: Document POPCNT and POPPAR.
669 2010-08-30 Janus Weil <janus@gcc.gnu.org>
672 * resolve.c (resolve_structure_cons): Handle pointer-valued PPCs.
674 2010-08-30 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
676 * Make-lang.in: Add frontend-passes.o dependencies.
678 2010-08-29 Janus Weil <janus@gcc.gnu.org>
681 * resolve.c (resolve_structure_cons): For derived types, make sure the
682 type has been resolved.
683 (resolve_typebound_procedures): Make sure the vtab has been generated.
685 2010-08-29 Janus Weil <janus@gcc.gnu.org>
688 * match.c (gfc_match_select_type): Give the associate-name the
689 FL_VARIABLE attribute.
691 2010-08-28 Steven G. Kargl <kargl@gcc.gnu.org>
693 * simplify.c (gfc_simplify_bessel_n2): Fix indention
696 2010-08-28 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
699 * trans-types.c (gfc_init_kinds): Disable TFmode.
701 2010-08-27 Janus Weil <janus@gcc.gnu.org>
704 * match.c (gfc_match_allocate): Avoid double free on error.
706 2010-08-27 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
709 * gfortran.h (gfc_real_info): Add c_float128 field.
710 * mathbuiltins.def: Indicate which builtins are const.
711 * trans-types.h (float128_type_node, complex_float128_type_node,
712 gfc_real16_is_float128): New variables.
713 * trans-types.c (float128_type_node, complex_float128_type_node,
714 gfc_real16_is_float128): New variables.
715 (gfc_init_kinds): Allow TFmode.
716 (gfc_build_real_type): Mark __float128 types as such.
717 (gfc_init_types): Initialize float128_type_node and
718 complex_float128_type_node
719 * f95-lang.c (gfc_init_builtin_functions): Adjust for new
720 argument of OTHER_BUILTIN macro.
721 * trans-intrinsic.c (gfc_intrinsic_map_t): Likewise.
722 (builtin_decl_for_precision): Special case for __float128.
723 (builtin_decl_for_float_kind): Likewise.
724 (define_quad_builtin): New function.
725 (gfc_build_intrinsic_lib_fndecls): Create all __float128
726 library decls if necessary. Store them in the real16_decl and
727 complex16_decl builtin map fields.
728 (gfc_get_intrinsic_lib_fndecl): Handle q-suffixed __float128
729 library function names.
731 2010-08-27 Tobias Burnus <burnus@net-b.de>
734 * gcc/fortran/intrinsic.c (add_functions): Add norm2 and parity.
735 * gcc/fortran/intrinsic.h (gfc_check_norm2, gfc_check_parity):
736 gfc_simplify_norm2, gfc_simplify_parity, gfc_resolve_norm2,
737 gfc_resolve_parity): New prototypes.
738 * gcc/fortran/gfortran.h (gfc_isym_id): New enum items
739 GFC_ISYM_NORM2 and GFC_ISYM_PARITY.
740 * gcc/fortran/iresolve.c (gfc_resolve_norm2,
741 gfc_resolve_parity): New functions.
742 * gcc/fortran/check.c (gfc_check_norm2, gfc_check_parity):
744 * gcc/fortran/trans-intrinsic.c (gfc_conv_intrinsic_arith,
745 gfc_conv_intrinsic_function): Handle NORM2 and PARITY.
746 * gcc/fortran/intrinsic.texi (NORM2, PARITY): Add.
747 * gcc/fortran/simplify.c (simplify_transformation_to_array):
748 Add post-processing opterator.
749 (gfc_simplify_all, gfc_simplify_any, gfc_simplify_count,
750 gfc_simplify_product, gfc_simplify_sum): Update call.
751 (add_squared, do_sqrt, gfc_simplify_norm2, do_xor,
752 gfc_simplify_parity): New functions.
754 2010-08-27 Janus Weil <janus@gcc.gnu.org>
757 * match.c (select_type_set_tmp): Add the possibility to reset the
759 (gfc_match_class_is): Reset the temporary in CLASS DEFAULT clauses.
761 2010-08-27 Thomas Koenig <tkoenig@gcc.gnu.org>
764 * dependency.c (check_section_vs_section): Single test for
765 identical strides which takes into account that only one
766 of the strides may be NULL.
768 2010-08-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
771 * primary.c (match_hollerith_constant): Calculate padding needed to
772 fill default integer and allocate string for that size. Set pad bytes
774 * gfortran.h: Add hollerith pad value to type spec union.
775 * data.c (create_character_initializer): Fix spelling of function name.
776 Use hollerith pad value to calculate length.
777 * arith.c (hollerith2representation); Use hollerith pad value to
780 2010-08-26 Daniel Kraft <d@domob.eu>
785 * gfortran.h (struct gfc_association_list): New flag `dangling'.
786 (gfc_build_block_ns): Declared here...
787 * parse.h (gfc_build_block_ns): ...instead of here.
788 * trans.h (gfc_process_block_locals): Expect additionally the
789 gfc_association_list of BLOCK (if present).
790 * match.c (select_type_set_tmp): Create sym->assoc for temporary.
791 * resolve.c (resolve_variable): Only check for invalid *array*
792 references on associate-names.
793 (resolve_assoc_var): New method with code previously in resolve_symbol.
794 (resolve_select_type): Use association to give the selector and
795 temporaries their values instead of ordinary assignment.
796 (resolve_fl_var_and_proc): Allow CLASS associate-names.
797 (resolve_symbol): Use new `resolve_assoc_var' instead of inlining here.
798 * trans-stmt.c (gfc_trans_block_construct): Pass association-list
799 to `gfc_process_block_locals' to match new interface.
800 * trans-decl.c (gfc_get_symbol_decl): Don't defer associate-names
802 (gfc_process_block_locals): Defer them rather here when linked to
803 from the BLOCK's association list.
805 2010-08-25 Jakub Jelinek <jakub@redhat.com>
807 * trans-decl.c (gfc_build_intrinsic_function_decls): Set
808 TREE_NOTHROW on fndecls that can't throw. Set
809 TREE_READONLY on gfor_fndecl_math_ishftc{4,8,16}.
810 (gfc_build_builtin_function_decls): Set TREE_NOTHROW on
811 gfor_fndecl_associated.
813 2010-08-23 Mikael Morin <mikael@gcc.gnu.org>
816 * frontend-passes.c (optimize_equality): Don't optimize array equality
818 2010-08-23 Janus Weil <janus@gcc.gnu.org>
821 * resolve.c (resolve_procedure_interface): New function split off from
823 (resolve_formal_arglist): Call it here ...
824 (resolve_symbol): ... and here.
826 2010-08-22 Joseph Myers <joseph@codesourcery.com>
828 * Make-lang.in (gfortranspec.o): Update dependencies.
829 * gfortranspec.c: Include coretypes.h before gcc.h. Include
831 (MATH_LIBRARY, FORTRAN_LIBRARY): Remove initial "-l".
832 (ADD_ARG_LIBGFORTRAN, Option, lookup_option): Remove.
833 (g77_xargc): Make unsigned.
834 (g77_xargv): Change to g77_x_decoded_options.
835 (g77_newargc): Make unsigned.
836 (g77_newargv): Change to g77_new_decoded_options.
837 (strings_same, options_same): New.
838 (append_arg): Use cl_decoded_option structures.
839 (append_option): New.
840 (add_arg_libgfortran): New.
841 (lang_specific_driver): Use cl_decoded_option structures.
843 2010-08-21 Janus Weil <janus@gcc.gnu.org>
847 * class.c (add_proc_comp): Add static initializer for PPCs.
848 (add_procs_to_declared_vtab): Modified comment.
849 * module.c (mio_component): Add argument 'vtype'. Don't read/write the
850 initializer if the component is part of a vtype.
851 (mio_component_list): Add argument 'vtype', pass it on to
853 (mio_symbol): Modified call to 'mio_component_list'.
854 * trans.h (gfc_conv_initializer): Modified prototype.
855 (gfc_trans_assign_vtab_procs): Removed.
856 * trans-common.c (create_common): Modified call to
857 'gfc_conv_initializer'.
858 * trans-decl.c (gfc_get_symbol_decl,get_proc_pointer_decl,
859 gfc_emit_parameter_debug_info): Modified call to
860 'gfc_conv_initializer'.
861 (build_function_decl): Remove assertion.
862 * trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
863 Removed call to 'gfc_trans_assign_vtab_procs'.
864 (gfc_conv_initializer): Add argument 'procptr'.
865 (gfc_conv_structure): Modified call to 'gfc_conv_initializer'.
866 (gfc_trans_assign_vtab_procs): Removed.
867 * trans-stmt.c (gfc_trans_allocate): Removed call to
868 'gfc_trans_assign_vtab_procs'.
870 2010-08-21 Tobias Burnus <burnus@net-b.de>
874 * intrinsic.c (add_sym): Init value attribute.
875 (set_attr_value): New function.
876 (add_functions) Use it and add JN/YN resolvers.
877 * symbol.c (gfc_copy_formal_args_intr): Copy value attr.
878 * intrinsic.h (gfc_resolve_bessel_n2): New prototype.
879 * gfortran.h (gfc_intrinsic_arg): Add value attribute.
880 * iresolve.c (gfc_resolve_bessel_n2): New function.
881 * trans-intrinsic.c (gfc_get_symbol_for_expr): Create
883 (gfc_conv_intrinsic_function,gfc_is_intrinsic_libcall):
884 Add GFC_ISYM_JN2/GFC_ISYM_YN2 as case value.
885 * simplify.c (): For YN set to -INF if previous values
887 * trans-expr.c (gfc_conv_procedure_call): Don't crash
889 * iresolve.c (gfc_resolve_extends_type_of): Set the
890 type of the dummy argument to the one of the actual.
892 2010-08-20 Joseph Myers <joseph@codesourcery.com>
894 * lang.opt (MD, MMD): Use NoDriverArg instead of NoArgDriver.
896 2010-08-20 Joseph Myers <joseph@codesourcery.com>
898 * gfortranspec.c (lang_specific_driver): Refer to -lgfortran in
901 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
903 * trans-openmp.c: Use FOR_EACH_VEC_ELT.
905 2010-08-19 Daniel Kraft <d@domob.eu>
909 * trans.h (struct gfc_se): New flag `byref_noassign'.
910 * trans-array.h (gfc_conv_shift_descriptor_lbound): New method.
911 (gfc_conv_array_extent_dim), (gfc_conv_descriptor_size): New methods.
912 * expr.c (gfc_check_pointer_assign): Allow bounds and rank remapping
913 and check for compile-time errors with those.
914 * trans-decl.c (trans_associate_var): Use new routine
915 `gfc_conv_shift_descriptor_lbound' instead of doing it manually.
916 * trans-array.c (gfc_conv_shift_descriptor_lbound): New method.
917 (gfc_conv_array_extent_dim), (gfc_conv_descriptor_size): New methods.
918 (gfc_array_init_size): Use new `gfc_conv_array_extent_dim'.
919 (gfc_conv_expr_descriptor): Handle new flag `byref_noassign'.
920 * trans-expr.c (gfc_trans_pointer_assignment): Handle bounds and
921 rank remapping for assignment.
923 2010-08-19 Tobias Burnus <burnus@net-b.de>
925 * intrinsic.texi (Bessel_jn, Bessel_yn): Fix typo.
926 * * simplify.c (gfc_simplify_bessel_yn): Change recursive
929 2010-08-19 Tobias Burnus <burnus@net-b.de>
933 * check.c (gfc_check_bessel_n2): New function.
934 * gfortran.h (gfc_isym_id): Add GFC_ISYM_JN2 and GFC_ISYM_YN2.
935 * intrinsic.c (add_functions): Add transformational version
936 of the Bessel_jn/yn intrinsics.
937 * intrinsic.h (gfc_check_bessel_n2,gfc_simplify_bessel_jn2,
938 gfc_simplify_bessel_yn2): New prototypes.
939 * intrinsic.texi (Bessel_jn, Bessel_yn): Document
940 transformational variant.
941 * simplify.c (gfc_simplify_bessel_jn, gfc_simplify_bessel_yn):
942 Check for negative order.
943 (gfc_simplify_bessel_n2,gfc_simplify_bessel_jn2,
944 gfc_simplify_bessel_yn2): New functions.
946 2010-08-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
949 * resolve.c (resolve_transfer): Traverse operands and set expression
950 to be checked to a non EXPR_OP type.
952 2010-08-19 Janus Weil <janus@gcc.gnu.org>
955 * gfortran.h (gfc_add_save): Modified prototype.
956 * decl.c (add_init_expr_to_sym): Defer checking of proc pointer init.
957 (match_pointer_init): New function to match F08 pointer initialization.
958 (variable_decl,match_procedure_decl,match_ppc_decl): Use
959 'match_pointer_init'.
960 (match_attr_spec): Module variables are implicitly SAVE.
961 (gfc_match_save): Modified call to 'gfc_add_save'.
962 * expr.c (gfc_check_assign_symbol): Extra checks for pointer
964 * primary.c (gfc_variable_attr): Handle SAVE attribute.
965 * resolve.c (resolve_structure_cons): Add new argument and do pointer
966 initialization checks.
967 (gfc_resolve_expr): Modified call to 'resolve_structure_cons'.
968 (resolve_values): Call 'resolve_structure_cons' directly with init arg.
969 (resolve_fl_variable): Handle SAVE_IMPLICIT.
970 * symbol.c (gfc_add_save,gfc_copy_attr,save_symbol): Handle
972 * trans-decl.c (gfc_create_module_variable): Module variables with
973 TARGET can already exist.
974 * trans-expr.c (gfc_conv_variable): Check for 'current_function_decl'.
975 (gfc_conv_initializer): Implement non-NULL pointer
978 2010-08-18 Tobias Burnus <burnus@net-b.de>
981 * intrinsic.texi (selected_char_kind): Document ISO_10646
984 2010-08-17 Jakub Jelinek <jakub@redhat.com>
987 * trans-decl.c (build_library_function_decl_1): Chain on
988 void_list_node instead of creating a new TREE_LIST.
989 * trans-intrinsic.c (gfc_get_intrinsic_lib_fndecl): Likewise.
990 * trans-types.c (gfc_get_function_type): Likewise. Set
991 typelist to void_list_node for the main program.
993 2010-08-17 Daniel Kraft <d@domob.eu>
996 * gfortran.h (struct gfc_association_list): New member `where'.
997 (gfc_is_associate_pointer) New method.
998 * match.c (gfc_match_associate): Remember locus for each associate
999 name matched and do not try to set variable flag.
1000 * parse.c (parse_associate): Use remembered locus for symbols.
1001 * primary.c (match_variable): Instead of variable-flag check for
1002 associate names set it for all such names used.
1003 * symbol.c (gfc_is_associate_pointer): New method.
1004 * resolve.c (resolve_block_construct): Don't generate assignments
1005 to give associate-names their values.
1006 (resolve_fl_var_and_proc): Allow associate-names to be deferred-shape.
1007 (resolve_symbol): Set some more attributes for associate variables,
1008 set variable flag here and check it and don't try to build an
1009 explicitely shaped array-spec for array associate variables.
1010 * trans-expr.c (gfc_conv_variable): Dereference in case of association
1012 * trans-types.c (gfc_is_nodesc_array): Handle array association symbols.
1013 (gfc_sym_type): Return pointer type for association to scalar vars.
1014 * trans-decl.c (gfc_get_symbol_decl): Defer association symbols.
1015 (trans_associate_var): New method.
1016 (gfc_trans_deferred_vars): Handle association symbols.
1018 2010-08-16 Joseph Myers <joseph@codesourcery.com>
1020 * lang.opt (MDX): Change back to MD. Mark NoDriverArg instead of
1022 (MMDX): Change back to MMD. Mark NoDriverArg instead of
1024 * cpp.c (gfc_cpp_handle_option): Use OPT_MD and OPT_MMD instead of
1025 OPT_MDX and OPT_MMDX.
1027 2010-08-16 Joseph Myers <joseph@codesourcery.com>
1029 * lang.opt (MDX, MMDX): Mark RejectDriver.
1031 2010-08-15 Janus Weil <janus@gcc.gnu.org>
1033 * trans-expr.c (gfc_trans_assign_vtab_procs): Clean up (we don't have
1034 vtabs for generics any more).
1036 2010-08-15 Daniel Kraft <d@domob.eu>
1039 * gfortran.h (gfc_find_proc_namespace): New method.
1040 * expr.c (gfc_build_intrinsic_call): No need to build symtree messing
1041 around with namespace.
1042 * symbol.c (gfc_find_proc_namespace): New method.
1043 * trans-decl.c (gfc_build_qualified_array): Use it for correct
1045 * primary.c (gfc_match_varspec): Handle associate-names as arrays.
1046 * parse.c (parse_associate): Removed assignment-generation here...
1047 * resolve.c (resolve_block_construct): ...and added it here.
1048 (resolve_variable): Handle names that are arrays but were not parsed
1049 as such because of association.
1050 (resolve_code): Fix BLOCK resolution.
1051 (resolve_symbol): Generate array-spec for associate-names.
1053 2010-08-15 Tobias Burnus <burnus@net-b.de>
1056 * decl.c (verify_c_interop_param): Remove superfluous space (" ").
1057 (verify_c_interop): Handle unresolved DT with bind(C).
1059 2010-08-15 Tobias Burnus <burnus@net-b.de>
1061 * trans-expr.c (gfc_conv_expr_present): Regard nullified
1062 pointer arrays as absent.
1063 (gfc_conv_procedure_call): Handle EXPR_NULL for non-pointer
1064 dummys as absent argument.
1065 * interface.c (compare_actual_formal,compare_parameter):
1068 2010-08-15 Tobias Burnus <burnus@net-b.de>
1070 * interface.c (compare_pointer, ): Allow passing TARGETs to pointers
1071 dummies with intent(in).
1073 2010-08-15 Daniel Kraft <d@domob.eu>
1076 * decl.c (gfc_match_prefix): Match IMPURE prefix and mark ELEMENTAL
1077 routines not IMPURE also as PURE.
1078 * intrinsic.c (enum klass): New class `CLASS_PURE' and renamed
1079 `NO_CLASS' in `CLASS_IMPURE'.
1080 (add_sym): Set symbol-attributes `pure' and `elemental' correctly.
1081 (add_sym_0s): Renamed `NO_CLASS' in `CLASS_IMPURE'.
1082 (add_functions): Ditto.
1083 (add_subroutines): Ditto and mark `MOVE_ALLOC' as CLASS_PURE.
1084 * resolve.c (gfc_pure): Do not treat ELEMENTAL as automatically PURE.
1085 (resolve_formal_arglist): Check that arguments to ELEMENTAL procedures
1086 are not ALLOCATABLE and have their INTENT specified.
1088 2010-08-13 Daniel Kraft <d@domob.eu>
1090 * gfortran.h (array_type): New type `AS_IMPLIED_SHAPE'.
1091 * array.c (gfc_match_array_spec): Match implied-shape specification and
1092 handle AS_IMPLIED_SHAPE correctly otherwise.
1093 * decl.c (add_init_expr_to_sym): Set upper bounds for implied-shape.
1094 (variable_decl): Some checks for implied-shape declaration.
1095 * resolve.c (resolve_symbol): Assert that array-spec is no longer
1096 AS_IMPLIED_SHAPE in any case.
1098 2010-08-12 Joseph Myers <joseph@codesourcery.com>
1100 * lang.opt (MD, MMD): Change to MDX and MMDX.
1101 * cpp.c (gfc_cpp_handle_option): Use OPT_MMD and OPT_MMDX.
1103 2010-08-11 Janus Weil <janus@gcc.gnu.org>
1106 * intrinsic.c (gfc_current_intrinsic_arg): Change type from 'char' to
1107 'gfc_intrinsic_arg'.
1108 (check_arglist,check_specific): Add reference to 'name' field.
1109 (init_arglist): Remove reference to 'name' field.
1110 * intrinsic.h (gfc_current_intrinsic_arg): Modify prototype.
1111 * check.c (variable_check): Reverse order of checks. Respect intent of
1113 (int_or_proc_check): New function.
1114 (coarray_check): New function.
1115 (allocatable_check): New function.
1116 (gfc_check_allocated,gfc_check_move_alloc): Use 'allocatable_check'.
1117 (gfc_check_complex): Use 'int_or_real_check'.
1118 (gfc_check_lcobound,gfc_check_image_index,gfc_check_this_image,
1119 gfc_check_ucobound): Use 'coarray_check'.
1120 (gfc_check_pack): Use 'real_or_complex_check'.
1121 (gfc_check_alarm_sub,gfc_check_signal,gfc_check_signal_sub): Use
1122 'int_or_proc_check'.
1123 (scalar_check,type_check,numeric_check,int_or_real_check,
1124 real_or_complex_check,kind_check,double_check,logical_array_check,
1125 array_check,same_type_check,rank_check,nonoptional_check,
1126 kind_value_check,gfc_check_a_p,gfc_check_associated,gfc_check_cmplx,
1127 gfc_check_cshift,gfc_check_dcmplx,gfc_check_dot_product,gfc_check_dprod,
1128 gfc_check_eoshift,gfc_check_fn_rc2008,gfc_check_index,gfc_check_kind,
1129 gfc_check_matmul,gfc_check_minloc_maxloc,check_reduction,gfc_check_null,
1130 gfc_check_present,gfc_check_reshape,gfc_check_same_type_as,
1131 gfc_check_spread,gfc_check_unpack,gfc_check_random_seed,
1132 gfc_check_getarg,gfc_check_and,gfc_check_storage_size): Add reference
1135 2010-08-10 Daniel Kraft <d@domob.eu>
1137 * gfortran.texi (Interoperability with C): Fix ordering in menu
1138 and add new subsection about pointers.
1139 (Interoperable Subroutines and Functions): Split off the pointer part.
1140 (working with Pointers): New subsection with extended discussion
1141 of pointers (especially procedure pointers).
1143 2010-08-09 Thomas Koenig <tkoenig@gcc.gnu.org>
1146 * array.c (gfc_ref_dimen_size): Add end argument.
1147 If end is non-NULL, calculate it.
1148 (ref_size): Adjust call to gfc_ref_dimen_size.
1149 (gfc_array_dimen_size): Likewise.
1150 (gfc_array_res_shape): Likewise.
1151 * gfortran.h: Adjust prototype for gfc_ref_dimen_size.
1152 * resolve.c (resolve_array_ref): For stride not equal to -1,
1153 fill in the lowest possible end.
1155 2010-08-09 Janus Weil <janus@gcc.gnu.org>
1157 * intrinsic.texi: Correct documentation of ASINH, ACOSH and ATANH.
1159 2010-08-07 Nathan Froyd <froydnj@codesourcery.com>
1161 * interface.c (compare_actual_formal): Use XALLOCAVEC instead of
1163 (check_some_aliasing): Likewise.
1164 * trans-intrinsic.c (gfc_conv_intrinsic_conversion): Likewise.
1165 (gfc_conv_intrinsic_int): Likewise.
1166 (gfc_conv_intrinsic_lib_function): Likewise.
1167 (gfc_conv_intrinsic_cmplx): Likewise.
1168 (gfc_conv_intrinsic_ctime): Likewise.
1169 (gfc_conv_intrinsic_fdate): Likewise.
1170 (gfc_conv_intrinsic_ttynam): Likewise.
1171 (gfc_conv_intrinsic_minmax): Likewise.
1172 (gfc_conv_intrinsic_minmax_char): Likewise.
1173 (gfc_conv_intrinsic_ishftc): Likewise.
1174 (gfc_conv_intrinsic_index_scan_verify): Likewise.
1175 (gfc_conv_intrinsic_merge): Likewise.
1176 (gfc_conv_intrinsic_trim): Likewise.
1177 * trans.c (gfc_trans_runtime_error_vararg): Likewise.
1179 2010-08-06 Thomas Koenig <tkoenig@gcc.gnu.org>
1182 * dependency.c (check_section_vs_section): Handle cases where
1183 the start expression coincides with the lower or upper
1186 2010-08-04 Janus Weil <janus@gcc.gnu.org>
1191 * class.c (gfc_find_derived_vtab): Do not generate vtabs for class
1192 container types. Do not artificially increase refs. Commit symbols one
1194 * interface.c (compare_parameter): Make sure vtabs are present before
1195 generating module variables.
1196 * resolve.c (resolve_allocate_expr): Ditto.
1198 2010-08-04 Tobias Burnus <burnus@net-b.de>
1202 * resolve.c (resolve_structure_cons): Fix
1205 2010-08-04 Mikael Morin <mikael@gcc.gnu.org>
1209 * symbol.c (changed_syms): Made static again.
1210 (gfc_symbol_state): Don't conditionalize on GFC_DEBUG.
1211 Changed conditional internal error into assert.
1212 Rename function to ...
1213 (gfc_enforce_clean_symbol_state): ... this.
1214 * gfortran.h (gfc_symbol_state, gfc_enforce_clean_symbol_state):
1215 Rename the former to the latter.
1216 * parse.c (decode_statement, decode_omp_directive,
1217 decode_gcc_attribute): Update callers accordingly. Don't conditionalize
1219 (changed_syms): Remove declaration.
1220 (next_statement): Use gfc_enforce_clean_symbol_state.
1222 2010-08-04 Tobias Burnus <burnus@net-b.de>
1225 * resolve.c (resolve_structure_cons): Fix handling of
1226 initialization structure constructors with character
1227 elements of the wrong length.
1228 * array.c (gfc_check_iter_variable): Add NULL check.
1229 (gfc_resolve_character_array_constructor): Also truncate
1232 2010-08-04 Tobias Burnus <burnus@net-b.de>
1234 * trans-io.c (gfc_build_io_library_fndecls): Fix return
1235 value of some libgfortran functions.
1237 2010-08-03 Thomas Koenig <tkoenig@gcc.gnu.org>
1240 * dependency.c (gfc_deb_compare_expr): Remove any integer
1241 conversion functions to larger types from both arguments.
1242 Remove handling these functions futher down.
1244 2010-08-03 Janus Weil <janus@gcc.gnu.org>
1248 * class.c (add_procs_to_declared_vtab1): Don't add erroneous procedures.
1249 * resolve.c (resolve_tb_generic_targets): Check for errors.
1251 2010-08-02 Thomas Koenig <tkoenig@gcc.gnu.org>
1254 * depencency.c (gfc_dep_resolver): Fix logic for when a loop
1257 2010-08-02 Thomas Koenig <tkoenig@gcc.gnu.org>
1260 * dependency.h: Add prototype for gfc_are_identical_variables.
1261 * frontend-passes.c: Include depencency.h.
1262 (optimimize_equality): Use gfc_are_identical_variables.
1263 * dependency.c (identical_array_ref): New function.
1264 (gfc_are_identical_variables): New function.
1265 (gfc_deb_compare_expr): Use gfc_are_identical_variables.
1266 * dependency.c (gfc_check_section_vs_section). Rename gfc_
1267 prefix from statc function.
1268 (check_section_vs_section): Change arguments to gfc_array_ref,
1269 adjust function body accordingly.
1271 2010-08-02 Mikael Morin <mikael@gcc.gnu.org>
1272 Janus Weil <janus@gcc.gnu.org>
1277 * intrinsic.c (gfc_get_intrinsic_sub_symbol): Commit changed symbol.
1278 * symbol.c (gen_cptr_param, gen_fptr_param, gen_shape_param,
1279 gfc_copy_formal_args, gfc_copy_formal_args_intr,
1280 gfc_copy_formal_args_ppc, generate_isocbinding_symbol): Ditto.
1281 * parse.c (parse_derived_contains, parse_spec, parse_progunit):
1282 Call reject_statement in case of error.
1283 (match_deferred_characteritics): Call gfc_undo_symbols in case match
1286 2010-08-01 Janus Weil <janus@gcc.gnu.org>
1289 * class.c (gfc_build_class_symbol): Make '$vptr' component private.
1290 (gfc_find_derived_vtab): Make vtabs and vtypes public.
1291 * module.c (read_module): When reading module files, always import
1292 vtab and vtype symbols.
1294 2010-07-31 Mikael Morin <mikael@gcc.gnu.org>
1298 * symbol.c (changed_syms): Made non-static.
1299 * parse.c (changed_syms): Declare new external.
1300 (next_statement): Assert changed_syms is NULL at the beginning.
1302 2010-07-30 Janus Weil <janus@gcc.gnu.org>
1303 Steven G. Kargl <kargl@gcc.gnu.org>
1306 * match.c (match_type_spec): Try to parse derived types before
1309 2010-07-30 Mikael Morin <mikael@gcc.gnu.org>
1311 * gfortran.h (gfc_release_symbol): New prototype.
1312 * symbol.c (gfc_release_symbol): New. Code taken from free_sym_tree.
1313 (gfc_undo_symbols, free_sym_tree, gfc_free_finalizer):
1314 Use gfc_release_symbol.
1315 * parse.c (gfc_fixup_sibling_symbols): Ditto.
1316 * resolve.c (resolve_symbol): Ditto.
1318 2010-07-29 Tobias Burnus <burnus@net-b.de>
1322 * trans-decl.c (gfc_get_extern_function_decl): Correctly handle
1323 external procedure declarations in modules.
1324 (gfc_get_symbol_decl): Modify assert.
1326 2010-07-29 Janus Weil <janus@gcc.gnu.org>
1329 * resolve.c (resolve_fl_derived): Call gfc_resolve_array_spec.
1331 2010-07-29 Janus Weil <janus@gcc.gnu.org>
1334 * trans-stmt.h (gfc_trans_class_init_assign): New prototype.
1335 (gfc_trans_class_assign): Modified prototype.
1336 * trans.h (gfc_conv_intrinsic_move_alloc): New prototype.
1337 * trans-expr.c (gfc_trans_class_init_assign): Split off from ...
1338 (gfc_trans_class_assign): ... here. Modified actual arguments.
1339 * trans-intrinsic.c (gfc_conv_intrinsic_move_alloc): New function to
1340 handle the MOVE_ALLOC intrinsic with scalar and class arguments.
1341 * trans.c (trans_code): Call 'gfc_conv_intrinsic_move_alloc'.
1343 2010-07-29 Mikael Morin <mikael@gcc.gnu.org>
1347 * class.c (gfc_find_derived_vtab): Accept or discard newly created
1348 symbols before returning.
1350 2010-07-29 Joseph Myers <joseph@codesourcery.com>
1352 * lang.opt (cpp): Remove Joined and Separate markers.
1353 (cpp=): New internal option.
1354 * lang-specs.h (F951_CPP_OPTIONS): Generate -cpp= option.
1355 * cpp.c (gfc_cpp_handle_option): Handle OPT_cpp_ instead of
1358 2010-07-29 Daniel Kraft <d@domob.eu>
1361 * array.c (resolve_array_bound): Fix error message to properly handle
1362 non-variable expressions.
1364 2010-07-28 Mikael Morin <mikael@gcc.gnu.org>
1366 * decl.c (free_value): Also free repeat field.
1367 * data.c (gfc_assign_data_value): Always free offset before returning.
1369 2010-07-28 Daniel Kraft <d@domob.eu>
1371 * gfortran.h (gfc_build_intrinsic_call): New method.
1372 * expr.c (gfc_build_intrinsic_call): New method.
1373 * simplify.c (range_check): Ignore non-constant value.
1374 (simplify_bound_dim): Handle non-variable expressions and
1375 fix memory leak with non-free'ed expression.
1376 (simplify_bound): Handle non-variable expressions.
1377 (gfc_simplify_shape): Ditto.
1378 (gfc_simplify_size): Ditto, but only in certain cases possible.
1380 2010-07-28 Joseph Myers <joseph@codesourcery.com>
1382 * gfortranspec.c (SWITCH_TAKES_ARG, WORD_SWITCH_TAKES_ARG):
1385 2010-07-28 Tobias Burnus <burnus@net-b.de>
1388 * trans-types.c (gfc_get_derived_type): Fix DT declaration
1389 from modules for whole-file mode.
1391 2010-07-27 Joseph Myers <joseph@codesourcery.com>
1393 * gfortran.h (gfc_handle_option): Update prototype and return
1395 * options.c (gfc_handle_option): Update prototype and return value
1398 2010-07-27 Joseph Myers <joseph@codesourcery.com>
1400 * cpp.c (gfc_cpp_init_options): Update prototype. Use number of
1401 decoded options in allocating deferred_opt.
1402 * cpp.h (gfc_cpp_init_options): Update prototype.
1403 * f95-lang.c (LANG_HOOKS_OPTION_LANG_MASK): Define.
1404 * gfortran.h (gfc_option_lang_mask): New.
1405 (gfc_init_options): Update prototype.
1406 * options.c (gfc_option_lang_mask): New.
1407 (gfc_init_options): Update prototype. Pass new arguments to
1408 gfc_cpp_init_options.
1410 2010-07-26 Tobias Burnus <burnus@net-b.de>
1413 * trans-decl.c (gfc_get_extern_function_decl): Fix generation
1414 for functions which are later in the same file.
1415 (gfc_create_function_decl, build_function_decl,
1416 build_entry_thunks): Add global argument.
1417 * trans.c (gfc_generate_module_code): Update
1418 gfc_create_function_decl call.
1419 * trans.h (gfc_create_function_decl): Update prototype.
1420 * resolve.c (resolve_global_procedure): Also resolve for
1423 2010-07-26 Richard Henderson <rth@redhat.com>
1426 * f95-lang.c (LANG_HOOKS_WRITE_GLOBALS): New.
1427 (gfc_write_global_declarations): New.
1429 2010-07-26 Tobias Burnus <burnus@net-b.de>
1432 * trans-io.c (build_dt): Use NULL_TREE rather than NULL
1433 for call to transfer_namelist_element.
1434 * trans-decl.c (gfc_get_symbol_decl): Also set sym->backend_decl
1437 2010-07-25 Thomas Koenig <tkoenig@gcc.gnu.org>
1440 * Make-lang.in: Add fortran/frontend-passes.o.
1441 * gfortran.h: Add prototype for gfc_run_passes.
1442 * resolve.c (gfc_resolve): Call gfc_run_passes.
1443 * frontend-passes.c: New file.
1445 2010-07-25 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1448 * scanner.c (gfc_next_char_literal): Enable truncation warning for
1451 2010-07-25 Mikael Morin <mikael@gcc.gnu.org>
1454 * gfortran.h (gfc_namespace): New field old_equiv.
1455 (gfc_free_equiv_until): New prototype.
1456 * match.c (gfc_free_equiv_until): New, renamed from gfc_free_equiv with
1457 a parameterized stop condition.
1458 (gfc_free_equiv): Use gfc_free_equiv_until.
1459 * parse.c (next_statement): Save equivalence list.
1460 (reject_statement): Restore equivalence list.
1462 2010-07-25 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1465 * scanner.c (gfc_next_char_literal): Move check for truncation earlier
1466 in the function so that it does not get missed by early exits.
1467 (load_line): Add checks for quoted strings and free form comments to
1468 disable warnings on comments. Add check for ampersand as first
1469 character after truncation and don't warn for this case, but warn if
1470 there are subsequent non-whitespace characters.
1472 2010-07-24 Tobias Burnus <burnus@net-b.de>
1475 * parse.c (gfc_parse_file): Do not override
1476 gfc_global_ns_list items.
1478 2010-07-24 Tobias Burnus <burnus@net-b.de>
1480 * options.c (gfc_init_options): Enable -fwhole-file by default.
1481 * interface.c (compare_parameter): Assume a Hollerith constant is
1482 compatible with all other argument types.
1484 2010-07-23 Tobias Burnus <burnus@net-b.de>
1487 * trans-decl.c (gfc_get_symbol_decl): Use module decl with
1488 -fwhole-file also for derived types.
1489 * trans-types.c (copy_dt_decls_ifequal): Remove static and
1490 rename to gfc_copy_dt_decls_ifequal.
1491 (gfc_get_derived_type): Update call.
1492 * trans-types.h (gfc_copy_dt_decls_ifequal): Add prototype.
1494 2010-07-23 Tobias Burnus <burnus@net-b.de>
1497 * resolve.c (resolve_global_procedure): Properly handle ENTRY.
1499 2010-07-23 Jakub Jelinek <jakub@redhat.com>
1501 * trans-types.c (gfc_get_array_descriptor_base,
1502 gfc_get_array_type_bounds): Set TYPE_NAMELESS.
1503 * trans-decl.c (gfc_build_qualified_array): Set DECL_NAMELESS
1504 instead of clearing DECL_NAME.
1505 (gfc_build_dummy_array_decl): Set DECL_NAMELESS.
1507 2009-07-23 Paul Thomas <pault@gcc.gnu.org>
1510 * trans-array.c (gfc_init_loopinfo): Initialize the reverse
1512 gfc_trans_scalarized_loop_end: If reverse set in dimension n,
1513 reverse the scalarization loop.
1514 gfc_conv_resolve_dependencies: Pass the reverse field of the
1515 loopinfo to gfc_dep_resolver.
1516 trans-expr.c (gfc_trans_assignment_1): Enable loop reversal for
1517 assignment by resetting loop.reverse.
1518 gfortran.h : Add the gfc_reverse enum.
1519 trans.h : Add the reverse field to gfc_loopinfo.
1520 dependency.c (gfc_check_dependency): Pass null to the new arg
1521 of gfc_dep_resolver.
1522 (gfc_check_section_vs_section): Check for reverse dependencies.
1523 (gfc_dep_resolver): Add reverse argument and deal with the loop
1525 dependency.h : Modify prototype for gfc_dep_resolver to include
1528 2010-07-23 Daniel Kraft <d@domob.eu>
1531 * gfortran.h (gfc_find_symtree_in_proc): New method.
1532 * symbol.c (gfc_find_symtree_in_proc): New method.
1533 * match.c (match_exit_cycle): Look for loop name also in parent
1534 namespaces within current procedure.
1536 2010-07-22 Tobias Burnus <burnus@net-b.de>
1539 * dependency.c (gfc_check_dependency): Add argument alising check.
1540 * symbol.c (gfc_symbols_could_alias): Add argument alising check.
1542 2010-07-22 Daniel Kraft <d@domob.eu>
1544 * trans-stmt.c (gfc_trans_return): Put back in the handling of se.post,
1545 now in the correct place.
1547 2010-07-21 Steven G. Kargl <kargl@gcc.gnu.org>
1550 * Revert my commit r162325.
1552 2010-07-21 Daniel Kraft <d@domob.eu>
1554 * trans.h (gfc_get_return_label): Removed.
1555 (gfc_generate_return): New method.
1556 (gfc_trans_deferred_vars): Update gfc_wrapped_block rather than
1557 returning a tree directly.
1558 * trans-stmt.c (gfc_trans_return): Use `gfc_generate_return'.
1559 (gfc_trans_block_construct): Update for new interface to
1560 `gfc_trans_deferred_vars'.
1561 * trans-decl.c (current_function_return_label): Removed.
1562 (current_procedure_symbol): New variable.
1563 (gfc_get_return_label): Removed.
1564 (gfc_trans_deferred_vars): Update gfc_wrapped_block rather than
1565 returning a tree directly.
1566 (get_proc_result), (gfc_generate_return): New methods.
1567 (gfc_generate_function_code): Clean up and do init/cleanup here
1568 also with gfc_wrapped_block. Remove return-label but rather
1571 2010-07-19 Steven G. Kargl <kargl@gcc.gnu.org>
1574 * fortran/match.c (match_type_spec): Check for derived type before
1577 2010-07-19 Paul Thomas <pault@gcc.gnu.org>
1580 * interface.c (matching_typebound_op): Add argument for the
1581 return of the generic name for the procedure.
1582 (build_compcall_for_operator): Add an argument for the generic
1583 name of an operator procedure and supply it to the expression.
1584 (gfc_extend_expr, gfc_extend_assign): Use the generic name in
1585 calls to the above procedures.
1586 * resolve.c (resolve_typebound_function): Catch procedure
1587 component calls for CLASS objects, check that the vtable is
1588 complete and insert the $vptr and procedure components, to make
1590 (resolve_typebound_function): The same.
1591 * trans-decl.c (gfc_trans_deferred_vars): Do not deallocate
1592 an allocatable scalar if it is a result.
1594 2010-07-19 Paul Thomas <pault@gcc.gnu.org>
1597 * match.c (gfc_match_iterator): Reverted.
1599 2010-07-18 Paul Thomas <pault@gcc.gnu.org>
1602 * match.c (gfc_match_iterator): Remove error that iterator
1603 cannot be INTENT(IN).
1605 2010-07-17 Mikael Morin <mikael@gcc.gnu.org>
1607 * trans-array.c (gfc_free_ss): Don't free beyond ss rank.
1608 Access subscript through the "dim" field index.
1609 (gfc_trans_create_temp_array): Access ss info through the "dim" field
1611 (gfc_conv_array_index_offset): Ditto.
1612 (gfc_conv_loop_setup): Ditto.
1613 (gfc_conv_expr_descriptor): Ditto.
1614 (gfc_conv_ss_startstride): Ditto. Update call to
1615 gfc_conv_section_startstride.
1616 (gfc_conv_section_startstride): Set values along the array dimension.
1617 Get array dimension directly from the argument.
1619 2010-07-15 Jakub Jelinek <jakub@redhat.com>
1621 * trans.h (gfc_string_to_single_character): New prototype.
1622 * trans-expr.c (string_to_single_character): Renamed to ...
1623 (gfc_string_to_single_character): ... this. No longer static.
1624 (gfc_conv_scalar_char_value, gfc_build_compare_string,
1625 gfc_trans_string_copy): Adjust callers.
1626 * config-lang.in (gtfiles): Add fortran/trans-stmt.c.
1627 * trans-stmt.c: Include ggc.h and gt-fortran-trans-stmt.h.
1628 (select_struct): Move to toplevel, add GTY(()).
1629 (gfc_trans_character_select): Optimize SELECT CASE
1630 with character length 1.
1632 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
1634 * f95-lang.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
1635 * trans-common.c: Likewise.
1636 * trans-decl.c: Likewise.
1637 * trans-types.c: Likewise.
1638 * trans.c: Likewise.
1640 2010-07-15 Janus Weil <janus@gcc.gnu.org>
1643 * resolve.c (resolve_typebound_generic_call): Resolve generic
1644 non-polymorphic type-bound procedure calls to the correct specific
1646 (resolve_typebound_subroutine): Remove superfluous code.
1648 2010-07-15 Daniel Kraft <d@domob.eu>
1651 * trans.h (struct gfc_wrapped_block): New struct.
1652 (gfc_start_wrapped_block), (gfc_add_init_cleanup): New methods.
1653 (gfc_finish_wrapped_block): New method.
1654 (gfc_init_default_dt): Add new init code to block rather than
1656 * trans-array.h (gfc_trans_auto_array_allocation): Use gfc_wrapped_block
1657 (gfc_trans_dummy_array_bias): Ditto.
1658 (gfc_trans_g77_array): Ditto.
1659 (gfc_trans_deferred_array): Ditto.
1660 * trans.c (gfc_add_expr_to_block): Call add_expr_to_chain.
1661 (add_expr_to_chain): New method based on old gfc_add_expr_to_block.
1662 (gfc_start_wrapped_block), (gfc_add_init_cleanup): New methods.
1663 (gfc_finish_wrapped_block): New method.
1664 * trans-array.c (gfc_trans_auto_array_allocation): use gfc_wrapped_block
1665 (gfc_trans_g77_array), (gfc_trans_dummy_array_bias): Ditto.
1666 (gfc_trans_deferred_array): Ditto.
1667 * trans-decl.c (gfc_trans_dummy_character): Ditto.
1668 (gfc_trans_auto_character_variable), (gfc_trans_assign_aux_var): Ditto.
1669 (init_intent_out_dt): Ditto.
1670 (gfc_init_default_dt): Add new init code to block rather than
1672 (gfc_trans_deferred_vars): Use gfc_wrapped_block to collect all init
1673 and cleanup code and put it all together.
1675 2010-07-15 Jakub Jelinek <jakub@redhat.com>
1677 * trans.h (gfc_build_compare_string): Add CODE argument.
1678 * trans-intrinsic.c (gfc_conv_intrinsic_strcmp): Pass OP to
1679 gfc_build_compare_string.
1680 * trans-expr.c (gfc_conv_expr_op): Pass CODE to
1681 gfc_build_compare_string.
1682 (string_to_single_character): Rename len variable to length.
1683 (gfc_optimize_len_trim): New function.
1684 (gfc_build_compare_string): Add CODE argument. If it is EQ_EXPR
1685 or NE_EXPR and one of the strings is string literal with LEN_TRIM
1686 bigger than the length of the other string, they compare unequal.
1689 * trans-stmt.c (gfc_trans_character_select): Always use NULL for high
1690 in CASE_LABEL_EXPR and use NULL for low for the default case.
1692 2010-07-14 Mikael Morin <mikael@gcc.gnu.org>
1694 * trans-array.c (gfc_conv_section_upper_bound): Remove
1695 (gfc_conv_section_startstride): Don't set the upper bound in the
1696 vector subscript case.
1697 (gfc_conv_loop_setup): Don't use gfc_conv_section_upper_bound
1699 2010-07-14 Janus Weil <janus@gcc.gnu.org>
1702 * gfortran.h (gfc_is_data_pointer): Remove prototype.
1703 * dependency.c (gfc_is_data_pointer): Make it static.
1704 * intrinsic.texi: Update documentation on C_LOC.
1705 * resolve.c (gfc_iso_c_func_interface): Fix pointer and target checks
1706 and add a check for polymorphic variables.
1708 2010-07-14 Jakub Jelinek <jakub@redhat.com>
1710 * trans-expr.c (string_to_single_character): Also optimize
1711 string literals containing a single char followed only by spaces.
1712 (gfc_trans_string_copy): Remove redundant string_to_single_character
1715 * trans-decl.c (gfc_build_intrinsic_function_decls,
1716 gfc_build_builtin_function_decls): Mark functions as
1717 DECL_PURE_P or TREE_READONLY.
1719 2010-07-13 Nathan Froyd <froydnj@codesourcery.com>
1721 * trans-decl.c (build_entry_thunks): Call build_call_expr_loc_vec
1722 instead of build_function_call_expr.
1723 * trans-intrinsic.c (gfc_conv_intrinsic_sr_kind): Likewise.
1725 2010-07-13 Tobias Burnus <burnus@net-b.de>
1726 Daniel Franke <franke.daniel@gmail.com>
1729 * trans.h (gfc_build_library_function_decl_with_spec): New prototype.
1730 * trans-decl.c (gfc_build_library_function_decl_with_spec): Removed
1732 * trans-io (gfc_build_io_library_fndecls): Add "fn spec" annotations.
1734 2010-07-13 Daniel Franke <franke.daniel@gmail.com>
1735 Tobias Burnus <burnus@net-b.de>
1738 * trans-decl.c (gfc_build_intrinsic_function_decls): Add
1739 noclobber/noescape annotations to function calls.
1740 (gfc_build_builtin_function_decls): Likewise.
1742 2010-07-13 Janus Weil <janus@gcc.gnu.org>
1748 * gfortran.h (gfc_find_derived_vtab): Modified prototype.
1749 * class.c (gfc_build_class_symbol): Modified call to
1750 'gfc_find_derived_vtab'.
1751 (add_proc_component): Removed, moved code into 'add_proc_comp'.
1752 (add_proc_comps): Renamed to 'add_proc_comp', removed treatment of
1754 (add_procs_to_declared_vtab1): Removed unnecessary argument 'resolved'.
1755 Removed treatment of generics.
1756 (copy_vtab_proc_comps): Removed unnecessary argument 'resolved'.
1757 Call 'add_proc_comp' instead of duplicating code.
1758 (add_procs_to_declared_vtab): Removed unnecessary arguments 'resolved'
1760 (add_generic_specifics,add_generics_to_declared_vtab): Removed.
1761 (gfc_find_derived_vtab): Removed unnecessary argument 'resolved'.
1762 Removed treatment of generics.
1763 * iresolve.c (gfc_resolve_extends_type_of): Modified call to
1764 'gfc_find_derived_vtab'.
1765 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
1766 Removed treatment of generics.
1767 (resolve_select_type,resolve_fl_derived): Modified call to
1768 'gfc_find_derived_vtab'.
1769 * trans-decl.c (gfc_get_symbol_decl): Ditto.
1770 * trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
1772 * trans-stmt.c (gfc_trans_allocate): Ditto.
1774 2010-07-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1777 * trans-io.c (build_dt): Set common.unit to flag chracter(kind=4)
1780 2010-07-12 Mikael Morin <mikael@gcc.gnu.org>
1782 * expr.c (gfc_get_int_expr): Don't initialize mpfr data twice.
1783 * resolve.c (build_default_init_expr): Ditto.
1785 2010-07-11 Tobias Burnus <burnus@net-b.de>
1788 * module.c (sort_iso_c_rename_list): Remove.
1789 (import_iso_c_binding_module,use_iso_fortran_env_module):
1790 Allow multiple imports of the same symbol.
1792 2010-07-11 Mikael Morin <mikael@gcc.gnu.org>
1794 * arith.c (gfc_arith_done_1): Release mpfr internal caches.
1796 2010-07-11 Janus Weil <janus@gcc.gnu.org>
1799 * decl.c (build_sym,attr_decl1): Only build the class container if the
1800 symbol has sufficient attributes.
1801 * expr.c (gfc_check_pointer_assign): Use class_pointer instead of
1802 pointer attribute for classes.
1803 * match.c (gfc_match_allocate,gfc_match_deallocate): Ditto.
1804 * module.c (MOD_VERSION): Bump.
1805 (enum ab_attribute,attr_bits): Add AB_CLASS_POINTER.
1806 (mio_symbol_attribute): Handle class_pointer attribute.
1807 * parse.c (parse_derived): Use class_pointer instead of pointer
1808 attribute for classes.
1809 * primary.c (gfc_variable_attr,gfc_expr_attr): Ditto.
1810 * resolve.c (resolve_structure_cons,resolve_deallocate_expr,
1811 resolve_allocate_expr,resolve_fl_derived): Ditto.
1812 (resolve_fl_var_and_proc): Check for class_ok attribute.
1814 2010-07-10 Mikael Morin <mikael@gcc.gnu.org>
1816 * trans-io.c (gfc_build_st_parameter): Update calls to
1817 gfc_add_field_to_struct.
1818 * trans-stmt.c (ADD_FIELD): Ditto.
1820 (gfc_get_derived_type): Ditto. Don't create backend_decl for C_PTR's
1822 (gfc_add_field_to_struct_1): Set TYPE_FIELDS(context) instead of
1823 fieldlist, remove fieldlist from argument list.
1824 (gfc_add_field_to_struct): Update call to gfc_add_field_to_struct_1
1825 and remove fieldlist from argument list.
1826 (gfc_get_desc_dim_type, gfc_get_array_descriptor_base,
1827 gfc_get_mixed_entry_union): Move setting
1828 TYPE_FIELDS to gfc_add_field_to_struct_1 and update calls to it.
1829 * trans-types.h (gfc_add_field_to_struct): Update prototype.
1831 2010-07-10 Paul Thomas <pault@gcc.gnu.org>
1834 * trans-expr.c (arrayfunc_assign_needs_temporary): No temporary
1835 if the lhs has never been host associated, as well as not being
1836 use associated, a pointer or a target.
1837 * resolve.c (resolve_variable): Mark variables that are host
1839 * gfortran.h: Add the host_assoc bit to the symbol_attribute
1842 2010-07-09 Janus Weil <janus@gcc.gnu.org>
1844 * intrinsic.texi: Add documentation for SAME_TYPE_AS, EXTENDS_TYPE_OF,
1845 STORAGE_SIZE, C_NULL_PTR and C_NULL_FUNPTR. Modify documentation of
1846 SIZEOF and C_SIZEOF.
1848 2010-07-08 Janus Weil <janus@gcc.gnu.org>
1851 * gfortran.h (gfc_isym_id): Add GFC_ISYM_C_SIZEOF,GFC_ISYM_STORAGE_SIZE.
1852 * intrinsic.h (gfc_check_c_sizeof,gfc_check_storage_size,
1853 gfc_resolve_storage_size): New prototypes.
1854 * check.c (gfc_check_c_sizeof,gfc_check_storage_size): New functions.
1855 * intrinsic.c (add_functions): Add STORAGE_SIZE.
1856 * iresolve.c (gfc_resolve_storage_size): New function.
1857 * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Handle polymorphic
1859 (gfc_conv_intrinsic_storage_size): New function.
1860 (gfc_conv_intrinsic_function): Handle STORAGE_SIZE.
1862 2010-07-08 Jakub Jelinek <jakub@redhat.com>
1865 * match.c (match_exit_cycle): Error on EXIT also from collapsed
1866 !$omp do loops. Error on CYCLE to non-innermost collapsed
1869 2010-07-08 Tobias Burnus <burnus@net-b.de>
1872 * array.c (gfc_match_array_ref): Better error message for
1873 coarrays with too few ranks.
1874 (match_subscript): Move one diagnostic to caller.
1875 * gfortran.h (gfc_get_corank): Add prottype.
1876 * expr.c (gfc_get_corank): New function.
1877 * iresolve.c (resolve_bound): Fix rank for cobounds.
1878 (gfc_resolve_lbound,gfc_resolve_lcobound, gfc_resolve_ubound,
1879 gfc_resolve_ucobound, gfc_resolve_this_image): Update
1882 2010-07-06 Tobias Burnus <burnus@net-b.de>
1885 * array.c (gfc_expand_constructor): Add optional diagnostic.
1886 * gfortran.h (gfc_expand_constructor): Update prototype.
1887 * expr.c (gfc_simplify_expr, check_init_expr,
1888 gfc_reduce_init_expr): Update gfc_expand_constructor call.
1889 * resolve.c (gfc_resolve_expr): Ditto.
1891 2010-07-06 Tobias Burnus <burnus@net-b.de>
1893 * trans-decl.c: Include diagnostic-core.h besides toplev.h.
1894 * trans-intrinsic.c: Ditto.
1895 * trans-types.c: Ditto.
1896 * convert.c: Include diagnostic-core.h instead of toplev.h.
1898 * trans-array.c: Ditto.
1899 * trans-const.c: Ditto.
1900 * trans-expr.c: Ditto.
1901 * trans-io.c: Ditto.
1902 * trans-openmp.c: Ditto.
1905 2010-07-06 Thomas Koenig <tkoenig@gcc.gnu.org>
1908 * check.c (dim_rank_check): Also check intrinsic functions.
1909 Adjust permissible rank for functions which reduce the rank of
1910 their argument. Spread is an exception, where DIM can
1911 be one larger than the rank of array.
1913 2010-07-05 Steven G. Kargl <kargl@gcc.gnu.org>
1916 * fortran/io.c (resolve_tag): Check EXIST tag is a default logical.
1918 2010-07-05 Paul Thomas <pault@gcc.gnu.org>
1921 * trans-types.c (gfc_get_derived_type): Derived type fields
1922 with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set
1923 but build_pointer_type_for_mode must be used for this.
1925 2010-07-05 Nathan Froyd <froydnj@codesourcery.com>
1927 * trans.h (gfc_conv_procedure_call): Take a VEC instead of a tree.
1928 * trans-intrinsic.c (gfc_conv_intrinsic_funcall): Adjust for new
1929 type of gfc_conv_procedure_call.
1930 (conv_generic_with_optional_char_arg): Likewise.
1931 * trans-stmt.c (gfc_trans_call): Likewise.
1932 * trans-expr.c (gfc_conv_function_expr): Likewise.
1933 (gfc_conv_procedure_call): Use build_call_vec instead of
1936 2010-07-04 Daniel Kraft <d@domob.eu>
1938 * gfc-internals.texi (gfc_code): Document BLOCK and ASSOCIATE.
1940 2010-07-04 Paul Thomas <pault@gcc.gnu.org>
1944 * trans-types.c (gfc_get_derived_type): Derived type fields
1945 with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set.
1947 2010-07-02 Mikael Morin <mikael@gcc.gnu.org>
1950 * decl.c (match_procedure_in_type): Clear structure before using.
1951 (gfc_match_generic): Ditto.
1953 2010-07-02 Nathan Froyd <froydnj@codesourcery.com>
1955 * trans-types.h (gfc_add_field_to_struct): Add tree ** parameter.
1956 * trans-types.c (gfc_add_field_to_struct_1): New function, most
1957 of which comes from...
1958 (gfc_add_field_to_struct): ...here. Call it. Add new parameter.
1959 (gfc_get_desc_dim_type): Call gfc_add_field_to_struct_1 for
1961 (gfc_get_array_descriptor_base): Likewise.
1962 (gfc_get_mixed_entry_union): Likewise.
1963 (gfc_get_derived_type): Add extra chain parameter for
1964 gfc_add_field_to_struct.
1965 * trans-stmt.c (gfc_trans_character_select): Likewise.
1966 * trans-io.c (gfc_build_st_parameter): Likewise.
1968 2010-06-29 Janus Weil <janus@gcc.gnu.org>
1971 * resolve.c (is_external_proc): Prevent procedure pointers from being
1972 regarded as external procedures.
1974 2010-06-29 Janus Weil <janus@gcc.gnu.org>
1977 * trans-intrinsic.c (gfc_conv_associated): Handle polymorphic variables
1978 passed as second argument of ASSOCIATED.
1980 2010-06-29 Paul Thomas <pault@gcc.gnu.org>
1983 * trans-expr.c (arrayfunc_assign_needs_temporary): New function
1984 to determine if a function assignment can be made without a
1986 (gfc_trans_arrayfunc_assign): Move all the conditions that
1987 suppress the direct function call to the above new functon and
1990 2010-06-28 Paul Thomas <pault@gcc.gnu.org>
1993 * interface.c (argument_rank_mismatch): New function.
1994 (compare_parameter): Call new function instead of generating
1997 2010-06-28 Nathan Froyd <froydnj@codesourcery.com>
1999 * trans-openmp.c (dovar_init): Define. Define VECs containing it.
2000 (gfc_trans_omp_do): Use a VEC to accumulate variables and their
2003 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
2005 * Make-lang.in: Update dependencies.
2007 2010-06-27 Nathan Froyd <froydnj@codesourcery.com>
2009 * gfortran.h (gfc_code): Split backend_decl field into cycle_label
2010 and exit_label fields.
2011 * trans-openmp.c (gfc_trans_omp_do): Assign to new fields
2013 * trans-stmt.c (gfc_trans_simple_do): Likewise.
2014 (gfc_trans_do): Likewise.
2015 (gfc_trans_do_while): Likewise.
2016 (gfc_trans_cycle): Use cycle_label directly.
2017 (gfc_trans_exit): Use exit_label directly.
2019 2010-06-27 Daniel Kraft <d@domob.eu>
2021 * dump-parse-tree.c (show_symbol): Dump target-expression for
2023 (show_code_node): Make distinction between BLOCK and ASSOCIATE.
2024 (show_namespace): Use show_level for correct indentation of
2025 "inner namespaces" (contained procedures or BLOCK).
2027 2010-06-27 Thomas Koenig <tkoenig@gcc.gnu.org>
2030 * dump-parse-tree.c (show_code_node): Show namespace for
2033 2010-06-26 Tobias Burnus <burnus@net-b.de>
2035 * decl.c (gfc_match_decl_type_spec): Support
2036 TYPE(intrinsic-type-spec).
2038 2010-06-25 Tobias Burnus <burnus@net-b.de>
2040 * intrinsic.h (gfc_check_selected_real_kind,
2041 gfc_simplify_selected_real_kind): Update prototypes.
2042 * intrinsic.c (add_functions): Add radix support to
2044 * check.c (gfc_check_selected_real_kind): Ditto.
2045 * simplify.c (gfc_simplify_selected_real_kind): Ditto.
2046 * trans-decl.c (gfc_build_intrinsic_function_decls):
2047 Change call from selected_real_kind to selected_real_kind2008.
2048 * intrinsic.texi (SELECTED_REAL_KIND): Update for radix.
2049 (PRECISION, RANGE, RADIX): Add cross @refs.
2051 2010-06-25 Tobias Burnus <burnus@net-b.de>
2053 * decl.c (gfc_match_entry): Mark ENTRY as GFC_STD_F2008_OBS.
2054 * gfortran.texi (_gfortran_set_options): Update for
2055 GFC_STD_F2008_OBS addition.
2056 * libgfortran.h: Add GFC_STD_F2008_OBS.
2057 * options.c (set_default_std_flags, gfc_handle_option): Handle
2059 io.c (check_format): Fix allow_std check.
2061 2010-06-25 Tobias Burnus <burnus@net-b.de>
2063 * decl.c (gfc_match_entry): Allow END besides
2064 END SUBROUTINE/END FUNCTION for contained procedures.
2066 2010-06-25 Tobias Burnus <burnus@net-b.de>
2068 * parse.c (next_free, next_fixed): Allow ";" as first character.
2070 2010-06-24 Tobias Burnus <burnus@net-b.de>
2073 * decl.c (variable_decl): Fix IMPORT diagnostic for CLASS.
2075 2010-06-22 Janus Weil <janus@gcc.gnu.org>
2078 * resolve.c (resolve_fl_derived): Avoid checking for abstract on class
2081 2010-06-21 Tobias Burnus <burnus@net-b.de>
2084 * interface.c (compare_parameter): Add gfc_is_simply_contiguous
2086 * symbol.c (gfc_add_contiguous): New function.
2087 (gfc_copy_attr, check_conflict): Handle contiguous attribute.
2088 * decl.c (match_attr_spec): Ditto.
2089 (gfc_match_contiguous): New function.
2090 * resolve.c (resolve_fl_derived, resolve_symbol): Handle
2092 * gfortran.h (symbol_attribute): Add contiguous.
2093 (gfc_is_simply_contiguous): Add prototype.
2094 (gfc_add_contiguous): Add prototype.
2095 * match.h (gfc_match_contiguous): Add prototype.
2096 * parse.c (decode_specification_statement,
2097 decode_statement): Handle contiguous attribute.
2098 * expr.c (gfc_is_simply_contiguous): New function.
2099 * dump-parse-tree.c (show_attr): Handle contiguous.
2100 * module.c (ab_attribute, attr_bits, mio_symbol_attribute):
2102 * trans-expr.c (gfc_add_interface_mapping): Copy
2104 * trans-array.c (gfc_conv_descriptor_stride_get,
2105 gfc_conv_array_parameter): Handle contiguous arrays.
2106 * trans-types.c (gfc_build_array_type, gfc_build_array_type,
2107 gfc_sym_type, gfc_get_derived_type, gfc_get_array_descr_info):
2109 * trans.h (gfc_array_kind): Ditto.
2110 * trans-decl.c (gfc_get_symbol_decl): Ditto.
2112 2010-06-20 Joseph Myers <joseph@codesourcery.com>
2114 * options.c (gfc_handle_option): Don't handle N_OPTS.
2116 2010-06-19 Janus Weil <janus@gcc.gnu.org>
2119 * resolve.c (resolve_fl_derived): Reverse ordering of conditions
2122 2010-06-18 Tobias Burnus <burnus@net-b.de>
2125 * resolve.c (resolve_allocate_deallocate): Properly check
2126 part-refs in stat=/errmsg= for invalid use.
2128 2010-06-17 Janus Weil <janus@gcc.gnu.org>
2131 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
2132 Return directly in case of an error.
2134 2010-06-16 Janus Weil <janus@gcc.gnu.org>
2137 * gfortran.h (gfc_get_typebound_proc): Modified Prototype.
2138 * decl.c (match_procedure_in_type): Give a unique gfc_typebound_proc
2139 structure to each procedure in a procedure list.
2140 * module.c (mio_typebound_proc): Add NULL argument to
2141 'gfc_get_typebound_proc'.
2142 * symbol.c (gfc_get_typebound_proc): Add a new argument, which is used
2143 to initialize the new structure.
2145 2010-06-15 Janus Weil <janus@gcc.gnu.org>
2148 * gfortran.h (gfc_expr): Add new member 'mold'.
2149 * match.c (gfc_match_allocate): Implement the MOLD tag.
2150 * resolve.c (resolve_allocate_expr): Ditto.
2151 * trans-stmt.c (gfc_trans_allocate): Ditto.
2153 2010-06-15 Jakub Jelinek <jakub@redhat.com>
2156 * trans-openmp.c (gfc_omp_predetermined_sharing): Don't return
2157 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with
2158 GFC_DECL_SAVED_DESCRIPTOR set.
2159 (gfc_omp_report_decl): New function.
2160 * trans.h (gfc_omp_report_decl): New prototype.
2161 * f95-lang.c (LANG_HOOKS_OMP_REPORT_DECL): Redefine.
2163 2010-06-13 Daniel Franke <franke.daniel@gmail.com>
2167 * gfortranspec.c (lang_specific_driver): Removed deprecation
2169 * lang.opt: Add options -M, -MM, -MD, -MMD, -MF, -MG, -MP, -MT, -MQ.
2170 * lang-specs.h (CPP_FORWARD_OPTIONS): Add -M* options.
2171 * cpp.h (gfc_cpp_makedep): New.
2172 (gfc_cpp_add_dep): New.
2173 (gfc_cpp_add_target): New.
2174 * cpp.c (gfc_cpp_option): Add deps* members.
2175 (gfc_cpp_makedep): New.
2176 (gfc_cpp_add_dep): New.
2177 (gfc_cpp_add_target): New.
2178 (gfc_cpp_init_options): Initialize new options.
2179 (gfc_cpp_handle_option): Handle new options.
2180 (gfc_cpp_post_options): Map new options to libcpp-options.
2181 (gfc_cpp_init): Handle deferred -MQ and -MT options.
2182 (gfc_cpp_done): If requested, write dependencies to file.
2183 * module.c (gfc_dump_module): Add a module filename as target.
2184 * scanner.c (open_included_file): New parameter system; add the
2185 included file as dependency.
2186 (gfc_open_included_file): Add the included file as dependency.
2187 (gfc_open_intrinsic_module): Likewise.
2188 * invoke.texi: Removed deprecation warning for -M.
2189 * gfortran.texi: Removed Makefile-dependencies project.
2191 2010-06-12 Daniel Franke <franke.daniel@gmail.com>
2193 * resolve.c (resolve_global_procedure): Improved checking if an
2194 explicit interface is required.
2196 2010-06-12 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2198 * trans-decl.c (gfc_build_intrinsic_function_decls): Fix
2200 * trans-intrinsic.c (gfc_conv_intrinsic_fdate): Fix argument type.
2201 (gfc_conv_intrinsic_ttynam): Likewise.
2202 (gfc_conv_intrinsic_trim): Likewise.
2204 2010-06-12 Janus Weil <janus@gcc.gnu.org>
2207 * decl.c (match_procedure_in_type): Allow procedure lists (F08).
2209 2010-06-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2211 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Fix comment.
2213 2010-06-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2215 * mathbuiltins.def: Add builtins that do not directly correspond
2216 to a Fortran intrinsic, with new macro OTHER_BUILTIN.
2217 * f95-lang.c (gfc_init_builtin_functions): Define OTHER_BUILTIN.
2218 * trans-intrinsic.c (gfc_intrinsic_map_t): Remove
2219 code_{r,c}{4,8,10,16} fields. Add
2220 {,complex}{float,double,long_double}_built_in fields.
2221 (gfc_intrinsic_map): Adjust definitions of DEFINE_MATH_BUILTIN,
2222 DEFINE_MATH_BUILTIN_C and LIB_FUNCTION accordingly. Add
2223 definition of OTHER_BUILTIN.
2224 (real_compnt_info): Remove unused struct.
2225 (builtin_decl_for_precision, builtin_decl_for_float_kind): New
2227 (build_round_expr): Call builtin_decl_for_precision instead of
2229 (gfc_conv_intrinsic_aint): Call builtin_decl_for_float_kind
2230 instead of a switch.
2231 (gfc_build_intrinsic_lib_fndecls): Match
2232 {real,complex}{4,8,10,16}decl into the C-style built_in_decls.
2233 (gfc_get_intrinsic_lib_fndecl): Do not hardcode floating-point
2235 (gfc_conv_intrinsic_lib_function): Go through all the extended
2237 (gfc_trans_same_strlen_check): Call builtin_decl_for_float_kind
2238 instead of a switch.
2239 (gfc_conv_intrinsic_abs): Likewise.
2240 (gfc_conv_intrinsic_mod): Likewise.
2241 (gfc_conv_intrinsic_sign): Likewise.
2242 (gfc_conv_intrinsic_fraction): Likewise.
2243 (gfc_conv_intrinsic_nearest): Likewise.
2244 (gfc_conv_intrinsic_spacing): Likewise.
2245 (gfc_conv_intrinsic_rrspacing): Likewise.
2246 (gfc_conv_intrinsic_scale): Likewise.
2247 (gfc_conv_intrinsic_set_exponent): Likewise.
2249 2010-06-11 Paul Thomas <pault@gcc.gnu.org>
2253 * trans-expr.c (gfc_conv_derived_to_class): Handle array-valued
2254 functions with CLASS formal arguments.
2256 2010-06-10 Janus Weil <janus@gcc.gnu.org>
2259 * resolve.c (conformable_arrays): Handle allocatable components.
2261 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2264 * gfortran.texi: Document that Cray pointers cannot be function
2267 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2270 * gfortran.texi: Document lack of support for syntax
2271 "complex FUNCTION name*16()", and existence of alternative
2272 legacy syntax "complex*16 FUNCTION name()".
2274 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2277 * intrinsic.texi (FLUSH): Note the difference between FLUSH and
2278 POSIX's fsync(), and how to call the latter from Fortran code.
2280 2010-06-10 Daniel Franke <franke.daniel@gmail.com>
2283 * interface.c (compare_actual_formal): Reject actual arguments with
2284 array subscript passed to ASYNCHRONOUS dummys.
2286 2010-06-10 Daniel Kraft <d@domob.eu>
2289 * gfortran.h (enum gfc_statement): Add ST_ASSOCIATE, ST_END_ASSOCIATE.
2290 (struct gfc_symbol): New field `assoc'.
2291 (struct gfc_association_list): New struct.
2292 (struct gfc_code): New struct `block' in union, move `ns' there
2293 and add association list.
2294 (gfc_free_association_list): New method.
2295 (gfc_has_vector_subscript): Made public;
2296 * match.h (gfc_match_associate): New method.
2297 * parse.h (enum gfc_compile_state): Add COMP_ASSOCIATE.
2298 * decl.c (gfc_match_end): Handle ST_END_ASSOCIATE.
2299 * interface.c (gfc_has_vector_subscript): Made public.
2300 (compare_actual_formal): Rename `has_vector_subscript' accordingly.
2301 * match.c (gfc_match_associate): New method.
2302 (gfc_match_select_type): Change reference to gfc_code's `ns' field.
2303 * primary.c (match_variable): Don't allow names associated to expr here.
2304 * parse.c (decode_statement): Try matching ASSOCIATE statement.
2305 (case_exec_markers, case_end): Add ASSOCIATE statement.
2306 (gfc_ascii_statement): Hande ST_ASSOCIATE and ST_END_ASSOCIATE.
2307 (parse_associate): New method.
2308 (parse_executable): Handle ST_ASSOCIATE.
2309 (parse_block_construct): Change reference to gfc_code's `ns' field.
2310 * resolve.c (resolve_select_type): Ditto.
2311 (resolve_code): Ditto.
2312 (resolve_block_construct): Ditto and add comment.
2313 (resolve_select_type): Set association list in generated BLOCK to NULL.
2314 (resolve_symbol): Resolve associate names.
2315 * st.c (gfc_free_statement): Change reference to gfc_code's `ns' field
2316 and free association list.
2317 (gfc_free_association_list): New method.
2318 * symbol.c (gfc_new_symbol): NULL new field `assoc'.
2319 * trans-stmt.c (gfc_trans_block_construct): Change reference to
2320 gfc_code's `ns' field.
2322 2010-06-10 Kai Tietz <kai.tietz@onevision.com>
2324 * error.c (error_print): Pre-initialize loc by NULL.
2325 * openmp.c (resolve_omp_clauses): Add explicit
2326 braces to avoid ambigous else.
2327 * array.c (match_subscript): Pre-initialize m to MATCH_ERROR.
2329 2010-06-10 Gerald Pfeifer <gerald@pfeifer.com>
2331 * gfc-internals.texi: Move to GFDL 1.3.
2332 * gfortran.texi: Ditto.
2333 * intrinsic.texi: Ditto.
2334 * invoke.texi: Ditto.
2336 2010-06-09 Daniel Franke <franke.daniel@gmail.com>
2339 * check.c (gfc_check_selected_real_kind): Verify that the
2340 actual arguments are scalar.
2342 2010-06-09 Daniel Franke <franke.daniel@gmail.com>
2345 * intrinsic.c (gfc_convert_type_warn): Further improve -Wconversion.
2347 2010-06-09 Janus Weil <janus@gcc.gnu.org>
2350 * dump-parse-tree.c (show_symbol): Avoid infinite loop.
2352 2010-06-09 Steven G. Kargl <kargl@gcc.gnu.org>
2354 * fortran/symbol.c (check_conflict): Remove an invalid conflict check.
2356 2010-06-09 Steven G. Kargl <kargl@gcc.gnu.org>
2358 * fortran/intrinsic.c (add_functions): Change gfc_check_btest,
2359 gfc_check_ibclr, and gfc_check_ibset to gfc_check_bitfcn.
2360 * fortran/intrinsic.h: Remove prototypes for gfc_check_btest,
2361 gfc_check_ibclr, and gfc_check_ibset. Add prototype for
2363 * fortran/check.c (nonnegative_check, less_than_bitsize1,
2364 less_than_bitsize2): New functions.
2365 (gfc_check_btest): Renamed to gfc_check_bitfcn. Use
2366 nonnegative_check and less_than_bitsize1.
2367 (gfc_check_ibclr, gfc_check_ibset): Removed.
2368 (gfc_check_ibits,gfc_check_mvbits): Use nonnegative_check and
2371 2010-06-09 Janus Weil <janus@gcc.gnu.org>
2374 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
2377 2010-06-09 Kai Tietz <kai.tietz@onevision.com>
2379 * resolve.c (resolve_deallocate_expr): Avoid warning
2380 about possible use of iunitialized sym.
2381 (resolve_allocate_expr): Pre-initialize sym by NULL.
2383 2010-06-09 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2386 * f95-lang.c (gfc_init_builtin_functions): Remove comment.
2388 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
2390 * trans-types.c (gfc_get_nodesc_array_type): Use typed GC
2392 (gfc_get_array_type_bounds): Likewise.
2394 * trans-decl.c (gfc_allocate_lang_decl): Likewise.
2395 (gfc_find_module): Likewise.
2397 * f95-lang.c (pushlevel): Likewise.
2399 * trans.h (struct lang_type): Add variable_size GTY option.
2400 (struct lang_decl): Likewise.
2402 2010-06-08 Tobias Burnus <burnus@net-b.de>
2405 * symbol.c (check_conflict): Move protected--external/procedure check ...
2406 * resolve.c (resolve_select_type): ... to the resolution stage.
2408 2010-06-07 Tobias Burnus <burnus@net-b.de>
2410 * options.c (gfc_handle_option): Fix -fno-recursive.
2412 2010-06-07 Tobias Burnus <burnus@net-b.de>
2414 * gfc-internals.texi (copyrights-gfortran): Fix copyright year format.
2415 * gfortran.texi (copyrights-gfortran): Ditto.
2417 2010-06-07 Joseph Myers <joseph@codesourcery.com>
2419 * lang.opt (fshort-enums): Define using Var and VarExists.
2420 * options.c (gfc_handle_option): Don't set flag_short_enums here.
2422 2010-06-05 Paul Thomas <pault@gcc.gnu.org>
2423 Janus Weil <janus@gcc.gnu.org>
2426 * resolve.c (get_declared_from_expr): Move to before
2427 resolve_typebound_generic_call. Make new_ref and class_ref
2428 ignorable if set to NULL.
2429 (resolve_typebound_generic_call): Once we have resolved the
2430 generic call, check that the specific instance is that which
2431 is bound to the declared type.
2432 (resolve_typebound_function,resolve_typebound_subroutine): Avoid
2433 freeing 'class_ref->next' twice.
2435 2010-06-05 Paul Thomas <pault@gcc.gnu.org>
2438 * trans-array.c (structure_alloc_comps): Dereference scalar
2439 'decl' if it is a REFERENCE_TYPE. Tidy expressions containing
2442 2010-06-04 Joseph Myers <joseph@codesourcery.com>
2444 * gfortranspec.c (append_arg, lang_specific_driver): Use
2445 GCC-specific formats in diagnostics.
2447 2010-06-02 Tobias Burnus <burnus@net-b.de>
2450 * parse.c (gfc_fixup_sibling_symbols): Do not "fix" use-associated
2453 2010-06-01 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2456 * match.c (gfc_match_stopcode): Move gfc_match_eos call inside
2459 2010-05-31 Steven G. Kargl <kargl@gcc.gnu.org>
2461 * fortran/gfortran.texi: Fix typos in description of variable-format-
2464 2010-05-31 Thomas Koenig <tkoenig@gcc.gnu.org>
2467 * dependency.c (gfc_check_section_vs_section): Check
2468 for interleaving array assignments without conflicts.
2470 2010-05-30 Janus Weil <janus@gcc.gnu.org>
2472 * gcc/fortran/gfortran.h (CLASS_DATA): New macro for accessing the
2473 $data component of a class container.
2474 * gcc/fortran/decl.c (attr_decl1): Use macro CLASS_DATA.
2475 * gcc/fortran/expr.c (gfc_check_pointer_assign,gfc_check_assign_symbol,
2476 gfc_has_ultimate_allocatable,gfc_has_ultimate_pointer): Ditto.
2477 * gcc/fortran/interface.c (matching_typebound_op): Ditto.
2478 * gcc/fortran/match.c (gfc_match_allocate, gfc_match_deallocate): Ditto.
2479 * gcc/fortran/parse.c (parse_derived): Ditto.
2480 * gcc/fortran/primary.c (gfc_match_varspec, gfc_variable_attr,
2481 gfc_expr_attr): Ditto.
2482 * gcc/fortran/resolve.c (resolve_structure_cons, find_array_spec,
2483 resolve_deallocate_expr, resolve_allocate_expr, resolve_select_type,
2484 resolve_fl_var_and_proc, resolve_typebound_procedure,
2485 resolve_fl_derived): Ditto.
2486 * gcc/fortran/symbol.c (gfc_type_compatible): Restructured.
2487 * gcc/fortran/trans-array.c (structure_alloc_comps): Use macro
2489 * gcc/fortran/trans-decl.c (gfc_get_symbol_decl,
2490 gfc_trans_deferred_vars): Ditto.
2491 * gcc/fortran/trans-stmt.c (gfc_trans_allocate): Ditto.
2493 2010-05-28 Tobias Burnus <burnus@net-b.de>
2495 * options.c (gfc_handle_option): Fix handling of -fno-whole-file.
2497 2010-05-28 Joseph Myers <joseph@codesourcery.com>
2499 * gfortranspec.c (append_arg, lang_specific_driver): Use
2500 fatal_error instead of fatal. Use warning instead of fprintf for
2503 2010-05-28 Joseph Myers <joseph@codesourcery.com>
2505 * cpp.c (gfc_cpp_init_0): Use xstrerror instead of strerror.
2506 * module.c (write_char, gfc_dump_module, gfc_use_module): Use
2507 xstrerror instead of strerror.
2509 2010-05-26 Joseph Myers <joseph@codesourcery.com>
2511 * cpp.c (cb_cpp_error): Save and restore
2512 global_dc->warn_system_headers, not variable warn_system_headers.
2514 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
2516 * fortran/f95-lang.c: Do not include libfuncs.h, expr.h, and except.h.
2518 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
2520 * trans-common.c: Do not include rtl.h, include output.h instead.
2521 * trans-decl.c: Likewise.
2523 2010-05-26 Paul Thomas <pault@gcc.gnu.org>
2526 * resolve.c (resolve_global_procedure): Resolve the gsymbol's
2527 namespace before trying to reorder the gsymbols.
2529 2010-05-25 Daniel Franke <franke.daniel@gmail.com>
2534 * resolve.c (resolve_global_procedure): Add check for global
2535 procedures with implicit interfaces and assumed-shape or optional
2536 dummy arguments. Verify that function return type, kind and string
2539 2010-05-21 Tobias Burnus <burnus@net-b.de>
2541 * gfortran.h: Do not include system.h.
2542 * bbt.c: Include system.h.
2544 * dependency.c: Ditto.
2545 * dump-parse-tree.c: Ditto.
2546 * arith.h: Do not include gfortran.h.
2547 * constructor.h: Do not include gfortran.h and splay-tree.h.
2548 * match.h: Do not include gfortran.h.
2550 * target-memory.h: Ditto.
2551 * openmp.c: Do not include toplev.h and target.h.
2552 * trans-stmt.c: Ditto not include toplev.h.
2554 * trans-common.c: Tell why toplev.h is needed. And
2555 do not include target.h.
2556 * trans-expr.c: Tell why toplev.h is needed.
2557 * trans-array.c: Ditto.
2558 * trans-openmp.c: Ditto.
2559 * trans-const.c: Ditto.
2561 * trans-types.c: Ditto.
2562 * trans-io.c: Ditto.
2563 * trans-decl.c: Ditto.
2566 * trans-intrinsic.c: Ditto.
2569 2010-05-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2572 * match.c (gfc_match_stopcode): Use gfc_match_init_expr. Go to cleanup
2573 before returning MATCH_ERROR. Add check for scalar. Add check for
2574 default integer kind.
2576 2010-05-22 Janus Weil <janus@gcc.gnu.org>
2579 * match.c (gfc_match_select_type): On error jump back out of the local
2581 * parse.c (parse_derived): Defer creation of vtab symbols to resolution
2582 stage, more precisely to ...
2583 * resolve.c (resolve_fl_derived): ... this place.
2585 2010-05-22 Janus Weil <janus@gcc.gnu.org>
2588 * resolve.c (ensure_not_abstract): Allow abstract types with
2589 non-abstract ancestors.
2591 2010-05-21 Steven Bosscher <steven@gcc.gnu.org>
2593 * trans-const.c: Include realmpfr.h.
2594 * Make-lang.in: Update dependencies.
2596 2010-05-21 Steven Bosscher <steven@gcc.gnu.org>
2598 * trans-const.c, trans-types.c, trans-intrinsic.c:
2599 Clean up redundant includes.
2601 2010-05-20 Daniel Franke <franke.daniel@gmail.com>
2604 * lang.opt (Wunused-dummy-argument): New option.
2605 * gfortran.h (gfc_option_t): Add warn_unused_dummy_argument.
2606 * options.c (gfc_init_options): Disable warn_unused_dummy_argument.
2607 (set_Wall): Enable warn_unused_dummy_argument.
2608 (gfc_handle_option): Set warn_unused_dummy_argument according to
2610 * trans-decl.c (generate_local_decl): Separate warnings about
2611 unused variables and unused dummy arguments.
2612 * invoke.texi: Documented new option.
2614 2010-05-20 Steven Bosscher <steven@gcc.gnu.org>
2616 * trans-expr.c: Do not include convert.h, ggc.h, real.h, and gimple.h.
2617 (gfc_conv_string_tmp): Do not assert type comparibilty.
2618 * trans-array.c: Do not include gimple.h, ggc.h, and real.h.
2619 (gfc_conv_expr_descriptor): Remove assert.
2620 * trans-common.c: Clarify why rtl.h and tm.h are included.
2621 * trans-openmp.c: Do not include ggc.h and real.h.
2622 Explain why gimple.h is included.
2623 * trans-const.c: Do not include ggc.h.
2624 * trans-stmt.c: Do not include gimple.h, ggc.h, and real.h.
2625 * trans.c: Do not include ggc.h and real.h.
2626 Explain why gimple.h is included.
2627 * trans-types.c: Do not include tm.h. Explain why langhooks.h
2628 and dwarf2out.h are included.
2629 * trans-io.c: Do not include gimple.h and real.h.
2630 * trans-decl.c: Explain why gimple.h, tm.h, and rtl.h are included.
2631 * trans-intrinsic.c: Do not include gimple.h. Explain why tm.h
2634 2010-05-20 Tobias Burnus <burnus@net-b.de>
2636 * options.c (gfc_init_options,gfc_post_options): Enable
2637 flag_associative_math by default.
2639 2010-05-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2642 * trans-stmt.c (gfc_trans_stop): Add generation of call to
2643 gfortran_error_stop_numeric. Fix up some whitespace. Use stop_string for
2644 blank STOP, handling a null expression. (gfc_trans_pause): Use
2645 pause_string for blank PAUSE.
2646 * trans.h: Add external function declaration for error_stop_numeric.
2647 * trans-decl.c (gfc_build_builtin_function_decls): Add the building of
2648 the declaration for the library call. Adjust whitespaces.
2649 * match.c (gfc_match_stopcode): Remove use of the actual stop code to
2650 signal no stop code. Match the expression following the stop and pass
2651 that to the translators. Remove the old use of digit matching. Add
2652 checks that the stop_code expression is INTEGER or CHARACTER, constant,
2653 and if CHARACTER, default character KIND.
2655 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
2658 * lang.opt (Wconversion-extra): New option.
2659 * gfortran.h (gfc_option_t): Add warn_conversion_extra.
2660 * options.c (gfc_init_options): Disable -Wconversion-extra by default.
2661 (set_Wall): Enable -Wconversion.
2662 (gfc_handle_option): Set warn_conversion_extra.
2663 * intrinsic.c (gfc_convert_type_warn): Ignore kind conditions
2664 introduced for -Wconversion if -Wconversion-extra is present.
2665 * invoke.texi: Add -Wconversion to -Wall; document new behaviour of
2666 -Wconversion; document -Wconversion-extra.
2668 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
2671 * gfortran.h (gfc_has_default_initializer): New.
2672 * expr.c (gfc_has_default_initializer): New.
2673 * resolve.c (has_default_initializer): Removed, use
2674 gfc_has_default_initializer() instead. Updated all callers.
2675 * trans-array.c (has_default_initializer): Removed, use
2676 gfc_has_default_initializer() instead. Updated all callers.
2677 * trans-decl.c (generate_local_decl): Do not check the
2678 first component only to check for initializers, but use
2679 gfc_has_default_initializer() instead.
2681 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
2684 * primary.c (match_string_constant): Move start_locus just inside
2686 * data.c (create_character_intializer): Clarified truncation warning.
2688 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
2691 * intrinsic.h (gfc_check_float): New prototype.
2692 (gfc_check_sngl): New prototype.
2693 * check.c (gfc_check_float): New.
2694 (gfc_check_sngl): New.
2695 * intrinsic.c (add_functions): Moved DFLOAT from aliasing DBLE
2696 to be a specific for REAL. Added check routines for FLOAT, DFLOAT
2698 * intrinsic.texi: Removed individual nodes of FLOAT, DFLOAT and SNGL,
2699 added them to the list of specifics of REAL instead.
2701 2010-05-17 Janus Weil <janus@gcc.gnu.org>
2704 * trans-expr.c (gfc_conv_structure): Remove unneeded and buggy code.
2705 This is now handled via 'gfc_class_null_initializer'.
2707 2010-05-17 Janus Weil <janus@gcc.gnu.org>
2709 * class.c (gfc_add_component_ref,gfc_class_null_initializer,
2710 gfc_build_class_symbol,add_proc_component,add_proc_comps,
2711 add_procs_to_declared_vtab1,copy_vtab_proc_comps,
2712 add_procs_to_declared_vtab,add_generic_specifics,
2713 add_generics_to_declared_vtab,gfc_find_derived_vtab,
2714 find_typebound_proc_uop,gfc_find_typebound_proc,
2715 gfc_find_typebound_user_op,gfc_find_typebound_intrinsic_op,
2716 gfc_get_tbp_symtree): Moved here from other places.
2717 * expr.c (gfc_add_component_ref,gfc_class_null_initializer): Move to
2719 * gfortran.h (gfc_build_class_symbol,gfc_find_derived_vtab,
2720 gfc_find_typebound_proc,gfc_find_typebound_user_op,
2721 gfc_find_typebound_intrinsic_op,gfc_get_tbp_symtree,
2722 gfc_add_component_ref, gfc_class_null_initializer): Moved to class.c.
2723 * Make-lang.in: Add class.o.
2724 * symbol.c (gfc_build_class_symbol,add_proc_component,add_proc_comps,
2725 add_procs_to_declared_vtab1,copy_vtab_proc_comps,
2726 add_procs_to_declared_vtab,add_generic_specifics,
2727 add_generics_to_declared_vtab,gfc_find_derived_vtab,
2728 find_typebound_proc_uop,gfc_find_typebound_proc,
2729 gfc_find_typebound_user_op,gfc_find_typebound_intrinsic_op,
2730 gfc_get_tbp_symtree): Move to class.c.
2732 2010-05-17 Nathan Froyd <froydnj@codesourcery.com>
2734 * trans-types.c (gfc_init_types): Use build_function_type_list.
2735 (gfc_get_ppc_type): Likewise.
2736 * trans-decl.c (gfc_generate_constructors): Likewise.
2737 * f95-lang.c (build_builtin_fntypes): Likewise.
2738 (gfc_init_builtin_functions): Likewise.
2739 (DEF_FUNCTION_TYPE_0): Likewise.
2740 (DEF_FUNCTION_TYPE_1): Likewise.
2741 (DEF_FUNCTION_TYPE_2): Likewise.
2742 (DEF_FUNCTION_TYPE_3): Likewise.
2743 (DEF_FUNCTION_TYPE_4): Likewise.
2744 (DEF_FUNCTION_TYPE_5): Likewise.
2745 (DEF_FUNCTION_TYPE_6): Likewise.
2746 (DEF_FUNCTION_TYPE_7): Likewise. Use ARG7.
2747 (DEF_FUNCTION_TYPE_VAR_0): Use build_varags_function_type_list.
2749 2010-05-17 Nathan Froyd <froydnj@codesourcery.com>
2751 * trans-array.c (gfc_trans_array_constructor_value): Use
2752 build_constructor instead of build_constructor_from_list.
2753 (gfc_build_constant_array_constructor): Likewise.
2754 * trans-decl.c (create_main_function): Likewise.
2755 * trans-stmt.c (gfc_trans_character_select): Likewise.
2757 2010-05-17 Janus Weil <janus@gcc.gnu.org>
2760 * resolve.c (resolve_fl_var_and_proc): Move error messages here from ...
2761 (resolve_fl_variable_derived): ... this place.
2762 (resolve_symbol): Make sure function symbols (and their result
2763 variables) are not resolved twice.
2765 2010-05-16 Daniel Franke <franke.daniel@gmail.com>
2768 * array.c (match_array_list): Revert change from 2010-05-13.
2770 2010-05-16 Richard Guenther <rguenther@suse.de>
2772 * trans-decl.c (module_htab_decls_hash): Revert last change.
2774 2010-05-16 Richard Guenther <rguenther@suse.de>
2776 * trans-decl.c (module_htab_decls_hash): Use IDENTIFIER_HASH_VALUE.
2778 2010-05-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
2780 * options.c (set_Wall): Remove special logic for Wuninitialized
2783 2010-05-15 Janus Weil <janus@gcc.gnu.org>
2787 * trans-decl.c (gfc_trans_deferred_vars): Modify ordering of
2790 2010-05-15 Janus Weil <janus@gcc.gnu.org>
2794 * gfortran.h (gfc_class_null_initializer): New prototype.
2795 * expr.c (gfc_class_null_initializer): New function to build a NULL
2796 initializer for CLASS pointers.
2797 * symbol.c (gfc_build_class_symbol): Modify internal naming of class
2798 containers. Remove default NULL initialization of $data component.
2799 * trans.c (gfc_allocate_array_with_status): Fix wording of an error
2801 * trans-expr.c (gfc_conv_initializer,gfc_trans_subcomponent_assign):
2802 Use new function 'gfc_class_null_initializer'.
2803 * trans-intrinsic.c (gfc_conv_allocated): Handle allocatable scalar
2806 2010-05-14 Steven G. Kargl <kargl@gcc.gnu.org>
2809 * fortran/interface.c (get_sym_storage_size): Use signed instead of
2810 unsigned mpz_get_?i routines.
2812 2010-05-14 Jakub Jelinek <jakub@redhat.com>
2814 * trans.c (trans_code): Set backend locus early.
2815 * trans-decl.c (gfc_get_fake_result_decl): Use source location
2816 of the function instead of current input_location.
2818 2010-05-13 Daniel Franke <franke.daniel@gmail.com>
2821 * intrinsic.c (gfc_init_expr): Renamed to gfc_init_expr_flag.
2823 * expr.c (init_flag): Removed; use gfc_init_expr_flag everywhere.
2824 * array.c (match_array_list): Pass on gfc_init_expr_flag when matching
2827 2010-05-13 Jakub Jelinek <jakub@redhat.com>
2830 * openmp.c (resolve_omp_clauses): Allow procedure pointers in clause
2832 * trans-openmp.c (gfc_omp_privatize_by_reference): Don't privatize
2833 by reference dummy procedures or non-dummy procedure pointers.
2834 (gfc_omp_predetermined_sharing): Return
2835 OMP_CLAUSE_DEFAULT_FIRSTPRIVATE for dummy procedures.
2837 2010-05-11 Daniel Franke <franke.daniel@gmail.com>
2840 * openmp.c (gfc_match_omp_taskwait): Report unexpected characters
2841 after OMP statement.
2842 (gfc_match_omp_critical): Likewise.
2843 (gfc_match_omp_flush): Likewise.
2844 (gfc_match_omp_workshare): Likewise.
2845 (gfc_match_omp_master): Likewise.
2846 (gfc_match_omp_ordered): Likewise.
2847 (gfc_match_omp_atomic): Likewise.
2848 (gfc_match_omp_barrier): Likewise.
2849 (gfc_match_omp_end_nowait): Likewise.
2851 2010-05-11 Daniel Franke <franke.daniel@gmail.com>
2854 * resolve.c (validate_case_label_expr): Removed FIXME.
2855 (resolve_select): Raise default warning on case labels out of range
2856 of the case expression.
2858 2010-05-10 Daniel Franke <franke.daniel@gmail.com>
2863 * intrinsic.c (gfc_convert_type_warn): Be more discriminative
2864 about conversion warnings.
2866 2010-05-10 Janus Weil <janus@gcc.gnu.org>
2869 * match.c (gfc_match_select_type): Move error message to
2870 resolve_select_type.
2871 * resolve.c (resolve_select_type): Error message moved here from
2872 gfc_match_select_type. Correctly set type of temporary.
2874 2010-05-10 Richard Guenther <rguenther@suse.de>
2876 * trans-decl.c (gfc_build_library_function_decl): Split out
2878 (build_library_function_decl_1): ... this new function.
2879 Set a fnspec attribute if a specification was provided.
2880 (gfc_build_library_function_decl_with_spec): New function.
2881 (gfc_build_intrinsic_function_decls): Annotate internal_pack
2882 and internal_unpack.
2884 2010-05-07 Daniel Franke <franke.daniel@gmail.com>
2887 * intrinc.c (gfc_is_intrinsic): Do not prematurely mark symbol
2890 2010-05-07 Jason Merrill <jason@redhat.com>
2892 * trans-expr.c (gfc_conv_procedure_call): Rename nullptr to null_ptr
2893 to avoid -Wc++-compat warning.
2895 2010-05-06 Manuel López-Ibáñez <manu@gcc.gnu.org>
2898 * options.c (gfc_handle_option): Add argument kind.
2899 * gfortran.h (gfc_handle_option): Update declaration.
2901 2010-05-06 Tobias Burnus <burnus@net-b.de>
2904 * trans-types.c (gfc_sym_type): Mark Cray pointees as
2907 2010-05-05 Daniel Franke <franke.daniel@gmail.com>
2910 * resolve.c (traverse_data_list): Rephrase error message for
2911 non-constant bounds in data-implied-do.
2913 2010-05-05 Daniel Franke <franke.daniel@gmail.com>
2916 * gfortran.h: Removed repeat count from constructor, removed
2918 * data.h (gfc_assign_data_value_range): Changed return value from
2920 * data.c (gfc_assign_data_value): Add location to constructor element.
2921 (gfc_assign_data_value_range): Call gfc_assign_data_value()
2922 for each element in range. Return early if an error was generated.
2923 * resolve.c (check_data_variable): Stop early if range assignment
2926 2010-05-05 Janus Weil <janus@gcc.gnu.org>
2929 * resolve.c (resolve_fl_derived): Some fixes for class variables.
2930 * symbol.c (gfc_build_class_symbol): Add separate class container for
2933 2010-05-03 Steven G. Kargl <kargl@gcc.gnu.org>
2936 * fortran/parse.c (parse_interface): Do not dereference a NULL pointer.
2938 2010-05-02 Tobias Burnus <burnus@net-b.de>
2941 * intrinsic.c (add_functions): Fix GFC_STD and add gfc_resolve_ calls
2942 for lcobound, ucobound, image_index and this_image.
2943 * intrinsic.h (gfc_resolve_lcobound, gfc_resolve_this_image,
2944 gfc_resolve_image_index, gfc_resolve_ucobound): New prototypes.
2945 * iresolve.c (gfc_resolve_lcobound, gfc_resolve_this_image,
2946 gfc_resolve_image_index, gfc_resolve_ucobound, resolve_bound): New
2948 (gfc_resolve_lbound, gfc_resolve_ubound): Use resolve_bound.
2950 2010-04-30 Tobias Burnus <burnus@net-b.de>
2954 * trans-types.c (gfc_get_array_descriptor_base): Fix index
2955 calculation for array descriptor types.
2957 2010-04-29 Janus Weil <janus@gcc.gnu.org>
2960 * symbol.c (add_proc_component,copy_vtab_proc_comps): Remove
2961 initializers for PPC members of the vtabs.
2963 2010-04-29 Janus Weil <janus@gcc.gnu.org>
2966 * symbol.c (add_proc_component,add_proc_comps): Correctly set the 'ppc'
2967 attribute for all PPC members of the vtypes.
2968 (copy_vtab_proc_comps): Copy the correct interface.
2969 * trans.h (gfc_trans_assign_vtab_procs): Modified prototype.
2970 * trans-expr.c (gfc_trans_assign_vtab_procs): Pass the derived type as
2971 a dummy argument and make sure all PPC members of the vtab are
2972 initialized correctly.
2973 (gfc_conv_derived_to_class,gfc_trans_class_assign): Additional argument
2974 in call to gfc_trans_assign_vtab_procs.
2975 * trans-stmt.c (gfc_trans_allocate): Ditto.
2977 2010-04-29 Paul Thomas <pault@gcc.gnu.org>
2980 * resolve.c (resolve_typebound_function): Renamed
2981 resolve_class_compcall.Do all the detection of class references
2983 (resolve_typebound_subroutine): resolve_class_typebound_call
2984 renamed. Otherwise same as resolve_typebound_function.
2985 (gfc_resolve_expr): Call resolve_typebound_function.
2986 (resolve_code): Call resolve_typebound_subroutine.
2988 2010-04-29 Janus Weil <janus@gcc.gnu.org>
2991 * resolve.c (resolve_typebound_generic_call): For CLASS methods
2992 pass back the specific symtree name, rather than the target
2995 2010-04-29 Paul Thomas <pault@gcc.gnu.org>
2998 * resolve.c (resolve_structure_cons): Make the initializer of
2999 the vtab component 'extends' the same type as the component.
3001 2010-04-29 Jerry DeLisle <jvdelisle@gcc.gnu.org>
3004 * interface.c (check_interface1): Pass symbol name rather than NULL to
3005 gfc_compare_interfaces.(gfc_compare_interfaces): Add assert to
3006 trap MULL. (gfc_compare_derived_types): Revert previous change
3007 incorporated incorrectly during merge from trunk, r155778.
3008 * resolve.c (check_generic_tbp_ambiguity): Pass symbol name rather
3009 than NULL to gfc_compare_interfaces.
3010 * symbol.c (add_generic_specifics): Likewise.
3012 2010-02-29 Janus Weil <janus@gcc.gnu.org>
3015 * interface.c (gfc_compare_derived_types): Add condition for vtype.
3016 * symbol.c (gfc_find_derived_vtab): Sey access to private.
3017 (gfc_find_derived_vtab): Likewise.
3018 * module.c (ab_attribute): Add enumerator AB_VTAB.
3019 (mio_symbol_attribute): Use new attribute, AB_VTAB.
3020 (check_for_ambiguous): Likewise.
3022 2010-04-29 Paul Thomas <pault@gcc.gnu.org>
3023 Janus Weil <janus@gcc.gnu.org>
3026 * trans-expr.c (select_class_proc): Remove function.
3027 (conv_function_val): Delete reference to previous.
3028 (gfc_conv_derived_to_class): Add second argument to the call to
3029 gfc_find_derived_vtab.
3030 (gfc_conv_structure): Exclude proc_pointer components when
3031 accessing $data field of class objects.
3032 (gfc_trans_assign_vtab_procs): New function.
3033 (gfc_trans_class_assign): Add second argument to the call to
3034 gfc_find_derived_vtab.
3035 * symbol.c (gfc_build_class_symbol): Add delayed_vtab arg and
3036 implement holding off searching for the vptr derived type.
3037 (add_proc_component): New function.
3038 (add_proc_comps): New function.
3039 (add_procs_to_declared_vtab1): New function.
3040 (copy_vtab_proc_comps): New function.
3041 (add_procs_to_declared_vtab): New function.
3042 (void add_generic_specifics): New function.
3043 (add_generics_to_declared_vtab): New function.
3044 (gfc_find_derived_vtab): Add second argument to the call to
3045 gfc_find_derived_vtab. Add the calls to
3046 add_procs_to_declared_vtab and add_generics_to_declared_vtab.
3047 * decl.c (build_sym, build_struct): Use new arg in calls to
3048 gfc_build_class_symbol.
3049 * gfortran.h : Add vtype bitfield to symbol_attr. Remove the
3050 definition of struct gfc_class_esym_list. Modify prototypes
3051 of gfc_build_class_symbol and gfc_find_derived_vtab.
3052 * trans-stmt.c (gfc_trans_allocate): Add second argument to the
3053 call to gfc_find_derived_vtab.
3054 * module.c : Add the vtype attribute.
3055 * trans.h : Add prototype for gfc_trans_assign_vtab_procs.
3056 * resolve.c (resolve_typebound_generic_call): Add second arg
3057 to pass along the generic name for class methods.
3058 (resolve_typebound_call): The same.
3059 (resolve_compcall): Use the second arg to carry the generic
3060 name from the above. Remove the reference to class_esym.
3061 (check_members, check_class_members, resolve_class_esym,
3062 hash_value_expr): Remove functions.
3063 (resolve_class_compcall, resolve_class_typebound_call): Modify
3064 to use vtable rather than member by member calls.
3065 (gfc_resolve_expr): Modify second arg in call to
3067 (resolve_select_type): Add second arg in call to
3068 gfc_find_derived_vtab.
3069 (resolve_code): Add second arg in call resolve_typebound_call.
3070 (resolve_fl_derived): Exclude vtypes from check for late
3071 procedure definitions. Likewise for checking of explicit
3072 interface and checking of pass arg.
3073 * iresolve.c (gfc_resolve_extends_type_of): Add second arg in
3074 calls to gfc_find_derived_vtab.
3075 * match.c (select_type_set_tmp): Use new arg in call to
3076 gfc_build_class_symbol.
3077 * trans-decl.c (gfc_get_symbol_decl): Complete vtable if
3079 * parse.c (endType): Finish incomplete classes.
3081 2010-04-28 Tobias Burnus <burnus@net-b.de>
3085 * simplify.c (simplify_cobound): Handle scalar coarrays.
3087 2010-04-27 Tobias Burnus <burnus@net-b.de>
3089 * gfc-internals.texi: Update copyright year.
3090 * gfortran.texi: Ditto.
3091 * invoke.texi: Ditto.
3093 2010-04-27 Tobias Burnus <burnus@net-b.de>
3096 * resolve.c (resolve_allocate_expr): Allow array coarrays.
3097 * trans-types.h (gfc_get_array_type_bounds): Update prototype.
3098 * trans-types.c (gfc_get_array_type_bounds,
3099 gfc_get_array_descriptor_base): Add corank argument.
3100 * trans-array.c (gfc_array_init_size): Handle corank.
3101 (gfc_trans_create_temp_array, gfc_array_allocate,
3102 gfc_conv_expr_descriptor): Add corank argument to call.
3103 * trans-stmt.c (gfc_trans_pointer_assign_need_temp): Ditto.
3105 2010-04-24 Steven G. Kargl <kargl@gcc.gnu.org>
3109 * trans-array.c (gfc_trans_array_bound_check): Use TREE_CODE instead
3110 of mucking with a tree directly.
3112 2010-04-24 Jerry DeLisle <jvdelisle@gcc.gnu.org>
3115 * io.c (gfc_match_open): Remove branch to syntax error. Add call to
3116 gfc_error with new error message.
3118 2010-04-24 Paul Thomas <pault@gcc.gnu.org>
3122 * trans-expr.c (gfc_conv_expr): Supply an address expression for
3124 (gfc_conv_expr_reference): Call gfc_conv_expr and return for
3126 * trans-array.c (gfc_add_loop_ss_code): Store the value rather
3127 than the address of a GFC_SS_REFERENCE.
3128 * trans.h : Change comment on GFC_SS_REFERENCE.
3130 2010-04-22 Richard Guenther <rguenther@suse.de>
3133 * resolve.c (gfc_resolve_index): Wrap around ...
3134 (gfc_resolve_index_1): ... this. Add parameter to allow
3135 any integer kind index type.
3136 (resolve_array_ref): Allow any integer kind for the start
3137 index of an array ref.
3139 2010-04-21 Jakub Jelinek <jakub@redhat.com>
3142 * f95-lang.c (gfc_define_builtin): Set TREE_NOTHROW on
3145 2010-04-20 Harald Anlauf <anlauf@gmx.de>
3147 * intrinsic.c (sort_actual): Remove 'is' in error message.
3149 2010-04-20 Paul Thomas <pault@gcc.gnu.org>
3152 * resolve.c (resolve_fl_derived): If a component character
3153 length has not been resolved, do so now.
3154 (resolve_symbol): The same as above for a symbol character
3156 * trans-decl.c (gfc_create_module_variable): A 'length' decl is
3157 not needed for a character valued, procedure pointer.
3160 * resolve.c (ensure_not_abstract_walker): If 'overriding' is
3161 not found, return FAILURE rather than ICEing.
3163 2010-04-19 Jakub Jelinek <jakub@redhat.com>
3166 * openmp.c (gfc_resolve_do_iterator): Only make iteration vars for
3167 sequential loops private in the innermost containing task region.
3169 2010-04-18 Eric Botcazou <ebotcazou@adacore.com>
3171 * f95-lang.c (gfc_init_decl_processing): Remove second argument in call
3172 to build_common_tree_nodes.
3174 2010-04-17 Steven G. Kargl <kargl@gcc.gnu.org>
3177 * fortran/trans-array.c (gfc_conv_ss_startstride): Remove the use of
3178 gfc_msg_bounds by using 'Array bound mismatch' directly.
3179 (gfc_trans_dummy_array_bias): Remove the use of gfc_msg_bounds. Reword
3180 error message to include the mismatch in the extent of array bound.
3181 * fortran/trans.c: Remove gfc_msg_bounds. It is only used in one place.
3182 * fortran/trans.h: Remove extern definition of gfc_msg_bounds.
3184 2010-04-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
3186 * gfortran.texi: Update information on temporary file locations.
3188 2010-04-16 Jakub Jelinek <jakub@redhat.com>
3190 * trans-decl.c (gfc_build_qualified_array): Ensure
3191 ubound.N and lbound.N artificial variable names don't appear
3194 2010-04-15 Steven G. Kargl <kargl@gcc.gnu.org>
3197 * trans-array.c (gfc_trans_array_bound_check): Eliminate a redundant
3198 block of code. Set name to the variable associated with the descriptor.
3200 2010-04-15 Jakub Jelinek <jakub@redhat.com>
3202 * trans-decl.c (gfc_build_qualified_array): Clear DECL_IGNORED_P
3203 on VAR_DECL LBOUND and/or UBOUND, even for -O1.
3205 2010-04-14 Steven G. Kargl <kargl@gcc.gnu.org>
3207 * intrinsic.texi: Add the missing specific name of intrinsic
3208 procedure where the specific name is identical to the generic name.
3209 Fix inconsistent or mismatch in the argument names in intrinsic
3210 procedure descriptions. Add the SCALAR allocatable description to
3213 2010-04-14 Tobias Burnus <burnus@net-b.de>
3216 * array.c (gfc_find_array_ref): Handle codimensions.
3217 (gfc_match_array_spec,gfc_match_array_ref): Use gfc_fatal_error.
3218 * check.c (is_coarray, dim_corank_check, gfc_check_lcobound,
3219 gfc_check_image_index, gfc_check_this_image, gfc_check_ucobound):
3221 * gfortran.h (gfc_isym_id): Add GFC_ISYM_IMAGE_INDEX,
3222 GFC_ISYM_LCOBOUND, GFC_ISYM_THIS_IMAGE,
3224 * intrinsic.h (add_functions): Add this_image, image_index,
3225 lcobound and ucobound intrinsics.
3226 * intrinsic.c (gfc_check_lcobound,gfc_check_ucobound,
3227 gfc_check_image_index, gfc_check_this_image,
3228 gfc_simplify_image_index, gfc_simplify_lcobound,
3229 gfc_simplify_this_image, gfc_simplify_ucobound):
3230 New function prototypes.
3231 * intrinsic.texi (IMAGE_INDEX, LCOBOUND, THIS_IMAGE
3232 IMAGE_INDEX): Document new intrinsic functions.
3233 * match.c (gfc_match_critical, sync_statement): Make -fcoarray=none
3235 * simplify.c (simplify_bound_dim): Handle coarrays.
3236 (simplify_bound): Update simplify_bound_dim call.
3237 (gfc_simplify_num_images): Add -fcoarray=none check.
3238 (simplify_cobound, gfc_simplify_lcobound, gfc_simplify_ucobound,
3239 gfc_simplify_ucobound, gfc_simplify_ucobound): New functions.
3241 2010-04-14 Jerry DeLisle <jvdelisle@gcc.gnu.org>
3244 * constructor.c: Fix typo in comment.
3245 * expr.c (find_array_section): Add check for max array limit.
3247 2010-04-13 Iain Sandoe <iains@gcc.gnu.org>
3250 * gfortranspec.c (lookup_option): Check for -static and return
3252 (lang_specific_driver): Break when OPTION_static is discovered.
3254 2010-04-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
3256 * array.c (extract_element): Restore function from trunk.
3257 (gfc_get_array_element): Restore function from trunk.
3258 (gfc_expand_constructor): Restore check against
3259 flag_max_array_constructor.
3260 * constructor.c (node_copy_and_append): Delete unused.
3261 * gfortran.h: Delete comment and extra include.
3262 * constructor.h: Bump copyright and clean up TODO comments.
3263 * resolve.c: Whitespace.
3265 2010-04-12 Daniel Franke <franke.daniel@gmail.com>
3267 * simplify.c (compute_dot_product): Replaced usage of ADVANCE macro
3268 with direct access access to elements. Adjusted prototype, fixed all
3270 (gfc_simplify_dot_product): Removed duplicate check for zero-sized
3272 (gfc_simplify_matmul): Removed usage of ADVANCE macro.
3273 (gfc_simplify_spread): Removed workaround, directly insert elements
3274 at a given array position.
3275 (gfc_simplify_transpose): Likewise.
3276 (gfc_simplify_pack): Replaced usage of ADVANCE macro with corresponding
3278 (gfc_simplify_unpack): Likewise.
3280 2010-04-12 Daniel Franke <franke.daniel@gmail.com>
3282 * simplify.c (only_convert_cmplx_boz): Renamed to ...
3283 (convert_boz): ... this and moved to start of file.
3284 (gfc_simplify_abs): Whitespace fix.
3285 (gfc_simplify_acos): Whitespace fix.
3286 (gfc_simplify_acosh): Whitespace fix.
3287 (gfc_simplify_aint): Whitespace fix.
3288 (gfc_simplify_dint): Whitespace fix.
3289 (gfc_simplify_anint): Whitespace fix.
3290 (gfc_simplify_and): Replaced if-gate by more common switch-over-type.
3291 (gfc_simplify_dnint): Whitespace fix.
3292 (gfc_simplify_asin): Whitespace fix.
3293 (gfc_simplify_asinh): Moved creation of result-expr out of switch.
3294 (gfc_simplify_atan): Likewise.
3295 (gfc_simplify_atanh): Whitespace fix.
3296 (gfc_simplify_atan2): Whitespace fix.
3297 (gfc_simplify_bessel_j0): Removed ATTRIBUTE_UNUSED.
3298 (gfc_simplify_bessel_j1): Likewise.
3299 (gfc_simplify_bessel_jn): Likewise.
3300 (gfc_simplify_bessel_y0): Likewise.
3301 (gfc_simplify_bessel_y1): Likewise.
3302 (gfc_simplify_bessel_yn): Likewise.
3303 (gfc_simplify_ceiling): Reorderd statements.
3304 (simplify_cmplx): Use convert_boz(), check for constant arguments.
3306 (gfc_simplify_cmplx): Use correct default kind. Removed check for
3308 (gfc_simplify_complex): Replaced if-gate. Removed check for
3310 (gfc_simplify_conjg): Whitespace fix.
3311 (gfc_simplify_cos): Whitespace fix.
3312 (gfc_simplify_cosh): Replaced if-gate by more common switch-over-type.
3313 (gfc_simplify_dcmplx): Removed check for constant arguments.
3314 (gfc_simplify_dble): Use convert_boz() and gfc_convert_constant().
3315 (gfc_simplify_digits): Whitespace fix.
3316 (gfc_simplify_dim): Whitespace fix.
3317 (gfc_simplify_dprod): Reordered statements.
3318 (gfc_simplify_erf): Whitespace fix.
3319 (gfc_simplify_erfc): Whitespace fix.
3320 (gfc_simplify_epsilon): Whitespace fix.
3321 (gfc_simplify_exp): Whitespace fix.
3322 (gfc_simplify_exponent): Use convert_boz().
3323 (gfc_simplify_floor): Reorderd statements.
3324 (gfc_simplify_gamma): Whitespace fix.
3325 (gfc_simplify_huge): Whitespace fix.
3326 (gfc_simplify_iand): Whitespace fix.
3327 (gfc_simplify_ieor): Whitespace fix.
3328 (simplify_intconv): Use gfc_convert_constant().
3329 (gfc_simplify_int): Use simplify_intconv().
3330 (gfc_simplify_int2): Reorderd statements.
3331 (gfc_simplify_idint): Reorderd statements.
3332 (gfc_simplify_ior): Whitespace fix.
3333 (gfc_simplify_ishftc): Removed duplicate type check.
3334 (gfc_simplify_len): Use range_check() instead of manual range check.
3335 (gfc_simplify_lgamma): Removed ATTRIBUTE_UNUSED. Whitespace fix.
3336 (gfc_simplify_log): Whitespace fix.
3337 (gfc_simplify_log10): Whitespace fix.
3338 (gfc_simplify_minval): Whitespace fix.
3339 (gfc_simplify_maxval): Whitespace fix.
3340 (gfc_simplify_mod): Whitespace fix.
3341 (gfc_simplify_modulo): Whitespace fix.
3342 (simplify_nint): Reorderd statements.
3343 (gfc_simplify_not): Whitespace fix.
3344 (gfc_simplify_or): Replaced if-gate by more common switch-over-type.
3345 (gfc_simplify_radix): Removed unused result-variable. Whitespace fix.
3346 (gfc_simplify_range): Removed unused result-variable. Whitespace fix.
3347 (gfc_simplify_real): Use convert_boz() and gfc_convert_constant().
3348 (gfc_simplify_realpart): Whitespace fix.
3349 (gfc_simplify_selected_char_kind): Removed unused result-variable.
3350 (gfc_simplify_selected_int_kind): Removed unused result-variable.
3351 (gfc_simplify_selected_real_kind): Removed unused result-variable.
3352 (gfc_simplify_sign): Whitespace fix.
3353 (gfc_simplify_sin): Whitespace fix.
3354 (gfc_simplify_sinh): Replaced if-gate by more common switch-over-type.