Questions tagged [optional]

Optional is an immutable type that may contain a value or reference.

Filter by
Sorted by
Tagged with
5 votes
1 answer
244 views

deep_ptr<T>; a header-only, deep copying, value semantic smart pointer for optionally defined types

Edit: final revision here A couple days ago I posted a similar question here. Since then, I have refined the implementation a bit further, as the solution I had previously posited was a bit off ...
Tom's user avatar
  • 417
6 votes
1 answer
209 views

Nullable<T>; header-only value semantics for forward declared types

Edit: I have refined the concept a bit further, and my new implementation can be found here Motivation: I found myself with class members of forward declared types in a header, such as: ...
Tom's user avatar
  • 417
2 votes
1 answer
4k views

`std::optional` under C++14 v1

This is a first version of an implementation of std::optional it is supposed to compile under C++14. The public interface of the class is complete, but there are ...
Harald Scheirich's user avatar