https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118964
Nathaniel Shead <nshead at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |nshead at gcc dot gnu.org
--- Comment #4 from Nathaniel Shead <nshead at gcc dot gnu.org> ---
The errors as described are correct and required by the standard; the noted
declarations are internal-linkage (declared with `static`) and thus cannot be
exposed from a non-TU-local entity in a module interface.
Clang would not provide these errors as it doesn't yet implement P1815
(https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2020/p1815r2.html).
That said, looking at your provided code this seems odd as it doesn't actually
use any of these noted declarations from OpenCV; I guess maybe this is some of
the known issues we have with not fully eliding all unused templates from the
GMF in the case of deferred instantiations.