summaryrefslogtreecommitdiff
path: root/absl/functional/BUILD.bazel
diff options
context:
space:
mode:
authorGravatar Dino Radakovic <dinor@google.com>2022-06-16 16:42:34 -0700
committerGravatar Copybara-Service <copybara-worker@google.com>2022-06-16 16:43:07 -0700
commitb7ceff06d2358d09ba967c00f526b6143f207d56 (patch)
treec8350bffed0225834428b7b889b4b905ce350955 /absl/functional/BUILD.bazel
parent53a90f079af7ab491530d432bb318a95371ba877 (diff)
Release absl::AnyInvocable
AnyInvocable is a C++11 compatible equivalent of the C++23 [std::move_only_function](https://en.cppreference.com/w/cpp/utility/functional/move_only_function/move_only_function). Although this implementation matches an intermediate draft revision of the standard (http://wg21.link/p0288r5), it is neither a standard tracking type nor a seamless backfill type. PiperOrigin-RevId: 455494585 Change-Id: If01565f8eecc78eee38fb794ef142b32b31abc7c
Diffstat (limited to 'absl/functional/BUILD.bazel')
-rw-r--r--absl/functional/BUILD.bazel35
1 files changed, 35 insertions, 0 deletions
diff --git a/absl/functional/BUILD.bazel b/absl/functional/BUILD.bazel
index dbfa81f3..c4fbce98 100644
--- a/absl/functional/BUILD.bazel
+++ b/absl/functional/BUILD.bazel
@@ -26,6 +26,40 @@ package(default_visibility = ["//visibility:public"])
licenses(["notice"])
cc_library(
+ name = "any_invocable",
+ srcs = ["internal/any_invocable.h"],
+ hdrs = ["any_invocable.h"],
+ copts = ABSL_DEFAULT_COPTS,
+ linkopts = ABSL_DEFAULT_LINKOPTS,
+ deps = [
+ "//absl/base:base_internal",
+ "//absl/base:config",
+ "//absl/base:core_headers",
+ "//absl/meta:type_traits",
+ "//absl/utility",
+ ],
+)
+
+cc_test(
+ name = "any_invocable_test",
+ srcs = [
+ "any_invocable_test.cc",
+ "internal/any_invocable.h",
+ ],
+ copts = ABSL_TEST_COPTS,
+ linkopts = ABSL_DEFAULT_LINKOPTS,
+ deps = [
+ ":any_invocable",
+ "//absl/base:base_internal",
+ "//absl/base:config",
+ "//absl/base:core_headers",
+ "//absl/meta:type_traits",
+ "//absl/utility",
+ "@com_google_googletest//:gtest_main",
+ ],
+)
+
+cc_library(
name = "bind_front",
srcs = ["internal/front_binder.h"],
hdrs = ["bind_front.h"],
@@ -86,6 +120,7 @@ cc_test(
tags = ["benchmark"],
visibility = ["//visibility:private"],
deps = [
+ ":any_invocable",
":function_ref",
"//absl/base:core_headers",
"@com_github_google_benchmark//:benchmark_main",