terraria-cpp2il-methodrecon v1.4.4.9
Terraria mobile dump, with reconstructed method body. Dump with CallAnalysis: https://infinitynichto.github.io/terraria-cpp2il
Loading...
Searching...
No Matches
AsyncMethodBuilderCore.cs
Go to the documentation of this file.
1using System;
8
10{
11 // Token: 0x02000492 RID: 1170
12 internal struct AsyncMethodBuilderCore
13 {
14 // Token: 0x06002274 RID: 8820 RVA: 0x0004D784 File Offset: 0x0004B984
16 {
17 /*
18An exception occurred when decompiling this method (06002274)
19
20ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void System.Runtime.CompilerServices.AsyncMethodBuilderCore::SetStateMachine(System.Runtime.CompilerServices.IAsyncStateMachine)
21
22 ---> System.Exception: Basic block has to end with unconditional control flow.
23{
24 IL_000B:
25 stloc:string(var_0_15, call:string(Environment::GetResourceString, ldstr:string("The builder was not properly initialized.")))
26}
27
28 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
29 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
30 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
31 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1846
32 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
33 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
34 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
35 --- End of inner exception stack trace ---
36 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
37 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
38*/;
39 }
40
41 // Token: 0x06002275 RID: 8821 RVA: 0x0004D7A8 File Offset: 0x0004B9A8
43 {
44 if (!true)
45 {
46 }
48 if (!true)
49 {
50 }
53 if (executionContext != null)
54 {
55 bool isPreAllocatedDefault = executionContext.IsPreAllocatedDefault;
56 if (this.m_defaultContextAction == null)
57 {
58 if (taskForTracing != null)
59 {
62 return action;
63 }
65 return action2;
66 }
67 }
68 else if (taskForTracing != null)
69 {
70 }
71 return action2;
72 }
73
74 // Token: 0x06002276 RID: 8822 RVA: 0x0004D7FC File Offset: 0x0004B9FC
80
81 // Token: 0x06002277 RID: 8823 RVA: 0x0004D80C File Offset: 0x0004BA0C
83 {
84 if (builtTask != null)
85 {
87 int id = builtTask.Id;
88 if ("Async: " == null)
89 {
90 }
91 if ("Async: " != null)
92 {
93 if ("Async: " == null)
94 {
95 }
96 bool flag = Task.AddToActiveTasks(builtTask);
97 }
98 }
100 }
101
102 // Token: 0x06002278 RID: 8824 RVA: 0x0004D854 File Offset: 0x0004BA54
111
112 // Token: 0x06002279 RID: 8825 RVA: 0x0000207A File Offset: 0x0000027A
114 {
115 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
116 }
117
118 // Token: 0x0600227A RID: 8826 RVA: 0x0004D880 File Offset: 0x0004BA80
120 {
121 if (true)
122 {
123 return;
124 }
125 }
126
127 // Token: 0x040012D2 RID: 4818
129
130 // Token: 0x040012D3 RID: 4819
132
133 // Token: 0x02000493 RID: 1171
134 internal sealed class MoveNextRunner
135 {
136 // Token: 0x0600227B RID: 8827 RVA: 0x0004D894 File Offset: 0x0004BA94
142
143 // Token: 0x0600227C RID: 8828 RVA: 0x0004D8B8 File Offset: 0x0004BAB8
144 internal void Run()
145 {
146 if (this.m_context != null)
147 {
148 ExecutionContext context = this.m_context;
151 context2.Dispose();
152 return;
153 }
155 }
156
157 // Token: 0x0600227D RID: 8829 RVA: 0x0004D918 File Offset: 0x0004BB18
158 private static void InvokeMoveNext(object stateMachine)
159 {
160 if (stateMachine == null)
161 {
162 return;
163 }
164 if (stateMachine != null && stateMachine != null)
165 {
166 return;
167 }
168 throw new InvalidCastException();
169 }
170
171 // Token: 0x040012D4 RID: 4820
173
174 // Token: 0x040012D5 RID: 4821
176
177 // Token: 0x040012D6 RID: 4822
179 }
180
181 // Token: 0x02000494 RID: 1172
183 {
184 // Token: 0x0600227E RID: 8830 RVA: 0x0004D940 File Offset: 0x0004BB40
196
197 // Token: 0x0600227F RID: 8831 RVA: 0x0004D974 File Offset: 0x0004BB74
198 internal void Invoke()
199 {
201 IntPtr invoke_impl = invokeAction.invoke_impl;
202 IntPtr method_code = invokeAction.method_code;
203 IntPtr method = invokeAction.method;
204 }
205
206 // Token: 0x040012D7 RID: 4823
208
209 // Token: 0x040012D8 RID: 4824
211
212 // Token: 0x040012D9 RID: 4825
214 }
215
216 // Token: 0x02000495 RID: 1173
218 private sealed class <>c__DisplayClass5_0
219 {
220 // Token: 0x06002280 RID: 8832 RVA: 0x0004D9A0 File Offset: 0x0004BBA0
222 {
223 }
224
225 // Token: 0x06002281 RID: 8833 RVA: 0x0004D9B4 File Offset: 0x0004BBB4
227 {
228 int id = this.innerTask.Id;
230 IntPtr invoke_impl = action.invoke_impl;
231 IntPtr method_code = action.method_code;
232 IntPtr method = action.method;
233 }
234
235 // Token: 0x040012DA RID: 4826
236 public Task innerTask;
237
238 // Token: 0x040012DB RID: 4827
239 public Action continuation;
240 }
241
242 // Token: 0x02000496 RID: 1174
244 [Serializable]
245 private sealed class <>c
246 {
247 // Token: 0x06002282 RID: 8834 RVA: 0x0004D9F0 File Offset: 0x0004BBF0
248 // Note: this type is marked as 'beforefieldinit'.
249 static <>c()
250 {
251 }
252
253 // Token: 0x06002283 RID: 8835 RVA: 0x0004DA00 File Offset: 0x0004BC00
254 public <>c()
255 {
256 }
257
258 // Token: 0x06002284 RID: 8836 RVA: 0x0004DA14 File Offset: 0x0004BC14
259 internal void <ThrowAsync>b__7_0(object state)
260 {
261 throw new InvalidCastException();
262 }
263
264 // Token: 0x06002285 RID: 8837 RVA: 0x0004DA2C File Offset: 0x0004BC2C
265 internal void <ThrowAsync>b__7_1(object state)
266 {
267 throw new InvalidCastException();
268 }
269
270 // Token: 0x040012DC RID: 4828
271 public static readonly AsyncMethodBuilderCore.<>c <>9;
272
273 // Token: 0x040012DD RID: 4829
274 public static SendOrPostCallback <>9__7_0;
275
276 // Token: 0x040012DE RID: 4830
277 public static WaitCallback <>9__7_1;
278 }
279 }
280}
class f__AnonymousType0<< Count > j__TPar
static void NotifyOfCrossThreadDependency()
Definition Debugger.cs:73
ContinuationWrapper(Action continuation, Action invokeAction, Task innerTask)
MoveNextRunner(ExecutionContext context, IAsyncStateMachine stateMachine)
static ExceptionDispatchInfo Capture(Exception source)
static ExecutionContext FastCapture()
static bool AddToActiveTasks(Task task)
Definition Task.2.cs:1797
static void ThrowAsync(Exception exception, SynchronizationContext targetContext)
static Action CreateContinuationWrapper(Action continuation, Action invokeAction, [Optional] Task innerTask)
Action GetCompletionAction(Task taskForTracing, AsyncMethodBuilderCore.MoveNextRunner runnerToInitialize)
Action OutputAsyncCausalityEvents(Task innerTask, Action continuation)
void PostBoxInitialization(IAsyncStateMachine stateMachine, AsyncMethodBuilderCore.MoveNextRunner runner, Task builtTask)