aboutsummaryrefslogtreecommitdiff
path: root/contrib/llvm-project/lldb/source/Plugins/ScriptInterpreter/Lua/Lua.cpp
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2023-09-02 21:17:18 +0000
committerDimitry Andric <dim@FreeBSD.org>2023-12-08 17:34:50 +0000
commit06c3fb2749bda94cb5201f81ffdb8fa6c3161b2e (patch)
tree62f873df87c7c675557a179e0c4c83fe9f3087bc /contrib/llvm-project/lldb/source/Plugins/ScriptInterpreter/Lua/Lua.cpp
parentcf037972ea8863e2bab7461d77345367d2c1e054 (diff)
parent7fa27ce4a07f19b07799a767fc29416f3b625afb (diff)
Diffstat (limited to 'contrib/llvm-project/lldb/source/Plugins/ScriptInterpreter/Lua/Lua.cpp')
-rw-r--r--contrib/llvm-project/lldb/source/Plugins/ScriptInterpreter/Lua/Lua.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/contrib/llvm-project/lldb/source/Plugins/ScriptInterpreter/Lua/Lua.cpp b/contrib/llvm-project/lldb/source/Plugins/ScriptInterpreter/Lua/Lua.cpp
index b82a2647e9a0..8dad22d077be 100644
--- a/contrib/llvm-project/lldb/source/Plugins/ScriptInterpreter/Lua/Lua.cpp
+++ b/contrib/llvm-project/lldb/source/Plugins/ScriptInterpreter/Lua/Lua.cpp
@@ -83,8 +83,8 @@ Lua::CallBreakpointCallback(void *baton, lldb::StackFrameSP stop_frame_sp,
lua_pushlightuserdata(m_lua_state, baton);
lua_gettable(m_lua_state, LUA_REGISTRYINDEX);
StructuredDataImpl extra_args_impl(std::move(extra_args_sp));
- return LLDBSwigLuaBreakpointCallbackFunction(m_lua_state, stop_frame_sp,
- bp_loc_sp, extra_args_impl);
+ return lua::SWIGBridge::LLDBSwigLuaBreakpointCallbackFunction(
+ m_lua_state, stop_frame_sp, bp_loc_sp, extra_args_impl);
}
llvm::Error Lua::RegisterWatchpointCallback(void *baton, const char *body) {
@@ -109,8 +109,8 @@ Lua::CallWatchpointCallback(void *baton, lldb::StackFrameSP stop_frame_sp,
lua_pushlightuserdata(m_lua_state, baton);
lua_gettable(m_lua_state, LUA_REGISTRYINDEX);
- return LLDBSwigLuaWatchpointCallbackFunction(m_lua_state, stop_frame_sp,
- wp_sp);
+ return lua::SWIGBridge::LLDBSwigLuaWatchpointCallbackFunction(
+ m_lua_state, stop_frame_sp, wp_sp);
}
llvm::Error Lua::CheckSyntax(llvm::StringRef buffer) {
@@ -131,14 +131,13 @@ llvm::Error Lua::CheckSyntax(llvm::StringRef buffer) {
}
llvm::Error Lua::LoadModule(llvm::StringRef filename) {
- FileSpec file(filename);
+ const FileSpec file(filename);
if (!FileSystem::Instance().Exists(file)) {
return llvm::make_error<llvm::StringError>("invalid path",
llvm::inconvertibleErrorCode());
}
- ConstString module_extension = file.GetFileNameExtension();
- if (module_extension != ".lua") {
+ if (file.GetFileNameExtension() != ".lua") {
return llvm::make_error<llvm::StringError>("invalid extension",
llvm::inconvertibleErrorCode());
}