7
mirror of https://gitlab.com/kicad/code/kicad.git synced 2025-04-14 17:09:36 +00:00

Don't use dynamic_cast across compile boundaries.

(Especially not after we've already tested the
filenames explicitly so that we don't have to.)
This commit is contained in:
Jeff Young 2025-01-24 16:51:44 +00:00
parent 6f2a3582ae
commit 60c2469c75

View File

@ -128,7 +128,9 @@ public:
if( it != m_settings.end() )
{
ret = dynamic_cast<T*>( it->get() );
// Do NOT use dynamic_cast here. CLang will think it's the wrong class across
// compile boundaries and return nullptr.
ret = static_cast<T*>( it->get() );
}
else
{