Cilador.Clone.MultiplexedConstructor.TryGetConstructionVariableIndex C# (CSharp) Method

TryGetConstructionVariableIndex() public method

Tries to get the index of a variable within the group of construction variables that have been pulled from the full collection of constructor variables.
public TryGetConstructionVariableIndex ( Instruction sourceInstruction, int &index ) : bool
sourceInstruction Mono.Cecil.Cil.Instruction Source instruction possibly referencing a variable to look up.
index int Index of the variable in the subset of variables.
return bool
        public bool TryGetConstructionVariableIndex(Instruction sourceInstruction, out int index)
        {
            Contract.Requires(sourceInstruction != null);

            VariableDefinition sourceVariable;

            if (this.TryGetReferencedVariable(sourceInstruction, out sourceVariable))
            {
                return this.TryGetConstructionVariableIndex(sourceVariable, out index);
            }

            index = -1;
            return false;
        }

Same methods

MultiplexedConstructor::TryGetConstructionVariableIndex ( Mono.Cecil.Cil.VariableDefinition sourceVariable, int &index ) : bool