Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 3 additions & 7 deletions lldb/include/lldb/ValueObject/DILAST.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@
#include "llvm/ADT/APInt.h"
#include "llvm/Support/Casting.h"

namespace lldb_private {

namespace dil {
namespace lldb_private::dil {

/// Struct to hold information about member fields. Used by the parser for the
/// Data Inspection Language (DIL).
Expand Down Expand Up @@ -142,7 +140,7 @@ enum class UnaryOpKind {

/// Translates DIL tokens to BinaryOpKind.
BinaryOpKind
dil_token_kind_to_binary_op_kind(dil::TokenKind token_kind);
dil_token_kind_to_binary_op_kind(Token::Kind token_kind);

/// Returns bool indicating whether or not the input kind is an assignment.
bool binary_op_kind_is_comp_assign(BinaryOpKind kind);
Expand Down Expand Up @@ -745,8 +743,6 @@ class Visitor {
virtual void Visit(const TernaryOpNode *node) = 0;
};

} // namespace dil

} // namespace lldb_private
} // namespace lldb_private::dil

#endif // LLDB_VALUEOBJECT_DILAST_H
25 changes: 9 additions & 16 deletions lldb/include/lldb/ValueObject/DILEval.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,16 @@
//
//===----------------------------------------------------------------------===//

#ifndef LLDB_VALUEOBJECT_DILEVAL_H_
#define LLDB_VALUEOBJECT_DILEVAL_H_
#ifndef LLDB_VALUEOBJECT_DILEVAL_H
#define LLDB_VALUEOBJECT_DILEVAL_H

#include <memory>
#include <vector>

#include "lldb/ValueObject/DILAST.h"
#include "lldb/ValueObject/DILParser.h"

namespace lldb_private {

namespace dil {
namespace lldb_private::dil {

class FlowAnalysis {
public:
Expand All @@ -33,13 +31,10 @@ class FlowAnalysis {

class DILInterpreter : Visitor {
public:
DILInterpreter(lldb::TargetSP target,
std::shared_ptr<DILSourceManager> sm);
DILInterpreter(lldb::TargetSP target,
std::shared_ptr<DILSourceManager> sm,
DILInterpreter(lldb::TargetSP target, llvm::StringRef expr);
DILInterpreter(lldb::TargetSP target, llvm::StringRef expr,
lldb::ValueObjectSP scope);
DILInterpreter(lldb::TargetSP target,
std::shared_ptr<DILSourceManager> sm,
DILInterpreter(lldb::TargetSP target, llvm::StringRef expr,
lldb::DynamicValueType use_dynamic);

lldb::ValueObjectSP DILEval(const DILASTNode* tree, lldb::TargetSP target_sp,
Expand Down Expand Up @@ -139,7 +134,7 @@ class DILInterpreter : Visitor {
// Used by the interpreter to create objects, perform casts, etc.
lldb::TargetSP m_target;

std::shared_ptr<DILSourceManager> m_sm;
llvm::StringRef m_expr;

// Flow analysis chain represents the expression evaluation flow for the
// current code branch. Each node in the chain corresponds to an AST node,
Expand All @@ -162,8 +157,6 @@ class DILInterpreter : Visitor {
Status m_error;
};

} // namespace dil

} // namespace lldb_private
} // namespace lldb_private::dil

#endif // LLDB_VALUEOBJECT_DILEVAL_H_
#endif // LLDB_VALUEOBJECT_DILEVAL_H
Loading