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
Nullable.cs
Go to the documentation of this file.
1using System;
4
5namespace System
6{
7 // Token: 0x020000E3 RID: 227
10 public struct Nullable<T> where T : struct
11 {
12 // Token: 0x0600084D RID: 2125 RVA: 0x000134F0 File Offset: 0x000116F0
14 public Nullable(T value)
15 {
16 this.hasValue = true;
17 }
18
19 // Token: 0x17000093 RID: 147
20 // (get) Token: 0x0600084E RID: 2126 RVA: 0x0000207A File Offset: 0x0000027A
21 public bool HasValue
22 {
24 get
25 {
26 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
27 }
28 }
29
30 // Token: 0x17000094 RID: 148
31 // (get) Token: 0x0600084F RID: 2127 RVA: 0x00013504 File Offset: 0x00011704
32 public T Value
33 {
34 get
35 {
37 return this.value;
38 }
39 }
40
41 // Token: 0x06000850 RID: 2128 RVA: 0x00013520 File Offset: 0x00011720
44 {
45 return this.value;
46 }
47
48 // Token: 0x06000851 RID: 2129 RVA: 0x00013534 File Offset: 0x00011734
50 public T GetValueOrDefault(T defaultValue)
51 {
52 /*
53An exception occurred when decompiling this method (06000851)
54
55ICSharpCode.Decompiler.DecompilerException: Error decompiling T System.Nullable`1::GetValueOrDefault(T)
56
57 ---> System.Exception: Basic block has to end with unconditional control flow.
58{
59 Block_0:
60 stloc:!T(var_0_06, ldfld:!T(Nullable`1::value, ldloc:valuetype System.Nullable`1&(this)))
61}
62
63 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
64 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
65 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
66 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
67 --- End of inner exception stack trace ---
68 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
69 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
70*/;
71 }
72
73 // Token: 0x06000852 RID: 2130 RVA: 0x00013548 File Offset: 0x00011748
74 public override bool Equals(object other)
75 {
76 bool flag;
77 if (other != null)
78 {
79 return flag;
80 }
81 return flag;
82 }
83
84 // Token: 0x06000853 RID: 2131 RVA: 0x0001355C File Offset: 0x0001175C
85 public override int GetHashCode()
86 {
87 int num;
88 return num;
89 }
90
91 // Token: 0x06000854 RID: 2132 RVA: 0x0001356C File Offset: 0x0001176C
92 public override string ToString()
93 {
94 string text;
95 return text;
96 }
97
98 // Token: 0x06000855 RID: 2133 RVA: 0x00013580 File Offset: 0x00011780
99 private static object Box(T? o)
100 {
101 }
102
103 // Token: 0x06000856 RID: 2134 RVA: 0x00013590 File Offset: 0x00011790
104 private static T? Unbox(object o)
105 {
106 throw new InvalidCastException();
107 }
108
109 // Token: 0x06000857 RID: 2135 RVA: 0x000135A4 File Offset: 0x000117A4
110 private static T? UnboxExact(object o)
111 {
112 Type type;
113 Type type2;
114 bool flag = type != type2;
115 return 1;
116 }
117
118 // Token: 0x0400036D RID: 877
119 private readonly bool hasValue;
120
121 // Token: 0x0400036E RID: 878
122 internal T value;
123 }
124}
class f__AnonymousType0<< Count > j__TPar
static ? T UnboxExact(object o)
Definition Nullable.cs:110
T GetValueOrDefault(T defaultValue)
Definition Nullable.cs:50
override string ToString()
Definition Nullable.cs:92
Nullable(T value)
Definition Nullable.cs:14
override bool Equals(object other)
Definition Nullable.cs:74
static ? T Unbox(object o)
Definition Nullable.cs:104
readonly bool hasValue
Definition Nullable.cs:119
T GetValueOrDefault()
Definition Nullable.cs:43
override int GetHashCode()
Definition Nullable.cs:85
static object Box(T? o)
Definition Nullable.cs:99
static void ThrowInvalidOperationException_InvalidOperation_NoValue()