llvm-project/lldb/scripts/interface
Aleksandr Urakov 40624a085c [Expressions] Add support of expressions evaluation in some object's context
Summary:
This patch adds support of expression evaluation in a context of some object.
Consider the following example:
```
struct S {
  int a = 11;
  int b = 12;
};

int main() {
  S s;
  int a = 1;
  int b = 2;
  // We have stopped here
  return 0;
}
```
This patch allows to do something like that:
```
lldb.frame.FindVariable("s").EvaluateExpression("a + b")
```
and the result will be `33` (not `3`) because fields `a` and `b` of `s` will be
used (not locals `a` and `b`).

This is achieved by replacing of `this` type and object for the expression. This
has some limitations: an expression can be evaluated only for values located in
the debuggee process memory (they must have an address of `eAddressTypeLoad`
type).

Reviewers: teemperor, clayborg, jingham, zturner, labath, davide, spyffe, serge-sans-paille

Reviewed By: jingham

Subscribers: abidh, lldb-commits, leonid.mashinskiy

Tags: #lldb

Differential Revision: https://reviews.llvm.org/D55318

llvm-svn: 353149
2019-02-05 09:14:36 +00:00
..
SBAddress.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBAttachInfo.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBBlock.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBBreakpoint.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBBreakpointLocation.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBBreakpointName.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBBroadcaster.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBCommandInterpreter.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBCommandReturnObject.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBCommunication.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBCompileUnit.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBData.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBDebugger.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBDeclaration.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBError.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBEvent.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBExecutionContext.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBExpressionOptions.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBFileSpec.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBFileSpecList.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBFrame.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBFunction.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBHostOS.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBInitializerOptions.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBInstruction.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBInstructionList.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBLanguageRuntime.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBLaunchInfo.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBLineEntry.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBListener.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBMemoryRegionInfo.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBMemoryRegionInfoList.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBModule.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBModuleSpec.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBPlatform.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBProcess.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBProcessInfo.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBQueue.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBQueueItem.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBSection.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBSourceManager.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBStream.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBStringList.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBStructuredData.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBSymbol.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBSymbolContext.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBSymbolContextList.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTarget.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBThread.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBThreadCollection.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBThreadPlan.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTrace.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTraceOptions.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBType.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTypeCategory.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTypeEnumMember.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTypeFilter.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTypeFormat.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTypeNameSpecifier.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTypeSummary.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBTypeSynthetic.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBUnixSignals.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBValue.i [Expressions] Add support of expressions evaluation in some object's context 2019-02-05 09:14:36 +00:00
SBValueList.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBVariablesOptions.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SBWatchpoint.i Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00