[all-commits] [llvm/llvm-project] 902974: Data formatters: Look through array element typedefs

Raphael Isemann via All-commits all-commits at lists.llvm.org
Fri Jan 10 02:45:45 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 902974277d507a149e33487d32e4ba58c41451b6
      https://github.com/llvm/llvm-project/commit/902974277d507a149e33487d32e4ba58c41451b6
  Author: Jaroslav Sevcik <jarin at google.com>
  Date:   2020-01-10 (Fri, 10 Jan 2020)

  Changed paths:
    A lldb/packages/Python/lldbsuite/test/functionalities/data-formatter/array_typedef/Makefile
    A lldb/packages/Python/lldbsuite/test/functionalities/data-formatter/array_typedef/TestArrayTypedef.py
    A lldb/packages/Python/lldbsuite/test/functionalities/data-formatter/array_typedef/main.cpp
    M lldb/source/API/SBType.cpp
    M lldb/source/DataFormatters/FormatManager.cpp
    M lldb/source/Symbol/ClangASTContext.cpp

  Log Message:
  -----------
  Data formatters: Look through array element typedefs

Summary:
Motivation: When formatting an array of typedefed chars, we would like to display the array as a string.

The string formatter currently does not trigger because the formatter lookup does not resolve typedefs for array elements (this behavior is inconsistent with pointers, for those we do look through pointee typedefs). This patch tries to make the array formatter lookup somewhat consistent with the pointer formatter lookup.

Reviewers: teemperor, clayborg

Reviewed By: teemperor, clayborg

Subscribers: clayborg, lldb-commits

Tags: #lldb

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




More information about the All-commits mailing list