diff options
author | Dino Radakovic <dinor@google.com> | 2024-05-07 19:09:38 -0700 |
---|---|---|
committer | Copybara-Service <copybara-worker@google.com> | 2024-05-07 19:10:24 -0700 |
commit | e444af7ccc82549c97ebbc17e8af435ccacdc4e2 (patch) | |
tree | a5b5e517d8684af447ee950afeac42dd70e1df57 /absl/functional/internal/any_invocable.h | |
parent | 289d8626b6ff1e2a7bd582b43c918345108f5fda (diff) |
`any_invocable`: Add public documentation for undefined behavior when invoking an empty AnyInvocable
This is currently documented in `internal/any_invocable.h`, but not in the public API.
For example, `std::function` [documents](https://en.cppreference.com/w/cpp/utility/functional/function) the fact that invoking an empty instance throws `std::bad_function_call`.
PiperOrigin-RevId: 631621604
Change-Id: I6b886a805ffa0e7aaef5f6971e1eafd14f94050c
Diffstat (limited to 'absl/functional/internal/any_invocable.h')
-rw-r--r-- | absl/functional/internal/any_invocable.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/absl/functional/internal/any_invocable.h b/absl/functional/internal/any_invocable.h index 5bb7d48a..ce58fd8c 100644 --- a/absl/functional/internal/any_invocable.h +++ b/absl/functional/internal/any_invocable.h @@ -39,7 +39,7 @@ // target object, directly returning the result. // // // // When in the logically empty state, the manager function is an empty // -// function and the invoker function is one that would be undefined-behavior // +// function and the invoker function is one that would be undefined behavior // // to call. // // // // An additional optimization is performed when converting from one // |