A growing collection of error utilities. More...
Classes | |
| class | sourcemeta::core::Error |
| class | sourcemeta::core::FileError< T > |
A growing collection of error utilities.
This functionality is included as follows:
| class sourcemeta::core::Error |
The base class of every error this project raises. It cannot be constructed on its own, and its message is fixed at compile time.
Public Member Functions | |
|---|---|
| auto | message () const noexcept -> StaticString |
Protected Member Functions | |
| Error (const StaticString message) noexcept | |
| Construct the error given its message. | |
|
inlinenodiscardnoexcept |
Get the message in the form another error can take it, which is how a handler raises a different error without restating the reason.
| class sourcemeta::core::FileError |
A wrapper that decorates an arbitrary exception type with a file path.
Public Member Functions | |
|---|---|
| template<typename... Args> | |
| FileError (std::filesystem::path path, Args &&...args) | |
| auto | path () const noexcept -> const std::filesystem::path & |
| The offending file path. | |
|
inline |
Construct the error given the offending file path and the underlying exception arguments.