Skip to content

Commit

Permalink
Bump c++ standard to c++14 per default
Browse files Browse the repository at this point in the history
Fixes: #18181.

Closes: #18280.
  • Loading branch information
davido committed May 2, 2023
1 parent fa47ba9 commit 94ed186
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion tools/cpp/bsd_cc_toolchain_config.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ def _impl(ctx):
),
flag_set(
actions = all_cpp_compile_actions + [ACTION_NAMES.lto_backend],
flag_groups = [flag_group(flags = ["-std=c++0x"])],
flag_groups = [flag_group(flags = ["-std=c++14"])],
),
],
)
Expand Down
4 changes: 2 additions & 2 deletions tools/cpp/unix_cc_configure.bzl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# pylint: disable=g-bad-file-header
# Copyright 2016 The Bazel Authors. All rights reserved.
#

# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
Expand Down Expand Up @@ -416,7 +416,7 @@ def configure_unix_toolchain(repository_ctx, cpu_value, overriden_tools):
cxx_opts = split_escaped(get_env_var(
repository_ctx,
"BAZEL_CXXOPTS",
"-std=c++0x",
"-std=c++14",
False,
), ":")

Expand Down
2 changes: 1 addition & 1 deletion tools/cpp/windows_cc_toolchain_config.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -1184,7 +1184,7 @@ def _impl(ctx):
ACTION_NAMES.lto_backend,
ACTION_NAMES.clif_match,
],
flag_groups = [flag_group(flags = ["-std=gnu++0x"])],
flag_groups = [flag_group(flags = ["-std=gnu++14"])],
),
],
)
Expand Down

0 comments on commit 94ed186

Please sign in to comment.