[all-commits] [llvm/llvm-project] fed7be: Mark identifier prefixes as substitutable

Harald van Dijk via All-commits all-commits at lists.llvm.org
Mon May 2 10:08:14 PDT 2022

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: fed7be096f8ed5d70029acd712ac19ffc61e04e5
  Author: Harald van Dijk <harald at gigawatt.nl>
  Date:   2022-05-02 (Mon, 02 May 2022)

  Changed paths:
    M clang/docs/ReleaseNotes.rst
    M clang/include/clang/Basic/LangOptions.h
    M clang/lib/AST/ItaniumMangle.cpp
    M clang/lib/Frontend/CompilerInvocation.cpp
    M clang/test/CodeGenCXX/clang-abi-compat.cpp
    M clang/test/CodeGenCXX/mangle.cpp

  Log Message:
  Mark identifier prefixes as substitutable

The Itanium C++ ABI says prefixes are substitutable. For most prefixes
we already handle this: the manglePrefix(const DeclContext *, bool) and
manglePrefix(QualType) overloads explicitly handles substitutions or
defer to functions that handle substitutions on their behalf. The
manglePrefix(NestedNameSpecifier *) overload, however, is different and
handles some cases implicitly, but not all. The Identifier case was not
handled; this change adds handling for it, as well as a test case.

Reviewed By: erichkeane

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

More information about the All-commits mailing list