Add array hint to wxArrayString contructors

This may be required for some compilers to prevent premature casting to
a single element.
This commit is contained in:
Seth Hillbrand 2018-12-04 08:00:43 -07:00
parent 2ec957a226
commit 8757fcf676
2 changed files with 4 additions and 2 deletions

View File

@ -145,7 +145,8 @@ public:
const wxArrayString GetFileExtensions() const override
{
return wxArrayString( 1, { "dxf" } );
// N.B. The extra "" hints for some compilers that the array should not be optimized out
return wxArrayString( 1, { "dxf", "" } );
}
bool Load( const wxString& aFileName ) override;

View File

@ -44,7 +44,8 @@ public:
const wxArrayString GetFileExtensions() const override
{
return wxArrayString( 1, { "svg" } );
// N.B. The extra "" hints for some compilers that the array should not be optimized out
return wxArrayString( 1, { "svg", "" } );
}
/**