Skip to content

Commit ba1e94e

Browse files
Joachim Schielekris-jusiak
authored andcommitted
Request to set CXX-14 instead of CXX-17 as a minimum required version
1 parent 423eb6f commit ba1e94e

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@ option(ENABLE_COVERAGE "Run coverage." OFF)
1414
add_custom_target(style)
1515
add_custom_command(TARGET style COMMAND find ${CMAKE_CURRENT_LIST_DIR}/benchmark ${CMAKE_CURRENT_LIST_DIR}/example ${CMAKE_CURRENT_LIST_DIR}/include ${CMAKE_CURRENT_LIST_DIR}/test -iname "*.h" -or -iname "*.cpp" | xargs clang-format -i)
1616

17-
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++1z")
17+
set(CMAKE_CXX_STANDARD 14)
18+
1819
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall")
1920
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wextra")
2021
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror")

include/GUnit/GAssert.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
#include <gtest/gtest.h>
1111

1212
#include <string>
13-
1413
#include "GUnit/Detail/StringUtils.h"
1514

1615
namespace testing {
@@ -34,7 +33,7 @@ class msg : public decltype(Message()) {
3433
const auto begin = info_.expr.find(comp_);
3534
auto lhs_expr = info_.expr.substr(0, begin);
3635
trim(lhs_expr);
37-
auto rhs_expr = info_.expr.substr(begin + std::size(comp_));
36+
auto rhs_expr = info_.expr.substr(begin + comp_.size());
3837
trim(rhs_expr);
3938
const AssertionResult gtest_ar =
4039
(Comp(lhs_expr.c_str(), rhs_expr.c_str(), lhs_, rhs_));

0 commit comments

Comments
 (0)