mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-07 03:50:11 +02:00
Remove redundant conditions
As mentioned in C++ Core Guidelines ES.87.
This commit is contained in:
@@ -258,7 +258,7 @@ LRESULT CALLBACK window_proc(HWND handle,
|
||||
reinterpret_cast<CREATESTRUCT*>(lParam);
|
||||
const auto editor =
|
||||
static_cast<Editor*>(window_parameters->lpCreateParams);
|
||||
if (editor == nullptr) {
|
||||
if (!editor) {
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -272,7 +272,7 @@ LRESULT CALLBACK window_proc(HWND handle,
|
||||
case WM_TIMER: {
|
||||
auto editor = reinterpret_cast<Editor*>(
|
||||
GetWindowLongPtr(handle, GWLP_USERDATA));
|
||||
if (editor == nullptr || wParam != idle_timer_id) {
|
||||
if (!editor || wParam != idle_timer_id) {
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user