Mercurial > hg > CbC > CbC_gcc
annotate gcc/testsuite/gfortran.dg/multiple_allocation_2.f90 @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
rev | line source |
---|---|
111 | 1 ! { dg-do run } |
2 ! PR 27470: This used fail because of confusion between | |
3 ! mol (allocatable) and mol(1)%array(:) (pointer). | |
4 ! Derived from a test case by FX Coudert. | |
5 PROGRAM MAIN | |
6 TYPE foo | |
7 INTEGER, DIMENSION(:), POINTER :: array | |
8 END TYPE foo | |
9 | |
10 type(foo),allocatable,dimension(:) :: mol | |
11 | |
12 ALLOCATE (mol(1)) | |
13 ALLOCATE (mol(1)%array(5)) | |
14 ALLOCATE (mol(1)%array(5)) | |
15 | |
16 END |