repo.or.cz
/
mono-project.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
[runtime] Avoid holding the init lock while calling the cctor in mono_runtime_class_i...
[mono-project.git]
/
mcs
/
tests
/
test-829.cs
blob
d5c83a033f9cbe9bbf5ddc45cc7d0b817684ddc5
1
using
System
;
2
3
struct
S2
4
{
5
public float
f1
;
6
}
7
8
struct
S
9
{
10
public
S2 s2
;
11
public float
F
;
12
}
13
14
class
C
15
{
16
static void
Test
(
bool
b
,
out
S s
)
17
{
18
if
(
b
) {
19
s
.
s2
=
new
S2
();
20
s
.
F
=
1.0
f
;
21
}
else
{
22
s
.
s2
.
f1
=
2.1
f
;
23
s
.
F
=
1.0
f
;
24
}
25
}
26
27
static void
Test2
(
bool
b
)
28
{
29
S s
;
30
if
(
b
) {
31
s
.
s2
=
new
S2
();
32
s
.
F
=
1.0
f
;
33
}
else
{
34
s
.
s2
.
f1
=
2.1
f
;
35
s
.
F
=
1.0
f
;
36
}
37
}
38
39
public static int
Main
()
40
{
41
S s
;
42
Test
(
true
,
out
s
);
43
Test
(
false
,
out
s
);
44
return
0
;
45
}
46
}