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
* config/pa/linux-atomic.c (__kernel_cmpxchg): Reorder arguments to
[official-gcc.git]
/
gcc
/
testsuite
/
gfortran.fortran-torture
/
execute
/
integer_select.f90
blob
765356d2610ffb3bd9c49d5c70ffbad70a589e88
1
PROGRAM
Test_INTEGER_select
2
3
! Every wrong branch leads to destruction.
4
5
INTEGER
,
PARAMETER
::
maxI
=
HUGE
(
maxI
)
6
INTEGER
,
PARAMETER
::
minI
= -
1
*
maxI
7
INTEGER
::
I
=
0
8
9
SELECT
CASE
(
I
)
10
CASE
(:-
1
)
11
CALL
abort
12
CASE
(
1
:)
13
CALL
abort
14
CASE DEFAULT
15
CONTINUE
16
END
SELECT
17
18
SELECT
CASE
(
I
)
19
CASE
(
3
,
2
,
1
)
20
CALL
abort
21
CASE
(
0
)
22
CONTINUE
23
CASE DEFAULT
24
call
abort
25
END
SELECT
26
27
! Not aborted by here, so it worked
28
! See about weird corner cases
29
30
I
=
maxI
31
32
SELECT
CASE
(
I
)
33
CASE
(:-
1
)
34
CALL
abort
35
CASE
(
1
:)
36
CONTINUE
37
CASE DEFAULT
38
CALL
abort
39
END
SELECT
40
41
SELECT
CASE
(
I
)
42
CASE
(
3
,
2
,
1
,:
0
)
43
CALL
abort
44
CASE
(
maxI
)
45
CONTINUE
46
CASE DEFAULT
47
call
abort
48
END
SELECT
49
50
I
=
minI
51
52
SELECT
CASE
(
I
)
53
CASE
(:-
1
)
54
CONTINUE
55
CASE
(
1
:)
56
CALL
abort
57
CASE DEFAULT
58
CALL
abort
59
END
SELECT
60
61
SELECT
CASE
(
I
)
62
CASE
(
3
:,
2
,
1
,
0
)
63
CALL
abort
64
CASE
(
minI
)
65
CONTINUE
66
CASE DEFAULT
67
call
abort
68
END
SELECT
69
70
END
71