#include "lldb/Symbol/PostfixExpression.h"
#include "lldb/Core/dwarf.h"
#include "lldb/Utility/Stream.h"
#include "llvm/ADT/StringExtras.h"
#include <optional>
usingnamespacelldb_private;
usingnamespacelldb_private::postfix;
usingnamespacelldb_private::dwarf;
static std::optional<BinaryOpNode::OpType>
GetBinaryOpType(llvm::StringRef token) { … }
static std::optional<UnaryOpNode::OpType>
GetUnaryOpType(llvm::StringRef token) { … }
Node *postfix::ParseOneExpression(llvm::StringRef expr,
llvm::BumpPtrAllocator &alloc) { … }
std::vector<std::pair<llvm::StringRef, Node *>>
postfix::ParseFPOProgram(llvm::StringRef prog, llvm::BumpPtrAllocator &alloc) { … }
namespace {
class SymbolResolver : public Visitor<bool> { … };
class DWARFCodegen : public Visitor<> { … };
}
void DWARFCodegen::Visit(BinaryOpNode &binary, Node *&) { … }
void DWARFCodegen::Visit(InitialValueNode &, Node *&) { … }
void DWARFCodegen::Visit(RegisterNode ®, Node *&) { … }
void DWARFCodegen::Visit(UnaryOpNode &unary, Node *&) { … }
bool postfix::ResolveSymbols(
Node *&node, llvm::function_ref<Node *(SymbolNode &)> replacer) { … }
void postfix::ToDWARF(Node &node, Stream &stream) { … }