[Lldb-commits] [PATCH] D81001: [lldb] Display autosuggestion part in gray if there is one possible suggestion

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Tue Jun 23 01:01:01 PDT 2020


labath added inline comments.


================
Comment at: lldb/source/Interpreter/CommandInterpreter.cpp:1875-1878
+    if (entry.startswith(line)) {
+      llvm::StringRef res = entry.substr(line.size());
+      result = res.str();
+      return result;
----------------
```
if (entry.consume_front(line)) {
  result = entry.str();
  return result; // Why is this returning the result both as a proper return value and a by-ref argument?
}
```


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

https://reviews.llvm.org/D81001





More information about the lldb-commits mailing list