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
Span.cs
Go to the documentation of this file.
1using System;
6
7namespace System
8{
9 // Token: 0x020000F9 RID: 249
10 [Obsolete("Types with embedded references are not supported in this version of your compiler.", true)]
11 [DebuggerDisplay("{ToString(),raw}")]
14 public readonly ref struct Span<T>
15 {
16 // Token: 0x06000955 RID: 2389 RVA: 0x000165A0 File Offset: 0x000147A0
17 public Span(T[] array)
18 {
19 int num = 1;
20 if (array != null)
21 {
22 this._pointer = num;
23 this._length = num;
24 return;
25 }
26 }
27
28 // Token: 0x06000956 RID: 2390 RVA: 0x000165C4 File Offset: 0x000147C4
29 public Span(T[] array, int start, int length)
30 {
31 int num = 1;
32 if (array != null)
33 {
35 this._pointer = num;
37 return;
38 }
39 if (num != 0)
40 {
42 }
43 }
44
45 // Token: 0x06000957 RID: 2391 RVA: 0x000165F8 File Offset: 0x000147F8
46 [CLSCompliant(false)]
53
54 // Token: 0x06000958 RID: 2392 RVA: 0x0001661C File Offset: 0x0001481C
55 internal Span(T ptr, int length)
56 {
59 }
60
61 // Token: 0x170000A3 RID: 163
62 public T this[int index]
63 {
64 [Intrinsic]
66 get
67 {
68 /*
69An exception occurred when decompiling this method (06000959)
70
71ICSharpCode.Decompiler.DecompilerException: Error decompiling T System.Span`1::get_Item(System.Int32)
72
73 ---> System.Exception: Basic block has to end with unconditional control flow.
74{
75 Block_0:
76 stloc:int32(var_0_06, ldfld:int32(Span`1::_length, ldloc:valuetype System.Span`1&(this)))
77 call:void(ThrowHelper::ThrowIndexOutOfRangeException)
78}
79
80 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
81 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
82 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
83 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
84 --- End of inner exception stack trace ---
85 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
86 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
87*/;
88 }
89 }
90
91 // Token: 0x0600095A RID: 2394 RVA: 0x00016654 File Offset: 0x00014854
93 {
94 if (this._length != 0)
95 {
96 return;
97 }
98 }
99
100 // Token: 0x0600095B RID: 2395 RVA: 0x0001666C File Offset: 0x0001486C
101 public void Clear()
102 {
103 }
104
105 // Token: 0x0600095C RID: 2396 RVA: 0x0001667C File Offset: 0x0001487C
106 public void Fill(T value)
107 {
108 if (this._length != 0)
109 {
110 return;
111 }
112 }
113
114 // Token: 0x0600095D RID: 2397 RVA: 0x00016694 File Offset: 0x00014894
120
121 // Token: 0x0600095E RID: 2398 RVA: 0x000166B4 File Offset: 0x000148B4
123 {
124 int length = this._length;
125 return true;
126 }
127
128 // Token: 0x0600095F RID: 2399 RVA: 0x0000207A File Offset: 0x0000027A
129 public static implicit operator ReadOnlySpan<T>(Span<T> span)
130 {
131 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
132 }
133
134 // Token: 0x06000960 RID: 2400 RVA: 0x000166CC File Offset: 0x000148CC
135 public override string ToString()
136 {
137 Type type;
138 Type type2;
139 bool flag = type == type2;
140 int length = this._length;
141 string text;
142 return text;
143 }
144
145 // Token: 0x06000961 RID: 2401 RVA: 0x000166F8 File Offset: 0x000148F8
146 public Span<T> Slice(int start)
147 {
148 int length = this._length;
150 int length2 = this._length;
151 return ref this;
152 }
153
154 // Token: 0x06000962 RID: 2402 RVA: 0x0001671C File Offset: 0x0001491C
155 public Span<T> Slice(int start, int length)
156 {
157 /*
158An exception occurred when decompiling this method (06000962)
159
160ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Span`1<T> System.Span`1::Slice(System.Int32,System.Int32)
161
162 ---> System.Exception: Basic block has to end with unconditional control flow.
163{
164 Block_0:
165 stloc:int32(var_0_06, ldfld:int32(Span`1::_length, ldloc:valuetype System.Span`1&(this)))
166 call:void(ThrowHelper::ThrowArgumentOutOfRangeException)
167}
168
169 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
170 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
171 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
172 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
173 --- End of inner exception stack trace ---
174 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
175 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
176*/;
177 }
178
179 // Token: 0x06000963 RID: 2403 RVA: 0x00016738 File Offset: 0x00014938
180 public T[] ToArray()
181 {
182 /*
183An exception occurred when decompiling this method (06000963)
184
185ICSharpCode.Decompiler.DecompilerException: Error decompiling T[] System.Span`1::ToArray()
186
187 ---> System.Exception: Basic block has to end with unconditional control flow.
188{
189 IL_0000:
190 brtrue(IL_0000, logicnot:bool(ldfld:int32[exp:bool](Span`1::_length, ldloc:valuetype System.Span`1&(this))))
191}
192
193 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
194 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
195 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
196 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
197 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
198 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
199 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
200 --- End of inner exception stack trace ---
201 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
202 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
203*/;
204 }
205
206 // Token: 0x170000A4 RID: 164
207 // (get) Token: 0x06000964 RID: 2404 RVA: 0x0001674C File Offset: 0x0001494C
208 public int Length
209 {
211 get
212 {
213 return this._length;
214 }
215 }
216
217 // Token: 0x06000965 RID: 2405 RVA: 0x0000207A File Offset: 0x0000027A
218 [Obsolete("Equals() on Span will always throw an exception. Use == instead.")]
219 public override bool Equals(object obj)
220 {
221 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
222 }
223
224 // Token: 0x06000966 RID: 2406 RVA: 0x0000207A File Offset: 0x0000027A
225 [Obsolete("GetHashCode() on Span will always throw an exception.")]
226 public override int GetHashCode()
227 {
228 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
229 }
230
231 // Token: 0x06000967 RID: 2407 RVA: 0x00016760 File Offset: 0x00014960
232 public static implicit operator Span<T>(T[] array)
233 {
234 }
235
236 // Token: 0x040003A0 RID: 928
238
239 // Token: 0x040003A1 RID: 929
240 private readonly int _length;
241 }
242}
class f__AnonymousType0<< Count > j__TPar
static void ThrowArgumentOutOfRangeException()
static void ThrowArgumentException_DestinationTooShort()
Span< T > Slice(int start, int length)
Definition Span.cs:155
void CopyTo(Span< T > destination)
Definition Span.cs:115
void Fill(T value)
Definition Span.cs:106
readonly ByReference< T > _pointer
Definition Span.cs:237
readonly int _length
Definition Span.cs:240
Span< T > Slice(int start)
Definition Span.cs:146
T GetPinnableReference()
Definition Span.cs:92
override bool Equals(object obj)
Definition Span.cs:219
override int GetHashCode()
Definition Span.cs:226
unsafe Span(void *pointer, int length)
Definition Span.cs:47
Span(T[] array)
Definition Span.cs:17
T[] ToArray()
Definition Span.cs:180
Span(T ptr, int length)
Definition Span.cs:55
int Length
Definition Span.cs:209
override string ToString()
Definition Span.cs:135
void Clear()
Definition Span.cs:101
Span(T[] array, int start, int length)
Definition Span.cs:29
bool TryCopyTo(Span< T > destination)
Definition Span.cs:122