1! RUN: %S/test_errors.sh %s %t %f18
2! Check for semantic errors in NULLIFY statements
3
4INTEGER, PARAMETER :: maxvalue=1024
5
6Type dt
7  Integer :: l = 3
8End Type
9Type t
10  Type(dt) :: p
11End Type
12
13Type(t),Allocatable :: x(:)
14
15Integer :: pi
16Procedure(Real) :: prp
17
18Allocate(x(3))
19!ERROR: component in NULLIFY statement must have the POINTER attribute
20Nullify(x(2)%p)
21
22!ERROR: name in NULLIFY statement must have the POINTER attribute
23Nullify(pi)
24
25!ERROR: name in NULLIFY statement must have the POINTER attribute
26Nullify(prp)
27
28!ERROR: name in NULLIFY statement must be a variable or procedure pointer name
29Nullify(maxvalue)
30
31End Program
32