Mercurial > hg > CbC > CbC_gcc
annotate gcc/testsuite/gfortran.dg/move_alloc_5.f90 @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children |
rev | line source |
---|---|
111 | 1 ! { dg-do run } |
2 ! | |
3 ! PR 48699: [4.6/4.7 Regression] [OOP] MOVE_ALLOC inside SELECT TYPE | |
4 ! | |
5 ! Contributed by Salvatore Filippone <sfilippone@uniroma2.it> | |
6 | |
7 program testmv1 | |
8 | |
9 type bar | |
10 end type | |
11 | |
12 type, extends(bar) :: bar2 | |
13 end type | |
14 | |
15 class(bar), allocatable :: sm | |
16 type(bar2), allocatable :: sm2 | |
17 | |
18 allocate (sm2) | |
19 call move_alloc (sm2,sm) | |
20 | |
131 | 21 if (allocated(sm2)) STOP 1 |
22 if (.not. allocated(sm)) STOP 2 | |
111 | 23 |
24 end program |