[Lldb-commits] [lldb] [lldb-dap] Use protocol types for modules request and events. (PR #146966)

Jonas Devlieghere via lldb-commits lldb-commits at lists.llvm.org
Thu Jul 3 16:32:41 PDT 2025


================
@@ -743,6 +743,48 @@ bool fromJSON(const llvm::json::Value &, DisassembledInstruction &,
               llvm::json::Path);
 llvm::json::Value toJSON(const DisassembledInstruction &);
 
+struct Module {
+  /// Unique identifier for the module.
+  std::string id;
+
+  /// A name of the module.
+  std::string name;
+
+  /// Logical full path to the module. The exact definition is implementation
+  /// defined, but usually this would be a full path to the on-disk file for the
+  /// module.
+  std::string path;
+
+  /// True if the module is optimized.
+  std::optional<bool> isOptimized;
+
+  /// True if the module is considered 'user code' by a debugger that supports
+  /// 'Just My Code'.
+  std::optional<bool> isUserCode;
+
+  /// Version of Module.
+  std::string version;
+
+  /// User-understandable description of if symbols were found for the module
+  /// (ex: 'Symbols Loaded', 'Symbols not found', etc.)
+  std::string symbolStatus;
+
+  /// Logical full path to the symbol file. The exact definition is
+  /// implementation defined.
+  std::string symbolFilePath;
+
+  /// Module created or modified, encoded as an RFC 3339 timestamp.
+  std::string dateTimeStamp;
+
+  /// Address range covered by this module.
+  std::string addressRange;
+
+  /* Custom fields */
+  /// Size of the debug_info sections in the module.
+  std::string debugInfoSize;
----------------
JDevlieghere wrote:

We don't use these style of comments. We can use Doxygen groups for this:


```suggestion
  /// Custom fields
  /// @{
  
  /// Size of the debug_info sections in the module.
  std::string debugInfoSize;
  
  /// @}
```

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


More information about the lldb-commits mailing list