[Lldb-commits] [lldb] [lldb-dap] Adding support for well typed events. (PR #130104)

Jonas Devlieghere via lldb-commits lldb-commits at lists.llvm.org
Wed Mar 19 07:54:55 PDT 2025


================
@@ -316,6 +316,36 @@ struct Source {
 bool fromJSON(const llvm::json::Value &, Source &, llvm::json::Path);
 llvm::json::Value toJSON(const Source &);
 
+// MARK: Events
+
+// "ExitedEvent": {
+//   "allOf": [ { "$ref": "#/definitions/Event" }, {
+//     "type": "object",
+//     "description": "The event indicates that the debuggee has exited and
+//     returns its exit code.", "properties": {
+//       "event": {
+//         "type": "string",
+//         "enum": [ "exited" ]
+//       },
+//       "body": {
+//         "type": "object",
+//         "properties": {
+//           "exitCode": {
+//             "type": "integer",
+//             "description": "The exit code returned from the debuggee."
+//           }
+//         },
+//         "required": [ "exitCode" ]
+//       }
+//     },
+//     "required": [ "event", "body" ]
+//   }]
+// }
+struct ExitedEventBody {
+  int exitCode;
----------------
JDevlieghere wrote:

Cool, I think we're on the same page. I'm fine with either. Unless @ashgti has an argument in favor of the classes I'm happy to go with this. 

https://github.com/llvm/llvm-project/pull/130104


More information about the lldb-commits mailing list