1! RUN: %S/test_errors.sh %s %t %f18 2program p1 3 integer(8) :: a, b, c, d 4 pointer(a, b) 5 !ERROR: 'b' cannot be a Cray pointer as it is already a Cray pointee 6 pointer(b, c) 7 !ERROR: 'a' cannot be a Cray pointee as it is already a Cray pointer 8 pointer(d, a) 9end 10 11program p2 12 pointer(a, c) 13 !ERROR: 'c' was already declared as a Cray pointee 14 pointer(b, c) 15end 16 17program p3 18 real a 19 !ERROR: Cray pointer 'a' must have type INTEGER(8) 20 pointer(a, b) 21end 22 23program p4 24 implicit none 25 real b 26 !ERROR: No explicit type declared for 'd' 27 pointer(a, b), (c, d) 28end 29 30program p5 31 integer(8) a(10) 32 !ERROR: Cray pointer 'a' must be a scalar 33 pointer(a, b) 34end 35 36program p6 37 real b(8) 38 !ERROR: Array spec was already declared for 'b' 39 pointer(a, b(4)) 40end 41 42program p7 43 !ERROR: Cray pointee 'b' must have must have explicit shape or assumed size 44 pointer(a, b(:)) 45contains 46 subroutine s(x, y) 47 real :: x(*) ! assumed size 48 !ERROR: Cray pointee 'y' must have must have explicit shape or assumed size 49 real :: y(:) ! assumed shape 50 pointer(w, y) 51 end 52end 53 54program p8 55 integer(8), parameter :: k = 2 56 type t 57 end type 58 !ERROR: 't' is not a variable 59 pointer(t, a) 60 !ERROR: 's' is not a variable 61 pointer(s, b) 62 !ERROR: 'k' is not a variable 63 pointer(k, c) 64contains 65 subroutine s 66 end 67end 68 69program p9 70 integer(8), parameter :: k = 2 71 type t 72 end type 73 !ERROR: 't' is not a variable 74 pointer(a, t) 75 !ERROR: 's' is not a variable 76 pointer(b, s) 77 !ERROR: 'k' is not a variable 78 pointer(c, k) 79contains 80 subroutine s 81 end 82end 83 84module m10 85 integer(8) :: a 86 real :: b 87end 88program p10 89 use m10 90 !ERROR: 'b' cannot be a Cray pointee as it is use-associated 91 pointer(a, c),(d, b) 92end 93 94program p11 95 pointer(a, b) 96 !ERROR: PARAMETER attribute not allowed on 'a' 97 parameter(a=2) 98 !ERROR: PARAMETER attribute not allowed on 'b' 99 parameter(b=3) 100end 101 102program p12 103 type t1 104 sequence 105 real c1 106 end type 107 type t2 108 integer c2 109 end type 110 type(t1) :: x1 111 type(t2) :: x2 112 pointer(a, x1) 113 !ERROR: Type of Cray pointee 'x2' is a non-sequence derived type 114 pointer(b, x2) 115end 116