diff options
Diffstat (limited to 'src/shader_recompiler')
3 files changed, 2 insertions, 20 deletions
diff --git a/src/shader_recompiler/CMakeLists.txt b/src/shader_recompiler/CMakeLists.txt index af8e51fe8..bcdd60db9 100644 --- a/src/shader_recompiler/CMakeLists.txt +++ b/src/shader_recompiler/CMakeLists.txt | |||
| @@ -241,24 +241,14 @@ target_link_libraries(shader_recompiler PUBLIC common fmt::fmt sirit) | |||
| 241 | if (MSVC) | 241 | if (MSVC) |
| 242 | target_compile_options(shader_recompiler PRIVATE | 242 | target_compile_options(shader_recompiler PRIVATE |
| 243 | /W4 | 243 | /W4 |
| 244 | /WX | 244 | |
| 245 | /we4018 # 'expression' : signed/unsigned mismatch | 245 | /we4242 # 'identifier': conversion from 'type1' to 'type2', possible loss of data |
| 246 | /we4244 # 'argument' : conversion from 'type1' to 'type2', possible loss of data (floating-point) | ||
| 247 | /we4245 # 'conversion' : conversion from 'type1' to 'type2', signed/unsigned mismatch | ||
| 248 | /we4254 # 'operator': conversion from 'type1:field_bits' to 'type2:field_bits', possible loss of data | 246 | /we4254 # 'operator': conversion from 'type1:field_bits' to 'type2:field_bits', possible loss of data |
| 249 | /we4267 # 'var' : conversion from 'size_t' to 'type', possible loss of data | ||
| 250 | /we4305 # 'context' : truncation from 'type1' to 'type2' | ||
| 251 | /we4800 # Implicit conversion from 'type' to bool. Possible information loss | 247 | /we4800 # Implicit conversion from 'type' to bool. Possible information loss |
| 252 | /we4826 # Conversion from 'type1' to 'type2' is sign-extended. This may cause unexpected runtime behavior. | ||
| 253 | ) | 248 | ) |
| 254 | else() | 249 | else() |
| 255 | target_compile_options(shader_recompiler PRIVATE | 250 | target_compile_options(shader_recompiler PRIVATE |
| 256 | -Werror | ||
| 257 | -Werror=conversion | 251 | -Werror=conversion |
| 258 | -Werror=ignored-qualifiers | ||
| 259 | $<$<CXX_COMPILER_ID:GNU>:-Werror=unused-but-set-parameter> | ||
| 260 | $<$<CXX_COMPILER_ID:GNU>:-Werror=unused-but-set-variable> | ||
| 261 | -Werror=unused-variable | ||
| 262 | 252 | ||
| 263 | # Bracket depth determines maximum size of a fold expression in Clang since 9c9974c3ccb6. | 253 | # Bracket depth determines maximum size of a fold expression in Clang since 9c9974c3ccb6. |
| 264 | # And this in turns limits the size of a std::array. | 254 | # And this in turns limits the size of a std::array. |
diff --git a/src/shader_recompiler/backend/glasm/emit_glasm_not_implemented.cpp b/src/shader_recompiler/backend/glasm/emit_glasm_not_implemented.cpp index 7094d8e42..1f4ffdd62 100644 --- a/src/shader_recompiler/backend/glasm/emit_glasm_not_implemented.cpp +++ b/src/shader_recompiler/backend/glasm/emit_glasm_not_implemented.cpp | |||
| @@ -5,10 +5,6 @@ | |||
| 5 | #include "shader_recompiler/backend/glasm/glasm_emit_context.h" | 5 | #include "shader_recompiler/backend/glasm/glasm_emit_context.h" |
| 6 | #include "shader_recompiler/frontend/ir/value.h" | 6 | #include "shader_recompiler/frontend/ir/value.h" |
| 7 | 7 | ||
| 8 | #ifdef _MSC_VER | ||
| 9 | #pragma warning(disable : 4100) | ||
| 10 | #endif | ||
| 11 | |||
| 12 | namespace Shader::Backend::GLASM { | 8 | namespace Shader::Backend::GLASM { |
| 13 | 9 | ||
| 14 | #define NotImplemented() throw NotImplementedException("GLASM instruction {}", __LINE__) | 10 | #define NotImplemented() throw NotImplementedException("GLASM instruction {}", __LINE__) |
diff --git a/src/shader_recompiler/backend/glsl/emit_glsl_not_implemented.cpp b/src/shader_recompiler/backend/glsl/emit_glsl_not_implemented.cpp index b03a8ba1e..9f1ed95a4 100644 --- a/src/shader_recompiler/backend/glsl/emit_glsl_not_implemented.cpp +++ b/src/shader_recompiler/backend/glsl/emit_glsl_not_implemented.cpp | |||
| @@ -7,10 +7,6 @@ | |||
| 7 | #include "shader_recompiler/backend/glsl/glsl_emit_context.h" | 7 | #include "shader_recompiler/backend/glsl/glsl_emit_context.h" |
| 8 | #include "shader_recompiler/frontend/ir/value.h" | 8 | #include "shader_recompiler/frontend/ir/value.h" |
| 9 | 9 | ||
| 10 | #ifdef _MSC_VER | ||
| 11 | #pragma warning(disable : 4100) | ||
| 12 | #endif | ||
| 13 | |||
| 14 | namespace Shader::Backend::GLSL { | 10 | namespace Shader::Backend::GLSL { |
| 15 | 11 | ||
| 16 | void EmitGetRegister(EmitContext& ctx) { | 12 | void EmitGetRegister(EmitContext& ctx) { |