I have three modules, a game module and a plugin with an editor module and a runtime module. The runtime module uses a fairly large external library which, upon including its main header file, generates a number of performance warnings. It is thus not quite easy to simply manually fix these errors, and I wouldn’t recommend attempting it either.
However, all of these are denoted as error C4800 with the message “forcing value to bool ‘true’ or ‘false’ (performance warning)”. If it is merely a performance warning, why does it then - being officially accounted for as an error - prevent successfully building the module? Is there a way to turn these pseudo-warnings off?
Do you have any plausible reasoning for this? Have you yet attempted to fix such rather trivial compiler complaints in a large, multiple hundred files large project that is not yours? It takes time and you can never be quite sure you’ve actually corrected it all. Besides, I’ve personally compiled the libraries ahead of time with VS2015 and it built without any errors. I’d think the performance impact of such a trivial implicit conversion would be minimal, but I’d have to run actual performance tests on that.
I have found an alternative solution on stackoverflow - see Arve’s answer. In a nutshell, instead of suppressing the warnings in the property pages of your project you can temporarily disable them by calling
Unless there’s some weird quirk of Unreal Engine that requires it, I think performance warnings should not be considered build errors. I don’t see how it’s a performance warning anyways, bools are not stored in memory any differently than ints are. It’s really frustrating when you work at a company designing software for Unreal, and the code that compiles fine on everyone else’s machines breaks in the Unreal Build Tool.