blob: b4919a13cde7b80bda66625b44b6c9159b04ae98 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
! { dg-do compile }
! { dg-options "-c -Wall" }
!
! PR fortran/40041
! cf. also PR fortran/20373
subroutine valid_one
REAL :: a
INTEGER :: n
INTRINSIC ABS, MAX
a(n) = MAX(ABS(2),ABS(3),n)
end subroutine
subroutine valid_two
IMPLICIT NONE
REAL :: a
INTEGER :: n
INTRINSIC ABS, MAX
a(n) = MAX(ABS(2),ABS(3),n)
end subroutine
subroutine warnings_one
REAL :: a
INTEGER :: n
REAL :: ABS ! { dg-warning "Type specified for intrinsic function" }
REAL :: MAX ! { dg-warning "Type specified for intrinsic function" }
INTRINSIC ABS, MAX
a(n) = MAX(ABS(2),ABS(3),n)
end subroutine
subroutine warnings_two
IMPLICIT NONE
REAL :: a
INTEGER :: n
INTRINSIC ABS ! { dg-warning "Type specified for intrinsic function" }
INTRINSIC MAX ! { dg-warning "Type specified for intrinsic function" }
REAL :: ABS
REAL :: MAX
a(n) = MAX(ABS(2),ABS(3),n)
end subroutine
|