repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
2011-05-23 Tom de Vries <tom@codesourcery.com>
[official-gcc.git]
/
gcc
/
testsuite
/
gfortran.dg
/
allocatable_scalar_11.f90
blob
b9fb1085760688c91d1ed77e82e33ad00021d3d4
1
! { dg-do compile }
2
!
3
! PR fortran/46484
4
!
5
6
function
g
()
7
implicit none
8
integer
,
allocatable
::
g
9
call
int
()
10
print
*,
loc
(
g
)
! OK
11
contains
12
subroutine
int
()
13
print
*,
loc
(
g
)
! OK
14
print
*,
allocated
(
g
)
! OK
15
end subroutine
int
16
end function
17
18
implicit none
19
integer
,
allocatable
::
x
20
print
*,
allocated
(
f
)
! { dg-error "must be a variable" }
21
print
*,
loc
(
f
)
! OK
22
contains
23
function
f
()
24
integer
,
allocatable
::
f
25
print
*,
loc
(
f
)
! OK
26
print
*,
allocated
(
f
)
! OK
27
end function
28
end