repo.or.cz
/
mcs.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
2009-03-11 Zoltan Varga <vargaz@gmail.com>
[mcs.git]
/
tests
/
test-140.cs
blob
03c9757b16b4e84969ee7ed8e2653f21fd8ef39c
1
//
2
// We used to generate incorrect code for breaks in infinite while loops
3
//
4
using
System
;
5
6
public class
BreakTest
7
{
8
static int
ok
=
0
;
9
10
public static void
B
()
11
{
12
ok
++;
13
while
(
true
)
14
{
15
ok
++;
16
break
;
17
}
18
ok
++;
19
}
20
21
public static int
Main
()
22
{
23
B
();
24
if
(
ok
!=
3
)
25
return
1
;
26
return
0
;
27
}
28
}