================
@@ -18,6 +18,16 @@ int init_arr();
 template<typename T> template<typename U> template<typename V> int 
Outer<T>::Inner<U>::arr[sizeof(T) + sizeof(U) + sizeof(V)] = { init_arr() };
 int *p = Outer<char[100]>::Inner<char[20]>::arr<char[3]>;
 
+//CHECK: @_ZN8GH1406221gIiEE = linkonce_odr constant %"struct.GH140622::S" 
zeroinitializer
+namespace GH140622 {
+template <typename> struct S {};
+template <typename T> constexpr S<T> g;
+void test() {
+    constexpr auto x = 42;
----------------
shafik wrote:

As I pointed out here: 
https://github.com/llvm/llvm-project/issues/140622#issuecomment-2892633775

this also happens when the local is *const*, so it is worth testing that case 
and the non const/constexpr case.

https://github.com/llvm/llvm-project/pull/140699
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to