[all-commits] [llvm/llvm-project] 3ee0f9: [libc++] Avoid including vector in <functional> (#...

Nikolas Klauser via All-commits all-commits at lists.llvm.org
Wed Jul 2 12:48:53 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 3ee0f97b950a550ef14e3adbdf45f507273f2190
      https://github.com/llvm/llvm-project/commit/3ee0f97b950a550ef14e3adbdf45f507273f2190
  Author: Nikolas Klauser <nikolasklauser at berlin.de>
  Date:   2025-07-02 (Wed, 02 Jul 2025)

  Changed paths:
    M libcxx/include/__functional/boyer_moore_searcher.h
    M libcxx/include/functional

  Log Message:
  -----------
  [libc++] Avoid including vector in <functional> (#144310)

`vector` has been used in a very simple way in `boyer_moore_searcher`.
We can instead just use `unique_ptr<T[]>`, which is a lot simpler,
allowing us to drop the `vector` dependency while not losing any
expressiveness in the code. As a nice side effect, this also reduces the
time it takes to instantiate the `boyer_moore_searcher` constructor from
26ms to 22ms on my machine.



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