Commit 9db297bf authored by Michael Lee's avatar Michael Lee Committed by Facebook Github Bot

Fix maybe-uninitialized warning in Conv.h

Summary: Some compilers think result may be uninitialized

Reviewed By: francis-ma

Differential Revision: D4074526

fbshipit-source-id: 5df4568cfa5eb8f3b2993a82b831fd5e4028a281
parent c1ead85d
...@@ -1490,7 +1490,7 @@ Expected<Tgt, detail::ParseToError<Tgt>> tryTo(StringPiece* src) { ...@@ -1490,7 +1490,7 @@ Expected<Tgt, detail::ParseToError<Tgt>> tryTo(StringPiece* src) {
template <class Tgt> template <class Tgt>
Tgt to(StringPiece* src) { Tgt to(StringPiece* src) {
Tgt result; Tgt result{};
using Error = detail::ParseToError<Tgt>; using Error = detail::ParseToError<Tgt>;
return parseTo(*src, result) return parseTo(*src, result)
.thenOrThrow( .thenOrThrow(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment