You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@impala.apache.org by "Joe McDonnell (Jira)" <ji...@apache.org> on 2020/05/19 04:54:00 UTC

[jira] [Created] (IMPALA-9761) Fix GCC 7 compilation issue: Ambiguous else warning with gtest macros

Joe McDonnell created IMPALA-9761:
-------------------------------------

             Summary: Fix GCC 7 compilation issue: Ambiguous else warning with gtest macros
                 Key: IMPALA-9761
                 URL: https://issues.apache.org/jira/browse/IMPALA-9761
             Project: IMPALA
          Issue Type: Bug
          Components: Backend
    Affects Versions: Impala 4.0
            Reporter: Joe McDonnell


Google test uses a macro to avoid a GCC warning about dangling else conditions. It suppresses a warning for code like:
{code:java}
if (foo) DCHECK(condition);{code}
[https://github.com/google/googletest/issues/1119]

GCC 7 added new warnings and this macro no longer works. The solution is to either disable the new warning or use braces. Since using braces is easy, we should fix this by adding appropriate braces.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)