re PR fortran/59414 ([OOP] ICE in in gfc_conv_expr_descriptor on ALLOCATE inside SELECT TYPE)
2013-12-07 Janus Weil <janus@gcc.gnu.org> PR fortran/59414 * resolve.c (resolve_specific_f0): Handle CLASS-valued functions. 2013-12-07 Janus Weil <janus@gcc.gnu.org> PR fortran/59414 * gfortran.dg/class_result_2.f90: New. From-SVN: r205785
This commit is contained in:
parent
ef43c728f3
commit
36ad06d23a
|
@ -1,3 +1,8 @@
|
|||
2013-12-07 Janus Weil <janus@gcc.gnu.org>
|
||||
|
||||
PR fortran/59414
|
||||
* resolve.c (resolve_specific_f0): Handle CLASS-valued functions.
|
||||
|
||||
2013-12-04 Tobias Burnus <burnus@net-b.de>
|
||||
|
||||
PR debug/37132
|
||||
|
|
|
@ -2616,7 +2616,9 @@ found:
|
|||
expr->ts = sym->ts;
|
||||
expr->value.function.name = sym->name;
|
||||
expr->value.function.esym = sym;
|
||||
if (sym->as != NULL)
|
||||
if (sym->ts.type == BT_CLASS && CLASS_DATA (sym)->as)
|
||||
expr->rank = CLASS_DATA (sym)->as->rank;
|
||||
else if (sym->as != NULL)
|
||||
expr->rank = sym->as->rank;
|
||||
|
||||
return MATCH_YES;
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2013-12-07 Janus Weil <janus@gcc.gnu.org>
|
||||
|
||||
PR fortran/59414
|
||||
* gfortran.dg/class_result_2.f90: New.
|
||||
|
||||
2013-12-06 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR tree-optimization/59388
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
! { dg-do compile }
|
||||
!
|
||||
! PR 59414: [OOP] Class array pointers: compile error on valid code (Different ranks in pointer assignment)
|
||||
!
|
||||
! Contributed by Antony Lewis <antony@cosmologist.info>
|
||||
|
||||
implicit none
|
||||
|
||||
Type TObjectList
|
||||
end Type
|
||||
|
||||
Class(TObjectList), pointer :: Arr(:)
|
||||
Arr => ArrayItem()
|
||||
|
||||
contains
|
||||
|
||||
function ArrayItem() result(P)
|
||||
Class(TObjectList), pointer :: P(:)
|
||||
end function
|
||||
|
||||
end
|
Loading…
Reference in New Issue