From b5e1e879229ca37332a73186924738b77181f666 Mon Sep 17 00:00:00 2001
From: Lioncash <mathew1800@gmail.com>
Date: Wed, 5 Jun 2019 15:43:55 -0400
Subject: [PATCH] yuzu/CMakeLists: Disable implicit type narrowing in connect()
 calls

Prevents hard-to-diagnose bugs from potentially occurring and requires
any type narrowing to be explicitly performed by our code.
---
 src/yuzu/CMakeLists.txt | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/yuzu/CMakeLists.txt b/src/yuzu/CMakeLists.txt
index 3ea7b55d0d..ec969a9a74 100644
--- a/src/yuzu/CMakeLists.txt
+++ b/src/yuzu/CMakeLists.txt
@@ -159,6 +159,9 @@ target_compile_definitions(yuzu PRIVATE
     # Disable implicit conversions from/to C strings
     -DQT_NO_CAST_FROM_ASCII
     -DQT_NO_CAST_TO_ASCII
+
+    # Disable implicit type narrowing in signal/slot connect() calls.
+    -DQT_NO_NARROWING_CONVERSIONS_IN_CONNECT
 )
 
 if (YUZU_ENABLE_COMPATIBILITY_REPORTING)