[all-commits] [llvm/llvm-project] 2d0328: [ADT] Move llvm::identity into IndexedMap (NFC) (#...

Kazu Hirata via All-commits all-commits at lists.llvm.org
Wed Oct 22 17:32:06 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 2d0328a47377fb6e8be4d76982072dcb607beb58
      https://github.com/llvm/llvm-project/commit/2d0328a47377fb6e8be4d76982072dcb607beb58
  Author: Kazu Hirata <kazu at google.com>
  Date:   2025-10-22 (Wed, 22 Oct 2025)

  Changed paths:
    M llvm/include/llvm/ADT/IndexedMap.h
    R llvm/include/llvm/ADT/identity.h

  Log Message:
  -----------
  [ADT] Move llvm::identity into IndexedMap (NFC) (#164568)

This patch moves llvm::identity to IndexedMap for two reasons:

- llvm::identity is used only IndexedMap.
- llvm::identity is not suitable for general use as it is not quite
  the same as std::identity despite the comments in identity.h.

Also, this patch renames the class to IdentityIndex and places it in
the "detail" namespace.



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