mirror of
https://github.com/genodelabs/genode.git
synced 2025-06-17 14:48:20 +00:00
os: forward args for Lazy_volatile_object
This patch makes the handling of constructor arguments consistent among the Volatile_object and Lazy_volatile_object classes. Arguments are always forwarded. Otherwise, passing a reference as argument would result in an unwanted copy of the passed object.
This commit is contained in:
@ -146,7 +146,7 @@ template <typename MT>
|
|||||||
struct Genode::Lazy_volatile_object : Volatile_object<MT>
|
struct Genode::Lazy_volatile_object : Volatile_object<MT>
|
||||||
{
|
{
|
||||||
template <typename... ARGS>
|
template <typename... ARGS>
|
||||||
Lazy_volatile_object(ARGS... args)
|
Lazy_volatile_object(ARGS &&... args)
|
||||||
:
|
:
|
||||||
Volatile_object<MT>((typename Volatile_object<MT>::Lazy *)0)
|
Volatile_object<MT>((typename Volatile_object<MT>::Lazy *)0)
|
||||||
{ }
|
{ }
|
||||||
|
Reference in New Issue
Block a user