blob: f06154a056052a6243bcb6bd907d7ca07487999b (
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
|
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
// 2 branches out of try with dead code after tryend
.assembly extern System.Console
{
.publickeytoken = (B0 3F 5F 7F 11 D5 0A 3A )
.ver 4:0:0:0
}
.assembly extern mscorlib
{
}
.assembly extern common{}
.assembly testit{
.hash algorithm 0x00008004
.ver 0:0:0:0
}
.module testit.exe
.imagebase 0x00400000
.subsystem 0x00000003
.file alignment 512
.corflags 0x00000001
.namespace hello
{
.class private auto ansi beforefieldinit Class1
extends [mscorlib]System.Object
{
.method public hidebysig static int32
Main(string[] args) cil managed
{
.entrypoint
.maxstack 2
.locals init (
class [mscorlib]System.IO.StringWriter expectedOut,
class [common]TestUtil.TestLog testLog
)
newobj instance void [mscorlib]System.IO.StringWriter::.ctor()
stloc.s expectedOut
ldloc.s expectedOut
ldstr "In try"
callvirt instance void [mscorlib]System.IO.TextWriter::WriteLine(string)
ldloc.s expectedOut
ldstr "In finally"
callvirt instance void [mscorlib]System.IO.TextWriter::WriteLine(string)
ldloc.s expectedOut
ldstr "After try"
callvirt instance void [mscorlib]System.IO.TextWriter::WriteLine(string)
ldloc.s expectedOut
newobj instance void [common]TestUtil.TestLog::.ctor(object)
stloc.s testLog
ldloc.s testLog
callvirt instance void [common]TestUtil.TestLog::StartRecording()
.try
{
ldstr "In try"
call void [System.Console]System.Console::WriteLine(string)
leave.s label2
ldstr "In try"
call void [System.Console]System.Console::WriteLine(string)
leave label1
}
finally
{
ldstr "In finally"
call void [System.Console]System.Console::WriteLine(string)
endfinally
}
label1:
ldstr "Unreached"
call void [System.Console]System.Console::WriteLine(string)
label2: ldstr "After try"
call void [System.Console]System.Console::WriteLine(string)
ldloc.s testLog
callvirt instance void [common]TestUtil.TestLog::StopRecording()
ldloc.s testLog
callvirt instance int32 [common]TestUtil.TestLog::VerifyOutput()
ret
}
.method public hidebysig specialname rtspecialname
instance void .ctor() cil managed
{
.maxstack 1
IL_0000: ldarg.0
IL_0001: call instance void [mscorlib]System.Object::.ctor()
IL_0006: ret
}
}
}
|