mirror of
https://github.com/wxWidgets/wxWidgets.git
synced 2026-09-22 06:05:36 +08:00
Avoid -Wunused-result in the except sample
MinGW gcc 12 started giving this (useful) warning in STL build because its std::vector::operator[] is declared with nodiscard attribute, but we really don't want to use the result here, so suppress it.
This commit is contained in:
@@ -564,7 +564,7 @@ void MyFrame::OnShowAssert(wxCommandEvent& WXUNUSED(event))
|
||||
{
|
||||
// provoke an assert from wxArrayString
|
||||
wxArrayString arr;
|
||||
arr[0];
|
||||
wxUnusedVar(arr[0]);
|
||||
}
|
||||
|
||||
#if wxUSE_THREADS
|
||||
|
||||
Reference in New Issue
Block a user