diff options
| author | Leitwolf11 | 2026-10-31 13:01:04 +0300 |
|---|---|---|
| committer | Leitwolf11 | 2026-10-31 13:01:04 +0300 |
| commit | 1f5458322669301f62599c1ec5dacb77b5dc2d8d (patch) | |
| tree | 7e32402fa9c06014328a27d7972c2fb1a9484352 /Guide/ERRORS.md | |
| parent | 8d1fb4807edc7920fbecd0554c9c61625827e19c (diff) | |
| download | progmasoft-cpp-docs/cpp17-and-cpp20.tar.gz | |
Cover C++17 as well as C++20docs/cpp17-and-cpp20
A project now picks one version. C++20 stays the default, and C++17 is
for libraries meant for other people's projects, because it is still the
widest common target and works in every later standard.
Section 5.13 gives the C++17 form of each C++20 feature the guide uses
and the checks such a project needs: CI in the versions it promises, with
each compiler, and headers that compile in default compiler modes.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'Guide/ERRORS.md')
| -rw-r--r-- | Guide/ERRORS.md | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Guide/ERRORS.md b/Guide/ERRORS.md index e57c790..20c524f 100644 --- a/Guide/ERRORS.md +++ b/Guide/ERRORS.md @@ -27,7 +27,7 @@ never lets one cross a C interface or escape a destructor. Third-party code keep ## 7.2 `Expected<T>` and `Error` A function that produces a value or fails returns `Expected<T>`; one that only succeeds or fails returns `Error`. The guide -does not prescribe the library. `llvm::Expected<T>` and `llvm::Error` suit code that already depends on LLVM; a C++20 +does not prescribe the library. `llvm::Expected<T>` and `llvm::Error` suit code that already depends on LLVM; a backport of `std::expected` (such as `tl::expected`) or a small type of the project's own suit the rest, and C++23's `std::expected` replaces them once a project moves to it. What matters is the discipline below: the failure is in the signature, it cannot be ignored, and it carries a message. |