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
Copy file name to clipboardExpand all lines: doc/92_relnotes.qbk
+22-1Lines changed: 22 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -26,7 +26,7 @@
26
26
* In C++17 all constructors (including copy and move) become core constant expressions
27
27
for co-operating types.
28
28
29
-
This addresses [@https://github.com/boostorg/optional/issues/143 issue #143].
29
+
This addresses issues [@https://github.com/boostorg/optional/issues/132 #132] and [@https://github.com/boostorg/optional/issues/143 #143].
30
30
31
31
* *Breaking change.* In the said implementation, abandoned the mechanism for customizing
32
32
`swap`. Hardly anyone knows about this mechanism and it was never documented.
@@ -37,10 +37,31 @@
37
37
* Construct `o = u`, where `o` is of type `optional<T>` and `u` is of type `U` convertible to `T`,
38
38
does not create a temporary `T`.
39
39
40
+
* In the said implementation, added a conversion from `optional<T>&` to `optional<T&>`. This addresses [@https://github.com/boostorg/optional/issues/142 issue #142].
41
+
40
42
* `none_t` is now `std::equality_comparable`, which means that `none_t` and `optional<T>`
41
43
model concept `std::equality_comparable_with` (for `std::equality_comparable` `T`s),
42
44
which means that you can `std::ranges::find(rng, boost::none)` for a range of optional objects.
43
45
46
+
* *Warning.* In the future releases we intend to introduce the range interface
47
+
in `optional`, so that `std::ranges::range<optional<T>>` will be `true`.
48
+
This may affect the overload resolution in programs that make decisions based
49
+
on predicates such as `std::ranges::range`. For instance, the following code
50
+
will start behaving differently:
51
+
52
+
```
53
+
template <typename T>
54
+
void serialize(T const& v)
55
+
{
56
+
if constexpr (std::ranges::range<T>)
57
+
serialize_as_range(v);
58
+
else if constexpr (custom::is_optional_like<T>)
59
+
serialize_as_optional(v);
60
+
else
61
+
serialize_as_value(v);
62
+
}
63
+
```
64
+
44
65
[heading Boost Release 1.87]
45
66
46
67
* *Breaking change.* Dropped support for C++03. C++11 is now the required minimum; at least some C++11 features.
0 commit comments