+2018-02-14 Janus Weil <janus@gcc.gnu.org>
+
+ PR fortran/84385
+ * match.c (gfc_match_select_type): Fix check for selector in
+ SELECT TYPE statement.
+
2018-02-13 Janus Weil <janus@gcc.gnu.org>
PR fortran/84313
|| CLASS_DATA (expr1)->attr.codimension)
&& expr1->ref
&& expr1->ref->type == REF_ARRAY
+ && expr1->ref->u.ar.type == AR_FULL
&& expr1->ref->next == NULL);
- /* Check for F03:C811. */
+ /* Check for F03:C811 (F08:C835). */
if (!expr2 && (expr1->expr_type != EXPR_VARIABLE
|| (!class_array && expr1->ref != NULL)))
{
+2018-02-14 Janus Weil <janus@gcc.gnu.org>
+
+ PR fortran/84385
+ * gfortran.dg/allocate_with_source_22.f03: Fix invalid test case.
+ * gfortran.dg/allocate_with_source_23.f90: Ditto.
+ * gfortran.dg/select_type_1.f03: Extend test case.
+
2017-02-14 Uros Bizjak <ubizjak@gmail.com>
* gcc.target/i386/pr57193.c (dg-do): Remove target selector.
! with -fcheck=bounds.
if (size(b) /= 4) call abort()
if (any(b(1:2)%i /= [ 1,2])) call abort()
- select type (b(1))
+ select type (b1 => b(1))
class is (tt)
continue
class default
allocate(b(1:4), source=a(1))
if (size(b) /= 4) call abort()
if (any(b(:)%i /= [ 1,1,1,1])) call abort()
- select type (b(1))
+ select type (b1 => b(1))
class is (tt)
continue
class default
allocate(b(1:4), source=a) ! Fail expected: sizes do not conform
if (size(b) /= 4) call abort()
if (any(b(1:2)%i /= [ 1,2])) call abort()
- select type (b(1))
+ select type (b1 => b(1))
class is (tt)
continue
class default
end type
class(t1), pointer :: a => NULL()
+ class(t1), allocatable, dimension(:) :: ca
type(t1), target :: b
type(t2), target :: c
a => b
select type (3.5) ! { dg-error "is not a named variable" }
select type (a%cp) ! { dg-error "is not a named variable" }
+ select type (ca(1))! { dg-error "is not a named variable" }
select type (b) ! { dg-error "Selector shall be polymorphic" }
end select