[clang] [clang-tools-extra] [llvm] [Clang] Add __builtin_type_pack_dedup template to deduplicate types in template arguments (PR #106730)
Matheus Izvekov via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 17 21:11:52 PDT 2024
================
@@ -309,7 +309,10 @@ enum BuiltinTemplateKind : int {
BTK__make_integer_seq,
/// This names the __type_pack_element BuiltinTemplateDecl.
- BTK__type_pack_element
+ BTK__type_pack_element,
+
+ /// This names the __type_list_dedup BuiltinTemplateDecl.
+ BTK__type_list_dedup,
----------------
mizvekov wrote:
One downside of builtin templates is that they can affect mangling, if we wish to support cases where we can't specialize them until dependencies are resolved.
For example, we can't do anything with __make_integer_seq if the count is value dependent, which means in order to support that case, we build a canonical TST which is named by the builtin template name, and this means `__make_integer_seq` will be mangled.
https://github.com/llvm/llvm-project/pull/106730
More information about the cfe-commits
mailing list