Commit e988905d authored by Joe Loser's avatar Joe Loser Committed by Facebook Github Bot

Remove -Wuninitialized for GCC in Expected.h (#1143)

Summary:
- Old versions of GCC (specifically, GCC 4.7) warn about uninitialized memory
  in `Expected.h`
- Newer versions of GCC do not complain, so remove the pragma push/pop which
  was disabling the warning.
Pull Request resolved: https://github.com/facebook/folly/pull/1143

Reviewed By: ericniebler

Differential Revision: D15586279

Pulled By: yfeldblum

fbshipit-source-id: 7b01934c7601ecf035f1e05f2ed3e5f799cf25b9
parent 18d4b8e1
...@@ -52,17 +52,6 @@ ...@@ -52,17 +52,6 @@
#define FOLLY_REQUIRES(...) template <FOLLY_REQUIRES_IMPL(__VA_ARGS__)> #define FOLLY_REQUIRES(...) template <FOLLY_REQUIRES_IMPL(__VA_ARGS__)>
/**
* gcc-4.7 warns about use of uninitialized memory around the use of storage_
* even though this is explicitly initialized at each point.
*/
#if defined(__GNUC__) && !defined(__clang__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wuninitialized"
#pragma GCC diagnostic ignored "-Wpragmas"
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#endif // __GNUC__
namespace folly { namespace folly {
/** /**
...@@ -1406,10 +1395,6 @@ bool operator>(const Value& other, const Expected<Value, Error>&) = delete; ...@@ -1406,10 +1395,6 @@ bool operator>(const Value& other, const Expected<Value, Error>&) = delete;
} // namespace folly } // namespace folly
#if defined(__GNUC__) && !defined(__clang__)
#pragma GCC diagnostic pop
#endif
#undef FOLLY_REQUIRES #undef FOLLY_REQUIRES
#undef FOLLY_REQUIRES_TRAILING #undef FOLLY_REQUIRES_TRAILING
......
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