/* Go straight to the class data. */
if (sym2->attr.dummy && !sym2->attr.optional)
{
- class_decl = DECL_LANG_SPECIFIC (sym2->backend_decl) ?
- GFC_DECL_SAVED_DESCRIPTOR (sym2->backend_decl) :
- sym2->backend_decl;
+ class_decl = sym2->backend_decl;
+ if (DECL_LANG_SPECIFIC (class_decl)
+ && GFC_DECL_SAVED_DESCRIPTOR (class_decl))
+ class_decl = GFC_DECL_SAVED_DESCRIPTOR (class_decl);
if (POINTER_TYPE_P (TREE_TYPE (class_decl)))
class_decl = build_fold_indirect_ref_loc (input_location,
class_decl);
contains
subroutine g(x)
real :: x(..)
- call h(x)
+ select rank (x)
+ rank (1)
+ call h(x)
+ end select
end
subroutine h(x)
real :: x(*)
subroutine test_array (a)
use iso_c_binding, only: c_size_t
class(*), dimension(..), target :: a
- call test_lib (a, int (sizeof (a), kind=c_size_t))
+ select rank (a)
+ rank (1)
+ call test_lib (a, int (sizeof (a), kind=c_size_t))
+ end select
end subroutine
end module
subroutine test_array (a)
use iso_c_binding, only: c_size_t
class(*), dimension(..), target :: a
- call test_lib (a, int (sizeof (a), kind=c_size_t))
+ select rank (a)
+ rank (1)
+ call test_lib (a, int (sizeof (a), kind=c_size_t))
+ end select
end subroutine
end module