2015-10-26 Steven G. Kargl <kargl@gcc.gnu.org>
[official-gcc.git] / gcc / fortran / ChangeLog
blob181545117f64dbefc7203e4d220941cc94913063
1 2015-10-26  Steven G. Kargl  <kargl@gcc.gnu.org>
3         PR fortran/36192
4         * array.c (gfc_ref_dimen_size): Check for BT_INTEGER before calling
5         mpz_set.
7 2015-10-26  Andre Vehreschild  <vehre@gcc.gnu.org>
9         PR fortran/66927
10         * trans-array.c (evaluate_bound): For deferred length arrays get the
11         bounds directly from the descriptor, i.e., prevent using constant
12         zero lower bound from the gfc_conv_array_lbound () routine.
13         (gfc_conv_section_startstride): Hand deferred array status to
14         evaluate_bound ().
15         (gfc_conv_expr_descriptor): Same.
17 2015-01-25  Paul Thomas  <pault@gcc.gnu.org>
19         PR fortran/67171
20         * trans-array.c (structure_alloc_comps): On deallocation of
21         class components, reset the vptr to the declared type vtable
22         and reset the _len field of unlimited polymorphic components.
23         *trans-expr.c (gfc_find_and_cut_at_last_class_ref): Bail out on
24         allocatable component references to the right of part reference
25         with non-zero rank and return NULL.
26         (gfc_reset_vptr): Simplify this function by using the function
27         gfc_get_vptr_from_expr. Return if the vptr is NULL_TREE.
28         (gfc_reset_len): If gfc_find_and_cut_at_last_class_ref returns
29         NULL return.
30         * trans-stmt.c (gfc_trans_allocate): Rely on the use of
31         gfc_trans_assignment if expr3 is a variable expression since
32         this deals correctly with array sections.
34 2015-10-25  Andre Vehreschild  <vehre@gcc.gnu.org>
36         PR fortran/66927
37         PR fortran/67044
38         * trans-array.c (build_array_ref): Modified call to
39         gfc_get_class_array_ref to adhere to new interface.
40         (gfc_conv_expr_descriptor): For one-based arrays that
41         are filled by a loop starting at one the start index of the
42         source array has to be mangled into the offset.
43         * trans-expr.c (gfc_get_class_array_ref): When the tree to get
44         the _data component is present already, add a way to supply it.
45         (gfc_copy_class_to_class): Allow to copy to a derived type also.
46         * trans-stmt.c (gfc_trans_allocate): Do not conv_expr_descriptor
47         for functions returning a class or derived object. Get the
48         reference instead.
49         * trans.h: Interface change of gfc_get_class_array_ref.
51 2015-10-24  Steven G. Kargl  <kargl@gcc.gnu.org>
53         PR fortran/68055
54         * decl.c (gfc_match_decl_type_spec): Check for valid kind in old-style
55         declarations.
57 2015-10-24  Steven G. Kargl  <kargl@gcc.gnu.org>
59         PR fortran/67805
60         * array.c (gfc_match_array_constructor): Check for error from type
61         spec matching.
62         * decl.c (char_len_param_value): Check for valid of charlen parameter.
63         Reap dead code dating to 2008.
64         match.c (gfc_match_type_spec): Special case the keyword use in REAL.
66 2015-10-23  Mikhail Maltsev  <maltsevm@gmail.com>
68         * trans-common.c (create_common): Adjust to use flag_checking.
69         * trans.c (gfc_add_modify_loc): Use gcc_checking_assert.
71 2015-10-21  Martin Sebor  <msebor@redhat.com>
73         PR driver/68043
74         * lang.opt: End each sentence that describes an option with a period.
76 2015-10-21  Steven G. Kargl  <kargl@gcc.gnu.org>
78         PR fortran/67939
79         * data.c (create_character_initializer): Deal with zero length string.
81 2015-10-19  Steven G. Kargl  <kargl@gcc.gnu.org>
83         * resolve.c (gfc_verify_binding_labels): Check for NULL pointer.
85 2015-10-19  Steven G. Kargl  <kargl@gcc.gnu.org>
87         PR fortran/68019
88         * decl.c (add_init_expr_to_sym): Remove an assert() to allow an error
89         message to be issued.
91 2015-10-18  Mikael Morin  <mikael@gcc.gnu.org>
93         PR fortran/67758
94         * gfortran.h (gfc_symbol): Expand comment.
95         * match.c (gfc_match_common): Delay adding the symbol to
96         the common_block after the gfc_add_in_common call.
97         * symbol.c (gfc_free_symbol): Move common block memory handling...
98         (gfc_set_symbol_common_block): ... here as a new function.
99         (restore_old_symbol): Restore common block fields.
100         (gfc_restore_last_undo_checkpoint):
101         Check the common_block pointer instead of the in_common attribute.
102         When a symbol has been removed from the common block linked list,
103         clear its common_next pointer.
105 2015-10-18  Paul Thomas  <pault@gcc.gnu.org>
107         PR fortran/67177
108         PR fortran/67977
109         * primary.c (match_substring): Add an argument 'deferred' to
110         flag that a substring reference with null start and end should
111         not be optimized away for deferred length strings.
112         (match_string_constant, gfc_match_rvalue): Set the argument.
113         * trans-expr.c (alloc_scalar_allocatable_for_assignment): If
114         there is a substring reference return.
115         * trans-intrinsic.c (conv_intrinsic_move_alloc): For deferred
116         characters, assign the 'from' string length to the 'to' string
117         length. If the 'from' expression is deferred, set its string
118         length to zero. If the 'to' expression has allocatable
119         components, deallocate them.
121 2015-10-17  Steven G. Kargl  <kargl@gcc.gnu.org>
123         PR fortran/67987
124         * decl.c (char_len_param_value): Unwrap unlong line.  If LEN < 0,
125         force it to zero per the Fortran 90, 95, 2003, and 2008 Standards.
126         * resolve.c (gfc_resolve_substring_charlen): Unwrap unlong line.
127         If 'start' is larger than 'end', length of substring is negative,
128         so explicitly set it to zero.
129         (resolve_charlen): Remove -Wsurprising warning.  Update comment to
130         reflect that the text is from the F2008 standard.
132 2015-10-16  Richard Biener  <rguenther@suse.de>
134         * trans-intrinsic.c (gfc_conv_intrinsic_lib_function): Adjust
135         calls to build_addr.
136         (gfc_conv_intrinsic_mod): Likewise.
137         (gfc_conv_intrinsic_ctime): Likewise.
138         (gfc_conv_intrinsic_fdate): Likewise.
139         (gfc_conv_intrinsic_ttynam): Likewise.
140         (gfc_conv_intrinsic_minmax_char): Likewise.
141         (gfc_conv_intrinsic_index_scan_verify): Likewise.
142         (gfc_conv_intrinsic_trim): Likewise.
144 2015-10-14  Maxim Ostapenko  <m.ostapenko@partner.samsung.com>
146         * parse.c (decode_statement): Initialize M to MATCH_NO.
148 2015-10-13  Jakub Jelinek  <jakub@redhat.com>
149             Ilya Verbin  <ilya.verbin@intel.com>
151         * f95-lang.c (DEF_FUNCTION_TYPE_9, DEF_FUNCTION_TYPE_10,
152         DEF_FUNCTION_TYPE_11, DEF_FUNCTION_TYPE_VAR_1): Define.
153         * trans-openmp.c (gfc_trans_omp_clauses): Set
154         OMP_CLAUSE_IF_MODIFIER to ERROR_MARK, OMP_CLAUSE_ORDERED_EXPR
155         to NULL.
156         (gfc_trans_omp_critical): Adjust for addition of clauses.
157         (gfc_trans_omp_ordered): Likewise.
158         * types.def (BT_FN_BOOL_UINT_LONGPTR_LONGPTR_LONGPTR,
159         BT_FN_BOOL_UINT_ULLPTR_ULLPTR_ULLPTR,
160         BT_FN_BOOL_UINT_LONGPTR_LONG_LONGPTR_LONGPTR,
161         BT_FN_BOOL_UINT_ULLPTR_ULL_ULLPTR_ULLPTR,
162         BT_FN_VOID_INT_SIZE_PTR_PTR_PTR_UINT_PTR,
163         BT_FN_VOID_INT_OMPFN_SIZE_PTR_PTR_PTR_UINT_PTR,
164         BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR_INT,
165         BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_UINT_LONG_INT_LONG_LONG_LONG,
166         BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_UINT_LONG_INT_ULL_ULL_ULL,
167         BT_FN_VOID_LONG_VAR, BT_FN_VOID_ULL_VAR): New.
168         (BT_FN_VOID_INT_PTR_SIZE_PTR_PTR_PTR,
169         BT_FN_VOID_INT_OMPFN_PTR_SIZE_PTR_PTR_PTR,
170         BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR): Remove.
172 2015-10-07  Andre Vehreschild  <vehre@gcc.gnu.org>
174         PR fortran/65889
175         * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Handle pointer to and
176         on stack class objects as sizeof parameter.
178 2015-10-06  Louis Krupp <louis.krupp@zoho.com>
179         PR fortran/65766
180         * resolve.c (gfc_resolve_substring_charlen): For derived type,
181         use typespec of string component when resolving substring length.
183 2015-10-04  Mikael Morin  <mikael@gcc.gnu.org>
185         * match.c (gfc_match_common): Remove dead variable old_blank_common.
187 2015-10-04  Mikael Morin  <mikael@gcc.gnu.org>
189         PR fortran/67758
190         * match.c (gfc_match_common): Delay the common_block pointer
191         assignment after error checking.
192         Delay the call to gfc_add_in_common attribute after the handling
193         of array specs.
194         * resolve.c (resolve_common_vars): Call gfc_add_in_common again.
196 2015-10-04  Mikael Morin  <mikael@gcc.gnu.org>
198         * resolve.c (resolve_common_vars): Move access to the common
199         block's head symbol inside the function.
200         (resolve_common_blocks, resolve_types): Update callers.
202 2015-10-01  Louis Krupp <louis.krupp@zoho.com>
204         PR fortran/62242
205         PR fortran/52332
206         * trans-array.c
207         (store_backend_decl): Create new gfc_charlen instance if requested
208         (get_array_ctor_all_strlen): Call store_backend_decl requesting
209         new gfc_charlen
210         (trans_array_constructor): Call store_backend_decl requesting
211         new gfc_charlen if get_array_ctor_strlen was called
212         (gfc_add_loop_ss_code): Don't try to convert non-constant length
214 2015-10-01  Steven G. Kargl  <kargl@gcc.gnu.org>
216         PR fortran.67802
217         * decl.c (add_init_expr_to_sym): Numeric constant for character
218         length must be an INTEGER.
220 2015-10-01  Steven G. Kargl  <kargl@gcc.gnu.org>
222         PR fortran/66979
223         * io.c (gfc_resolve_filepos): Check for a UNIT number.  Add a nearby
224         missing 'return false'.
226 2015-10-01  Steven G. Kargl  <kargl@gcc.gnu.org>
228         PR fortran/67616
229         * primary.c (gfc_match_structure_constructor): Use a possibly
230         host-associated symtree to prevent ICE.
232 2015-09-28  Paul Thomas  <pault@gcc.gnu.org>
234         PR fortran/40054
235         PR fortran/63921
236         * decl.c (get_proc_name): Return if statement function is
237         found.
238         * expr.c (gfc_check_vardef_context): Add error return for
239         derived type expression lacking the derived type itself.
240         * match.c (gfc_match_ptr_fcn_assign): New function.
241         * match.h : Add prototype for gfc_match_ptr_fcn_assign.
242         * parse.c : Add static flag 'in_specification_block'.
243         (decode_statement): If in specification block match a statement
244         function, then, if no error arising from statement function
245         matching, try to match pointer function assignment.
246         (parse_interface): Set 'in_specification_block' on exiting from
247         parse_spec.
248         (parse_spec): Set and then reset 'in_specification_block'.
249         (gfc_parse_file): Set 'in_specification_block'.
250         * resolve.c (get_temp_from_expr): Extend to include functions
251         and array constructors as rvalues..
252         (resolve_ptr_fcn_assign): New function.
253         (gfc_resolve_code): Call it on finding a pointer function as an
254         lvalue. If valid or on error, go back to start of resolve_code.
255         * symbol.c (gfc_add_procedure): Add a sentence to the error to
256         flag up the ambiguity between a statement function and pointer
257         function assignment at the end of the specification block.
259 2015-09-28  Nathan Sidwell  <nathan@codesourcery.com>
261         * f95-lang.c (DEF_FUNCTION_TYPE_VAR_6): New.
262         (DEF_FUNCTION_TYPE_VAR_11): Delete.
263         * types.def (DEF_FUNCTION_TYPE_VAR_6): New.
264         (DEF_FUNCTION_TYPE_VAR_11): Delete.
266 2015-09-26  Mikael Morin  <mikael@gcc.gnu.org>
268         PR fortran/67721
269         * trans-expr.c (gfc_trans_assignment_1): Remove the non-constantness
270         condition guarding deep copy.
272 2013-09-26  Paul Thomas  <pault@gcc.gnu.org>
274         PR fortran/67567
275         * resolve.c (resolve_fl_procedure): For module procedures, take
276         the parent module name and the submodule name from the name of
277         the namespace.
279 2015-09-25  Steven G. Kargl  <kargl@gcc.gnu.org>
281         PR fortran/67614
282         * resolve.c (gfc_resolve_code): Prevent ICE for invalid EXPR_NULL.
284 2015-09-25  Steven G. Kargl  <kargl@gcc.gnu.org>
286         PR fortran/67525
287         * parse.c (match_deferred_characteristics): Remove an assert, which
288         allows an invalid SELECT TYPE selector to be detected.
290 2015-09-25  Manuel López-Ibáñez  <manu@gcc.gnu.org>
292         PR pretty-print/67567
293         * resolve.c (resolve_fl_procedure): Work-around when iface->module
294         == NULL.
296 2015-09-21  Steven G. Kargl  <kargl@gcc.gnu.org>
298         * resolve.c (nonscalar_typebound_assign): Fix typos in comment.
300 2015-09-21  Steven G. Kargl  <kargl@gcc.gnu.org>
302         PR fortran/67615
303         * resolve.c (gfc_resolve_code): Check for scalar expression in
304         arithmetic-if.
306 2015-09-17  Paul Thomas  <pault@gcc.gnu.org>
308         PR fortran/52846
309         PR fortran/67588
310         * module.c : Add static no_module_procedures.
311         (gfc_match_submodule): Correct memory leakage caused during the
312         freeing of use_lists.
313         (mio_symbol_attribute): Reset above if module procedure is
314         encountered.
315         (gfc_dump_module): Set above and exit without writing smod file
316         if it reset.
317         * gfortran.texi : Add section on submodule support.
319 2015-09-10  Steven G. Kargl  <kargl@gcc.gnu.org>
321         PR fortran/67526
322         * expr.c (gfc_check_init_expr): Do not dereference a NULL pointer.
324 2015-09-10  Paul Thomas  <pault@gcc.gnu.org>
326         PR fortran/66993
327         * module.c (read_module): If a symtree exists and the symbol has
328         been associated in a submodule from a parent (sub)module, attach
329         the symbol to a 'unique symtree' and the new symbol to the
330         existing symtree.
332 2015-09-04  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
334         * intrinsic.h (gfc_simplify_mvbits): Remove.
335         * simplify.c (gfc_simplify_mvbits): Remove.
336         * intrinsic.c (add_subroutines): Remove reference to
337         gfc_simplify_mvbits.
339 2015-09-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
341         PR fortran/67429
342         * error.c (gfc_clear_pp_buffer): Reset last_location, otherwise
343         caret lines might be skipped when actually giving a diagnostic.
345 2015-08-31  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
347         PR fortran/54833
348         * trans.c (gfc_call_free): Don't check if pointer is NULL.
349         * trans.h (gfc_call_free): Adjust comment.
351 2015-08-29  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
353         * trans.c (gfc_call_malloc, gfc_allocate_using_malloc,
354         gfc_allocate_using_lib, gfc_allocate_allocatable,
355         gfc_call_realloc): Simplify code.
356         * trans-array.c (gfc_trans_allocate_array_storage,
357         gfc_trans_auto_array_allocation, gfc_conv_array_parameter): Do not
358         convert gfc_call_free() argument.
359         * trans-expr.c (gfc_conv_string_tmp, gfc_conv_procedure_call,
360         fcncall_realloc_result): Likewise.
361         * trans-intrinsic.c (gfc_conv_intrinsic_transfer): Likewise.
363 2015-08-28  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
365         PR fortran/53668
366         * intrinsic.c (add_functions, add_subroutines): Remove resolution
367         functions for FREE and MALLOC.
368         * intrinsic.h (gfc_resolve_malloc, gfc_resolve_free): Remove.
369         * iresolve.c (gfc_resolve_malloc, gfc_resolve_free): Remove.
370         * trans-intrinsic.c (conv_intrinsic_free,
371         gfc_conv_intrinsic_malloc): New functions.
373 2015-08-24  Louis Krupp <louis.krupp@zoho.com>
375         PR fortran/62536
376         PR fortran/66175
377         * decl.c (gfc_match_end): Clean up nested BLOCKs.
378         * parse.c (parse_block_construct): Deal gracefully with cleaned-up
379         BLOCKs.
381 2015-08-23  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
383         PR libfortran/54572
384         * config-lang.in: Add libbacktrace to target_libs.
386 2015-08-18  Trevor Saunders  <tbsaunde@tbsaunde.org>
388         * dependency.c, dependency.h, gfortran.h, io.c, module.c,
389         parse.h, resolve.c, trans-types.h, trans.h: remove useless typedefs.
391 2015-08-16  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
393         PR fortran/54656
394         * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Add decl
395         for quadruple precision BUILT_IN_SQRT.
397 2015-08-16  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
399         * trans-intrinsic.c (conv_intrinsic_ieee_is_negative): Use type
400         generic BUILT_IN_SIGNBIT.
401         (conv_intrinsic_ieee_copy_sign): Likewise.
402         * f95-lang.c (gfc_init_builtin_functions): Add BUILT_IN_ISINF,
403         BUILT_IN_ISINF_SIGN, BUILT_IN_SIGNBIT, BUILT_IN_ISLESS,
404         BUILT_IN_ISLESSGREATER, BUILT_IN_ISGREATER. Remove non-type generic
405         variants of BUILT_IN_SIGNBIT.
406         * mathbuiltins.def: Remove SIGNBIT.
408 2015-08-16  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
410         PR fortran/41387
411         * gfortran.texi: New section "File operations on symbolic links".
413 2015-08-08  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
415         PR fortran/67059
416         * gfortranspec.c (lang_specific_driver): Adjust --version output.
418 2015-08-08  Bud Davis  <jmdavis@link.com>
419             Mikael Morin  <mikael@gcc.gnu.org>
421         PR fortran/59746
422         * symbol.c (gfc_restore_last_undo_checkpoint): Delete a common block
423         symbol if it was put in the list.
425 2015-08-07  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
427         PR fortran/64104
428         * expr.c (gfc_check_init_expr): Allow some IEEE functions in
429         constant expressions.
430         (external_spec_function): Allow some IEEE functions in specification
431         expressions.
432         * simplify.c (gfc_simplify_ieee_selected_real_kind): Remove.
433         (simplify_ieee_selected_real_kind, simplify_ieee_support,
434         matches_ieee_function_name, gfc_simplify_ieee_functions): New
435         functions.
436         * gfortran.h (gfc_simplify_ieee_selected_real_kind): Remove
437         prototype.
438         (gfc_simplify_ieee_functions): Add prototype.
440 2015-08-06  Mikael Morin  <mikael@gcc.gnu.org>
442         * trans.h (gfc_trans_scalar_assign): Remove fourth argument.
443         * trans-expr.c (gfc_trans_scalar_assign): Merge fourth into sixth
444         argument.
445         (gfc_conv_subref_array_arg, gfc_trans_subarray_assign,
446          gfc_trans_subcomponent_assign, gfc_trans_assignment_1): Update callers.
447         * trans-array.c (gfc_conv_expr_descriptor): Ditto.
448         * trans-stmt.c (forall_make_variable_temp,
449         generate_loop_for_temp_to_lhs, generate_loop_for_rhs_to_temp,
450         gfc_trans_where_assign, gfc_trans_where_3): Ditto.
452 2015-08-05  Paul Thomas  <pault@gcc.gnu.org>
454         PR fortran/52846
455         * module.c (check_access): Return true if new static flag
456         'dump_smod' is true..
457         (gfc_dump_module): Rename original 'dump_module' and call from
458         new version. Use 'dump_smod' rather than the stack state to
459         determine if a submodule is being processed. The new version of
460         this procedure sets 'dump_smod' depending on the stack state and
461         then writes both the mod and smod files if a module is being
462         processed or just the smod for a submodule.
463         (gfc_use_module): Eliminate the check for module_name and
464         submodule_name being the same.
465         * trans-decl.c (gfc_finish_var_decl, gfc_build_qualified_array,
466         get_proc_pointer_decl): Set TREE_PUBLIC unconditionally and use
467         the conditions to set DECL_VISIBILITY as hidden and to set as
468         true DECL_VISIBILITY_SPECIFIED.
470 2015-08-04  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
472         PR fortran/64022
473         * simplify.c (gfc_simplify_ieee_selected_real_kind): Extend IEEE
474         support to all real kinds.
476 2015-08-03  Steven G. Kargl  <kargl@gcc.gnu.org>
478         PR fortran/66942
479         * trans-expr.c (gfc_conv_procedure_call): Avoid NULL pointer reference
481 2015-08-03  Mikael Morin  <mikael@gcc.gnu.org>
483         PR fortran/64921
484         * class.c (generate_finalization_wrapper): Set finalization
485         procedure symbol's always_explicit attribute.
487 2015-08-01  Paul Thomas  <pault@gcc.gnu.org>
489         PR fortran/67091
490         * trans-intrinsic.c (gfc_conv_associated): Add the pre and post
491         blocks for the second argument to se.
493 2015-07-27  Thomas Schwinge  <thomas@codesourcery.com>
495         * parse.c (parse_oacc_structured_block): Fix logic error.
496         Reported by Mikael Morin <mikael.morin@sfr.fr>.
498 2015-07-24  Mikael Morin  <mikael@gcc.gnu.org>
500         PR fortran/64986
501         * trans-expr.c (gfc_trans_assignment_1): Put component deallocation
502         code at the beginning of the block.
504 2015-07-22  Mikael Morin  <mikael@gcc.gnu.org>
506         PR fortran/61831
507         PR fortran/66929
508         * trans-array.c (gfc_get_proc_ifc_for_expr): Use esym as procedure
509         symbol if available.
511 2015-07-17  Paul Thomas  <pault@gcc.gnu.org>
513         PR fortran/52846
514         * decl.c (gfc_match_end): Pick out declared submodule name from
515         the composite identifier.
516         * gfortran.h : Add 'submodule_name' to gfc_use_list structure.
517         * module.c (gfc_match_submodule): Define submodule_name and add
518         static 'submodule_name'.
519         (gfc_match_submodule): Build up submodule filenames, using '@'
520         as a delimiter. Store the output filename in 'submodule_name'.
521         Similarly, the submodule identifier is built using '.' as an
522         identifier.
523         (gfc_dump_module): If current state is COMP_SUBMODULE, write
524         to file 'submodule_name', using SUBMODULE_EXTENSION.
525         (gfc_use_module): Similarly, use the 'submodule_name' field in
526         the gfc_use_list structure and SUBMODULE_EXTENSION to read the
527         implicitly used submodule files.
529 2015-07-17  Alessandro Fanfarillo  <fanfarillo.gcc@gmail.com>
531         * trans-intrinsic.c (conv_co_collective): Remove redundant address
532         operator in the generated code.
534 2015-07-17  Andre Vehreschild  <vehre@gcc.gnu.org>
536         PR fortran/66035
537         * trans-expr.c (alloc_scalar_allocatable_for_subcomponent_assignment):
538         Compute the size to allocate for class and derived type objects
539         correclty.
540         (gfc_trans_subcomponent_assign): Only allocate memory for a
541         component when the object to assign is not an allocatable class
542         object (the memory is already present for allocatable class objects).
543         Furthermore use copy_class_to_class for assigning the rhs to the
544         component (may happen for dummy class objects on the rhs).
546 2015-07-17  Mikael Morin  <mikael@gcc.gnu.org>
547             Dominique d'Humieres  <dominiq@lps.ens.fr>
549         PR fortran/61831
550         * trans-array.c (gfc_conv_array_parameter): Guard allocatable
551         component deallocation code generation with descriptorless
552         calling convention flag.
553         * trans-expr.c (gfc_conv_expr_reference): Remove allocatable
554         component deallocation code generation from revision 212329.
555         (expr_may_alias_variables): New function.
556         (gfc_conv_procedure_call): New boolean elemental_proc to factor
557         check for procedure elemental-ness.  Rename boolean f to nodesc_arg
558         and declare it in the outer scope.  Use expr_may_alias_variables,
559         elemental_proc and nodesc_arg to decide whether generate allocatable
560         component deallocation code.
561         (gfc_trans_subarray_assign): Set deep copy flag.
563 2015-07-16  Steven G. Kargl  <kargl@gcc.gnu.org>
565         PR fortran/66724
566         PR fortran/66724
567         * io.c (is_char_type): Call gfc_resolve_expr ().
568         (match_open_element, match_dt_element, match_inquire_element): Fix
569         ASYNCHRONOUS case.
571 2015-07-15  Andrew MacLeod  <amacleod@redhat.com>
573         * trans-types.c: Remove multiline #include comment.
575 2015-07-14  Steven G. Kargl  <kargl@gcc.gnu.org>
577         * simplify.c (gfc_simplify_floor): Set precision of temporary to
578         that of arg.
580 2015-07-13  Andre Vehreschild  <vehre@gcc.gnu.org>
582         PR fortran/64589
583         * class.c (find_intrinsic_vtab): Put/Search vtabs for intrinsic
584         types in the top-level namespace.
586 2015-07-12  Aldy Hernandez  <aldyh@redhat.com>
588         * trans-stmt.c: Fix double word typos.
590 2015-07-09  Andrew MacLeod  <amacleod@redhat.com>
592         * arith.c: Adjust includes for flags.h changes.
593         * array.c: Likewise.
594         * check.c: Likewise.
595         * decl.c: Likewise.
596         * error.c: Likewise.
597         * expr.c: Likewise.
598         * frontend-passes.c: Likewise.
599         * interface.c: Likewise.
600         * intrinsic.c: Likewise.
601         * io.c: Likewise.
602         * match.c: Likewise.
603         * openmp.c: Likewise.
604         * parse.c: Likewise.
605         * primary.c: Likewise.
606         * resolve.c: Likewise.
607         * scanner.c: Likewise.
608         * simplify.c: Likewise.
609         * symbol.c: Likewise.
610         * target-memory.c: Likewise.
612 2015-07-07  Andrew MacLeod  <amacleod@redhat.com>
614         * convert.c: Adjust includes.
615         * cpp.c: Likewise.
616         * decl.c: Likewise.
617         * f95-lang.c: Likewise.
618         * iresolve.c: Likewise.
619         * match.c: Likewise.
620         * module.c: Likewise.
621         * options.c: Likewise.
622         * target-memory.c: Likewise.
623         * trans-array.c: Likewise.
624         * trans-common.c: Likewise.
625         * trans-const.c: Likewise.
626         * trans-decl.c: Likewise.
627         * trans-expr.c: Likewise.
628         * trans-intrinsic.c: Likewise.
629         * trans-io.c: Likewise.
630         * trans-openmp.c: Likewise.
631         * trans-stmt.c: Likewise.
632         * trans-types.c: Likewise.
633         * trans.c: Likewise.
635 2015-07-07  Andre Vehreschild  <vehre@gmx.de>
637         PR fortran/66578
638         * trans-array.c (gfc_conv_expr_descriptor): Ensure array descriptor
639         is one-based for non-full array refs. Correct the offset when a
640         rank_remap occurs.
642 2015-07-06  Steven G. Kargl  <kargl@gcc.gnu.org>
644         * io.c (check_char_variable): New function.
645         (match_open_element, match_close_element, match_file_element,
646         match_dt_element, match_inquire_element, match_wait_element): Use it.
648 2015-07-06  Andre Vehreschild  <vehre@gmx.de>
650         PR fortran/58586
651         * resolve.c (resolve_symbol): Non-private functions in modules
652         with allocatable or pointer components are marked referenced
653         now. Furthermore is the default init especially for those
654         components now done in gfc_conf_procedure_call preventing
655         duplicate code.
656         * trans-decl.c (gfc_generate_function_code): Generate a fake
657         result decl for functions returning an object with allocatable
658         components and initialize them.
659         * trans-expr.c (gfc_conv_procedure_call): For value typed trees
660         use the tree without indirect ref. And for non-decl trees
661         add a temporary variable to prevent evaluating the tree
662         multiple times (prevent multiple function evaluations).
663         * trans.h: Made gfc_trans_structure_assign () protoype
664         available, which is now needed by trans-decl.c:gfc_generate_
665         function_code(), too.
667 2015-07-04  Steven G. Kargl  <kargl@gcc.gnu.org>
669         PR fortran/66725
670         * io.c (is_char_type): New function to test for BT_CHARACTER
671         (gfc_match_open, gfc_match_close, match_dt_element): Use it.
673 2015-07-02  David Edelsohn  <dje.gcc@gmail.com>
675         * trans-common.c: Include <map> after system.h.
677 2015-07-02  Paul Thomas  <pault@gcc.gnu.org>
679         PR fortran/52846
680         * decl.c (get_proc_name): Make a partially populated interface
681         symbol to carry the characteristics of a module procedure and
682         its result.
683         (variable_decl): Declarations of dummies or results in the
684         abreviated form of module procedure is an error.
685         (gfc_match_import): IMPORT is not permitted in the interface
686         declaration of module procedures.
687         (match_attr_spec): Submodule variables have implicit save
688         attribute for F2008 onwards.
689         (gfc_match_prefix): Add 'module' as the a prefix and set the
690         module_procedure attribute.
691         (gfc_match_formal_arglist): For a module procedure keep the
692         interface formal_arglist from the interface, match new the
693         formal arguments and then compare the number and names of each.
694         (gfc_match_procedure): Add case COMP_SUBMODULE.
695         (gfc_match_function_decl, gfc_match_subroutine_decl): Set the
696         module_procedure attribute.
697         (gfc_match_entry, gfc_match_end):  Add case COMP_SUBMODULE. If
698         attr abr_modproc_decl is set, switch the message accordingly
699         for subroutines and functions.
700         (gfc_match_submod_proc): New function to match the abbreviated
701         style of submodule declaration.
702         * gfortran.h : Add ST_SUBMODULE and ST_END_SUBMODULE. Add the
703         attribute bits 'used_in_submodule' and 'module_procedure'. Add
704         the bit field 'abr_modproc_decl' to gfc_symbol. Add prototypes
705         for 'gfc_copy_dummy_sym', 'gfc_check_dummy_characteristics' and
706         'gfc_check_result_characteristics'.
707         * interface.c : Add the prefix 'gfc_' to the names of functions
708         'check_dummy(result)_characteristics' and all their references.
709         * match.h : Add prototype for 'gfc_match_submod_proc' and
710         'gfc_match_submodule'.
711         (check_sym_interfaces): A module procedure is not an error in
712         a module procedure statment in a generic interface.
713         * module.c (gfc_match_submodule): New function. Add handling
714         for the 'module_procedure' attribute bit.
715         (gfc_use_module): Make sure that a submodule cannot use itself.
716         * parse.c (decode_statement): Set attr has_'import_set' for
717         the interface declaration of module procedures. Handle a match
718         occurring in 'gfc_match_submod_proc' and a match for
719         'submodule'.
720         (gfc_enclosing_unit): Include the state COMP_SUBMODULE.
721         (gfc_ascii_statement): Add END SUBMODULE.
722         (accept_statement): Add ST_SUBMODULE.
723         (parse_spec): Disallow statement functions in a submodule
724         specification part.
725         (parse_contained): Add ST_END_SUBMODULE and COMP_SUBMODULE
726         twice each.
727         (get_modproc_result): Copy the result symbol of the interface.
728         (parse_progunit): Call it.
729         (set_syms_host_assoc): Make symbols from the ancestor module
730         and submodules use associated, as required by the standard and
731         set all private components public. Module procedures 'external'
732         attribute bit is reset and the 'used_in_submodule' bit is set.
733         (parse_module): If this is a submodule, use the ancestor module
734         and submodules. Traverse the namespace, calling
735         'set_syms_host_assoc'. Add ST_END_SUBMODULE and COMP_SUBMODULE.
736         * parse.h : Add COMP_SUBMODULE.
737         * primary.c (match_variable): Add COMP_SUBMODULE.
738         * resolve.c (compare_fsyms): New function to compare the dummy
739         characteristics of a module procedure with its interface.
740         (resolve_fl_procedure): Compare the procedure, result and dummy
741         characteristics of a module_procedure with its interface, using
742         'compare_fsyms' for the dummy arguments.
743         * symbol.c (gfc_add_procedure): Suppress the check for existing
744         procedures in the case of a module procedure.
745         (gfc_add_explicit_interface): Skip checks that must fail for
746         module procedures.
747         (gfc_add_type): Allow a new type to be added to module
748         procedures, their results or their dummy arguments.
749         (gfc_copy_dummy_sym): New function to generate new dummy args
750         and copy the characteristics from the interface.
751         * trans-decl.c (gfc_sym_mangled_function_id): Module procedures
752         must always have their names mangled as if they are symbols
753         coming from a declaration in a module.
754         (gfc_get_symbol_decl): Add 'used_in_submodule' to the assert.
755         (gfc_finish_var_decl): Symbols with the 'used_in_submodule' bit
756         set are set DECL_EXTERNAL as if they were use associated.
758 2015-07-02  Steven G. Kargl  <kargl@gcc.gnu.org>
760         PR fortran/56520
761         * match.c (gfc_match_name): Special case unary minus and plus.
763 2015-07-02  Steven G. Kargl   <kargl@gcc.gnu.org>
765         PR fortran/66545
766         * primary.c (match_sym_complex_part): Do not dereference NULL pointer.
768 2015-07-01  Thomas Koenig  <tkoenig@gcc.gnu.org>
770         * arith.c (gfc_arith_divide):  With -Winteger-division,
771         warn about contant integer division if there is a non-zero
772         remainder.
773         * invoke.texi:  Document -Winteger-division.
774         * lang.opt:  Add -Winteger-division.
776 2015-06-25  Andrew MacLeod  <amacleod@redhat.com>
778         * f95-lang.c: Remove ipa-ref.h and plugin-api.h from include list.
779         * trans-decl.c: Likewise.
781 2015-06-25  Richard Sandiford  <richard.sandiford@arm.com>
783         * trans-decl.c (module_hasher): Likewise.
784         * trans.h (module_decl_hasher): Likewise.
786 2015-06-24  Manuel López-Ibáñez  <manu@gcc.gnu.org>
788         PR fortran/66528
789         * error.c (gfc_warning_check): Restore the default output_buffer
790         before calling diagnostic_action_after_output.
791         (gfc_error_check): Likewise.
792         (gfc_diagnostics_init): Add comment.
794 2015-06-23  Andre Vehreschild  <vehre@gmx.de>
796         PR fortran/64674
797         * parse.c (parse_associate): Figure the rank and as of a
798         class array in an associate early.
799         * primary.c (gfc_match_varspec): Prevent setting the
800         dimension attribute on the sym for classes.
801         * resolve.c (resolve_variable): Correct the component
802         ref's type for associated variables.  Add a full array ref
803         when class array's are associated.
804         (resolve_assoc_var): Correct the type of the symbol,
805         when in the associate the expression's rank becomes scalar.
806         * trans-expr.c (gfc_conv_variable): Indirect ref needed for
807         allocatable associated objects.
809 2015-06-19  Mikael Morin  <mikael@gcc.gnu.org>
811         PR fortran/66549
812         * resolve.c (resolve_global_procedure): Don't save and restore
813         OpenMP state around the call to gfc_resolve.
814         (gfc_resolve): Save OpenMP state on entry and restore it on return.
816 2015-06-17  Andrew MacLeod  <amacleod@redhat.com>
818         * convert.c: Do not include input.h, line-map.h or is-a.h.
819         * cpp.c: Likewise.
820         * decl.c: Likewise.
821         * f95-lang.c: Likewise.
822         * gfortran.h: Likewise.
823         * iresolve.c: Likewise.
824         * match.c: Likewise.
825         * module.c: Likewise.
826         * options.c: Likewise.
827         * target-memory.c: Likewise.
828         * trans-array.c: Likewise.
829         * trans-common.c: Likewise.
830         * trans-const.c: Likewise.
831         * trans-decl.c: Likewise.
832         * trans-expr.c: Likewise.
833         * trans-intrinsic.c: Likewise.
834         * trans-io.c: Likewise.
835         * trans-openmp.c: Likewise.
836         * trans-stmt.c: Likewise.
837         * trans-types.c: Likewise.
838         * trans.c: Likewise.
840 2015-06-15  Andre Vehreschild  <vehre@gmx.de>
842         PR fortran/44672
843         PR fortran/45440
844         PR fortran/57307
845         * gfortran.h: Extend gfc_code.ext.alloc to carry a
846         flag indicating that the array specification has to be
847         taken from expr3.
848         * resolve.c (resolve_allocate_expr): Add F2008 notify
849         and flag indicating source driven array spec.
850         (resolve_allocate_deallocate): Check for source driven
851         array spec, when array to allocate has no explicit
852         array spec.
853         * trans-array.c (gfc_array_init_size): Get lower and
854         upper bound from a tree array descriptor, except when
855         the source expression is an array-constructor which is
856         fixed to be one-based.
857         (retrieve_last_ref): Extracted from gfc_array_allocate().
858         (gfc_array_allocate): Enable allocate(array, source=
859         array_expression) as specified by F2008:C633.
860         (gfc_conv_expr_descriptor): Add class tree expression
861         into the saved descriptor for class arrays.
862         * trans-array.h: Add temporary array descriptor to
863         gfc_array_allocate ().
864         * trans-expr.c (gfc_conv_procedure_call): Special handling
865         for _copy() routine translation, that comes without an
866         interface. Third and fourth argument are now passed by value.
867         * trans-stmt.c (gfc_trans_allocate): Get expr3 array
868         descriptor for temporary arrays to allow allocate(array,
869         source = array_expression) for array without array
870         specification.
872 2015-06-14  Thomas Koenig  <tkoenig@gcc.gnu.org>
874         * intrinsic.texi:  Change \leq to < in descrition of imaginary
875         part in argument to log.
877 2015-06-11  Paul Thomas  <pault@gcc.gnu.org>
879         PR fortran/66079
880         * trans-expr.c (gfc_conv_procedure_call): Allocatable scalar
881         function results must be freed and nullified after use. Create
882         a temporary to hold the result to prevent duplicate calls.
883         * trans-stmt.c (gfc_trans_allocate): Rename temporary variable
884         as 'source'. Deallocate allocatable components of non-variable
885         'source's.
887 2015-06-11  Pierre-Marie de Rodat  <derodat@adacore.com>
889         * f95-lang.c (gfc_create_decls): Register the main translation unit
890         through the new debug hook.
892 2015-06-08  Andrew MacLeod  <amacleod@redhat.com>
894         * convert.c : Adjust include files.
895         * cpp.c : Likewise.
896         * decl.c : Likewise.
897         * f95-lang.c : Likewise.
898         * gfortran.h : Likewise.
899         * iresolve.c : Likewise.
900         * match.c : Likewise.
901         * module.c : Likewise.
902         * openmp.c : Likewise.
903         * options.c : Likewise.
904         * target-memory.c : Likewise.
905         * trans-array.c : Likewise.
906         * trans-common.c : Likewise.
907         * trans-const.c : Likewise.
908         * trans-decl.c : Likewise.
909         * trans-expr.c : Likewise.
910         * trans-intrinsic.c : Likewise.
911         * trans-io.c : Likewise.
912         * trans-openmp.c : Likewise.
913         * trans-stmt.c : Likewise.
914         * trans-types.c : Likewise.
915         * trans.c : Likewise.
917 2015-06-08  Steven G. Kargl  <kargl@gcc.gnu.org>
919         PR fortran/66245
920         * match.c (gfc_match_type_is, gfc_match_class_is):  Check if the
921         return type spec or derived type spec is validate.
923 2015-06-06  Thomas Koenig  <tkoenig@netcologne.de>
925         PR fortran/47659
926         * arith.c (eval_intrinsic_op): Set warn flag for
927         gfc_type_convert_binary if -Wconversion or -Wconversion-extra
928         are set.
929         (wprecision_real_real): New function.
930         (wprecision_int_real): New function.
931         (gfc_int2int): If -fno-range-check and -Wconversion are specified
932         and it is a narrowing conversion, warn.
933         (gfc_int2real): If there is a change in value for the conversion,
934         warn.
935         (gfc_int2complex):  Likewise.
936         (gfc_real2int): If there is a fractional part to the real number,
937         warn with -Wconversion, otherwise warn with -Wconversion-extra.
938         (gfc_real2real): Emit warning if the constant was changed by
939         conversion with either -Wconversion or -Wconversion-extra.  With
940         -Wconversion-extra, warn if no warning was issued earlier.
941         (gfc_real2complex):  Likewise.
942         (gfc_complex2int): For -Wconversion or -Wconversion-extra, if
943         there was an imaginary part, warn; otherwise, warn for change in
944         value.  Warn with -Wconversion-extra if no other warning was
945         issued.
946         (gfc_complex2real): For -Wconversion or -Wconversion-extra, if
947         there was an imaginary part, warn; otherwise, warn for change in
948         value. Warn with -Wconversion-extra if no other warning was
949         issued.
950         (gfc_complex2complex):  For -Wconversion, warn if the value of
951         either the real or the imaginary part was changed.  Warn for
952         -Wconversion-extra if no prior warning was issued.
953         * expr.c (gfc_check_assign):  Remove check for change in value.
954         * primary.c (match_real_constant): For -Wconversion-extra, check
955         against a number in which the last non-zero digit has been
956         replaced with a zero.  If the number compares equal, warn.
957         * intrinsic.c (gfc_convert_type_warn):  Do not warn about constant
958         conversions.
960 2015-06-05  Steven G. Kargl  <kargl@gcc.gnu.org>
962         PR fortran/66347
963         * resolve.c (apply_default_init_local): Do not dereference a NULL
964         pointer.
966 2015-06-05  Thomas Koenig  <tkoenig@gcc.gnu.org>
968         PR fortran/66385
969         * frontend-passes.c (combine_array_constructor): Return early if
970         inside a FORALL loop.
972 2015-06-05  Aldy Hernandez  <aldyh@redhat.com>
974         * f95-lang.c (gfc_write_global_declarations): Remove.
975         (LANG_HOOKS_WRITE_GLOBALS): Remove.
976         (gfc_write_global_declarations): Move code from here to...
977         (gfc_be_parse_file): ...here.
978         Call global_decl_processing.
979         * trans-decl.c (gfc_emit_parameter_debug_info): Rename global_decl
980         to early_global_decl.
982 2015-06-05  Russell Whitesides  <russelldub@gmail.com>
983             Steven G. Kargl  <kargl@gcc.gnu.org>
985         PR fortran/40958
986         PR fortran/60780
987         PR fortran/66377
988         * module.c (load_equiv): Add check for loading duplicate EQUIVALENCEs
989         from different modules.  Eliminate the pruning of unused
990         equivalence-objects
992 2015-06-04  Thomas Koenig  <tkoenig@netcologne.de>
994         PR fortran/58749
995         * iresolve.c (gfc_resolve_adjustl):  If string has a charlen,
996         copy it to the function.
997         (gfc_resolve_adjustr):  Likewise.
999 2015-06-04  Andrew MacLeod  <amacleod@redhat.com>
1001         * convert.c: Adjust includes for restructured coretypes.h.
1002         * cpp.c: Likewise.
1003         * decl.c: Likewise.
1004         * f95-lang.c: Likewise.
1005         * iresolve.c: Likewise.
1006         * match.c: Likewise.
1007         * module.c: Likewise.
1008         * options.c: Likewise.
1009         * target-memory.c: Likewise.
1010         * trans-array.c: Likewise.
1011         * trans-common.c: Likewise.
1012         * trans-const.c: Likewise.
1013         * trans-decl.c: Likewise.
1014         * trans-expr.c: Likewise.
1015         * trans-intrinsic.c: Likewise.
1016         * trans-io.c: Likewise.
1017         * trans-openmp.c: Likewise.
1018         * trans-stmt.c: Likewise.
1019         * trans-types.c: Likewise.
1020         * trans.c: Likewise.
1022 2015-06-02  Steven G. Kargl  <kargl@gcc.gnu.org>
1024         PR fortran/66380
1025         * simplify.c (gfc_simplify_reshape): Convert assert into returning
1026         NULL, which triggers an error condition.
1028 2015-05-27  Andre Vehreschild  <vehre@gmx.de>
1030         PR fortran/65548
1031         * trans-stmt.c (gfc_trans_allocate): Add missing location
1032         information for e3rhs.
1034 2015-05-26  Paul Thomas  <pault@gcc.gnu.org>
1036         PR fortran/66082
1037         * trans-array.c (gfc_conv_array_parameter): Ensure that all
1038         non-variable arrays with allocatable components have the
1039         components deallocated after the procedure call.
1041 2015-05-24  Mikael Morin  <mikael@gcc.gnu.org>
1043         PR fortran/66257
1044         * resolve.c (resolve_actual_arglist): Don't throw an error
1045         if the argument with procedure pointer component is not a variable.
1047 2015-05-24  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1049         PR fortran/44054
1050         * gfortran.h (struct gfc_error_buf): Rename as
1051         gfc_error_buffer. Move closer to push, pop and free
1052         methods. Reimplement using an output_buffer.
1053         * error.c (errors, warnings, warning_buffer, cur_error_buffer):
1054         Delete everywhere in this file.
1055         (error_char): Delete all contents.
1056         (gfc_increment_error_count): Delete.
1057         (gfc_error_now): Update comment. Set error_buffer.flag.
1058         (gfc_warning_check): Do not handle warning_buffer.
1059         (gfc_error_1): Delete.
1060         (gfc_error_now_1): Delete.
1061         (gfc_error_check): Simplify.
1062         (gfc_move_error_buffer_from_to): Renamed from
1063         gfc_move_output_buffer_from_to.
1064         (gfc_push_error): Handle only gfc_error_buffer.
1065         (gfc_pop_error): Likewise.
1066         (gfc_free_error): Likewise.
1067         (gfc_get_errors): Remove warnings and errors.
1068         (gfc_diagnostics_init): Use static error_buffer.
1069         (gfc_error_1,gfc_error_now_1): Delete declarations.
1070         * symbol.c, decl.c, trans-common.c, data.c, expr.c, expr.c,
1071         frontend-passes.c, resolve.c, match.c, parse.c: Replace
1072         gfc_error_1 with gfc_error and gfc_error_now_1 with gfc_error_1
1073         everywhere.
1074         * f95-lang.c (gfc_be_parse_file): Do not update errorcount and
1075         warningcount here.
1076         * primary.c (match_complex_constant): Replace gfc_error_buf and
1077         output_buffer with gfc_error_buffer.
1079 2015-05-22  Jim Wilson  <jim.wilson@linaro.org>
1081         * Make-lang.in (check_gfortran_parallelize): Update comment.
1083 2015-05-21  Thomas Koenig  <tkoenig@gcc.gnu.org>
1085         PR fortran/66176
1086         * frontend-passes.c (check_conjg_variable):  New function.
1087         (inline_matmul_assign):  Use it to keep track of conjugated
1088         variables.
1090 2015-05-20  Andre Vehreschild  <vehre@gmx.de>
1092         PR fortran/65548
1093         * trans-stmt.c (gfc_trans_allocate): Always retrieve the
1094         descriptor or a reference to a source= expression for
1095         arrays and non-arrays, respectively.  Use a temporary
1096         symbol and gfc_trans_assignment for all source=
1097         assignments to allocated objects besides for class and
1098         derived types.
1100 2015-05-19  Jakub Jelinek  <jakub@redhat.com>
1102         PR middle-end/66199
1103         * trans-openmp.c (gfc_trans_omp_teams): Set OMP_TEAMS_COMBINED for
1104         combined constructs.
1105         (gfc_trans_omp_target): Make sure BIND_EXPR has non-NULL
1106         BIND_EXPR_BLOCK.
1108 2015-05-19  David Malcolm  <dmalcolm@redhat.com>
1110         * cpp.c (maybe_print_line): Strengthen local "map" from
1111         const line_map * to const line_map_ordinary *.
1112         (cb_file_change): Likewise for param "map" and local "from".
1113         (cb_line_change): Likewise for local "map".
1115 2015-05-19  Mikhail Maltsev  <maltsevm@gmail.com>
1117         * interface.c (compare_actual_formal): Use std::swap instead of
1118         explicit swaps.
1119         * trans-array.c (gfc_trans_scalarized_loop_end): Likewise.
1120         * trans-intrinsic.c (walk_inline_intrinsic_transpose): Likewise.
1122 2015-05-18  Steven G. Kargl  <kargl@gcc.gnu.org>
1124         PR fortran/66106
1125         * interface.c(gfc_match_end_interface): Enforce F2008 C1202 (R1201).
1126         * match.c(gfc_op2string): Return 'none' for INTRINSIC_NONE.
1128 2015-05-18  Steven G. Kargl  <kargl@gcc.gnu.org>
1130         PR fortran/66057
1131         * decl.c(gfc_match_generic):  Detected a malformed GENERIC statement.
1133 2015-05-18  Steven G. Kargl  <kargl@gcc.gnu.org>
1135         PR fortran/66043
1136         * gfortran.dg/storage_size_6.f90: New tests.
1138 2015-05-18  Steven G. Kargl  <kargl@gcc.gnu.org>
1140         PR fortran/66043
1141         * gfortran.dg/storage_size_6.f90: New tests.
1143 2015-05-18  Steven G. Kargl  <kargl@gcc.gnu.org>
1145         PR fortran/66044
1146         * decl.c(gfc_match_entry):  Change a gfc_internal_error() into
1147         a gfc_error()
1149 2015-05-18  Steven G. Kargl  <kargl@gcc.gnu.org>
1151         PR fortran/66043
1152         * gfortran.dg/storage_size_6.f90: New tests.
1154 2015-05-18  Steven G. Kargl  <kargl@gcc.gnu.org>
1156         PR fortran/66040
1157         * parse.c(verify_st_order): Replace a gfc_internal_error with your
1158         generic gfc_error.
1160 2015-05-18  Steven G. Kargl  <kargl@gcc.gnu.org>
1162         PR fortran/66039
1163         * io.c (match_filepos): Check for incomplete/mangled REWIND, FLUSH,
1164         BACKSPACE, and ENDFILE statements
1166 2015-05-18  Steven G. Kargl  <kargl@gcc.gnu.org>
1168         PR fortran/64925
1169         * symbol.c(check_conflict):  Check for a conflict between a dummy
1170         argument and an internal procedure name.
1172 2015-05-16  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1174         PR fortran/65903
1175         * io.c (format_lex): Change to NONSTRING when checking for
1176         possible doubled quote.
1177         * scanner.c (gfc_next_char_literal): Revert change from 64506
1178         and add a check for quotes and return.
1180 2015-05-16  Thomas Koenig  <tkoenig@gcc.gnu.org>
1182         PR fortran/66113
1183         * expr.c (is_parent_of_current_ns):  New function.
1184         (check_restricted):  Use it.
1186 2015-05-16  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1188         PR fortran/44054
1190         Replace all calls to gfc_notify_std_1 with gfc_notify_std and
1191         gfc_warning_1 with gfc_warning.
1192         * decl.c (gfc_verify_c_interop_param): Here.
1193         * resolve.c (resolve_branch): Here.
1194         (resolve_fl_derived): Here.
1195         * dependency.c (gfc_check_argument_var_dependency):
1196         * scanner.c (preprocessor_line): Use gfc_warning_now_at. Fix line
1197         counter and locations before and after warning.
1198         * gfortran.h (gfc_warning_1, gfc_warning_now_1, gfc_notify_std_1):
1199         Delete.
1200         (gfc_warning_now_at): Declare.
1201         * error.c (gfc_warning_1): Delete.
1202         (gfc_notify_std_1): Delete.
1203         (gfc_warning_now_1): Delete.
1204         (gfc_format_decoder): Handle two locations.
1205         (gfc_diagnostic_build_prefix): Rename as
1206         gfc_diagnostic_build_kind_prefix.
1207         (gfc_diagnostic_build_locus_prefix): Take an expanded_location
1208         instead of diagnostic_info.
1209         (gfc_diagnostic_build_locus_prefix): Add overload that takes two
1210         expanded_location.
1211         (gfc_diagnostic_starter): Handle two locations.
1212         (gfc_warning_now_at): New.
1213         (gfc_diagnostics_init): Initialize caret_chars array.
1214         (gfc_diagnostics_finish): Reset caret_chars array to default.
1216 2015-05-16  Mikael Morin  <mikael@gcc.gnu.org>
1217             Paul Thomas  <pault@gcc.gnu.org>
1219         PR fortran/65792
1220         * trans-expr.c (gfc_trans_subcomponent_assign): Always assign
1221         the expression component to the destination. In addition, if
1222         the component has allocatable components, copy them and
1223         deallocate those of the expression, if it is not a variable.
1224         The expression is fixed if not a variable to prevent multiple
1225         evaluations.
1227 2015-05-12  Thomas Koenig  <tkoenig@gcc.gnu.org>
1229         PR fortran/66111
1230         * frontend-passes.c (has_dimen_vector_ref):  New function.
1231         (inline_matmul_assign):  Use it to return early in case
1232         of unhandled vector subscripts.
1234 2015-05-12  Thomas Koenig  <tkoenig@gcc.gnu.org>
1236         PR fortran/66041
1237         PR fortran/37131
1238         * gfortran.h (gfc_array_spec):  Add field resolved.
1239         * array.c (gfc_resolve_array_spec):  Resolve array spec
1240         only once.
1242 2015-05-11  Mikael Morin  <mikael@gcc.gnu.org>
1244         PR fortran/66100
1245         * simplify.c (simplify_bound): Fix assert to accept subobject arrays.
1247 2015-05-10  Thomas Koenig  <tkoenig@gcc.gnu.org>
1249         PR fortran/66041
1250         * frontend-passes.c (scalarized_expr): Set correct dimension and
1251         shape for the expression to be passed to lbound. Remove trailing
1252         references after array refrence.
1253         (inline_matmul_assign):  Remove gfc_copy_expr from calls
1254         to scalarized_expr().
1256 2015-05-10  Mikael Morin  <mikael@gcc.gnu.org>
1258         * simplify.c (simplify_bound_dim): Don't check for emptyness
1259         in the case of cobound simplification.  Factor lower/upper
1260         bound differenciation before the actual simplification.
1261         (simplify_bound): Remove assumed shape specific simplification.
1262         Don't give up early for the lbound of an assumed shape.
1264 2015-05-09  Mikael Morin  <mikael@gcc.gnu.org>
1266         PR fortran/65894
1267         * trans-array.h (gfc_scalar_elemental_arg_saved_as_reference):
1268         New prototype.
1269         * trans-array.c (gfc_scalar_elemental_arg_saved_as_reference):
1270         New function.
1271         (gfc_add_loop_ss_code): Use gfc_scalar_elemental_arg_saved_as_reference
1272         as conditional.
1273         (gfc_walk_elemental_function_args): Set the dummy_arg field.
1274         * trans.h (gfc_ss_info): New subfield dummy_arg.
1275         * trans-expr.c (gfc_conv_procedure_call): Revert the change
1276         of revision 222361.
1277         (gfc_conv_expr): Use gfc_scalar_elemental_arg_saved_as_reference
1278         as conditional.
1280 2015-05-08  Mikael Morin  <mikael@gcc.gnu.org>
1282         * trans-array.c (gfc_walk_elemental_function_args):
1283         Don't skip the advance to the next dummy argument when skipping
1284         absent optional args.
1286 2015-05-05  David Malcolm  <dmalcolm@redhat.com>
1288         * expr.c (check_inquiry): Fix indentation so that it reflects the
1289         block structure.
1290         * interface.c (compare_parameter): Likewise.
1291         * parse.c (parse_oacc_structured_block): Likewise.
1292         * target-memory.c (expr_to_char): Likewise.
1293         * trans-types.c (gfc_init_kinds): Likewise.
1295 2015-05-02  Steven G. Kargl  <kargl@gcc.gnu.org>
1297         PR fortran/65976
1298         * invoke.texi:  Remove 'no-' in '-fno-fixed-form'
1300 2015-05-01  Mikael Morin  <mikael@gcc.gnu.org>
1302         * simplify.c (simplify_bound_dim): Tighten the check for array fullness
1303         by also checking for absence of subreference.
1304         (simplify_bound): Don't skip simplification if the array
1305         has subreferences.
1306         (simplify_cobound): Same.
1308 2015-04-30  Thomas Koenig  <tkoenig@gcc.gnu.org>
1310         PR fortran/37131
1311         * simplify.c (simplify_bound): Get constant lower bounds of one
1312         from array spec for assumed and explicit shape shape arrays if
1313         the lower bounds are indeed one.
1315 2015-04-30  David Malcolm  <dmalcolm@redhat.com>
1317         * options.c (gfc_init_options): Remove spurious second
1318         semicolon.
1319         * trans-stmt.c (gfc_trans_allocate): Likewise.
1321 2015-04-28  Andre Vehreschild  <vehre@gmx.de>
1323         * interface.c (gfc_compare_types): Check for unlimited
1324         polymorphism flag in the correct position indepent of the _data
1325         component being present or not.  This prevents a segfault, when
1326         the _data component is not present.
1327         * symbol.c (gfc_type_compatible): Same.
1329 2015-04-27  Jim Wilson  <jim.wilson@linaro.org>
1331         * Make-lang.in (fortran.mostlyclean): Remove gfortran and
1332         gfortran-cross.
1334 2015-04-27  Andre Vehreschild  <vehre@gmx.de>
1336         PR fortran/59678
1337         PR fortran/65841
1338         * trans-array.c (duplicate_allocatable): Fixed deep copy of
1339         allocatable components, which are liable for copy only, when
1340         they are allocated.
1341         (gfc_duplicate_allocatable): Add deep-copy code into if
1342         component allocated block. Needed interface change for that.
1343         (gfc_copy_allocatable_data): Supplying NULL_TREE for code to
1344         add into if-block for checking whether a component was
1345         allocated.
1346         (gfc_duplicate_allocatable_nocopy): Likewise.
1347         (structure_alloc_comps): Likewise.
1348         * trans-array.h: Likewise.
1349         * trans-expr.c (gfc_trans_alloc_subarray_assign): Likewise.
1350         * trans-openmp.c (gfc_walk_alloc_comps): Likewise.
1352 2015-04-23  Andre Vehreschild  <vehre@gmx.de>
1354         PR fortran/60322
1355         * expr.c (gfc_lval_expr_from_sym): Code to select the regular
1356         or class array added.
1357         * gfortran.h: Add IS_CLASS_ARRAY macro.
1358         * trans-array.c (gfc_add_loop_ss_code): Treat class objects
1359         to be referenced always.
1360         (build_class_array_ref): Adapt retrieval of array descriptor.
1361         (build_array_ref): Likewise.
1362         (gfc_conv_array_ref): Hand the vptr or the descriptor to
1363         build_array_ref depending whether the sym is class or not.
1364         (gfc_trans_array_cobounds):  Select correct gfc_array_spec for
1365         regular and class arrays.
1366         (gfc_trans_array_bounds): Likewise.
1367         (gfc_trans_dummy_array_bias): Likewise.
1368         (gfc_get_dataptr_offset): Correcting call of build_array_ref.
1369         (gfc_conv_expr_descriptor): Set the array's offset to -1 when
1370         lbound in inner most dim is 1 and symbol non-pointer/assoc.
1371         * trans-decl.c (gfc_build_qualified_array): Select correct
1372         gfc_array_spec for regular and class arrays.
1373         (gfc_build_dummy_array_decl): Likewise.
1374         (gfc_get_symbol_decl): Get a dummy array for class arrays.
1375         (gfc_trans_deferred_vars): Tell conv_expr that the descriptor
1376         is desired.
1377         * trans-expr.c (gfc_class_vptr_get): Get the class descriptor
1378         from the correct location for class arrays.
1379         (gfc_class_len_get): Likewise.
1380         (gfc_conv_intrinsic_to_class): Add handling of _len component.
1381         (gfc_conv_class_to_class):  Prevent access to unset array data
1382         when the array is an optional argument. Add handling of _len
1383         component.
1384         (gfc_copy_class_to_class): Check that _def_init is non-NULL
1385         when used in _vptr->copy()
1386         (gfc_trans_class_init_assign): Ensure that the rank of
1387         _def_init is zero.
1388         (gfc_conv_component_ref): Get the _vptr along with _data refs.
1389         (gfc_conv_variable): Make sure the temp array descriptor is
1390         returned for class arrays, too, and that class arrays are
1391         dereferenced correctly.
1392         (gfc_conv_procedure_call): For polymorphic type initialization
1393         the initializer has to be a pointer to _def_init stored in a
1394         dummy variable, which then needs to be used by value.
1395         * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Use the
1396         temporary array descriptor for class arrays, too.
1397         (gfc_conv_intrinsic_storage_size): Likewise.
1398         (gfc_conv_intrinsic_loc): Add ref to _data for BT_CLASS
1399         expressions.
1400         * trans-stmt.c (trans_associate_var): Use a temporary array for
1401         the associate variable of class arrays, too, making the array
1402         one-based (lbound == 1).
1403         * trans-types.c (gfc_is_nodesc_array): Use the correct
1404         array data.
1405         * trans.c (gfc_build_array_ref): Use the dummy array descriptor
1406         when present.
1407         * trans.h: Add class_vptr to gfc_se for storing a class ref's
1408         vptr.
1410 2015-04-22  Steven G. Kargl  <kargl@gcc.gnu.org>
1412         PR fortran/65429
1413         * decl.c (add_init_expr_to_sym): Set the length type parameter.
1415 2015-04-10  Tobias Burnus  <burnus@net-b.de>
1417         * trans-stmt.c (gfc_trans_lock_unlock): Implement -fcoarray=lib
1418         version; reject not-yet-implemented variants.
1419         * trans-types.c (gfc_get_derived_type): For lock_type with
1420         -fcoarray=lib, use a void pointer as type.
1421         * trans.c (gfc_allocate_using_lib, gfc_allocate_allocatable):
1422         Handle lock_type with -fcoarray=lib.
1424 2015-04-10  Mikael Morin  <mikael@gcc.gnu.org>
1426         PR fortran/56674
1427         PR fortran/58813
1428         PR fortran/59016
1429         PR fortran/59024
1430         * symbol.c (save_symbol_data, gfc_save_symbol_data): Rename the
1431         former to the latter and make it non-static.  Update callers.
1432         * gfortran.h (gfc_save_symbol_data): New prototype.
1433         * decl.c (gfc_match_decl_type_spec): Call 'gfc_save_symbol_data'
1434         before modifying symbols 'sym' and 'dt_sym'.
1436 2013-04-09  Paul Thomas  <pault@gcc.gnu.org>
1438         PR fortran/56852
1439         * primary.c (gfc_variable_attr): Avoid ICE on AR_UNKNOWN if any
1440         of the index variables are untyped and errors are present.
1442 2015-04-07  Andre Vehreschild  <vehre@gmx.de>
1444         PR fortran/65548
1445         * trans-stmt.c (gfc_trans_allocate): For intrinsic functions
1446         use conv_expr_descriptor() instead of conv_expr_reference().
1448 2015-03-30  Jakub Jelinek  <jakub@redhat.com>
1450         PR fortran/65597
1451         * trans-openmp.c (gfc_trans_omp_do): For !simple simd with explicit
1452         linear clause for the iterator set OMP_CLAUSE_LINEAR_NO_COPYIN.
1453         For implcitly added !simple OMP_CLAUSE_LINEAR set it too.  Use step 1
1454         instead of the original step on the new iterator - count.
1456 2015-03-25  Mikael Morin  <mikael@gcc.gnu.org>
1458         PR fortran/64952
1459         PR fortran/65532
1460         * gfortran.h (struct gfc_namespace): New field 'types_resolved'.
1461         * resolve.c (resolve_types): Return early if field 'types_resolved'
1462         is set.  Set 'types_resolved' at the end.
1464 2015-03-24  Andre Vehreschild  <vehre@gmx.de>
1466         PR fortran/55901
1467         * trans-expr.c (gfc_conv_structure): Fixed indendation.
1468         Using integer_zero_node now instead of explicitly
1469         constructing a integer constant zero node.
1470         (gfc_conv_derived_to_class): Add handling of _len component,
1471         i.e., when the rhs has a string_length then assign that to
1472         class' _len, else assign 0.
1473         (gfc_conv_intrinsic_to_class): Likewise.
1475 2015-03-24  Andre Vehreschild  <vehre@gmx.de>
1477         PR fortran/64787
1478         PR fortran/57456
1479         PR fortran/63230
1480         * class.c (gfc_add_component_ref):  Free no longer needed
1481         ref-chains to prevent memory loss.
1482         (find_intrinsic_vtab): For deferred length char arrays or
1483         unlimited polymorphic objects, store the size in bytes of one
1484         character in the size component of the vtab.
1485         * gfortran.h: Added gfc_add_len_component () define.
1486         * trans-array.c (gfc_trans_create_temp_array): Switched to new
1487         function name for getting a class' vtab's field.
1488         (build_class_array_ref): Likewise.
1489         (gfc_array_init_size): Using the size information from allocate
1490         more consequently now, i.e., the typespec of the entity to
1491         allocate is no longer needed.  This is to address the last open
1492         comment in PR fortran/57456.
1493         (gfc_array_allocate): Likewise.
1494         (structure_alloc_comps): gfc_copy_class_to_class () needs to
1495         know whether the class is unlimited polymorphic.
1496         * trans-array.h: Changed interface of gfc_array_allocate () to
1497         reflect the no longer needed typespec.
1498         * trans-expr.c (gfc_find_and_cut_at_last_class_ref): New.
1499         (gfc_reset_len): New.
1500         (gfc_get_class_array_ref): Switch to new function name for
1501         getting a class' vtab's field.
1502         (gfc_copy_class_to_class):  Added flag to know whether the class
1503         to copy is unlimited polymorphic.  Adding _len dependent code
1504         then, which calls ->vptr->copy () with four arguments adding
1505         the length information ->vptr->copy(from, to, from_len, to_cap).
1506         (gfc_conv_procedure_call): Switch to new function name for
1507         getting a class' vtab's field.
1508         (alloc_scalar_allocatable_for_assignment): Use the string_length
1509         as computed by gfc_conv_expr and not the statically backend_decl
1510         which may be incorrect when ref-ing.
1511         (gfc_trans_assignment_1): Use the string_length variable and
1512         not the rse.string_length.  The former has been computed more
1513         generally.
1514         * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Switch to new
1515         function name for getting a class' vtab's field.
1516         (gfc_conv_intrinsic_storage_size): Likewise.
1517         (gfc_conv_intrinsic_transfer): Likewise.
1518         * trans-stmt.c (gfc_trans_allocate): Restructured to evaluate
1519         source=expr3 only once before the loop over the objects to
1520         allocate, when the objects are not arrays. Doing correct _len
1521         initialization and calling of vptr->copy () fixing PR 64787.
1522         (gfc_trans_deallocate): Reseting _len to 0, preventing future
1523         errors.
1524         * trans.c (gfc_build_array_ref): Switch to new function name
1525         for getting a class' vtab's field.
1526         (gfc_add_comp_finalizer_call): Likewise.
1527         * trans.h: Define the prototypes for the gfc_class_vtab_*_get ()
1528         and gfc_vptr_*_get () functions.
1529         Added gfc_find_and_cut_at_last_class_ref () and
1530         gfc_reset_len () routine prototype.  Added flag to
1531         gfc_copy_class_to_class () prototype to signal an unlimited
1532         polymorphic entity to copy.
1534 2015-03-24  Iain Sandoe  <iain@codesourcery.com>
1535             Tobias Burnus  <burnus@net-b.de>
1537         * gfortran.texi (_gfortran_caf_sync_memory): Improve wording.
1539 2015-03-23  Paul Thomas  <pault@gcc.gnu.org>
1540             Mikael Morin  <mikael@gcc.gnu.org>
1542         PR fortran/64952
1543         * gfortran.h (struct symbol_attribute) : New field
1544         'array_outer_dependency'.
1545         * trans.h (struct gfc_ss_info): New field 'array_outer_dependency'.
1546         * module.c (enum ab_attribute): New value AB_ARRAY_OUTER_DEPENDENCY.
1547         (attr_bits): Append same value to initializer.
1548         (mio_symbol_attribute): Handle 'array_outer_dependency' attr
1549         in module read and write.
1550         * resolve.c (update_current_proc_outer_array_dependency): New function.
1551         (resolve_function, resolve_call): Add code to update current procedure's
1552         'array_outer_dependency' attribute.
1553         (resolve_variable): Mark current procedure with attribute
1554         array_outer_dependency if the variable is an array coming from outside
1555         the current namespace.
1556         (resolve_fl_procedure): Mark a procedure without body with attribute
1557         'array_outer_dependency'.
1558         * trans-array.c (gfc_conv_resolve_dependencies): If any ss is
1559         marked as 'array_outer_dependency' generate a temporary.
1560         (gfc_walk_function_expr): If the function may reference external arrays,
1561         mark the head gfc_ss with flag 'array_outer_dependency'.
1563 2015-03-22 Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1565         PR libgfortran/59513
1566         * gfortran.texi (Read/Write after EOF marker): New information.
1568 2015-03-21  H.J. Lu  <hongjiu.lu@intel.com>
1570         * gfortran.texi (_gfortran_caf_sync_memory): Put @{xxx} in one
1571         line.
1573 2015-03-21  Tobias Burnus  <burnus@net-b.de>
1575         * gfortran.texi (_gfortran_caf_sync_all, _gfortran_caf_sync_images,
1576         _gfortran_caf_sync_memory, _gfortran_caf_error_stop,
1577         _gfortran_caf_error_stop_str, _gfortran_caf_atomic_define,
1578         _gfortran_caf_atomic_ref, _gfortran_caf_atomic_cas,
1579         _gfortran_caf_atomic_op): New sections.
1581 2015-03-21  Tobias Burnus  <burnus@net-b.de>
1583         * trans-expr.c (gfc_get_tree_for_caf_expr): Reject unimplemented
1584         coindexed coarray accesses.
1586 2015-03-17  Paul Thomas  <pault@gcc.gnu.org>
1588         PR fortran/59198
1589         * trans-types.c (gfc_get_derived_type): If an abstract derived
1590         type with procedure pointer components has no other type of
1591         component, return the backend_decl. Otherwise build the
1592         components if any of the non-procedure pointer components have
1593         no backend_decl.
1595 2015-03-16  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1597         PR fortran/64432
1598         *trans-intrinisic.c (conv_intrinsic_system_clock): Check the
1599         smallest kind passed in user arguments and hardcode tesults for
1600         KIND=1 or KIND=2 to indicate no clock available.
1602 2015-03-16  Andre Vehreschild  <vehre@gmx.de>
1604         * resolve.c: Prevent segfault on illegal input.
1606 2015-03-14  Mikael Morin  <mikael@gcc.gnu.org>
1608         PR fortran/61138
1609         * trans-expr.c (gfc_trans_pointer_assignment): Clear DESCRIPTOR_ONLY
1610         field before reusing LSE.
1612 2015-03-11  Janne Blomqvist  <jb@gcc.gnu.org>
1614         PR libfortran/65200
1615         * gfortran.texi: Document behavior when opening files without
1616         explicit ACTION= specifier.
1618 2015-03-10  Paul Thomas  <pault@gcc.gnu.org>
1620         PR fortran/65024
1621         * trans-expr.c (gfc_conv_component_ref): If the component
1622         backend declaration is missing and the derived type symbol is
1623         available in the reference, call gfc_build_derived_type.
1625 2015-03-10  Alessandro Fanfarillo  <fanfarillo.gcc@gmail.com>
1626             Tobias Burnus  <burnus@net-b.de>
1628         * trans.h (caf_sync_memory): New function decl tree.
1629         * trans-decl.c (gfc_build_builtin_function_decls): Define it.
1630         (create_main_function): Don't call sync_synchronize and leave
1631         it to the CAF library.
1632         * trans-stmt.c (gfc_trans_stop): Ditto.
1633         (gfc_trans_sync): Ditto; add call library call for sync memory.
1635 2015-03-08  Mikael Morin  <mikael@gcc.gnu.org>
1637         PR fortran/60898
1638         * resolve.c (resolve_symbol): Check that the symbol found by
1639         name lookup really is the current symbol being resolved.
1641 2015-03-02  Tobias Burnus  <burnus@net-b.de>
1643         * check.c (gfc_check_atomic): Properly check for coarrayness
1644         and for being coindexed.
1646 2015-02-26  Martin Liska  <mliska@suse.cz>
1648         * resolve.c: Rename enum 'comparison' to 'compare_result' as
1649         solution for -Wodr issue.
1651 2015-02-24  Thomas Schwinge  <thomas@codesourcery.com>
1653         PR libgomp/64625
1654         * f95-lang.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
1655         Remove macros.
1656         (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
1657         * types.def (BT_FN_VOID_INT_PTR_SIZE_PTR_PTR_PTR_INT_INT_VAR)
1658         (BT_FN_VOID_INT_OMPFN_PTR_SIZE_PTR_PTR_PTR_INT_INT_INT_INT_INT_VAR):
1659         Remove function types.
1660         (BT_FN_VOID_INT_SIZE_PTR_PTR_PTR)
1661         (BT_FN_VOID_INT_SIZE_PTR_PTR_PTR_INT_INT_VAR)
1662         (BT_FN_VOID_INT_OMPFN_SIZE_PTR_PTR_PTR_INT_INT_INT_INT_INT_VAR):
1663         New function types.
1665 2015-02-22  Bernd Edlinger  <bernd.edlinger@hotmail.de>
1667         PR fortran/64980
1668         PR fortran/61960
1669         * trans-expr.c (gfc_apply_interface_mapping_to_expr): Remove mapping
1670         for component references to class objects.
1671         (gfc_conv_procedure_call): Compare the class by name.
1673 2015-02-13  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1675         PR fortran/64506
1676         * scanner.c (gfc_next_char_literal): For free form source,
1677         check for '!' and if found, clear the comment and go back
1678         and get the next character. For fixed form source, skip the
1679         rest of the line.
1681 2015-02-12  Paul Thomas  <pault@gcc.gnu.org>
1683         PR fortran/64932
1684         * trans-stmt.c (gfc_trans_deallocate): If a component array
1685         expression is not a descriptor type and it is a derived type
1686         that has allocatable components and is not finalizable, then
1687         deallocate the allocatable components.
1689 2015-02-08  Mikael Morin  <mikael@gcc.gnu.org>
1691         PR fortran/63744
1692         * module.c (check_for_ambiguous): Change argument type
1693         from gfc_symbol to gfc_symtree.  Check local (symtree) name
1694         instead of original (symbol) name.
1695         (read_module): Update caller.
1697 2015-02-06  Paul Thomas  <pault@gcc.gnu.org>
1699         PR fortran/63205
1700         * gfortran.h: Add 'must finalize' field to gfc_expr and
1701         prototypes for gfc_is_alloc_class_scalar_function and for
1702         gfc_is_alloc_class_array_function.
1703         * expr.c (gfc_is_alloc_class_scalar_function,
1704         gfc_is_alloc_class_array_function): New functions.
1705         * trans-array.c (gfc_add_loop_ss_code): Do not move the
1706         expression for allocatable class scalar functions outside the
1707         loop.
1708         (conv_array_index_offset): Cope with deltas being NULL_TREE.
1709         (build_class_array_ref): Do not return with allocatable class
1710         array functions. Add code to pick out the returned class array.
1711         Dereference if necessary and return if not a class object.
1712         (gfc_conv_scalarized_array_ref): Cope with offsets being NULL.
1713         (gfc_walk_function_expr): Return an array ss for the result of
1714         an allocatable class array function.
1715         * trans-expr.c (gfc_conv_subref_array_arg): Remove the assert
1716         that the argument should be a variable. If an allocatable class
1717         array function, set the offset to zero and skip the write-out
1718         loop in this case.
1719         (gfc_conv_procedure_call): Add allocatable class array function
1720         to the assert. Call gfc_conv_subref_array_arg for allocatable
1721         class array function arguments with derived type formal arg..
1722         Add the code for handling allocatable class functions, including
1723         finalization calls to prevent memory leaks.
1724         (arrayfunc_assign_needs_temporary): Return if an allocatable
1725         class array function.
1726         (gfc_trans_assignment_1): Set must_finalize to rhs expression
1727         for allocatable class functions. Set scalar_to_array as needed
1728         for scalar class allocatable functions assigned to an array.
1729         Nullify the allocatable components corresponding the the lhs
1730         derived type so that the finalization does not free them.
1732 2015-01-29  Andre Vehreschild  <vehre@gmx.de>
1733             Janus Weil  <janus@gcc.gnu.org>
1735         PR fortran/60289
1736         Initial patch by Janus Weil
1737         * resolve.c (resolve_allocate_expr): Add check for comp. only
1738         when target is not unlimited polymorphic.
1739         * trans-stmt.c (gfc_trans_allocate): Assign correct value to
1740         _len component of unlimited polymorphic entities.
1742 2015-02-05  Tobias Burnus  <burnus@net-b.de>
1744         PR fortran/64943
1745         * resolve.c (resolve_transfer): Also check structure
1746         constructors.
1748 2015-02-05  Paul Thomas  <pault@gcc.gnu.org>
1750         PR fortran/64757
1751         * resolve.c (resolve_structure_cons): Obtain the rank of class
1752         components.
1753         * trans-expr.c (gfc_trans_alloc_subarray_assign): Do the
1754         assignment to allocatable class array components.
1755         (alloc_scalar_allocatable_for_subcomponent_assignment): If comp
1756         is a class component, allocate to the _data field.
1757         (gfc_trans_subcomponent_assign): If a class component with a
1758         derived type expression set the _vptr field and for array
1759         components, call gfc_trans_alloc_subarray_assign. For scalars,
1760         the assignment is performed here.
1762 2015-02-04  Jakub Jelinek  <jakub@redhat.com>
1764         * options.c: Include langhooks.h.
1765         (gfc_post_options): Change lang_hooks.name based on
1766         selected -std= mode.
1768 2015-02-03  Steven G. Kargl  <kargl@gcc.gnu.org>
1770         * intrinsic.texi (CO_ASSOCIATED): c_prt_1 should be c_ptr_1.
1772 2015-01-30  Andre Vehreschild  <vehre@gmx.de>
1774         * trans-decl.c (gfc_get_symbol_decl): Removed duplicate code.
1775         * trans-expr.c (gfc_conv_intrinsic_to_class): Fixed indentation.
1776         Fixed datatype of charlen to be a 32-bit int.
1778 2015-02-01  Joseph Myers  <joseph@codesourcery.com>
1780         * error.c (gfc_warning (const char *, ...), gfc_warning_now (const
1781         char *, ...)): Remove functions.
1782         * gfortran.h (gfc_warning (const char *, ...), gfc_warning_now
1783         (const char *, ...)): Remove declarations.
1784         * arith.c, check.c, data.c, decl.c, frontend-passes.c,
1785         interface.c, intrinsic.c, io.c, matchexp.c, module.c, openmp.c,
1786         options.c, parse.c, primary.c, resolve.c, scanner.c, symbol.c,
1787         trans-common.c, trans-const.c, trans-stmt.c: All callers of
1788         gfc_warning and gfc_warning_now changed to pass 0 or option number
1789         as first argument.
1791 2015-01-30  Joseph Myers  <joseph@codesourcery.com>
1793         * f95-lang.c, gfortranspec.c, trans-const.c, trans-expr.c: All
1794         callers of fatal_error changed to pass input_location as first
1795         argument.
1797 2015-01-28  Tobias Burnus  <burnus@net-b.de>
1799         * intrinsic.texi (CO_BROADCAST): Correct argument description.
1801 2015-01-27  Tobias Burnus  <burnus@net-b.de>
1803         PR fortran/63861
1804         * trans-openmp.c (gfc_has_alloc_comps, gfc_trans_omp_clauses):
1805         Fix handling for scalar coarrays.
1806         * trans-types.c (gfc_get_element_type): Add comment.
1808 2015-01-27  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1810         PR fortran/64771
1811         * interface.c: Remove <algorithm>.
1812         (check_dummy_characteristics): Use MAX instead of std::max.
1814 2015-01-26  Paul Thomas  <pault@gcc.gnu.org>
1816         PR fortran/62044
1817         * resolve.c (resolve_allocate_expr): If the default initializer
1818         is NULL, keep the original MOLD expression so that the correct
1819         typespec is available.
1821 2015-01-26  Tobias Burnus  <burnus@net-b.de>
1823         PR fortran/64771
1824         * interface.c (check_dummy_characteristics): Fix coarray handling.
1826 2015-01-26  Tobias Burnus  <burnus@net-b.de>
1828         * io.c (gfc_match_inquire): Replace "-1" by a defined constant.
1830 2015-01-26  Janus Weil  <janus@gcc.gnu.org>
1832         PR fortran/64230
1833         * class.c (finalize_component): New argument 'sub_ns'. Insert code to
1834         check if 'expr' is associated.
1835         (generate_finalization_wrapper): Rename 'ptr' symbols to 'ptr1' and
1836         'ptr2'. Pass 'sub_ns' to finalize_component.
1838 2015-01-25  Mikael Morin  <mikael@gcc.gnu.org>
1840         PR fortran/62044
1841         * decl.c (gfc_match_derived_decl): Don't insert a new symtree element.
1842         * module.c (MOD_VERSION): Bump.
1843         (write_module): Don't write list of extensions.
1844         (read_module): Don't jump over list of extensions;
1845         don't load list of extensions.
1846         (load_derived_extensions, write_dt_extensions,
1847          write_derived_extensions): Remove.
1849 2015-01-24  Tobias Burnus  <burnus@net-b.de>
1851         * parse.c (gfc_parse_file): Fix two-location gfc_error call.
1853 2015-01-23  Martin Liska  <mliska@suse.cz>
1855         * decl.c (attr_decl1): Workaround -Wmaybe-uninitialized
1856         false positive during profiledbootstrap by initializing them.
1857         * matchexp.c (match_mult_operand): Likewise.
1858         * module.c (write_atom): Likewise.
1859         (read_module): Likewise.
1861 2015-01-23  Tom de Vries  <tom@codesourcery.com>
1863         PR libgomp/64672
1864         * lang.opt (fopenacc): Mark as LTO option.
1866 2015-01-23  Tom de Vries  <tom@codesourcery.com>
1868         PR libgomp/64707
1869         * lang.opt (fopenmp): Mark as LTO option.
1871 2015-01-23  Andre Vehreschild  <vehre@gmx.de>
1873         * trans-decl.c (gfc_finish_var_decl): Fixed moved comment.
1874         * trans-stmt.c (gfc_trans_allocate): Fixed indentation.
1876 2015-01-23  Jakub Jelinek  <jakub@redhat.com>
1878         * gfc-diagnostic.def (DK_ICE_NOBT): New kind.
1880 2015-01-23  Janus Weil  <janus@gcc.gnu.org>
1882         PR fortran/60922
1883         * class.c (finalize_component): Apply the check for 'fini_coarray' only
1884         to coarray components.
1886 2015-01-23  Tobias Burnus  <burnus@net-b.de>
1888         PR fortran/64726
1889         * trans-openmp.c (gfc_trans_oacc_combined_directive): Fix
1890         loop generation.
1892 2015-01-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1894         PR fortran/61933
1895         * libgfortran.h:
1896         * trans-io.c (set_parameter_value): Delete use of has_iostat.
1897         Redefine to not generate any runtime error check calls.
1898         (set_parameter_value_chk): Rename of the former
1899         set_parameter_value with the runtime error checks and fix
1900         whitespace. (set_parameter_value_inquire): New function that
1901         builds a runtime conditional block to set the INQUIRE
1902         common parameter block unit number to -2 when unit numbers
1903         exceed positive KIND=4 limits. (gfc_trans_open): Whitespace.
1904         For unit, use the renamed set_parameter_value_chk.
1905         (gfc_trans_close): Likewise use renamed function.
1906         (build_filepos): Whitespace and use renamed function.
1907         (gfc_trans_inquire): Whitespace and for unit use
1908         set_parameter_value and set_parameter_value_inquire.
1909         (gfc_trans_wait): Remove p->iostat from call to
1910         set_parameter_value. Use new set_parameter_value_chk for unit.
1911         (build_dt): Use the new set_parameter_value without p->iostat
1912         and fix whitespace. Use set_parameter_value_chk for unit.
1914 2015-01-21  Thomas Koenig  <tkoenig@netcologne.de>
1916         PR fortran/57023
1917         * dependency.c (callback_dummy_intent_not_int):  New function.
1918         (dummy_intent_not_in):  New function.
1919         (gfc_full_array_ref_p):  Use dummy_intent_not_in.
1921 2015-01-18  Andre Vehreschild  <vehre@gmx.de>
1922             Janus Weil <janus@gcc.gnu.org>
1924         PR fortran/60255
1925         * class.c (gfc_get_len_component): New.
1926         (gfc_build_class_symbol): Add _len component to unlimited
1927         polymorphic entities.
1928         (find_intrinsic_vtab): Removed emitting of error message.
1929         * gfortran.h: Added prototype for gfc_get_len_component.
1930         * simplify.c (gfc_simplify_len): Use _len component where
1931         available.
1932         * trans-expr.c (gfc_class_len_get): New.
1933         (gfc_conv_intrinsic_to_class): Add handling for deferred
1934         character arrays.
1935         (gfc_conv_structure): Treat _len component correctly.
1936         (gfc_conv_expr): Prevent bind_c handling when not required.
1937         (gfc_trans_pointer_assignment): Propagate _len component.
1938         * trans-stmt.c (class_has_len_component): New.
1939         (trans_associate_var): _len component treatment for associate
1940         context.
1941         (gfc_trans_allocate): Same as for trans_associate_var()
1942         * trans.h: Added prototype for gfc_class_len_get.
1944 2015-01-18  Paul Thomas  <pault@gcc.gnu.org>
1946         PR fortran/57959
1947         * trans-expr.c (gfc_trans_subcomponent_assign): Use a deep copy
1948         for allocatable components, where the source is a variable.
1950 2015-01-18  Paul Thomas  <pault@gcc.gnu.org>
1952         PR fortran/55901
1953         * primary.c (gfc_match_varspec): Exclude dangling associate-
1954         names with dimension 0 from being counted as arrays.
1955         * resolve.c (resolve_assoc_var): Sub-strings are permissible
1956         for associate-names, so exclude characters from the test for
1957         misuse as arrays.
1958         * trans-decl.c (gfc_get_symbol_decl): Associate-names can use
1959         the hidden string length variable of their associated target.
1960         Signal this by setting 'length' to a constant, if the decl for
1961         the string length is a variable.
1963 2015-01-17  Paul Thomas  <pault@gcc.gnu.org>
1965         PR fortran/64578
1966         * trans-expr.c (gfc_trans_pointer_assignment): Make sure that
1967         before reinitializing rse, to add the rse.pre to block before
1968         creating 'ptrtemp'.
1969         * trans-intrinsic.c (gfc_conv_associated): Deal with the class
1970         data being a descriptor.
1972 2015-01-17  Andre Vehreschild  <vehre@gmx.de>
1974         PR fortran/60357
1975         * primary.c (build_actual_constructor): Prevent warning.
1976         * trans-expr.c (alloc_scalar_allocatable_for_subcomponent_
1977         assignment): New function encapsulates treatment of allocatable
1978         components.
1979         (gfc_trans_subcomponent_assign): Needed to distinguish between
1980         regular assignment and initilization.
1981         (gfc_trans_structure_assign): Same.
1982         (gfc_conv_structure): Same.
1984         PR fortran/61275
1985         * gfortran.h: deferred_parameter is not needed, because
1986         it artificial does the trick completely.
1987         * primary.c (build_actual_constructor): Same.
1988         (gfc_convert_to_structure_constructor): Same.
1989         * resolve.c (resolve_fl_derived0): Same.
1990         * trans-expr.c (gfc_conv_component_ref): Prevent treating
1991         allocatable deferred length char arrays here.
1992         (gfc_trans_subcomponent_assign): Same as above.
1993         * trans-types.c (gfc_sym_type): This is done in
1994         gfc_get_derived_type already.
1996 2015-01-17  Andre Vehreschild  <vehre@gmx.de>
1998         PR fortran/60334
1999         * trans-decl.c (gfc_get_symbol_decl):Use a ref on the string
2000         length when the symbol is declared to be a result.
2001         * trans-expr.c (gfc_conv_procedure_call): Strip deref on the
2002         string length when functions are nested and the string length
2003         is a reference already.
2005 2015-01-16  Janus Weil  <janus@gcc.gnu.org>
2007         PR fortran/45290
2008         * decl.c (match_pointer_init): Error out if resolution of init expr
2009         failed.
2011 2015-01-15  Tobias Burnus  <burnus@net-b.de>
2013         * openmp.c (check_symbol_not_pointer, resolve_oacc_data_clauses,
2014         resolve_oacc_deviceptr_clause, resolve_omp_clauses,
2015         gfc_resolve_oacc_declare): Replace '%s' by %qs.
2017 2015-01-15  Thomas Schwinge  <thomas@codesourcery.com>
2018             Cesar Philippidis  <cesar@codesourcery.com>
2019             James Norris  <jnorris@codesourcery.com>
2020             Ilmir Usmanov  <i.usmanov@samsung.com>
2021             Tobias Burnus  <burnus@net-b.de>
2023         * lang.opt (fopenacc): New option.
2024         * cpp.c (cpp_define_builtins): Conditionally define _OPENACC.
2025         * dump-parse-tree.c (show_omp_node): Split part of it into...
2026         (show_omp_clauses): ... this new function.
2027         (show_omp_node, show_code_node): Handle EXEC_OACC_PARALLEL_LOOP,
2028         EXEC_OACC_PARALLEL, EXEC_OACC_KERNELS_LOOP, EXEC_OACC_KERNELS,
2029         EXEC_OACC_DATA, EXEC_OACC_HOST_DATA, EXEC_OACC_LOOP,
2030         EXEC_OACC_UPDATE, EXEC_OACC_WAIT, EXEC_OACC_CACHE,
2031         EXEC_OACC_ENTER_DATA, EXEC_OACC_EXIT_DATA.
2032         (show_namespace): Update for OpenACC.
2033         * f95-lang.c (DEF_FUNCTION_TYPE_VAR_2, DEF_FUNCTION_TYPE_VAR_8)
2034         (DEF_FUNCTION_TYPE_VAR_12, DEF_GOACC_BUILTIN)
2035         (DEF_GOACC_BUILTIN_COMPILER): New macros.
2036         * types.def (BT_FN_VOID_INT_INT_VAR)
2037         (BT_FN_VOID_INT_PTR_SIZE_PTR_PTR_PTR_INT_INT_VAR)
2038         (BT_FN_VOID_INT_OMPFN_PTR_SIZE_PTR_PTR_PTR_INT_INT_INT_INT_INT_VAR):
2039         New function types.
2040         * gfortran.h (gfc_statement): Add ST_OACC_PARALLEL_LOOP,
2041         ST_OACC_END_PARALLEL_LOOP, ST_OACC_PARALLEL, ST_OACC_END_PARALLEL,
2042         ST_OACC_KERNELS, ST_OACC_END_KERNELS, ST_OACC_DATA,
2043         ST_OACC_END_DATA, ST_OACC_HOST_DATA, ST_OACC_END_HOST_DATA,
2044         ST_OACC_LOOP, ST_OACC_END_LOOP, ST_OACC_DECLARE, ST_OACC_UPDATE,
2045         ST_OACC_WAIT, ST_OACC_CACHE, ST_OACC_KERNELS_LOOP,
2046         ST_OACC_END_KERNELS_LOOP, ST_OACC_ENTER_DATA, ST_OACC_EXIT_DATA,
2047         ST_OACC_ROUTINE.
2048         (struct gfc_expr_list): New data type.
2049         (gfc_get_expr_list): New macro.
2050         (gfc_omp_map_op): Add OMP_MAP_FORCE_ALLOC, OMP_MAP_FORCE_DEALLOC,
2051         OMP_MAP_FORCE_TO, OMP_MAP_FORCE_FROM, OMP_MAP_FORCE_TOFROM,
2052         OMP_MAP_FORCE_PRESENT, OMP_MAP_FORCE_DEVICEPTR.
2053         (OMP_LIST_FIRST, OMP_LIST_DEVICE_RESIDENT, OMP_LIST_USE_DEVICE)
2054         (OMP_LIST_CACHE): New enumerators.
2055         (struct gfc_omp_clauses): Add async_expr, gang_expr, worker_expr,
2056         vector_expr, num_gangs_expr, num_workers_expr, vector_length_expr,
2057         wait_list, tile_list, async, gang, worker, vector, seq,
2058         independent, wait, par_auto, gang_static, and loc members.
2059         (struct gfc_namespace): Add oacc_declare_clauses member.
2060         (gfc_exec_op): Add EXEC_OACC_KERNELS_LOOP,
2061         EXEC_OACC_PARALLEL_LOOP, EXEC_OACC_PARALLEL, EXEC_OACC_KERNELS,
2062         EXEC_OACC_DATA, EXEC_OACC_HOST_DATA, EXEC_OACC_LOOP,
2063         EXEC_OACC_UPDATE, EXEC_OACC_WAIT, EXEC_OACC_CACHE,
2064         EXEC_OACC_ENTER_DATA, EXEC_OACC_EXIT_DATA.
2065         (gfc_free_expr_list, gfc_resolve_oacc_directive)
2066         (gfc_resolve_oacc_declare, gfc_resolve_oacc_parallel_loop_blocks)
2067         (gfc_resolve_oacc_blocks): New prototypes.
2068         * match.c (match_exit_cycle): Handle EXEC_OACC_LOOP and
2069         EXEC_OACC_PARALLEL_LOOP.
2070         * match.h (gfc_match_oacc_cache, gfc_match_oacc_wait)
2071         (gfc_match_oacc_update, gfc_match_oacc_declare)
2072         (gfc_match_oacc_loop, gfc_match_oacc_host_data)
2073         (gfc_match_oacc_data, gfc_match_oacc_kernels)
2074         (gfc_match_oacc_kernels_loop, gfc_match_oacc_parallel)
2075         (gfc_match_oacc_parallel_loop, gfc_match_oacc_enter_data)
2076         (gfc_match_oacc_exit_data, gfc_match_oacc_routine): New
2077         prototypes.
2078         * openmp.c: Include "diagnostic.h" and "gomp-constants.h".
2079         (gfc_free_omp_clauses): Update for members added to struct
2080         gfc_omp_clauses.
2081         (gfc_match_omp_clauses): Change mask paramter to uint64_t.  Add
2082         openacc parameter.
2083         (resolve_omp_clauses): Add openacc parameter.  Update for OpenACC.
2084         (struct fortran_omp_context): Add is_openmp member.
2085         (gfc_resolve_omp_parallel_blocks): Initialize it.
2086         (gfc_resolve_do_iterator): Update for OpenACC.
2087         (gfc_resolve_omp_directive): Call
2088         resolve_omp_directive_inside_oacc_region.
2089         (OMP_CLAUSE_PRIVATE, OMP_CLAUSE_FIRSTPRIVATE)
2090         (OMP_CLAUSE_LASTPRIVATE, OMP_CLAUSE_COPYPRIVATE)
2091         (OMP_CLAUSE_SHARED, OMP_CLAUSE_COPYIN, OMP_CLAUSE_REDUCTION)
2092         (OMP_CLAUSE_IF, OMP_CLAUSE_NUM_THREADS, OMP_CLAUSE_SCHEDULE)
2093         (OMP_CLAUSE_DEFAULT, OMP_CLAUSE_ORDERED, OMP_CLAUSE_COLLAPSE)
2094         (OMP_CLAUSE_UNTIED, OMP_CLAUSE_FINAL, OMP_CLAUSE_MERGEABLE)
2095         (OMP_CLAUSE_ALIGNED, OMP_CLAUSE_DEPEND, OMP_CLAUSE_INBRANCH)
2096         (OMP_CLAUSE_LINEAR, OMP_CLAUSE_NOTINBRANCH, OMP_CLAUSE_PROC_BIND)
2097         (OMP_CLAUSE_SAFELEN, OMP_CLAUSE_SIMDLEN, OMP_CLAUSE_UNIFORM)
2098         (OMP_CLAUSE_DEVICE, OMP_CLAUSE_MAP, OMP_CLAUSE_TO)
2099         (OMP_CLAUSE_FROM, OMP_CLAUSE_NUM_TEAMS, OMP_CLAUSE_THREAD_LIMIT)
2100         (OMP_CLAUSE_DIST_SCHEDULE): Use uint64_t.
2101         (OMP_CLAUSE_ASYNC, OMP_CLAUSE_NUM_GANGS, OMP_CLAUSE_NUM_WORKERS)
2102         (OMP_CLAUSE_VECTOR_LENGTH, OMP_CLAUSE_COPY, OMP_CLAUSE_COPYOUT)
2103         (OMP_CLAUSE_CREATE, OMP_CLAUSE_PRESENT)
2104         (OMP_CLAUSE_PRESENT_OR_COPY, OMP_CLAUSE_PRESENT_OR_COPYIN)
2105         (OMP_CLAUSE_PRESENT_OR_COPYOUT, OMP_CLAUSE_PRESENT_OR_CREATE)
2106         (OMP_CLAUSE_DEVICEPTR, OMP_CLAUSE_GANG, OMP_CLAUSE_WORKER)
2107         (OMP_CLAUSE_VECTOR, OMP_CLAUSE_SEQ, OMP_CLAUSE_INDEPENDENT)
2108         (OMP_CLAUSE_USE_DEVICE, OMP_CLAUSE_DEVICE_RESIDENT)
2109         (OMP_CLAUSE_HOST_SELF, OMP_CLAUSE_OACC_DEVICE, OMP_CLAUSE_WAIT)
2110         (OMP_CLAUSE_DELETE, OMP_CLAUSE_AUTO, OMP_CLAUSE_TILE): New macros.
2111         (gfc_match_omp_clauses): Handle those.
2112         (OACC_PARALLEL_CLAUSES, OACC_KERNELS_CLAUSES, OACC_DATA_CLAUSES)
2113         (OACC_LOOP_CLAUSES, OACC_PARALLEL_LOOP_CLAUSES)
2114         (OACC_KERNELS_LOOP_CLAUSES, OACC_HOST_DATA_CLAUSES)
2115         (OACC_DECLARE_CLAUSES, OACC_UPDATE_CLAUSES)
2116         (OACC_ENTER_DATA_CLAUSES, OACC_EXIT_DATA_CLAUSES)
2117         (OACC_WAIT_CLAUSES): New macros.
2118         (gfc_free_expr_list, match_oacc_expr_list, match_oacc_clause_gang)
2119         (gfc_match_omp_map_clause, gfc_match_oacc_parallel_loop)
2120         (gfc_match_oacc_parallel, gfc_match_oacc_kernels_loop)
2121         (gfc_match_oacc_kernels, gfc_match_oacc_data)
2122         (gfc_match_oacc_host_data, gfc_match_oacc_loop)
2123         (gfc_match_oacc_declare, gfc_match_oacc_update)
2124         (gfc_match_oacc_enter_data, gfc_match_oacc_exit_data)
2125         (gfc_match_oacc_wait, gfc_match_oacc_cache)
2126         (gfc_match_oacc_routine, oacc_is_loop)
2127         (resolve_oacc_scalar_int_expr, resolve_oacc_positive_int_expr)
2128         (check_symbol_not_pointer, check_array_not_assumed)
2129         (resolve_oacc_data_clauses, resolve_oacc_deviceptr_clause)
2130         (oacc_compatible_clauses, oacc_is_parallel, oacc_is_kernels)
2131         (omp_code_to_statement, oacc_code_to_statement)
2132         (resolve_oacc_directive_inside_omp_region)
2133         (resolve_omp_directive_inside_oacc_region)
2134         (resolve_oacc_nested_loops, resolve_oacc_params_in_parallel)
2135         (resolve_oacc_loop_blocks, gfc_resolve_oacc_blocks)
2136         (resolve_oacc_loop, resolve_oacc_cache, gfc_resolve_oacc_declare)
2137         (gfc_resolve_oacc_directive): New functions.
2138         * parse.c (next_free): Update for OpenACC.  Move some code into...
2139         (verify_token_free): ... this new function.
2140         (next_fixed): Update for OpenACC.  Move some code into...
2141         (verify_token_fixed): ... this new function.
2142         (case_executable): Add ST_OACC_UPDATE, ST_OACC_WAIT,
2143         ST_OACC_CACHE, ST_OACC_ENTER_DATA, and ST_OACC_EXIT_DATA.
2144         (case_exec_markers): Add ST_OACC_PARALLEL_LOOP, ST_OACC_PARALLEL,
2145         ST_OACC_KERNELS, ST_OACC_DATA, ST_OACC_HOST_DATA, ST_OACC_LOOP,
2146         ST_OACC_KERNELS_LOOP.
2147         (case_decl): Add ST_OACC_ROUTINE.
2148         (push_state, parse_critical_block, parse_progunit): Update for
2149         OpenACC.
2150         (gfc_ascii_statement): Handle ST_OACC_PARALLEL_LOOP,
2151         ST_OACC_END_PARALLEL_LOOP, ST_OACC_PARALLEL, ST_OACC_END_PARALLEL,
2152         ST_OACC_KERNELS, ST_OACC_END_KERNELS, ST_OACC_KERNELS_LOOP,
2153         ST_OACC_END_KERNELS_LOOP, ST_OACC_DATA, ST_OACC_END_DATA,
2154         ST_OACC_HOST_DATA, ST_OACC_END_HOST_DATA, ST_OACC_LOOP,
2155         ST_OACC_END_LOOP, ST_OACC_DECLARE, ST_OACC_UPDATE, ST_OACC_WAIT,
2156         ST_OACC_CACHE, ST_OACC_ENTER_DATA, ST_OACC_EXIT_DATA,
2157         ST_OACC_ROUTINE.
2158         (verify_st_order, parse_spec): Handle ST_OACC_DECLARE.
2159         (parse_executable): Handle ST_OACC_PARALLEL_LOOP,
2160         ST_OACC_KERNELS_LOOP, ST_OACC_LOOP, ST_OACC_PARALLEL,
2161         ST_OACC_KERNELS, ST_OACC_DATA, ST_OACC_HOST_DATA.
2162         (decode_oacc_directive, parse_oacc_structured_block)
2163         (parse_oacc_loop, is_oacc): New functions.
2164         * parse.h (struct gfc_state_data): Add oacc_declare_clauses
2165         member.
2166         (is_oacc): New prototype.
2167         * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Handle
2168         EXEC_OACC_PARALLEL_LOOP, EXEC_OACC_PARALLEL,
2169         EXEC_OACC_KERNELS_LOOP, EXEC_OACC_KERNELS, EXEC_OACC_DATA,
2170         EXEC_OACC_HOST_DATA, EXEC_OACC_LOOP, EXEC_OACC_UPDATE,
2171         EXEC_OACC_WAIT, EXEC_OACC_CACHE, EXEC_OACC_ENTER_DATA,
2172         EXEC_OACC_EXIT_DATA.
2173         (resolve_codes): Call gfc_resolve_oacc_declare.
2174         * scanner.c (openacc_flag, openacc_locus): New variables.
2175         (skip_free_comments): Update for OpenACC.  Move some code into...
2176         (skip_omp_attribute): ... this new function.
2177         (skip_oacc_attribute): New function.
2178         (skip_fixed_comments, gfc_next_char_literal): Update for OpenACC.
2179         * st.c (gfc_free_statement): Handle EXEC_OACC_PARALLEL_LOOP,
2180         EXEC_OACC_PARALLEL, EXEC_OACC_KERNELS_LOOP, EXEC_OACC_KERNELS,
2181         EXEC_OACC_DATA, EXEC_OACC_HOST_DATA, EXEC_OACC_LOOP,
2182         EXEC_OACC_UPDATE, EXEC_OACC_WAIT, EXEC_OACC_CACHE,
2183         EXEC_OACC_ENTER_DATA, EXEC_OACC_EXIT_DATA.
2184         * trans-decl.c (gfc_generate_function_code): Update for OpenACC.
2185         * trans-openmp.c: Include "gomp-constants.h".
2186         (gfc_omp_finish_clause, gfc_trans_omp_clauses): Use GOMP_MAP_*
2187         instead of OMP_CLAUSE_MAP_*.  Use OMP_CLAUSE_SET_MAP_KIND.
2188         (gfc_trans_omp_clauses): Handle OMP_LIST_USE_DEVICE,
2189         OMP_LIST_DEVICE_RESIDENT, OMP_LIST_CACHE, and OMP_MAP_FORCE_ALLOC,
2190         OMP_MAP_FORCE_DEALLOC, OMP_MAP_FORCE_TO, OMP_MAP_FORCE_FROM,
2191         OMP_MAP_FORCE_TOFROM, OMP_MAP_FORCE_PRESENT,
2192         OMP_MAP_FORCE_DEVICEPTR, and gfc_omp_clauses' async, seq,
2193         independent, wait_list, num_gangs_expr, num_workers_expr,
2194         vector_length_expr, vector, vector_expr, worker, worker_expr,
2195         gang, gang_expr members.
2196         (gfc_trans_omp_do): Handle EXEC_OACC_LOOP.
2197         (gfc_convert_expr_to_tree, gfc_trans_oacc_construct)
2198         (gfc_trans_oacc_executable_directive)
2199         (gfc_trans_oacc_wait_directive, gfc_trans_oacc_combined_directive)
2200         (gfc_trans_oacc_declare, gfc_trans_oacc_directive): New functions.
2201         * trans-stmt.c (gfc_trans_block_construct): Update for OpenACC.
2202         * trans-stmt.h (gfc_trans_oacc_directive, gfc_trans_oacc_declare):
2203         New prototypes.
2204         * trans.c (tranc_code): Handle EXEC_OACC_CACHE, EXEC_OACC_WAIT,
2205         EXEC_OACC_UPDATE, EXEC_OACC_LOOP, EXEC_OACC_HOST_DATA,
2206         EXEC_OACC_DATA, EXEC_OACC_KERNELS, EXEC_OACC_KERNELS_LOOP,
2207         EXEC_OACC_PARALLEL, EXEC_OACC_PARALLEL_LOOP, EXEC_OACC_ENTER_DATA,
2208         EXEC_OACC_EXIT_DATA.
2209         * gfortran.texi: Update for OpenACC.
2210         * intrinsic.texi: Likewise.
2211         * invoke.texi: Likewise.
2213 2015-01-15  Janus Weil  <janus@gcc.gnu.org>
2215         PR fortran/58023
2216         * resolve.c (resolve_fl_derived0): Continue resolving next component
2217         after error.
2219 2015-01-14  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2221         PR fortran/61933
2222         * io.c (gfc_match_inquire): Generate error if unit number in
2223         inquire statement is a constant -1.  All other values allowed.
2224         * trans-io.c (gfc_trans_inquire): Delete dummy iostat variable.
2225         (create_dummy_iostat): Delete function no longer used.
2227 2015-01-13  Jakub Jelinek  <jakub@redhat.com>
2229         PR fortran/64528
2230         * trans-decl.c (create_function_arglist): Don't set TREE_READONLY
2231         on dummy args with VALUE attribute.
2233 2015-01-11  Janus Weil  <janus@gcc.gnu.org>
2235         PR fortran/63733
2236         * interface.c (gfc_extend_expr): Look for type-bound operators before
2237         non-typebound ones.
2239 2015-01-11  Janus Weil  <janus@gcc.gnu.org>
2241         PR fortran/58023
2242         * resolve.c (resolve_fl_derived0): Set error flag if problems with the
2243         interface of a procedure-pointer component were detected.
2245 2015-01-11  Janus Weil  <janus@gcc.gnu.org>
2247         PR fortran/64508
2248         * interface.c (compare_parameter): Interface check for
2249         procedure-pointer component as actual argument.
2251 2015-01-10  Thomas Schwinge  <thomas@codesourcery.com>
2253         * gfortran.texi: Update for libgomp being renamed from "GNU OpenMP
2254         Runtime Library" to "GNU Offloading and Multi Processing Runtime
2255         Library".
2256         * intrinsic.texi: Likewise.
2258 2015-01-10  Tobias Burnus  <burnus@net-b.de>
2260         PR fortran/64522
2261         * invoke.texi (Wline-truncation): Document new behaviour.
2262         * lang.opt (Wline-truncation): Add Init(-1).
2263         * options.c (gfc_post_options): If -Wline-truncation is unset,
2264         enable it for free-form source files; for the latter, also use
2265         -Werror=line-truncation, unless -Wno-error has been specified.
2267 2015-01-09  Michael Collison  <michael.collison@linaro.org>
2269         * convert.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2270         input.h, alias.h, symtab.h, options.h, fold-const.h,
2271         wide-int.h, and inchash.h due to flattening of tree.h.
2272         * cpp.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2273         input.h, alias.h, symtab.h, fold-const.h,
2274         wide-int.h, and inchash.h due to flattening of tree.h.
2275         * decl.c: Ditto.
2276         * f95.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2277         input.h, alias.h, symtab.h, options.h, fold-const.h,
2278         wide-int.h, and inchash.h due to flattening of tree.h.
2279         * iresolve.c: Ditto.
2280         * match.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2281         input.h, alias.h, symtab.h, fold-const.h,
2282         wide-int.h, and inchash.h due to flattening of tree.h.
2283         * module.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2284         input.h, alias.h, symtab.h, options.h, fold-const.h,
2285         wide-int.h, and inchash.h due to flattening of tree.h.
2286         * options.c: Ditto.
2287         * target-memory.c: Include hash-set.h, vec.h,
2288         double-int.h, input.h, alias.h, symtab.h, fold-const.h,
2289         wide-int.h, and inchash.h due to flattening of tree.h.
2290         * trans-array.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2291         input.h, alias.h, symtab.h, options.h, fold-const.h,
2292         wide-int.h, and inchash.h due to flattening of tree.h.
2293         * trans.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2294         input.h, alias.h, symtab.h, options.h, fold-const.h,
2295         wide-int.h, and inchash.h due to flattening of tree.h.
2296         * trans-common.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2297         input.h, alias.h, symtab.h, fold-const.h,
2298         wide-int.h, and inchash.h due to flattening of tree.h.
2299         * trans-const.c: Ditto.
2300         * trans-decl.c: Ditto.
2301         * trans-expr.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2302         input.h, alias.h, symtab.h, options.h, fold-const.h,
2303         wide-int.h, and inchash.h due to flattening of tree.h.
2304         * trans-intrinsic.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2305         input.h, alias.h, symtab.h, fold-const.h,
2306         wide-int.h, inchash.h and real.h due to flattening of tree.h.
2307         * trans-io.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2308         input.h, alias.h, symtab.h, options.h, fold-const.h,
2309         wide-int.h, and inchash.h due to flattening of tree.h.
2310         * trans-openmp.c: Ditto.
2311         * trans-stmt.c: Ditto.
2312         * trans-types.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
2313         input.h, alias.h, symtab.h, fold-const.h,
2314         wide-int.h, inchash.h and real.h due to flattening of tree.h.
2316 2015-01-08  Tobias Burnus  <burnus@net-b.de>
2318         * trans-decl.c (gfc_build_qualified_array): Fix coarray tokens
2319         for module coarrays with -fcoarray=lib.
2320         (get_proc_pointer_decl): As module variable, make only public
2321         when not marked as private.
2323 2015-01-05  Thomas Koenig  <tkoenig@gcc.gnu.org>
2325         PR fortran/47674
2326         * dependency.h:  Actually commit changes.
2328 2015-01-05  Thomas Koenig  <tkoenig@gcc.gnu.org>
2330         PR fortran/47674
2331         * dependency.c:  Update copyright years.
2332         (gfc_discard_nops):  Add prototype.
2333         * dependency.c (discard_nops):  Rename to gfc_discard_nops,
2334         make non-static.
2335         (gfc_discard_nops):  Use gfc_discard_nops.
2336         (gfc_dep_difference):  Likewise.
2337         * frontend-passes.c  Update copyright years.
2338         (realloc_strings):  New function.  Add prototype.
2339         (gfc_run_passes):  Call realloc_strings.
2340         (realloc_string_callback):  New function.
2341         (create_var):  Add prototype.  Handle case of a
2342         scalar character variable.
2343         (optimize_trim):  Do not handle allocatable variables.
2345 2015-01-05  Jakub Jelinek  <jakub@redhat.com>
2347         Update copyright years.
2349         * gfortranspec.c (lang_specific_driver): Update copyright notice
2350         dates.
2351         * gfc-internals.texi: Bump @copying's copyright year.
2352         * gfortran.texi: Ditto.
2353         * intrinsic.texi: Ditto.
2354         * invoke.texi: Ditto.
2356 2015-01-02  Janus Weil  <janus@gcc.gnu.org>
2358         PR fortran/57562
2359         * expr.c (find_component_ref): Deal with extended types.
2361 2015-01-02  Tobias Burnus  <burnus@net-b.de>
2363         * trans-decl.c (gfc_build_qualified_array): Fix coarray tokens
2364         for module coarrays with -fcoarray=lib.
2366 2015-01-02  Janus Weil  <janus@gcc.gnu.org>
2368         PR fortran/60507
2369         * interface.c (is_procptr_result): New function to check if an
2370         expression is a procedure-pointer result.
2371         (compare_actual_formal): Use it.
2373 Copyright (C) 2015 Free Software Foundation, Inc.
2375 Copying and distribution of this file, with or without modification,
2376 are permitted in any medium without royalty provided the copyright
2377 notice and this notice are preserved.