C++: Add #pragma to disable MSVC C4369 enum range warnings

This commit is contained in:
Katy Coe
2020-07-25 16:55:40 +02:00
parent cf6b64e0d2
commit 59f5083235

View File

@@ -40,6 +40,10 @@ namespace Il2CppInspector.Outputs
writeSectionHeader("IL2CPP internal types");
writeCode(model.UnityHeaders.GetTypeHeaderText(model.WordSize));
// Stop MSVC complaining about out-of-bounds enum values
if (model.TargetCompiler == CppCompilerType.MSVC)
writeCode("#pragma warning(disable : 4369)");
writeCode("namespace app {");
writeLine("");