This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Patch, fortran] PR34681 & PR34704 (4.3 regression) - default initialisers/allocatable/allocatable components


:ADDPATCH fortran:

The attached patch corrects a couple of errors in the application of
default initializers to arrays of derived types with allocatable
components, especially where the array is allocatable.

Regtested on Cygwin_NT - OK for trunk?

I will bootstrap and regtest on x86_ia64 before committing.

Paul

2008-01-08  Paul Thomas  <pault@gcc.gnu.org>

	PR fortran/34681
	* trans_array.c (gfc_trans_deferred_array): Do not null the
	data pointer on entering scope, nor deallocate it on leaving
	scope, if the symbol has the 'save' attribute.

	PR fortran/34704
	* trans_decl.c (gfc_finish_var_decl): Derived types with
	allocatable components and an initializer must be TREE_STATIC.

2008-01-08  Paul Thomas  <pault@gcc.gnu.org>

	PR fortran/34681
	PR fortran/34704
	* gfortran.dg/alloc_comp_default_init_1.f90: New test.

-- 
The knack of flying is learning how to throw yourself at the ground and miss.
       --Hitchhikers Guide to the Galaxy

Attachment: submit.diff
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]