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

◆ DefineLocal()

LocalDefinition System.Linq.Expressions.Interpreter.LocalVariables.DefineLocal ( ParameterExpression variable,
int start )
inline

Definition at line 40 of file LocalVariables.cs.

41 {
44 VariableScope variableScope;
46 {
47 variableScope = new VariableScope(localVariable, start, value);
48 if (value.ChildScopes == null)
49 {
50 value.ChildScopes = new List<VariableScope>();
51 }
52 value.ChildScopes.Add(variableScope);
53 }
54 else
55 {
56 variableScope = new VariableScope(localVariable, start, null);
57 }
59 return new LocalDefinition(localVariable.Index, variable);
60 }
bool TryGetValue(TKey key, [MaybeNullWhen(false)] out TValue value)
readonly HybridReferenceDictionary< ParameterExpression, VariableScope > _variables

References System.Linq.Expressions.Interpreter.LocalVariables._localCount, System.Linq.Expressions.Interpreter.LocalVariables._maxLocalCount, System.Linq.Expressions.Interpreter.LocalVariables._variables, System.Math.Max(), System.start, System.Collections.Generic.Dictionary< TKey, TValue >.TryGetValue(), and System.value.

Referenced by System.Linq.Expressions.Interpreter.LightCompiler.CompileAddress(), System.Linq.Expressions.Interpreter.LightCompiler.CompileArrayIndexAddress(), System.Linq.Expressions.Interpreter.LightCompiler.CompileBinaryExpression(), System.Linq.Expressions.Interpreter.LightCompiler.CompileBlockStart(), System.Linq.Expressions.Interpreter.LightCompiler.CompileCoalesceBinaryExpression(), System.Linq.Expressions.Interpreter.LightCompiler.CompileConvertUnaryExpression(), System.Linq.Expressions.Interpreter.LightCompiler.CompileIndexAssignment(), System.Linq.Expressions.Interpreter.LightCompiler.CompileLiftedLogicalBinaryExpression(), System.Linq.Expressions.Interpreter.LightCompiler.CompileMemberAssignment(), System.Linq.Expressions.Interpreter.LightCompiler.CompileMultiDimArrayAccess(), System.Linq.Expressions.Interpreter.LightCompiler.CompileSwitchExpression(), System.Linq.Expressions.Interpreter.LightCompiler.CompileTop(), and System.Linq.Expressions.Interpreter.LightCompiler.CompileTryExpression().