[all-commits] [llvm/llvm-project] 8feb84: [Clang][Type] Add static assertion to guard future...

Yueh-Ting (eop) Chen via All-commits all-commits at lists.llvm.org
Thu Jun 8 09:37:21 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 8feb8423602351afa190f88977f71444cf15304f
      https://github.com/llvm/llvm-project/commit/8feb8423602351afa190f88977f71444cf15304f
  Author: eopXD <yueh.ting.chen at gmail.com>
  Date:   2023-06-08 (Thu, 08 Jun 2023)

  Changed paths:
    M clang/include/clang/AST/Type.h

  Log Message:
  -----------
  [Clang][Type] Add static assertion to guard future expansion for BuiltinType numbering

Recent expansion D152070 exceeds the limit and I had a hard time
triaging the bug because the overflow just creates unexpected
behaviors within the compiler.

This patch adds a static assertion to keep an eye for overflows when we
expand more types in the future.

Reviewed By: aaron.ballman

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




More information about the All-commits mailing list