Add getter for section category name.

This commit is contained in:
Bartosz Taudul
2026-07-14 16:53:25 +02:00
parent ece976e820
commit 42fc8d8d8f
2 changed files with 12 additions and 0 deletions

View File

@@ -9195,4 +9195,15 @@ bool Worker::IsSourceExternalBody( StringIdx filename, uint32_t key, unordered_f
return res;
}
const char* Worker::GetSectionCategoryDescription( uint16_t category ) const
{
auto it = m_data.sectionsDescription.find( category );
assert( it != m_data.sectionsDescription.end() );
if( it->second.Active() ) return GetString( it->second );
static char buf[64];
sprintf( buf, "Category %" PRIu16, category );
return buf;
}
}