[Lldb-commits] [lldb] [lldb-dap] Migrating DAP 'initialize' to new typed RequestHandler. (PR #133007)
John Harrison via lldb-commits
lldb-commits at lists.llvm.org
Thu Mar 27 09:22:45 PDT 2025
================
@@ -54,6 +54,79 @@ bool fromJSON(const llvm::json::Value &, DisconnectArguments &,
/// body field is required.
using DisconnectResponse = VoidResponse;
+/// Arguments for `initialize` request.
+struct InitializeRequestArguments {
+ /// The ID of the debug adapter.
+ std::string adatperID;
+
+ /// The ID of the client using this adapter.
+ std::optional<std::string> clientID;
+
+ /// The human-readable name of the client using this adapter.
+ std::optional<std::string> clientName;
+
+ /// The ISO-639 locale of the client using this adapter, e.g. en-US or de-CH.
+ std::optional<std::string> locale;
+
+ enum class PathFormat { path, uri };
+
+ /// Determines in what format paths are specified. The default is `path`,
+ /// which is the native format.
+ std::optional<PathFormat> pathFormat = PathFormat::path;
+
+ /// If true all line numbers are 1-based (default).
+ std::optional<bool> linesStartAt1;
+
+ /// If true all column numbers are 1-based (default).
+ std::optional<bool> columnsStartAt1;
+
+ enum class Feature {
+ /// Client supports the `type` attribute for variables.
+ supportsVariableType,
+ /// Client supports the paging of variables.
+ supportsVariablePaging,
+ /// Client supports the `runInTerminal` request.
+ supportsRunInTerminalRequest,
+ /// Client supports memory references.
+ supportsMemoryReferences,
+ /// Client supports progress reporting.
+ supportsProgressReporting,
+ /// Client supports the `invalidated` event.
+ supportsInvalidatedEvent,
+ /// Client supports the `memory` event.
+ supportsMemoryEvent,
+ /// Client supports the `argsCanBeInterpretedByShell` attribute on the
+ /// `runInTerminal` request.
+ supportsArgsCanBeInterpretedByShell,
+ /// Client supports the `startDebugging` request.
+ supportsStartDebuggingRequest,
+ /// The client will interpret ANSI escape sequences in the display of
+ /// `OutputEvent.output` and `Variable.value` fields when
+ /// `Capabilities.supportsANSIStyling` is also enabled.
+ supportsANSIStyling,
+ };
----------------
ashgti wrote:
I dropped 'support' from the name to shorten things slightly.
https://github.com/llvm/llvm-project/pull/133007
More information about the lldb-commits
mailing list