LLDB mainline
ScriptInterpreterNone.cpp
Go to the documentation of this file.
1//===-- ScriptInterpreterNone.cpp -----------------------------------------===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
10#include "lldb/Core/Debugger.h"
12#include "lldb/Utility/Stream.h"
14
15#include "llvm/Support/Threading.h"
16
17#include <mutex>
18
19using namespace lldb;
20using namespace lldb_private;
21
23
26
28
29bool ScriptInterpreterNone::ExecuteOneLine(llvm::StringRef command,
31 const ExecuteScriptOptions &) {
33 "error: there is no embedded script interpreter in this mode.\n");
34 return false;
35}
36
39 "error: there is no embedded script interpreter in this mode.\n");
40}
41
43 static llvm::once_flag g_once_flag;
44
45 llvm::call_once(g_once_flag, []() {
49 });
50}
51
53
56 return std::make_shared<ScriptInterpreterNone>(debugger);
57}
58
60 return "Null script interpreter";
61}
#define LLDB_PLUGIN_DEFINE(PluginName)
Definition: PluginManager.h:31
A class to manage flag bits.
Definition: Debugger.h:79
StreamFile & GetErrorStream()
Definition: Debugger.h:155
static bool RegisterPlugin(llvm::StringRef name, llvm::StringRef description, ABICreateInstance create_callback)
bool ExecuteOneLine(llvm::StringRef command, CommandReturnObject *result, const ExecuteScriptOptions &options=ExecuteScriptOptions()) override
static llvm::StringRef GetPluginNameStatic()
static llvm::StringRef GetPluginDescriptionStatic()
static lldb::ScriptInterpreterSP CreateInstance(Debugger &debugger)
size_t PutCString(llvm::StringRef cstr)
Output a C string to the stream.
Definition: Stream.cpp:63
A class that represents a running process on the host machine.
Definition: SBAttachInfo.h:14
Definition: SBAddress.h:15
@ eScriptLanguageNone
std::shared_ptr< lldb_private::ScriptInterpreter > ScriptInterpreterSP
Definition: lldb-forward.h:384