Performance optimizations.

This commit is contained in:
Jeff Young 2025-06-06 10:35:03 +01:00
parent aa892efc17
commit 31c6c28882
4 changed files with 15 additions and 17 deletions

View File

@ -590,8 +590,6 @@ wxString EscapeHTML( const wxString& aString )
wxString UnescapeHTML( const wxString& aString )
{
wxString converted = aString;
// clang-format off
static const std::map<wxString, wxString> c_replacements = {
{ wxS( "quot" ), wxS( "\"" ) },
@ -617,7 +615,7 @@ wxString UnescapeHTML( const wxString& aString )
size_t len = 0;
wxString result;
wxString str = converted;
wxString str = aString;
while( regex.Matches( str ) )
{

View File

@ -730,9 +730,9 @@ void KIBIS_PIN::getKuKdFromFile( const std::string& aSimul )
Report( _( "Cannot remove temporary output file" ), RPT_SEVERITY_WARNING );
}
m_Ku = ku;
m_Kd = kd;
m_t = t;
m_Ku = std::move( ku );
m_Kd = std::move( kd );
m_t = std::move( t );
}
@ -831,9 +831,9 @@ void KIBIS_PIN::getKuKdOneWaveform( KIBIS_MODEL&
ku.push_back( 0 );
kd.push_back( 0 );
t.push_back( 0 );
m_Ku = ku;
m_Kd = kd;
m_t = t;
m_Ku = std::move( ku );
m_Kd = std::move( kd );
m_t = std::move( t );
}
else
{
@ -978,9 +978,9 @@ void KIBIS_PIN::getKuKdNoWaveform( KIBIS_MODEL& aModel, const KIBIS_PARAMETER& a
t.push_back( 0 );
}
m_Ku = ku;
m_Kd = kd;
m_t = t;
m_Ku = std::move( ku );
m_Kd = std::move( kd );
m_t = std::move( t );
}
@ -1003,9 +1003,9 @@ void KIBIS_PIN::getKuKdTwoWaveforms( KIBIS_MODEL&
ku.push_back( 0 );
kd.push_back( 0 );
t.push_back( 0 );
m_Ku = ku;
m_Kd = kd;
m_t = t;
m_Ku = std::move( ku );
m_Kd = std::move( kd );
m_t = std::move( t );
}
else
{

View File

@ -1999,7 +1999,7 @@ bool SHAPE_POLY_SET::Parse( std::stringstream& aStream )
paths.push_back( std::move( outline ) );
}
m_polys.push_back( paths );
m_polys.push_back( std::move( paths ) );
}
return true;

View File

@ -257,7 +257,7 @@ bool WALKAROUND::singleStep()
if ( anyColliding )
{
shortest = shortest_alt;
shortest = std::move( shortest_alt );
}
if( !shortest )