Warnings as errors

I noticed that we cannot set the compiler options to treat warnings as errors (on Windows) while compiling the engine or the game DLL. What is the reason behind this?

Thanks,

Hi,

Yes, option ‘treat warnings as errors’ is disabled. “Clang on Windows does not respect “#pragma warning (error: ####)”, and we are not passing “/WX”, so warnings are not treated as errors when compiling on Windows using Clang right now." (c)

UE4 complies with Unreal Build Tool (UBT). You should look for compiler options in VCToolChain.cs
Try to add this in line 58

Arguments.Append(" /WX");

Hope it helps!

Thanks , will add this.

Thanks ,

Will add this.