================
@@ -0,0 +1,26 @@
+// RUN: rm -rf %t
+// RUN: split-file %s %t
+//
+// RUN: %clang_cc1 -std=c++26 -triple %itanium_abi_triple 
-emit-module-interface %t/a.cppm -o %t/a.pcm
+// RUN: %clang_cc1 -std=c++26 -triple %itanium_abi_triple 
-fmodule-file=a=%t/a.pcm -emit-llvm -o - %t/b.cpp | FileCheck %s
+
+//--- a.cppm
+export module a;
+
+template<typename... Ts>
+using element = Ts...[0];
+
+export element<int> a = 0;
+
+//--- b.cpp
+import a;
+
+int b() {
+  return a;
+}
+
+// The pack indexing type `element<int>` must be lowered to `i32` without
+// crashing in CodeGen.
----------------
zyn0217 wrote:

```suggestion
```

https://github.com/llvm/llvm-project/pull/205965
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to