You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to create a stout::Borrowable as a member variable in a class (in my case, for a test fixture class, but that part isn't super important), where my T needs to be initialized in the body of the class constructor (i.e. not in the initializer list).
Unfortunately, because stout::Borrowable does not have operator=, I don't see a way for me to set the variable's value in the constructor body, even though it hasn't been initialized to anything else yet.
Other types of smart pointer allow assignment, and it's confusing to me that this type doesn't.
The text was updated successfully, but these errors were encountered:
stephaniepalocz
changed the title
Be able to assign a stout::Borrowed<> object
Be able to assign a stout::Borrowable<> object
Jun 27, 2022
I would like to create a stout::Borrowable as a member variable in a class (in my case, for a test fixture class, but that part isn't super important), where my T needs to be initialized in the body of the class constructor (i.e. not in the initializer list).
Unfortunately, because stout::Borrowable does not have operator=, I don't see a way for me to set the variable's value in the constructor body, even though it hasn't been initialized to anything else yet.
Other types of smart pointer allow assignment, and it's confusing to me that this type doesn't.
The text was updated successfully, but these errors were encountered: