[all-commits] [llvm/llvm-project] c4eaf5: [ADT] Mark StringSwitch Cases with 6+ arguments as...

Jakub Kuderski via All-commits all-commits at lists.llvm.org
Wed Oct 15 07:10:54 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c4eaf56122d791d06c0a6f6be0224d8491d3beed
      https://github.com/llvm/llvm-project/commit/c4eaf56122d791d06c0a6f6be0224d8491d3beed
  Author: Jakub Kuderski <jakub at nod-labs.com>
  Date:   2025-10-15 (Wed, 15 Oct 2025)

  Changed paths:
    M llvm/include/llvm/ADT/StringSwitch.h

  Log Message:
  -----------
  [ADT] Mark StringSwitch Cases with 6+ arguments as deprecated. NFC. (#163405)

Switch to the `.Cases({S0, S1, ...}, Value)` overload instead.

Update existing uses affected by the deprecation and the surrounding
code (for consistency).

This is a part of a larger cleanup of StringSwitch. The goal is to
eventually deprecate all manually-enumerated overloads of Cases with a
hardcoded number of case values (in favor of passing them via an
initializer list). You can find the full explanation here:
https://github.com/llvm/llvm-project/pull/163117.

Start small (6+ arguments) to keep the number of changes manageable.



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