labath added a comment.

Thanks for the patch. It's a very interesting feature, but I'm not sure it is 
actually a good idea. Some tab completions can be very expensive (not to 
mention they can crash lldb), and so running them after every keypress sounds 
problematic to me. Editors usually have very complex logic to implement these 
things efficiently and unobtrusively. It usually involves running the 
completions on a separate thread with various delays to avoid stalling a user 
who types fast and avoid burning the cpu needlessly.

I don't see anything like that in this patch, and I'm not sure the complexity 
that would entail is worth avoiding pressing tab a couple of times. If we 
really do want this feature, I think it should be controlled by a setting, and 
probably the setting should be off by default.

I'm not sure what's your main motivation for this, but they way I could see 
this potentially being useful is if we had a notion of "lightweight" 
completions. These would things that don't do any extraordinary amount of work 
(like parsing gigabytes of debug info) -- just basic completions for lldb 
commands and their arguments.

Regarding the actual patch, I have two quick comments:

- please avoid unrelated formatting changes -- run clang-format only over the 
lines you've changed (`git clang-format HEAD^` or something similar)
- don't work with `stdout` directly -- you should be using the "stdout" notions 
local to the Editline class (e.g.., `m_output_file`)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D81001/new/

https://reviews.llvm.org/D81001



_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to