mirror of
https://github.com/RetroDECK/Duckstation.git
synced 2024-11-22 13:55:38 +00:00
Misc: Warning fixes
This commit is contained in:
parent
b29b703e6f
commit
9de8bf9da5
|
@ -892,7 +892,7 @@ public:
|
||||||
|
|
||||||
ALWAYS_INLINE bool rempty() const { return lt32(zwzw()).mask() != 0x00ff; }
|
ALWAYS_INLINE bool rempty() const { return lt32(zwzw()).mask() != 0x00ff; }
|
||||||
|
|
||||||
ALWAYS_INLINE GSVector4i runion(const GSVector4i& v) const { return min_i32(v).upl64(max_i32(v).srl<8>()); }
|
ALWAYS_INLINE GSVector4i runion(const GSVector4i& v) const { return min_i32(v).blend32<0xc>(max_i32(v)); }
|
||||||
|
|
||||||
ALWAYS_INLINE GSVector4i rintersect(const GSVector4i& v) const { return sat_i32(v); }
|
ALWAYS_INLINE GSVector4i rintersect(const GSVector4i& v) const { return sat_i32(v); }
|
||||||
ALWAYS_INLINE bool rintersects(const GSVector4i& v) const { return !rintersect(v).rempty(); }
|
ALWAYS_INLINE bool rintersects(const GSVector4i& v) const { return !rintersect(v).rempty(); }
|
||||||
|
@ -1371,7 +1371,8 @@ public:
|
||||||
|
|
||||||
ALWAYS_INLINE static GSVector4i loadnt(const void* p)
|
ALWAYS_INLINE static GSVector4i loadnt(const void* p)
|
||||||
{
|
{
|
||||||
return GSVector4i(_mm_stream_load_si128(static_cast<const __m128i*>(p)));
|
// Should be const, but isn't...
|
||||||
|
return GSVector4i(_mm_stream_load_si128(const_cast<__m128i*>(static_cast<const __m128i*>(p))));
|
||||||
}
|
}
|
||||||
|
|
||||||
ALWAYS_INLINE static GSVector4i load32(const void* p) { return GSVector4i(_mm_loadu_si32(p)); }
|
ALWAYS_INLINE static GSVector4i load32(const void* p) { return GSVector4i(_mm_loadu_si32(p)); }
|
||||||
|
|
|
@ -594,7 +594,7 @@ void DebuggerWindow::setMemoryViewRegion(Bus::MemoryRegion region)
|
||||||
void* const mem_ptr = Bus::GetMemoryRegionPointer(region);
|
void* const mem_ptr = Bus::GetMemoryRegionPointer(region);
|
||||||
const bool mem_writable = Bus::IsMemoryRegionWritable(region);
|
const bool mem_writable = Bus::IsMemoryRegionWritable(region);
|
||||||
const MemoryViewWidget::EditCallback edit_callback =
|
const MemoryViewWidget::EditCallback edit_callback =
|
||||||
((region == Bus::MemoryRegion::RAM) ? edit_ram_callback : nullptr);
|
((region == Bus::MemoryRegion::RAM) ? static_cast<MemoryViewWidget::EditCallback>(edit_ram_callback) : nullptr);
|
||||||
m_ui.memoryView->setData(start, mem_ptr, end - start, mem_writable, edit_callback);
|
m_ui.memoryView->setData(start, mem_ptr, end - start, mem_writable, edit_callback);
|
||||||
|
|
||||||
#define SET_REGION_RADIO_BUTTON(name, rb_region) \
|
#define SET_REGION_RADIO_BUTTON(name, rb_region) \
|
||||||
|
|
|
@ -917,6 +917,8 @@ void ImGuiFullscreen::BeginMenuButtons(u32 num_items, float y_align, float x_pad
|
||||||
case ImGuiDir_Down:
|
case ImGuiDir_Down:
|
||||||
ImGui::SetScrollY(std::min(ImGui::GetScrollY() + item_height, ImGui::GetScrollMaxY()));
|
ImGui::SetScrollY(std::min(ImGui::GetScrollY() + item_height, ImGui::GetScrollMaxY()));
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -73,12 +73,16 @@ class Error;
|
||||||
#include "vulkan_entry_points.h"
|
#include "vulkan_entry_points.h"
|
||||||
|
|
||||||
// We include vk_mem_alloc globally, so we don't accidentally include it before the vulkan header somewhere.
|
// We include vk_mem_alloc globally, so we don't accidentally include it before the vulkan header somewhere.
|
||||||
#ifdef __clang__
|
#if defined(__clang__)
|
||||||
#pragma clang diagnostic push
|
#pragma clang diagnostic push
|
||||||
#pragma clang diagnostic ignored "-Wnullability-completeness"
|
#pragma clang diagnostic ignored "-Wnullability-completeness"
|
||||||
#pragma clang diagnostic ignored "-Wunused-variable"
|
#pragma clang diagnostic ignored "-Wunused-variable"
|
||||||
#pragma clang diagnostic ignored "-Wmissing-field-initializers"
|
#pragma clang diagnostic ignored "-Wmissing-field-initializers"
|
||||||
#pragma clang diagnostic ignored "-Wunused-function"
|
#pragma clang diagnostic ignored "-Wunused-function"
|
||||||
|
#elif defined(__GNUC__)
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#pragma GCC diagnostic ignored "-Wunused-variable"
|
||||||
|
#pragma GCC diagnostic ignored "-Wunused-function"
|
||||||
#elif defined(_MSC_VER)
|
#elif defined(_MSC_VER)
|
||||||
#pragma warning(push, 0)
|
#pragma warning(push, 0)
|
||||||
#endif
|
#endif
|
||||||
|
@ -88,8 +92,10 @@ class Error;
|
||||||
#define VMA_STATS_STRING_ENABLED 0
|
#define VMA_STATS_STRING_ENABLED 0
|
||||||
#include "vulkan/vk_mem_alloc.h"
|
#include "vulkan/vk_mem_alloc.h"
|
||||||
|
|
||||||
#ifdef __clang__
|
#if defined(__clang__)
|
||||||
#pragma clang diagnostic pop
|
#pragma clang diagnostic pop
|
||||||
|
#elif defined(__GNUC__)
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
#elif defined(_MSC_VER)
|
#elif defined(_MSC_VER)
|
||||||
#pragma warning(pop)
|
#pragma warning(pop)
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue