[Lldb-commits] [lldb] c25e48c - [lldb] Move CommandOverrideCallbackWithResult to lldb_private namespace

Alex Langford via lldb-commits lldb-commits at lists.llvm.org
Thu Jul 13 11:21:44 PDT 2023


Author: Alex Langford
Date: 2023-07-13T11:21:35-07:00
New Revision: c25e48c5d776c5fb8f94f13a73f44cd930968c29

URL: https://github.com/llvm/llvm-project/commit/c25e48c5d776c5fb8f94f13a73f44cd930968c29
DIFF: https://github.com/llvm/llvm-project/commit/c25e48c5d776c5fb8f94f13a73f44cd930968c29.diff

LOG: [lldb] Move CommandOverrideCallbackWithResult to lldb_private namespace

This has an `lldb_private` type in its parameter, it should be in
`lldb-private-types.h`

Differential Revision: https://reviews.llvm.org/D155129

Added: 
    

Modified: 
    lldb/include/lldb/Interpreter/CommandObject.h
    lldb/include/lldb/lldb-private-types.h
    lldb/include/lldb/lldb-types.h

Removed: 
    


################################################################################
diff  --git a/lldb/include/lldb/Interpreter/CommandObject.h b/lldb/include/lldb/Interpreter/CommandObject.h
index c601570ab90e82..d8358435a483ba 100644
--- a/lldb/include/lldb/Interpreter/CommandObject.h
+++ b/lldb/include/lldb/Interpreter/CommandObject.h
@@ -294,8 +294,9 @@ class CommandObject : public std::enable_shared_from_this<CommandObject> {
     m_command_override_baton = baton;
   }
 
-  void SetOverrideCallback(lldb::CommandOverrideCallbackWithResult callback,
-                           void *baton) {
+  void
+  SetOverrideCallback(lldb_private::CommandOverrideCallbackWithResult callback,
+                      void *baton) {
     m_command_override_callback = callback;
     m_command_override_baton = baton;
   }
@@ -377,7 +378,7 @@ class CommandObject : public std::enable_shared_from_this<CommandObject> {
   Flags m_flags;
   std::vector<CommandArgumentEntry> m_arguments;
   lldb::CommandOverrideCallback m_deprecated_command_override_callback;
-  lldb::CommandOverrideCallbackWithResult m_command_override_callback;
+  lldb_private::CommandOverrideCallbackWithResult m_command_override_callback;
   void *m_command_override_baton;
   bool m_is_user_command = false;
 

diff  --git a/lldb/include/lldb/lldb-private-types.h b/lldb/include/lldb/lldb-private-types.h
index 9ff85ab162ada9..1db266b5cf116d 100644
--- a/lldb/include/lldb/lldb-private-types.h
+++ b/lldb/include/lldb/lldb-private-types.h
@@ -121,6 +121,8 @@ using ValueObjectProviderTy =
 
 typedef void (*DebuggerDestroyCallback)(lldb::user_id_t debugger_id,
                                         void *baton);
+typedef bool (*CommandOverrideCallbackWithResult)(
+    void *baton, const char **argv, lldb_private::CommandReturnObject &result);
 } // namespace lldb_private
 
 #endif // #if defined(__cplusplus)

diff  --git a/lldb/include/lldb/lldb-types.h b/lldb/include/lldb/lldb-types.h
index f38095ffebd890..b9b42c7f0a1535 100644
--- a/lldb/include/lldb/lldb-types.h
+++ b/lldb/include/lldb/lldb-types.h
@@ -71,8 +71,6 @@ typedef int pipe_t;                     // Host pipe type
 
 typedef void (*LogOutputCallback)(const char *, void *baton);
 typedef bool (*CommandOverrideCallback)(void *baton, const char **argv);
-typedef bool (*CommandOverrideCallbackWithResult)(
-    void *baton, const char **argv, lldb_private::CommandReturnObject &result);
 typedef bool (*ExpressionCancelCallback)(ExpressionEvaluationPhase phase,
                                          void *baton);
 


        


More information about the lldb-commits mailing list