-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Let constructing
AnyRef<Handle>
from `Any<Handle, inline_size, inli…
…ne_align>` adopt the state if possible instead of forming a reference. This is done by extending `any_internal::IsAny` to accept also rvalue references to `Any` and `AnyRef`, so that private `Initialize()` functions recognize also such rvalue references as types to consider adopting the state from. This required adapting these functions, as well as `AnyInitializer::ConstructMethod()` which also uses `any_internal::IsAny`, to apply `std::remove_reference_t` for accessing static members of the `Any` or `AnyRef`, because rvalue references are not transparent in this case. PiperOrigin-RevId: 713281200
- Loading branch information
Showing
3 changed files
with
23 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters