2
0
mirror of https://github.com/boostorg/outcome.git synced 2026-01-22 05:22:28 +00:00

227 Commits

Author SHA1 Message Date
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
b169c8205b Merging commit ned14/outcome@db728f98d6:
upd
2026-01-08 18:50:09 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
9b343380e1 Merging commit ned14/outcome@47e5f5f6e9:
Merge branch 'wg14_result' into develop
2025-12-16 21:14:56 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
168a4c3064 Port Outcome over to work with ABI refactored status_code. 2025-12-04 19:28:02 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
19d8353ddc Add WG14 reference C reimplementation of Outcome. 2025-10-29 18:35:59 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
e7805af0f1 Merging commit ned14/outcome@9b5743a715:
Update changelog and Rust recipe.
2025-05-01 23:28:01 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
1e0a9ede31 Merging commit ned14/outcome@10eb45ca7d:
- Outcome.Experimental has had C representation support since the beginning, however it had
been mainly intended that C++ would originate Results, they would pass through C, and back
into C++. It hadn't really been expected that C would want to do much with Results other than
inspect them for happy or sad path.

 It turns out there is more demand than expected for a more functional Result from within C,
so this release adds the power to create Results in success and two types of failure, semantic
comparison of Results, and printing of Result messages. You can also wrap a C enum into a
quick status code from enum, allowing easy custom C error coding from 100% within C.

 [The documentation for the C support]({{% relref "../experimental/c-api" %}}) has been updated
to reflect the new facilities.
2024-07-16 21:03:04 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
10eb45ca7d - Outcome.Experimental has had C representation support since the beginning, however it had
been mainly intended that C++ would originate Results, they would pass through C, and back
into C++. It hadn't really been expected that C would want to do much with Results other than
inspect them for happy or sad path.

 It turns out there is more demand than expected for a more functional Result from within C,
so this release adds the power to create Results in success and two types of failure, semantic
comparison of Results, and printing of Result messages. You can also wrap a C enum into a
quick status code from enum, allowing easy custom C error coding from 100% within C.

 [The documentation for the C support]({{% relref "../experimental/c-api" %}}) has been updated
to reflect the new facilities.
2024-07-16 21:39:48 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
b0e3190a5a Merging commit ned14/outcome@5bcd0f32f2:
Fix issue #299 GCC 14 warns on use of `_`.
2024-06-21 12:13:31 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
5bcd0f32f2 Fix issue #299 GCC 14 warns on use of _. 2024-06-21 12:50:49 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
03cadce530 Merging commit ned14/outcome@571f9c930e:
upd
2024-03-13 20:50:49 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
84577bff26 Merging commit ned14/outcome@d4d196619d:
Fixes #293
- Some users wished that Outcome would be clean with `-Wpedantic`, this is now turned on for
the test suite.

Fixes #294
- All use of `assert()` has been replaced with `OUTCOME_ASSERT`, which can be user overridden
at compile time.

Fixes #295
- In git commit 12b14e1533 (Aug 11 2022) status code had its
paths changed due to its headers not previously having the right path convention. It was not
realised at the time that in Boost.Outcome this resulted in
`<boost/outcome/experimental/status-code/status-code/headers.hpp>` which is not desirable.
This has now been remedied to remove the double `status-code`, which will obviously break
any Boost.Outcome code which relies on the double `status-code`. Standalone Outcome is unaffected.
2023-12-16 21:13:43 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
d4d196619d Fixes #293
- Some users wished that Outcome would be clean with `-Wpedantic`, this is now turned on for
the test suite.

Fixes #294
- All use of `assert()` has been replaced with `OUTCOME_ASSERT`, which can be user overridden
at compile time.

Fixes #295
- In git commit 12b14e1533 (Aug 11 2022) status code had its
paths changed due to its headers not previously having the right path convention. It was not
realised at the time that in Boost.Outcome this resulted in
`<boost/outcome/experimental/status-code/status-code/headers.hpp>` which is not desirable.
This has now been remedied to remove the double `status-code`, which will obviously break
any Boost.Outcome code which relies on the double `status-code`. Standalone Outcome is unaffected.
2023-12-16 20:51:26 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
ef1b519850 Merging commit ned14/outcome@f7892ac2e8:
A Result or Outcome with `void` value type and move-only non-value type was only usable in
const use cases, due to the lack of provision of non-const member functions in relevant observers
injection layers for the `void` specialisation. The missing non-const member functions have now
been added. Fixes #291.
2023-11-17 09:20:02 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
f7892ac2e8 A Result or Outcome with void value type and move-only non-value type was only usable in
const use cases, due to the lack of provision of non-const member functions in relevant observers
injection layers for the `void` specialisation. The missing non-const member functions have now
been added. Fixes #291.
2023-11-17 08:58:24 +00:00
Niall Douglas
8eefcf3780 Merging commit ned14/outcome@0bedf671c0:
Merge pull request #283 from ned14/wip-fix-addressof

Use a preprocessor macro to control the use of std::addressof(), fixing #282.
2023-07-15 22:16:38 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
cc6088dae7 Use a preprocessor macro to control the use of std::addressof(),
fixing #282.
2023-07-15 11:44:03 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
474d09a402 Merging commit ned14/outcome@b274e869c2:
Merge branch 'use-addressof' of https://github.com/gix/outcome into develop
2023-06-28 21:46:36 +00:00
Nico Rieck
2c8330485a Use std::addressof instead of operator& 2023-06-02 17:20:00 +02:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
9aa84a322a Merging commit ned14/outcome@a74e523195:
Try to work around stupid clang-cl parse bug.
2023-04-26 16:53:35 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
a74e523195 Try to work around stupid clang-cl parse bug. 2023-04-26 17:16:30 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
b6239dd336 Merging commit ned14/outcome@8108b6cbf8:
Fix Boost.Outcome breakage on MSVC in C++ 14.
2023-04-26 09:29:39 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
8108b6cbf8 Fix Boost.Outcome breakage on MSVC in C++ 14. 2023-04-26 10:03:59 +01:00
Henrik Gaßmann
02b07b0a93 Merging commit ned14/outcome@093f364aa6:
Merge pull request #274 from amerry/appleclang-warning-fix

