Remove `AZStd::to_string(string&, bool)` overload from MCore's StringConversion header
This overload has significant impact on overload resolution. Consider these overloads: ```cpp void to_string(AZStd::string& dest, AZStd::wstring_view src); void to_string(string& str, bool value); ``` And then calling code like this: ``` WCHAR src[260]; AZStd::string dst; AZStd::to_string(dst, src); // Which overload does this call? ``` If the .cpp has not included `MCore/Source/StringConversions.h`, the call to `to_string()` will convert the `WCHAR[260]` type to a `AZStd::wstring_view`, and call the first overload. But if `StringConversions.h` _has_ been included, the implicit conversion of `WCHAR[260]` to `bool` has a higher precedence, and it will be chosen instead. This overload was causing some uses of `to_string` in `AnimGraph/GameController.cpp` to resolve to the wrong overload in unity builds. Signed-off-by: Chris Burel <burelc@amazon.com>monroegm-disable-blank-issue-2
parent
d4eb310950
commit
3d0a15f009
Loading…
Reference in New Issue