19#include "llvm/Support/FormatAdapters.h"
34 value_sp = dynamic_sp;
40 value_sp = synthetic_sp;
46static llvm::Expected<lldb::TypeSystemSP>
48 auto stack_frame = ctx->CalculateStackFrame();
50 return llvm::createStringError(
"no stack frame in this context");
52 stack_frame->GetSymbolContext(lldb::eSymbolContextCompUnit);
55 return llvm::createStringError(
"no compile unit in this context");
58 symbol_context = stack_frame->GetSymbolContext(lldb::eSymbolContextModule);
59 return symbol_context.
module_sp->GetTypeSystemForLanguage(language);
65 return type_system.get()->GetBasicTypeFromAST(basic_type);
72 llvm::StringRef name) {
82llvm::Expected<lldb::ValueObjectSP>
85 return llvm::make_error<DILDiagnosticError>(
m_expr,
"invalid value object",
87 llvm::Expected<lldb::TypeSystemSP> type_system =
90 return type_system.takeError();
93 if (valobj->IsBitfield()) {
98 uint32_t bitfield_size = valobj->GetBitfieldBitSize();
101 if (bitfield_size > 0 && in_type.
IsInteger()) {
105 llvm::Expected<uint64_t> int_bit_size =
108 return int_bit_size.takeError();
109 llvm::Expected<uint64_t> uint_bit_size =
112 return int_bit_size.takeError();
113 if (bitfield_size < *int_bit_size ||
114 (in_type.
IsSigned() && bitfield_size == *int_bit_size))
115 return valobj->CastToBasicType(int_type);
116 if (bitfield_size <= *uint_bit_size)
117 return valobj->CastToBasicType(uint_type);
120 bool resolved = valobj->ResolveValue(scalar);
122 return llvm::createStringError(
"invalid scalar value");
131 if (valobj->GetCompilerType().IsInteger() ||
132 valobj->GetCompilerType().IsUnscopedEnumerationType()) {
133 llvm::Expected<CompilerType> promoted_type =
134 type_system.get()->DoIntegralPromotion(valobj->GetCompilerType(),
137 return promoted_type.takeError();
138 if (!promoted_type->CompareTypes(valobj->GetCompilerType()))
139 return valobj->CastToBasicType(*promoted_type);
148 std::vector<lldb::VariableSP> possible_matches;
151 llvm::StringRef str_ref_name = var_sp->GetName().GetStringRef();
153 str_ref_name.consume_front(
"::");
159 if (var_sp->NameMatches(name))
160 possible_matches.push_back(var_sp);
164 if (possible_matches.size() > 0)
165 return possible_matches[0];
171 llvm::StringRef name_ref, std::shared_ptr<StackFrame> stack_frame,
175 stack_frame->GetSymbolContext(lldb::eSymbolContextCompUnit);
180 name_ref.consume_front(
"::");
187 stack_frame->GetValueObjectForFrameVariable(var_sp, use_dynamic);
195 target_sp->GetImages().FindGlobalVariables(
196 ConstString(name_ref), std::numeric_limits<uint32_t>::max(),
199 if (!modules_var_list.
Empty()) {
212 std::shared_ptr<StackFrame> stack_frame,
216 if (name_ref.consume_front(
"$")) {
221 if (
const RegisterInfo *reg_info = reg_ctx->GetRegisterInfoByName(name_ref))
227 if (!name_ref.contains(
"::")) {
231 stack_frame->GetInScopeVariableList(
false));
236 variable_list->FindVariable(
ConstString(name_ref));
239 stack_frame->GetValueObjectForFrameVariable(var_sp, use_dynamic);
247 lldb::eSymbolContextFunction | lldb::eSymbolContextBlock);
249 value_sp = stack_frame->FindVariable(
ConstString(ivar_name));
251 value_sp = value_sp->GetChildMemberWithName(name_ref);
260 std::shared_ptr<StackFrame> frame_sp,
262 bool fragile_ivar,
bool check_ptr_vs_member)
270 auto value_or_error = node.
Accept(
this);
272 if (value_or_error && !*value_or_error)
273 return llvm::make_error<DILDiagnosticError>(
m_expr,
"invalid value object",
277 return value_or_error;
280llvm::Expected<lldb::ValueObjectSP>
282 auto valobj_or_err =
Evaluate(node);
284 return valobj_or_err;
288 if (valobj->GetCompilerType().IsReferenceType()) {
289 valobj = valobj->Dereference(
error);
291 return error.ToError();
296llvm::Expected<lldb::ValueObjectSP>
308 llvm::formatv(
"use of undeclared identifier '{0}'", node.
GetName());
309 return llvm::make_error<DILDiagnosticError>(
316llvm::Expected<lldb::ValueObjectSP>
329 operand = dynamic_op;
335 child_sp = synth_obj_sp->Dereference(
error);
339 return llvm::make_error<DILDiagnosticError>(
m_expr,
error.AsCString(),
348 return llvm::make_error<DILDiagnosticError>(
m_expr,
error.AsCString(),
354 if (operand->GetCompilerType().IsReferenceType()) {
355 operand = operand->Dereference(
error);
357 return error.ToError();
359 llvm::Expected<lldb::ValueObjectSP> conv_op =
367 llvm::formatv(
"invalid argument type '{0}' to unary expression",
369 return llvm::make_error<DILDiagnosticError>(
m_expr, errMsg,
373 bool resolved = operand->ResolveValue(scalar);
380 m_target, scalar, operand->GetCompilerType(),
"result");
384 if (operand->GetCompilerType().IsReferenceType()) {
385 operand = operand->Dereference(
error);
387 return error.ToError();
389 llvm::Expected<lldb::ValueObjectSP> conv_op =
399 llvm::formatv(
"invalid argument type '{0}' to unary expression",
401 return llvm::make_error<DILDiagnosticError>(
m_expr, errMsg,
407 return llvm::make_error<DILDiagnosticError>(
m_expr,
"invalid unary operation",
411llvm::Expected<lldb::ValueObjectSP>
424 const uint32_t pointer_type_flags =
425 base->GetCompilerType().GetTypeInfo(
nullptr);
426 if ((pointer_type_flags & lldb::eTypeIsObjC) &&
427 (pointer_type_flags & lldb::eTypeIsPointer)) {
436 if (!base->IsPointerType() && base->HasSyntheticValue()) {
439 base->GetSyntheticValue()->Dereference(deref_error);
440 synth_deref_sp && deref_error.
Success()) {
441 base = std::move(synth_deref_sp);
443 if (!base || deref_error.
Fail()) {
444 std::string errMsg = llvm::formatv(
445 "Failed to dereference synthetic value: {0}", deref_error);
446 return llvm::make_error<DILDiagnosticError>(
452 std::string errMsg =
"Failed to dereference synthetic value";
453 return llvm::make_error<DILDiagnosticError>(
461 bool base_is_ptr = base->IsPointerType();
463 if (expr_is_ptr != base_is_ptr) {
466 llvm::formatv(
"member reference type {0} is a pointer; "
467 "did you mean to use '->'?",
468 base->GetCompilerType().TypeDescription());
469 return llvm::make_error<DILDiagnosticError>(
473 llvm::formatv(
"member reference type {0} is not a pointer; "
474 "did you mean to use '.'?",
475 base->GetCompilerType().TypeDescription());
476 return llvm::make_error<DILDiagnosticError>(
486 field_obj = base->GetSyntheticValue();
488 field_obj = field_obj->GetChildMemberWithName(node.
GetFieldName());
492 std::string errMsg = llvm::formatv(
493 "\"{0}\" is not a member of \"({1}) {2}\"", node.
GetFieldName(),
494 base->GetTypeName().AsCString(
"<invalid type>"), base->GetName());
495 return llvm::make_error<DILDiagnosticError>(
505 field_obj = dynamic_val_sp;
511 if (node.
GetIsArrow() && base->IsPointerType())
513 std::string errMsg = llvm::formatv(
514 "\"{0}\" is not a member of \"({1}) {2}\"", node.
GetFieldName(),
515 base->GetTypeName().AsCString(
"<invalid type>"), base->GetName());
516 return llvm::make_error<DILDiagnosticError>(
520llvm::Expected<lldb::ValueObjectSP>
527 if (!idx->GetCompilerType().IsIntegerOrUnscopedEnumerationType()) {
528 return llvm::make_error<DILDiagnosticError>(
533 uint64_t child_idx = idx->GetValueAsUnsigned(0);
541 CompilerType base_type = base->GetCompilerType().GetNonReferenceType();
542 base->GetExpressionPath(var_expr_path_strm);
543 bool is_incomplete_array =
false;
545 bool is_objc_pointer =
true;
548 is_objc_pointer =
false;
549 else if (!base->GetCompilerType().IsPointerType())
550 is_objc_pointer =
false;
553 std::string err_msg = llvm::formatv(
554 "\"({0}) {1}\" is an Objective-C pointer, and cannot be subscripted",
555 base->GetTypeName().AsCString(
"<invalid type>"),
557 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
560 if (is_objc_pointer) {
562 if (!synthetic || synthetic == base) {
563 std::string err_msg =
564 llvm::formatv(
"\"({0}) {1}\" is not an array type",
565 base->GetTypeName().AsCString(
"<invalid type>"),
567 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
570 if (
static_cast<uint32_t
>(child_idx) >=
571 synthetic->GetNumChildrenIgnoringErrors()) {
572 std::string err_msg = llvm::formatv(
573 "array index {0} is not valid for \"({1}) {2}\"", child_idx,
574 base->GetTypeName().AsCString(
"<invalid type>"),
576 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
579 child_valobj_sp = synthetic->GetChildAtIndex(child_idx);
580 if (!child_valobj_sp) {
581 std::string err_msg = llvm::formatv(
582 "array index {0} is not valid for \"({1}) {2}\"", child_idx,
583 base->GetTypeName().AsCString(
"<invalid type>"),
585 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
589 if (
auto dynamic_sp = child_valobj_sp->GetDynamicValue(
m_use_dynamic))
590 child_valobj_sp = std::move(dynamic_sp);
592 return child_valobj_sp;
595 child_valobj_sp = base->GetSyntheticArrayMember(child_idx,
true);
596 if (!child_valobj_sp) {
597 std::string err_msg = llvm::formatv(
598 "failed to use pointer as array for index {0} for "
600 child_idx, base->GetTypeName().AsCString(
"<invalid type>"),
603 err_msg =
"subscript of pointer to incomplete type 'void'";
604 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
607 }
else if (base_type.
IsArrayType(
nullptr,
nullptr, &is_incomplete_array)) {
608 child_valobj_sp = base->GetChildAtIndex(child_idx);
610 child_valobj_sp = base->GetSyntheticArrayMember(child_idx,
true);
611 if (!child_valobj_sp) {
612 std::string err_msg = llvm::formatv(
613 "array index {0} is not valid for \"({1}) {2}\"", child_idx,
614 base->GetTypeName().AsCString(
"<invalid type>"),
616 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
621 base->GetSyntheticBitFieldChild(child_idx, child_idx,
true);
622 if (!child_valobj_sp) {
623 std::string err_msg = llvm::formatv(
624 "bitfield range {0}:{1} is not valid for \"({2}) {3}\"", child_idx,
625 child_idx, base->GetTypeName().AsCString(
"<invalid type>"),
627 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
633 std::string err_msg =
634 llvm::formatv(
"\"{0}\" is not an array type",
635 base->GetTypeName().AsCString(
"<invalid type>"));
636 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
639 if (
static_cast<uint32_t
>(child_idx) >=
640 synthetic->GetNumChildrenIgnoringErrors(child_idx + 1)) {
641 std::string err_msg = llvm::formatv(
642 "array index {0} is not valid for \"({1}) {2}\"", child_idx,
643 base->GetTypeName().AsCString(
"<invalid type>"),
645 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
648 child_valobj_sp = synthetic->GetChildAtIndex(child_idx);
649 if (!child_valobj_sp) {
650 std::string err_msg = llvm::formatv(
651 "array index {0} is not valid for \"({1}) {2}\"", child_idx,
652 base->GetTypeName().AsCString(
"<invalid type>"),
654 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(err_msg),
659 if (child_valobj_sp) {
661 if (
auto dynamic_sp = child_valobj_sp->GetDynamicValue(
m_use_dynamic))
662 child_valobj_sp = std::move(dynamic_sp);
664 return child_valobj_sp;
668 int64_t signed_child_idx = idx->GetValueAsSigned(0, &success);
670 return llvm::make_error<DILDiagnosticError>(
671 m_expr,
"could not get the index as an integer",
673 return base->GetSyntheticArrayMember(signed_child_idx,
true);
676llvm::Expected<lldb::ValueObjectSP>
679 if (!first_idx_or_err)
680 return first_idx_or_err;
683 if (!last_idx_or_err)
684 return last_idx_or_err;
687 if (!first_idx->GetCompilerType().IsIntegerOrUnscopedEnumerationType() ||
688 !last_idx->GetCompilerType().IsIntegerOrUnscopedEnumerationType()) {
689 return llvm::make_error<DILDiagnosticError>(
693 bool success_first, success_last;
694 int64_t first_index = first_idx->GetValueAsSigned(0, &success_first);
695 int64_t last_index = last_idx->GetValueAsSigned(0, &success_last);
696 if (!success_first || !success_last)
697 return llvm::make_error<DILDiagnosticError>(
701 if (first_index > last_index)
702 std::swap(first_index, last_index);
709 base->GetSyntheticBitFieldChild(first_index, last_index,
true);
710 if (!child_valobj_sp) {
711 std::string message = llvm::formatv(
712 "bitfield range {0}:{1} is not valid for \"({2}) {3}\"", first_index,
713 last_index, base->GetTypeName().AsCString(
"<invalid type>"),
714 base->GetName().AsCString());
715 return llvm::make_error<DILDiagnosticError>(
m_expr, message,
718 return child_valobj_sp;
721llvm::Expected<CompilerType>
723 std::shared_ptr<ExecutionContextScope> ctx,
728 llvm::APInt apint = literal.
GetValue();
730 llvm::SmallVector<std::pair<lldb::BasicType, lldb::BasicType>, 3> candidates;
741 for (
auto [signed_, unsigned_] : candidates) {
742 CompilerType signed_type = type_system->GetBasicTypeFromAST(signed_);
745 llvm::Expected<uint64_t> size = signed_type.
GetBitSize(ctx.get());
747 return size.takeError();
748 if (!literal.
IsUnsigned() && apint.isIntN(*size - 1))
751 return type_system->GetBasicTypeFromAST(unsigned_);
754 return llvm::make_error<DILDiagnosticError>(
756 "integer literal is too large to be represented in any integer type",
760llvm::Expected<lldb::ValueObjectSP>
762 llvm::Expected<lldb::TypeSystemSP> type_system =
765 return type_system.takeError();
767 llvm::Expected<CompilerType> type =
770 return type.takeError();
775 llvm::Expected<uint64_t> type_bitsize =
778 return type_bitsize.takeError();
784llvm::Expected<lldb::ValueObjectSP>
786 llvm::Expected<lldb::TypeSystemSP> type_system =
789 return type_system.takeError();
792 &node.
GetValue().getSemantics() == &llvm::APFloat::IEEEsingle();
798 return llvm::make_error<DILDiagnosticError>(
806llvm::Expected<lldb::ValueObjectSP>
812llvm::Expected<CastKind>
818 std::string errMsg = llvm::formatv(
"Cast from {0} to {1} is not allowed",
821 return llvm::make_error<DILDiagnosticError>(
822 m_expr, std::move(errMsg), location,
832 uint64_t type_byte_size = 0;
833 uint64_t rhs_type_byte_size = 0;
835 type_byte_size = *temp;
837 std::string errMsg = llvm::formatv(
"unable to get byte size for type {0}",
839 return llvm::make_error<DILDiagnosticError>(
840 m_expr, std::move(errMsg), location,
845 rhs_type_byte_size = *temp;
847 std::string errMsg = llvm::formatv(
"unable to get byte size for type {0}",
849 return llvm::make_error<DILDiagnosticError>(
850 m_expr, std::move(errMsg), location,
854 if (type_byte_size < rhs_type_byte_size) {
855 std::string errMsg = llvm::formatv(
856 "cast from pointer to smaller type {0} loses information",
858 return llvm::make_error<DILDiagnosticError>(
859 m_expr, std::move(errMsg), location,
864 std::string errMsg = llvm::formatv(
"cannot convert {0} to {1}",
868 return llvm::make_error<DILDiagnosticError>(
869 m_expr, std::move(errMsg), location,
875llvm::Expected<CastKind>
886 std::string errMsg = llvm::formatv(
"Cast from {0} to {1} is not allowed",
890 return llvm::make_error<DILDiagnosticError>(
891 m_expr, std::move(errMsg), location,
901 std::string errMsg = llvm::formatv(
902 "cannot cast from type {0} to pointer type {1}",
905 return llvm::make_error<DILDiagnosticError>(
906 m_expr, std::move(errMsg), location,
913 std::string errMsg = llvm::formatv(
914 "casting of {0} to {1} is not implemented yet",
916 return llvm::make_error<DILDiagnosticError>(
917 m_expr, std::move(errMsg), location,
925 return operand_or_err;
935 operand->GetName().GetStringRef());
936 op_type = operand->GetCompilerType();
941 return type_or_err.takeError();
944 if (operand->GetCompilerType().IsReferenceType()) {
946 operand = operand->Dereference(
error);
948 return llvm::make_error<DILDiagnosticError>(
m_expr,
error.AsCString(),
955 return operand->CastToEnumType(target_type);
961 return operand->CastToBasicType(target_type);
966 ? operand->GetLoadAddress()
967 : (op_type.
IsSigned() ? operand->GetValueAsSigned(0)
968 : operand->GetValueAsUnsigned(0));
969 llvm::StringRef name =
"result";
981 llvm::formatv(
"unable to cast from '{0}' to '{1}'",
983 return llvm::make_error<DILDiagnosticError>(
m_expr, std::move(errMsg),
static llvm::raw_ostream & error(Stream &strm)
lldb::VariableListSP GetVariableList(bool can_create)
Get the variable list for a compile unit.
lldb::LanguageType GetLanguage()
Generic representation of a type in a programming language.
bool IsEnumerationType(bool &is_signed) const
bool IsArrayType(CompilerType *element_type=nullptr, uint64_t *size=nullptr, bool *is_incomplete=nullptr) const
CompilerType GetPointerType() const
Return a new CompilerType that is a pointer to this type.
llvm::Expected< uint64_t > GetByteSize(ExecutionContextScope *exe_scope) const
Return the size of the type in bytes.
bool IsPointerToVoid() const
CompilerType GetNonReferenceType() const
If this type is a reference to a type (L value or R value reference), return a new type with the refe...
ConstString GetTypeName(bool BaseOnly=false) const
bool IsReferenceType(CompilerType *pointee_type=nullptr, bool *is_rvalue=nullptr) const
std::string TypeDescription()
CompilerType GetArrayElementType(ExecutionContextScope *exe_scope) const
Creating related types.
bool IsInteger() const
This is used when you don't care about the signedness of the integer.
CompilerType GetPointeeType() const
If this type is a pointer type, return the type that the pointer points to, else return an invalid ty...
llvm::Expected< uint64_t > GetBitSize(ExecutionContextScope *exe_scope) const
Return the size of the type in bits.
bool IsScalarType() const
bool IsNullPtrType() const
bool IsPointerType(CompilerType *pointee_type=nullptr) const
A uniqued constant string class.
llvm::StringRef GetStringRef() const
Get the string value as a llvm::StringRef.
"lldb/Target/ExecutionContextScope.h" Inherit from this if your object can reconstruct its execution ...
virtual void CalculateExecutionContext(ExecutionContext &exe_ctx)=0
Reconstruct the object's execution context into sc.
"lldb/Target/ExecutionContext.h" A class that contains an execution context.
void TruncOrExtendTo(uint16_t bits, bool sign)
Convert to an integer with bits and the given signedness.
bool Fail() const
Test for error condition.
bool Success() const
Test for success condition.
const char * GetData() const
Defines a symbol context baton that can be handed other debug core functions.
llvm::StringRef GetInstanceVariableName()
Determines the name of the instance variable for the this decl context.
lldb::ModuleSP module_sp
The Module for a given query.
CompileUnit * comp_unit
The CompileUnit for a given query.
static lldb::ValueObjectSP Create(ExecutionContextScope *exe_scope, lldb::RegisterContextSP ®_ctx_sp, const RegisterInfo *reg_info)
static lldb::ValueObjectSP Create(ExecutionContextScope *exe_scope, const lldb::VariableSP &var_sp)
static lldb::ValueObjectSP CreateValueObjectFromBool(lldb::TargetSP target, bool value, llvm::StringRef name)
Create a value object containing the given boolean value.
CompilerType GetCompilerType()
static lldb::ValueObjectSP CreateValueObjectFromAddress(llvm::StringRef name, uint64_t address, const ExecutionContext &exe_ctx, CompilerType type, bool do_deref=true)
Given an address either create a value object containing the value at that address,...
lldb::addr_t GetLoadAddress()
Return the target load address associated with this value object.
static lldb::ValueObjectSP CreateValueObjectFromScalar(lldb::TargetSP target, Scalar &s, CompilerType type, llvm::StringRef name)
Create a value object containing the given Scalar value.
The rest of the classes in this file, except for the Visitor class at the very end,...
uint32_t GetLocation() const
virtual llvm::Expected< lldb::ValueObjectSP > Accept(Visitor *v) const =0
ASTNode & GetBase() const
ASTNode & GetIndex() const
ASTNode & GetOperand() const
CompilerType GetType() const
const llvm::APFloat & GetValue() const
std::string GetName() const
uint32_t GetRadix() const
IntegerTypeSuffix GetTypeSuffix() const
const llvm::APInt & GetValue() const
std::shared_ptr< StackFrame > m_exe_ctx_scope
llvm::Expected< lldb::ValueObjectSP > Evaluate(const ASTNode &node)
Evaluate an ASTNode.
llvm::Expected< lldb::ValueObjectSP > EvaluateAndDereference(const ASTNode &node)
Evaluate an ASTNode.
Interpreter(lldb::TargetSP target, llvm::StringRef expr, std::shared_ptr< StackFrame > frame_sp, lldb::DynamicValueType use_dynamic, bool use_synthetic, bool fragile_ivar, bool check_ptr_vs_member)
llvm::Expected< lldb::ValueObjectSP > UnaryConversion(lldb::ValueObjectSP valobj, uint32_t location)
Perform usual unary conversions on a value.
llvm::Expected< lldb::ValueObjectSP > Visit(const IdentifierNode &node) override
bool m_check_ptr_vs_member
llvm::Expected< CompilerType > PickIntegerType(lldb::TypeSystemSP type_system, std::shared_ptr< ExecutionContextScope > ctx, const IntegerLiteralNode &literal)
lldb::DynamicValueType m_use_dynamic
llvm::Expected< CastKind > VerifyCastType(lldb::ValueObjectSP operand, CompilerType source_type, CompilerType target_type, int location)
As a preparation for type casting, compare the requested 'target' type of the cast with the type of t...
llvm::Expected< CastKind > VerifyArithmeticCast(CompilerType source_type, CompilerType target_type, int location)
A helper function for VerifyCastType (below).
llvm::StringRef GetFieldName() const
ASTNode & GetBase() const
UnaryOpKind GetKind() const
ASTNode & GetOperand() const
CastKind
The type casts allowed by DIL.
@ eEnumeration
Casting from a scalar to an enumeration type.
@ ePointer
Casting to a pointer type.
@ eNone
Invalid promotion type (results in error).
@ eArithmetic
Casting to a scalar.
lldb::ValueObjectSP GetDynamicOrSyntheticValue(lldb::ValueObjectSP value_sp, lldb::DynamicValueType use_dynamic, bool use_synthetic)
static CompilerType GetBasicType(lldb::TypeSystemSP type_system, lldb::BasicType basic_type)
static lldb::ValueObjectSP ArrayToPointerConversion(ValueObject &valobj, ExecutionContextScope &ctx, llvm::StringRef name)
static llvm::Expected< lldb::TypeSystemSP > GetTypeSystemFromCU(std::shared_ptr< ExecutionContextScope > ctx)
static lldb::VariableSP DILFindVariable(ConstString name, VariableList &variable_list)
lldb::ValueObjectSP LookupGlobalIdentifier(llvm::StringRef name_ref, std::shared_ptr< StackFrame > frame_sp, lldb::TargetSP target_sp, lldb::DynamicValueType use_dynamic)
Given the name of an identifier, check to see if it matches the name of a global variable.
lldb::ValueObjectSP LookupIdentifier(llvm::StringRef name_ref, std::shared_ptr< StackFrame > frame_sp, lldb::DynamicValueType use_dynamic)
Given the name of an identifier (variable name, member name, type name, etc.), find the ValueObject f...
std::shared_ptr< lldb_private::TypeSystem > TypeSystemSP
BasicType
Basic types enumeration for the public API SBType::GetBasicType().
@ eBasicTypeUnsignedLongLong
std::shared_ptr< lldb_private::ValueObject > ValueObjectSP
LanguageType
Programming language type.
@ eLanguageTypeObjC
Objective-C.
std::shared_ptr< lldb_private::VariableList > VariableListSP
std::shared_ptr< lldb_private::Variable > VariableSP
std::shared_ptr< lldb_private::Target > TargetSP
std::shared_ptr< lldb_private::RegisterContext > RegisterContextSP
Every register is described in detail including its name, alternate name (optional),...