[PATCHv2,0/8] Further filename completion improvements

Message ID cover.1713603415.git.aburgess@redhat.com
Headers
Series Further filename completion improvements |

Message

Andrew Burgess April 20, 2024, 9:10 a.m. UTC
  In V2:

  - Patches #1 and #2 are new in this iteration.  Patches #3 to #8 are
    the patches from V1 rebased onto these two new patches,

  - Patch #1 adds documentation for the formatting of filename
    arguments, this tries to explain the two diffent ways that GDB
    expects filename arguments to be formatted.

  - Patch #2 addresses the problem that Lancelot pointed out: some
    commands don't expect filename arguments to be quoted, or to
    contain escapes.  In this patch I split the filename completion in
    two so the two different filename argument formats are handled
    separately...

  - This clears the way for the rest of the series, which updates how
    completion works for those filename arguments that do accept
    quoting and escaping,

  - Patches #3 to #8 are in principle the same as in V1, but there
    were some changes after rebasing onto the new patch #2.

---

Andrew Burgess (8):
  gdb/doc: document how filename arguments are formatted
  gdb: split apart two different types of filename completion
  gdb: improve escaping when completing filenames
  gdb: move display of completion results into completion_result class
  gdb: simplify completion_result::print_matches
  gdb: add match formatter mechanism for 'complete' command output
  gdb: apply escaping to filenames in 'complete' results
  gdb: improve gdb_rl_find_completion_word for quoted words

 gdb/auto-load.c                               |   4 +-
 gdb/breakpoint.c                              |   5 +-
 gdb/cli/cli-cmds.c                            |  34 +-
 gdb/cli/cli-decode.c                          |  12 +-
 gdb/cli/cli-dump.c                            |   6 +-
 gdb/compile/compile.c                         |   3 +-
 gdb/completer.c                               | 501 +++++++++++++++---
 gdb/completer.h                               |  79 ++-
 gdb/corefile.c                                |   4 +-
 gdb/corelow.c                                 |   4 +-
 gdb/doc/gdb.texinfo                           |  66 +++
 gdb/dwarf2/index-write.c                      |   3 +-
 gdb/exec.c                                    |   7 +-
 gdb/guile/scm-cmd.c                           |   2 +-
 gdb/infcmd.c                                  |  15 +-
 gdb/inferior.c                                |   2 +-
 gdb/jit.c                                     |   2 +-
 gdb/python/py-cmd.c                           |   2 +-
 gdb/record-full.c                             |   5 +-
 gdb/record.c                                  |   2 +-
 gdb/skip.c                                    |   2 +-
 gdb/source.c                                  |   3 +-
 gdb/symfile.c                                 |   7 +-
 gdb/target-descriptions.c                     |   7 +-
 gdb/target.c                                  |   4 +-
 gdb/target.h                                  |   9 +-
 .../gdb.base/filename-completion.exp          | 257 +++++++--
 gdb/tracectf.c                                |   3 +-
 gdb/tracefile-tfile.c                         |   4 +-
 29 files changed, 857 insertions(+), 197 deletions(-)


base-commit: 7a59cf956369336eb9346196a85976e4042019f5