Issue |
100887
|
Summary |
[Modules] instantiation of templated class with static field causes compilation error
|
Labels |
new issue
|
Assignees |
|
Reporter |
GuzevArtem
|
Repro:
https://godbolt.org/z/43zn8f68d
```
Module.ixx:17:25: error: declaration of 'static_pointer' in module Main follows declaration in module Module
17 | int* derived<parent_t>::static_pointer = nullptr;
| ^
Module.ixx:11:12: note: in instantiation of static data member 'derived<dummy>::static_pointer' requested here
11 | return static_pointer != nullptr;
| ^
Main.ixx:8:28: note: in instantiation of member function 'derived<dummy>::check' requested here
8 | return derived<dummy>::check();
| ^
Module.ixx:8:13: note: previous declaration is here
8 | static int* static_pointer;
| ^
```
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs