OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [argument_checking_12.f90] - Blame information for rev 694

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do compile }
2
! { dg-options "-std=f2003" }
3
!
4
! PR fortran/34665
5
!
6
! Test argument checking
7
!
8
implicit none
9
CONTAINS
10
SUBROUTINE test2(a,b,c,d,e)
11
 character(len=*), dimension(:) :: a
12
 character(len=*), pointer, dimension(:) :: b
13
 character(len=*), dimension(*) :: c
14
 character(len=*), dimension(5) :: d
15
 character(len=*)               :: e
16
 
17
 call cas_size(e)
18
 call cas_size("abc")
19
 call cas_size(e//"a")
20
 call cas_size(("abc"))
21
 call cas_size(a(1))
22
 call cas_size(b(1))
23
 call cas_size((a(1)//"a"))
24
 call cas_size((b(1)//"a"))
25
 call cas_size((c(1)//"a"))
26
 call cas_size((d(1)//"a"))
27
 call cas_size(e(1:3))
28
 call cas_size("abcd"(1:3))
29
 call cas_size((e(1:3)))
30
 call cas_size(("abcd"(1:3)//"a"))
31
 call cas_size(e(1:3))
32
 call cas_size("abcd"(1:3))
33
 call cas_size((e(1:3)))
34
 call cas_size(("abcd"(1:3)//"a"))
35
 call cas_expl(e)
36
 call cas_expl("abc")
37
 call cas_expl(e//"a")
38
 call cas_expl(("abc"))
39
 call cas_expl(a(1))
40
 call cas_expl(b(1))
41
 call cas_expl((a(1)//"a"))
42
 call cas_expl((b(1)//"a"))
43
 call cas_expl((c(1)//"a"))
44
 call cas_expl((d(1)//"a"))
45
 call cas_expl(e(1:3))
46
 call cas_expl("abcd"(1:3))
47
 call cas_expl((e(1:3)))
48
 call cas_expl(("abcd"(1:3)//"a"))
49
END SUBROUTINE test2
50
 
51
SUBROUTINE cas_size(a)
52
 character(len=*), dimension(*) :: a
53
END SUBROUTINE cas_size
54
 
55
SUBROUTINE cas_expl(a)
56
 character(len=*), dimension(5) :: a
57
END SUBROUTINE cas_expl
58
END
59
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.