[Lldb-commits] [lldb] [lldb][lldb-dap] Basic implementation of a deferred request. (PR #140260)

John Harrison via lldb-commits lldb-commits at lists.llvm.org
Fri May 16 08:44:49 PDT 2025


================
@@ -46,7 +46,14 @@ class BaseRequestHandler {
 
   virtual ~BaseRequestHandler() = default;
 
-  void Run(const protocol::Request &);
+  /// Return `true` if the request should be deferred.
+  [[nodiscard]]
+  bool Run(const protocol::Request &);
+
+  [[nodiscard]]
+  virtual bool DeferRequest() const {
----------------
ashgti wrote:

This is specifically about deferring until configurationDone is called. We don't really have support for an async request handler yet. I thought about implementing an `AsyncRequestHandler` that would allow the request handler to unblock the handler queue before sending a reply, but I haven't needed it just yet so I haven't sent that out for a PR.

Thats a long winded way of saying, should we make this more specific? Maybe `DeferUntilConfigurationDone`? I'm open to other names, just want to be clear.

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


More information about the lldb-commits mailing list