cmake: Remove -Wcomma for C++ when using Qt >= 5.10
The Qt team introduced a lot of "Possible misuse of comma operator here" warnings in qstring.h and qstringview.h in version 5.10. Now we need to fix the Qt source again. Change-Id: I948ba5a224d4dca1ebb6a758100c064d501c1d4a Reviewed-on: https://code.wireshark.org/review/24779 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
This commit is contained in:
parent
621498f88e
commit
91f63908df
|
@ -464,7 +464,6 @@ else()
|
|||
-Wno-overlength-strings
|
||||
-Wno-long-long
|
||||
-Wheader-guard
|
||||
-Wcomma
|
||||
)
|
||||
|
||||
#
|
||||
|
@ -517,6 +516,11 @@ else()
|
|||
# -Wimplicit-function-declaration into an error by default.
|
||||
#
|
||||
-Werror=implicit
|
||||
#
|
||||
# The Qt headers in version 5.10 introduced a lot of
|
||||
# "Possible misuse of comma operator here" warnings.
|
||||
#
|
||||
-Wcomma
|
||||
)
|
||||
|
||||
set(CXX_WARN_FLAGS
|
||||
|
@ -530,6 +534,13 @@ else()
|
|||
-Wshorten-64-to-32
|
||||
)
|
||||
endif()
|
||||
if (Qt5Core_VERSION VERSION_LESS 5.10)
|
||||
# The Qt headers in version 5.10 introduced a lot of
|
||||
# "Possible misuse of comma operator here" warnings.
|
||||
set(CXX_WARN_FLAGS ${CXX_WARN_FLAGS}
|
||||
-Wcomma
|
||||
)
|
||||
endif()
|
||||
|
||||
#
|
||||
# These are not enabled by default, because the warnings they
|
||||
|
|
Loading…
Reference in New Issue