Преглед изворни кода

k_affinity_mask: Avoid implicit truncation to bool

This can cause compiler warnings. Instead, we can explicitly add a
boolean expression around it to naturally turn the result into a bool.
Lioncash пре 5 година
родитељ
комит
756365386a
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      src/core/hle/kernel/k_affinity_mask.h

+ 1 - 1
src/core/hle/kernel/k_affinity_mask.h

@@ -27,7 +27,7 @@ public:
     }
 
     [[nodiscard]] constexpr bool GetAffinity(s32 core) const {
-        return this->mask & GetCoreBit(core);
+        return (this->mask & GetCoreBit(core)) != 0;
     }
 
     constexpr void SetAffinity(s32 core, bool set) {