Properly guard the usage of [[likely]] (especially for AppleClang 12)
2023-01-26 06:59:42 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
4875357541 Merging commit ned14/outcome@66ebdd4e86:
Stop Boost regression tests complaining about no test tree.
2022-11-18 18:44:33 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
66ebdd4e86 Stop Boost regression tests complaining about no test tree. 2022-11-18 18:15:09 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
3d6ad998b7 Merging commit ned14/outcome@2d2c444e36:
Merge branch 'develop'
2022-04-16 12:05:02 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
364077e301 Merging commit ned14/outcome@33c97cdf63:
Fix issue #261 where the fix for issue #259 did not account for void types.
2022-04-16 12:04:59 +00:00
Niall Douglas
94575dc7ff Merging commit ned14/outcome@eeda50853d:
Merge pull request #260 from ned14/issue0259fix

Fix issue #259 enabling of move assignable is not calculated correctly.
2022-04-16 12:04:55 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
6ee1a897d2 Merging commit ned14/outcome@3bdb7949f0:
Merge branch 'issue0261' into develop
2022-04-06 09:51:48 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
3bdb7949f0 Merge branch 'issue0261' into develop 2022-04-05 22:53:31 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
33c97cdf63 Fix issue #261 where the fix for issue #259 did not account for void types. 2022-04-05 22:43:52 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
eb4a3ea9cd Merging commit ned14/outcome@cfdb4fe11f:
Merge branch 'issue0259fix' into develop
2022-04-01 08:36:39 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
267009ab6b Merging commit ned14/outcome@f27104952c:
Merge branch 'issue0259fix' into develop
2022-04-01 08:36:37 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
cfdb4fe11f Merge branch 'issue0259fix' into develop 2022-04-01 09:09:20 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
1c0a83e5ed Fix last commit on GCC, which for some reason disabled the implicit constructors. 2022-04-01 09:07:34 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
f27104952c Merge branch 'issue0259fix' into develop 2022-03-30 13:36:59 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
95fe32c86c Fix issue #259 enabling of move assignable is not calculated correctly. 2022-03-30 13:01:11 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
0090259cd0 Merging commit ned14/outcome@71a8796b1d:
Fix last commit not building if exceptions were disabled.
2022-03-18 15:11:00 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
0fd2a2307e Merging commit ned14/outcome@dd70808c68:
Add Outcome specialised awaitables::generator<T>.
2022-03-18 15:10:59 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
71a8796b1d Fix last commit not building if exceptions were disabled. 2022-03-17 20:13:07 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
dd70808c68 Add Outcome specialised awaitables::generator<T>. 2022-03-17 19:36:18 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
9db6a9a85d Merging commit ned14/outcome@7468dda5ce:
Fix up tests broken by updated status code last commit.
2022-01-27 19:30:08 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
7468dda5ce Fix up tests broken by updated status code last commit. 2022-01-27 19:04:24 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
64406c50fc Merging commit ned14/outcome@af7e4879b9:
Complete first attempt at review of error handling frameworks for the docs.
2022-01-04 12:41:50 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
d5bcf026ae Merging commit ned14/outcome@a86c6b053b:
Restore Experimental Outcome constexpr compatibility in C++ 20 which was an undocumented property of the Outcome v2.1 series, and which had been dropped in the v2.2 series (issue #255)
2021-10-29 13:30:18 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
a86c6b053b Restore Experimental Outcome constexpr compatibility in C++ 20 which was an undocumented property of the Outcome v2.1 series, and which had been dropped in the v2.2 series (issue #255) 2021-09-22 11:54:37 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
613953775e Merging commit ned14/outcome@1a8140bda2:
Fix previous commit of CMakeLists.txt for Boost.Outcome test. Also workaround Boost conversion for test issue0203, and disable for Boost test issue0182.
2021-07-17 13:39:36 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
1a8140bda2 Fix previous commit of CMakeLists.txt for Boost.Outcome test. Also workaround Boost conversion for test issue0203, and disable for Boost test issue0182. 2021-05-28 14:36:07 +01:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
8afa4cc690 Merging commit ned14/outcome@9ec7fe7a5c:
BREAKING CHANGE [#247](https://github.com/ned14/outcome/issues/247)

Previously the value of "spare_storage(const basic_result|basic_outcome *) noexcept" was
not propagated over `OUTCOME_TRY`, which causes things like stack backtraces captured at the point of
construction of an errored result to get dropped at every `TRY` point. This has been fixed by adding
an optional `spare_storage` to "success_type<T>" and "failure_type<T>"}, as well
as to "auto success(T &&, ...)" and "auto failure(T &&, ...)".

You should not notice this in your code, except that where before spare storage values did not
propagate through TRY, now they do, which is a breaking change.
2021-02-23 22:41:03 +00:00
Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)
ba11268330 Merging commit ned14/outcome@38142ef2a3:
Add cmake option OUTCOME_ENABLE_CXX_MODULES, which fails to compile currently (#246).
2021-02-23 22:41:01 +00:00