HomePhabricator

Added initial code completion support for the `expr` command

Description

Added initial code completion support for the expr command

Summary:
This patch adds initial code completion support for the expr command.

We now have a completion handler in the expression CommandObject that
essentially just attempts to parse the given user expression with Clang with
an attached code completion consumer. We filter and prepare the
code completions provided by Clang and send them back to the completion
API.

The current completion is limited to variables that are in the current scope.
This includes local variables and all types used by local variables. We however
don't do any completion of symbols that are not used in the local scope (or
in some other way already in the ASTContext).

This is partly because there is not yet any code that manually searches for additiona
information in the debug information. Another cause is that for some reason the existing
code for loading these additional symbols when requested by Clang doesn't seem to work.
This will be fixed in a future patch.

Reviewers: jingham, teemperor

Reviewed By: teemperor

Subscribers: labath, aprantl, JDevlieghere, friss, lldb-commits

Differential Revision: https://reviews.llvm.org/D48465

Details

Committed
teemperorAug 30 2018, 10:29 AM
Reviewer
teemperor
Differential Revision
D48465: Added initial code completion support for the `expr` command
Parents
rL341085: [LLVM-C] Add Bindings For Named Metadata
Branches
Unknown
Tags
Unknown