Closed st0012 closed 1 year ago
With https://github.com/ruby/irb/pull/730, the request should not be broken anymore once it's released. And while it's still better not to use the deprecated InputCompletor
, I think we can wait a while to see how the new API will evolve before updating it.
I'm not sure but also LSP may need completion feature so different library is another idea for completion?
You're right, LSP also needs completion feature and we're building one in ruby-lsp
with a inhouse indexer, which we hope to extract into a gem when it's feature-completed.
But unlike a LSP server, IRB and debug
both have access to binding objects and runtime information, which means it can get great completion result without going through the expensive indexing process. So I think it's still worth exploring a different completor for IRB and debug
.
In IRB 1.8.2, the completor's design and API has been changed and thus would break DAP server's completion request. This commit fixes the issue by introducing a
Completor
class that abstracts away the differences between the old and new completor.cc @tompng