Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Create()

static Instruction System.Linq.Expressions.Interpreter.OrInstruction.Create ( Type type)
inlinestaticinherited

Definition at line 191 of file OrInstruction.cs.

192 {
193 return type.GetNonNullableType().GetTypeCode() switch
194 {
195 TypeCode.SByte => s_SByte ?? (s_SByte = new OrSByte()),
196 TypeCode.Int16 => s_Int16 ?? (s_Int16 = new OrInt16()),
197 TypeCode.Int32 => s_Int32 ?? (s_Int32 = new OrInt32()),
198 TypeCode.Int64 => s_Int64 ?? (s_Int64 = new OrInt64()),
199 TypeCode.Byte => s_Byte ?? (s_Byte = new OrByte()),
200 TypeCode.UInt16 => s_UInt16 ?? (s_UInt16 = new OrUInt16()),
201 TypeCode.UInt32 => s_UInt32 ?? (s_UInt32 = new OrUInt32()),
202 TypeCode.UInt64 => s_UInt64 ?? (s_UInt64 = new OrUInt64()),
203 TypeCode.Boolean => s_Boolean ?? (s_Boolean = new OrBoolean()),
204 _ => throw ContractUtils.Unreachable,
205 };
206 }

References System.Linq.Expressions.Interpreter.OrInstruction.s_Boolean, System.Linq.Expressions.Interpreter.OrInstruction.s_Byte, System.Linq.Expressions.Interpreter.OrInstruction.s_Int16, System.Linq.Expressions.Interpreter.OrInstruction.s_Int32, System.Linq.Expressions.Interpreter.OrInstruction.s_Int64, System.Linq.Expressions.Interpreter.OrInstruction.s_SByte, System.Linq.Expressions.Interpreter.OrInstruction.s_UInt16, System.Linq.Expressions.Interpreter.OrInstruction.s_UInt32, System.Linq.Expressions.Interpreter.OrInstruction.s_UInt64, System.type, and System.Dynamic.Utils.ContractUtils.Unreachable.

Referenced by System.Linq.Expressions.Interpreter.InstructionList.EmitOr().