[all-commits] [llvm/llvm-project] 216314: Centralize the handling of completion for simple a...

jimingham via All-commits all-commits at lists.llvm.org
Mon Feb 19 16:43:20 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 21631494b068d9364b8dc8f18e59adee9131a0a5
      https://github.com/llvm/llvm-project/commit/21631494b068d9364b8dc8f18e59adee9131a0a5
  Author: jimingham <jingham at apple.com>
  Date:   2024-02-19 (Mon, 19 Feb 2024)

  Changed paths:
    M lldb/include/lldb/Interpreter/CommandObject.h
    M lldb/include/lldb/Interpreter/CommandOptionArgumentTable.h
    M lldb/include/lldb/lldb-enumerations.h
    M lldb/source/Commands/CommandObjectCommands.cpp
    M lldb/source/Commands/CommandObjectDWIMPrint.cpp
    M lldb/source/Commands/CommandObjectDWIMPrint.h
    M lldb/source/Commands/CommandObjectFrame.cpp
    M lldb/source/Commands/CommandObjectPlatform.cpp
    M lldb/source/Commands/CommandObjectPlugin.cpp
    M lldb/source/Commands/CommandObjectProcess.cpp
    M lldb/source/Commands/CommandObjectRegister.cpp
    M lldb/source/Commands/CommandObjectSession.cpp
    M lldb/source/Commands/CommandObjectSettings.cpp
    M lldb/source/Commands/CommandObjectTarget.cpp
    M lldb/source/Commands/CommandObjectThread.cpp
    M lldb/source/Commands/CommandObjectType.cpp
    M lldb/source/Commands/CommandObjectWatchpoint.cpp
    M lldb/source/Interpreter/CommandObject.cpp
    M lldb/test/API/commands/help/TestHelp.py

  Log Message:
  -----------
  Centralize the handling of completion for simple argument lists. (#82085)

Most commands were adding argument completion handling by themselves,
resulting in a lot of unnecessary boilerplate. In many cases, this could
be done generically given the argument definition and the entries in the
g_argument_table.

I'm going to address this in a couple passes. In this first pass, I
added handling of commands that have only one argument list, with one
argument type, either single or repeated, and changed all the commands
that are of this sort (and don't have other bits of business in their
completers.)

I also added some missing connections between arg types and completions
to the table, and added a RemoteFilename and RemotePath to use in places
where we were using the Remote completers. Those arguments used to say
they were "files" but they were in fact remote files.

I also added a module arg type to use where we were using the module
completer. In that case, we should call the argument module.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list