1 2011-02-14 Janus Weil <janus@gcc.gnu.org>
4 * class.c (gfc_build_class_symbol): Give a fatal error on polymorphic
6 * primary.c (gfc_match_varspec): Avoid ICE for invalid class
9 2011-02-14 Janus Weil <janus@gcc.gnu.org>
12 * interface.c (get_expr_storage_size): Handle derived-type components.
14 2011-02-13 Tobias Burnus <burnus@net-b.de>
17 * interface.c (compare_parameter): Avoid ICE with
20 2011-02-12 Janus Weil <janus@gcc.gnu.org>
22 * class.c (gfc_build_class_symbol): Reject polymorphic arrays.
23 * decl.c (build_sym,build_struct,attr_decl1): Use return value of
24 'gfc_build_class_symbol'.
26 2011-02-12 Michael Matz <matz@suse.de>
27 Janus Weil <janus@gcc.gnu.org>
28 Tobias Burnus <burnus@net-b.de>
31 * trans-expr.c (conv_parent_component_references): Avoid unintendent
32 skipping of parent compounds.
34 2011-02-11 Tobias Burnus <burnus@net-b.de>
37 * resolve.c (resolve_formal_arglist): PURE with VALUE
38 and no INTENT: Add -std= diagnostics.
40 2011-02-09 Janus Weil <janus@gcc.gnu.org>
43 * resolve.c (resolve_procedure_interface): If interface has a result
44 variable, copy the typespec and set result pointer to self.
46 2011-02-09 Janus Weil <janus@gcc.gnu.org>
49 * resolve.c (resolve_typebound_subroutine): Remove erroneous line.
51 2011-02-09 Janus Weil <janus@gcc.gnu.org>
54 * trans-decl.c (init_intent_out_dt): Handle CLASS arguments.
56 2011-02-08 Jerry DeLisle <jvdelisle@gcc.gnu.org>
58 * io.c (match_io_element): Do not set dt if not inquire.
60 2011-02-08 Janus Weil <janus@gcc.gnu.org>
63 * expr.c (gfc_check_assign_symbol): Reject pointers as pointer
64 initialization target.
66 2011-02-07 Janne Blomqvist <jb@gcc.gnu.org>
67 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
69 * gfortran.texi (Thread-safety): texinfo styling fixes.
70 * intrinsic.texi: Likewise.
72 2011-02-06 Janne Blomqvist <jb@gcc.gnu.org>
74 * gfortran.texi (Compiler Characteristics): Add reference to
75 thread-safety section.
77 2011-02-06 Janne Blomqvist <jb@gcc.gnu.org>
79 * gfortran.texi (Thread-safety): New section.
80 * intrinsic.texi (EXECUTE_COMMAND_LINE): Mention thread-safety.
82 (GET_ENVIRONMENT_VARIABLE): Likewise.
85 2011-02-06 Paul Thomas <pault@gcc.gnu.org>
88 * trans-stmt.c (gfc_trans_allocate): For deferred character
89 length allocations with SOURCE, store to the values and string
90 length to avoid calculating twice. Replace gfc_start_block
91 with gfc_init_block to avoid unnecessary contexts and to keep
92 declarations of temporaries where they should be. Tidy up the
95 2011-02-05 Janne Blomqvist <jb@gcc.gnu.org>
98 * intrinsic.texi (SYSTEM_CLOCK): Update documentation.
100 2011-02-02 Janus Weil <janus@gcc.gnu.org>
101 Paul Thomas <pault@gcc.gnu.org>
104 * trans-expr.c (gfc_trans_class_init_assign): Add call to
105 gfc_get_derived_type.
106 * module.c (read_cleanup): Do not use unique_symtrees for vtabs
109 2011-02-02 Janus Weil <janus@gcc.gnu.org>
112 * resolve.c (resolve_fl_variable): Handle polymorphic allocatables.
114 2011-02-01 Janus Weil <janus@gcc.gnu.org>
117 * trans-expr.c (gfc_conv_structure): Handle constructors for procedure
118 pointer components with allocatable result.
120 2011-01-31 Janus Weil <janus@gcc.gnu.org>
123 * trans-expr.c (gfc_conv_procedure_call): Handle procedure pointers
124 with pointer or allocatable result.
126 2011-01-31 Paul Thomas <pault@gcc.gnu.org>
129 * trans-stmt.c (gfc_trans_allocate): Improve handling of
130 deferred character lengths with SOURCE.
131 * iresolve.c (gfc_resolve_repeat): Calculate character
132 length from source length and ncopies.
133 * dump-parse-tree.c (show_code_node): Show MOLD and SOURCE
134 expressions for ALLOCATE.
136 2011-01-31 Janus Weil <janus@gcc.gnu.org>
139 * resolve.c (resolve_typebound_subroutine): Bug fix for the case of
140 an argument of a typebound assignment being a component.
142 2011-01-31 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
144 * gfortranspec.c (add_arg_libgfortran) [HAVE_LD_STATIC_DYNAMIC] Use
145 LD_STATIC_OPTION, LD_DYNAMIC_OPTION.
147 2011-01-31 Tobias Burnus <burnus@net-b.de>
150 * resolve.c (resolve_fl_procedure): Reject stmt functions
151 with pointer/allocatable attribute.
153 2011-01-31 Tobias Burnus <burnus@net-b.de>
156 * interface.c (gfc_procedure_use): Add explicit interface check for
157 pointer/allocatable functions.
159 2011-01-30 Paul Thomas <pault@gcc.gnu.org>
162 * trans-expr.c (gfc_trans_assignment_1): If the rhs is an op
163 expr and is assigned to a deferred character length scalar,
164 make sure that the function is called before reallocation,
165 so that the length is available. Include procedure pointer
166 and procedure pointer component rhs as well.
171 * gfortran.dg/allocatable_function_5.f90: New test not added by
172 mistake on 2011-01-28.
174 2011-01-29 Tobias Burnus <burnus@net-b.de>
177 * check.c (gfc_check_shape): Support kind argument in SHAPE.
178 * intrinsic.c (add_functions): Ditto.
179 * resolve.c (gfc_resolve_shape): Ditto.
180 * simplify.c (gfc_simplify_shape): Ditto.
181 * intrinsic.h (gfc_check_shape, gfc_resolve_shape,
182 gfc_simplify_shape): Update prototypes.
183 * intrinisc.text (SHAPE): Document kind argument.
185 2011-01-28 Tobias Burnus <burnus@net-b.de>
188 * resolve.c (resolve_formal_arglist): Allow arguments with VALUE
189 attribute also without INTENT.
191 2011-01-28 Tobias Burnus <burnus@net-b.de>
193 * gfortran.texi (Fortran 2003 status): Mention support for
194 nonconstant namelist variables.
196 2011-01-28 Paul Thomas <pault@gcc.gnu.org>
197 Tobias Burnus <burnus@gcc.gnu.org>
202 * interface.c (compare_actual_formal): An allocatable or pointer
203 deferred length actual is only allowed if the formal argument
204 is also deferred length. Clean up whitespace.
205 * trans-expr.c (gfc_conv_procedure_call): Pass string length for
206 deferred character length formal arguments by reference. Do the
207 same for function results.
208 (gfc_trans_pointer_assignment): Do not do runtime check of lhs
209 and rhs character lengths, if deferred length lhs. In this case
210 set the lhs character length to that of the rhs.
211 (gfc_conv_string_parameter): Remove assert that string length is
213 (is_scalar_reallocatable_lhs): New function.
214 (alloc_scalar_allocatable_for_assignment): New function.
215 (gfc_trans_assignment_1): Call above new function. If the rhs is
216 a deferred character length itself, makes ure that the function
217 is called before reallocation, so that the length is available.
218 (gfc_trans_asssignment): Remove error about assignment to
219 deferred length character variables.
220 * gfortran.texi : Update entry about (re)allocation on
222 * trans-stmt.c (gfc_trans_allocate): Add code to handle deferred
223 length character variables.
224 * module.c (mio_typespec): Transfer deferred characteristic.
225 * trans-types.c (gfc_get_function_type): New code to generate
226 hidden typelist, so that those character lengths that are
227 passed by reference get the right type.
228 * resolve.c (resolve_contained_fntype): Supress error for
229 deferred character length functions.
230 (resolve_function, resolve_fl_procedure) The same.
231 (check_symbols): Remove the error that support for
232 entity with deferred type parameter is not yet implemented.
233 (resolve_fl_derived): The same.
234 match.c (alloc_opt_list): Allow MOLD for deferred length object.
235 * trans-decl.c (gfc_get_symbol_decl): For deferred character
236 length dummies, generate a local variable for string length.
237 (create_function_arglist): Hidden length can be a pointer.
238 (gfc_trans_deferred_vars): For deferred character length
239 results and dummies, assign the string length to the local
240 variable from the hidden argument on entry and the other way
241 round on exit, as appropriate.
243 2011-01-27 Tobias Burnus <burnus@net-b.de>
246 * trans-decl.c (gfc_generate_function_code): Fix init
247 of allocatable result variable with allocatable components.
249 2011-01-27 Tobias Burnus <burnus@net-b.de>
252 * options.c (gfc_handle_module_path_options): Save
253 module path without trailing slash as include path.
255 2011-01-25 Tobias Burnus <burnus@net-b.de>
258 * interface.c (gfc_check_operator_interface): Fix
259 defined-assignment check.
261 2011-01-23 Tobias Burnus <burnus@net-b.de>
264 * trans-decl.c (gfc_trans_deferred_vars): Do not nullify
265 scalar allocatable dummy arguments.
267 2011-01-22 Thomas Koenig <tkoenig@gcc.gnu.org>
270 * resolve.c (gfc_iso_c_func_interface): For C_LOC,
271 check for array sections followed by component references
272 which are illegal. Also check for coindexed arguments.
274 2011-01-22 Tobias Burnus <burnus@net-b.de>
277 * primary.c (gfc_match_varspec): Relax gcc_assert to allow for
280 2011-01-21 Tobias Burnus <burnus@net-b.de>
283 * error.c (gfc_error_now, gfc_fatal_error, gfc_error_check):
284 Use defined instead of magic number exit status codes.
285 * scanner.c (include_line, gfc_new_file): Ditto.
287 2011-01-21 Tobias Burnus <burnus@net-b.de>
290 * expr.c (gfc_check_pointer_assign): Reject expr data-targets
291 without pointer attribute.
293 2011-01-18 Janus Weil <janus@gcc.gnu.org>
296 * resolve.c (expression_rank): Fix rank of procedure poiner components.
297 * trans-expr.c (gfc_conv_procedure_call): Take care of procedure
298 pointer components as actual arguments.
300 2011-01-17 Jakub Jelinek <jakub@redhat.com>
303 * gfortran.h (struct gfc_omp_saved_state): New type.
304 (gfc_omp_save_and_clear_state, gfc_omp_restore_state): New prototypes.
305 * resolve.c (resolve_global_procedure): Call it around gfc_resolve
307 * openmp.c (gfc_omp_save_and_clear_state, gfc_omp_restore_state): New
310 2011-01-17 Tobias Burnus <burnus@net-b.de>
313 * invoke.texi (Options to request or suppress errors
314 and warnings): Fix cross link.
316 2011-01-15 Tobias Burnus <burnus@net-b.de>
318 * gfortran.texi: Update Fortran 2003 Status section.
321 * invoke.texi: Add missing "-E" to the -dM example.
323 2011-01-13 Tobias Burnus <burnus@net-b.de>
326 * intrinsic.texi (get_command_argument, get_environment_variable):
327 Mark arguments as optional in the Arguments section.
329 2011-01-13 Kai Tietz <kai.tietz@onevision.com>
330 Tobias Burnus <burnus@net-b.de>
333 * trans-decl.c (gfc_get_extern_function_decl,
334 build_function_decl): Set TREE_PUBLIC/TREE_EXTERNAL before
335 calling decl_attributes.
337 2011-01-13 Tobias Burnus <burnus@net-b.de>
338 Mikael Morin <mikael@gcc.gnu.org>
342 * gfortran.h (gfc_code): Move union ext's case_list into
344 * dump-parse-tree.c (show_code_node): Adapt by prefixing case_list
346 * frontend-passes.c (gfc_code_walker): Ditto.
347 * match.c (gfc_match_goto, gfc_match_call, gfc_match_case,
348 gfc_match_type_is, gfc_match_class_is): Ditto.
349 * resolve.c (resolve_select, resolve_select_type): Ditto.
350 * st.c (gfc_free_statement): Ditto.
351 * trans-stmt.c (gfc_trans_integer_select, gfc_trans_logical_select,
352 gfc_trans_character_select): Ditto.
353 * parse.c (resolve_all_program_units): For error recovery, avoid
354 segfault is proc_name is NULL.
356 2011-01-11 Paul Thomas <pault@gcc.gnu.org>
359 * trans-array.c (gfc_alloc_allocatable_for_assignment): Change
360 to be standard compliant by testing for shape rather than size
361 before skipping reallocation. Improve comments.
363 2011-01-09 Janus Weil <janus@gcc.gnu.org>
366 * resolve.c (resolve_actual_arglist): Remove unneeded and buggy piece
369 2011-01-09 Thomas Koenig <tkoenig@gcc.gnu.org>
372 * resolve.c (is_scalar_expr_ptr): For a substring reference,
373 use gfc_dep_compare_expr to compare start and end expession.
374 Add FIXME for using gfc_deb_compare_expr elsewhere.
376 2011-01-09 Janus Weil <janus@gcc.gnu.org>
379 * class.c (get_unique_type_string): Make type name start with upper
382 2011-01-08 Thomas Koenig <tkoenig@gcc.gnu.org>
385 * invoke.texi: Mention -ffree-line-length-none and
386 -ffixed-line-length-none for preprocessing.
388 2011-01-08 Paul Thomas <pault@gcc.gnu.org>
391 * trans-expr.c (gfc_conv_procedure_call): With a non-copying
392 procedure argument (eg TRANSPOSE) use a temporary if there is
393 any chance of aliasing due to host or use association.
394 (arrayfunc_assign_needs_temporary): Correct logic for function
395 results and do not use a temporary for implicitly PURE
396 variables. Use a temporary for Cray pointees.
397 * symbol.c (gfc_add_save): Explicit SAVE not compatible with
398 implicit pureness of containing procedure.
399 * decl.c (match_old_style_init, gfc_match_data): Where decl
400 would fail in PURE procedure, set implicit_pure to zero.
401 * gfortran.h : Add implicit_pure to structure symbol_attr and
402 add prototype for function gfc_implicit_pure.
403 * expr.c (gfc_check_pointer_assign, gfc_check_vardef_context):
404 Where decl would fail in PURE procedure, reset implicit_pure.
405 * io.c (match_vtag, gfc_match_open, gfc_match_close,
406 gfc_match_print, gfc_match_inquire, gfc_match_wait): The same.
407 * match.c (gfc_match_critical, gfc_match_stopcode,
408 sync_statement, gfc_match_allocate, gfc_match_deallocate): The
410 * parse.c (decode_omp_directive): The same.
411 (parse_contained): If not PURE, set implicit pure attribute.
412 * resolve.c (resolve_formal_arglist, resolve_structure_cons,
413 resolve_function, resolve_ordinary_assign) : The same.
414 (gfc_implicit_pure): New function.
415 * module.c (mio_symbol_attribute): Introduce AB_IMPLICIT_PURE
416 to ab_attribute enum and use it in this function.
418 2011-01-08 Thomas Koenig <tkoenig@gcc.gnu.org>
421 * symbol.c (gfc_symbols_could_alias): Strip gfc_ prefix,
422 make static and move in front of its only caller, to ...
423 * trans-array.c (symbols_could_alias): ... here.
424 Pass information about pointer and target status as
425 arguments. Allocatable arrays don't alias anything
426 unless they have the POINTER attribute.
427 (gfc_could_be_alias): Keep track of pointer and target
428 status when following references. Also check if typespecs
429 of components match those of other components or symbols.
431 2011-01-07 Tobias Burnus <burnus@net-b.de>
434 * class.c (gfc_build_class_symbol): Mark __vtab as attr.vtab.
435 * intrinsic.c (add_functions): Use simplify functions for
436 EXTENDS_TYPE_OF and SAME_TYPE_AS.
437 * intrinsic.h (gfc_simplify_extends_type_of,
438 gfc_simplify_same_type_as): New prototypes.
439 * simplify.c (is_last_ref_vtab, gfc_simplify_extends_type_of,
440 gfc_simplify_same_type_as): New functions.
442 2011-01-07 Janus Weil <janus@gcc.gnu.org>
446 * gfortran.h (gfc_lval_expr_from_sym): Moved prototype.
447 * class.c (gfc_class_null_initializer): Initialize _vptr to declared
449 * expr.c (gfc_lval_expr_from_sym): Moved here from symbol.c.
450 * resolve.c (resolve_deallocate_expr): _data component will be added
451 at translation stage.
452 * symbol.c (gfc_lval_expr_from_sym): Moved to expr.c.
453 * trans-stmt.c (gfc_trans_deallocate): Reset _vptr to declared type.
455 2011-01-06 Daniel Franke <franke.daniel@gmail.com>
459 * parse.c (parse_interface): Remove check for procedure types.
460 * interface.c (check_interface0): Verify that procedures are
461 either all SUBROUTINEs or all FUNCTIONs.
463 2011-01-05 Janus Weil <janus@gcc.gnu.org>
466 * trans-expr.c (gfc_trans_class_assign): Bugfix for r168524 (make sure
467 'vtab' is initialized).
469 2011-01-05 Janus Weil <janus@gcc.gnu.org>
472 * trans-expr.c (gfc_trans_class_assign): For a polymorphic NULL pointer
473 assignment, set the _vptr component to the declared type.
475 2011-01-05 Thomas Koenig <tkoenig@gcc.gnu.org>
478 * resolve.c (resolve_allocate_deallocate): Follow references to
479 check for duplicate occurence of allocation/deallocation objects.
481 2011-01-05 Janus Weil <janus@gcc.gnu.org>
484 * trans-decl.c (gfc_trans_deferred_vars): Initialize the _vpr component
485 of polymorphic allocatables according to their declared type.
487 2011-01-04 Janus Weil <janus@gcc.gnu.org>
490 * class.c (gfc_find_derived_vtab): Set the module field for the copying
491 routine to make sure it receives module name mangling.
493 2011-01-03 Jakub Jelinek <jakub@redhat.com>
495 * gfortranspec.c (lang_specific_driver): Update copyright notice
498 2011-01-03 Janus Weil <janus@gcc.gnu.org>
500 * intrinsic.texi (LEADZ): Fix example.
502 2011-01-02 Janus Weil <janus@gcc.gnu.org>
505 * class.c (gfc_find_derived_vtab): Use EXEC_INIT_ASSIGN for __copy_
509 Copyright (C) 2011 Free Software Foundation, Inc.
511 Copying and distribution of this file, with or without modification,
512 are permitted in any medium without royalty provided the copyright
513 notice and this notice are preserved.