Commit 5f49ee87 authored by Yedidya Feldblum's avatar Yedidya Feldblum Committed by facebook-github-bot-4

Avoid requiring a suppression (unevaluated-expression)

Summary: [Folly] Avoid requiring a suppression (`unevaluated-expression`).

I am not a fan of suppressing warnings. This warning comes from the internals of gtest, but anyway.

Replace with something that does not trigger the warning.

Reviewed By: Gownta

Differential Revision: D2706279

fb-gh-sync-id: 2ecac1d230308a8fd21a69565193c52585526448
parent 4e5cb0ef
......@@ -177,14 +177,7 @@ TEST(ExceptionWrapper, with_exception_test) {
EXPECT_EQ(ew2.class_name(), "IntException");
ew2.with_exception([&](AbstractIntException& ie) {
EXPECT_EQ(ie.getInt(), expected);
#if __CLANG_PREREQ(3, 6)
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Wunevaluated-expression"
#endif
EXPECT_EQ(typeid(ie), typeid(IntException));
#if __CLANG_PREREQ(3, 6)
# pragma clang diagnostic pop
#endif
EXPECT_TRUE(dynamic_cast<IntException*>(&ie));
});
// Test with const this. If this compiles and does not crash due to
......
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