src/debug/netcoredbg/SymbolReader.cs
/// <summary>
/// Returns local variable name for given local index and IL offset.
/// </summary>
/// <param name="symbolReaderHandle">symbol reader handle returned by LoadSymbolsForModule</param>
/// <param name="methodToken">method token</param>
/// <param name="localIndex">local variable index</param>
/// <param name="localVarName">local variable name return</param>
/// <returns>true if name has been found</returns>
Returns local variable name for given local index and IL offset.
Returns local variable name for given local index and IL offset .
internal static bool GetLocalVariableName(IntPtr symbolReaderHandle, int methodToken, int localIndex, out IntPtr localVarName)
        {
            localVarName = IntPtr.Zero;
            string localVar = null;
            if (!GetLocalVariableByIndex(symbolReaderHandle, methodToken, localIndex, out localVar))
                return false;
            localVarName = Marshal.StringToBSTR(localVar);
            localVar = null;
            return true;
        }
internal static bool GetLocalVariableName ( IntPtr symbolReaderHandle , int methodToken , int localIndex , out IntPtr localVarName ) { localVarName = IntPtr . Zero ; string localVar = null ; if ( ! GetLocalVariableByIndex ( symbolReaderHandle , methodToken , localIndex , out localVar ) ) return false ; localVarName = Marshal . StringToBSTR ( localVar ) ; localVar = null ; return true ; }
Returns local variable name for given local index and IL offset.
Returns local variable name for given local index and IL offset .
true if name has been found
true if name has been found
symbolReaderHandle
IntPtr
symbol reader handle returned by LoadSymbolsForModule
symbol reader handle returned by LoadSymbolsForModule
methodToken
int
None
localIndex
int
local variable index
local variable index
IntPtr
out
localVarName
local variable name return
local variable name return