diff options
author | George L. Albany <Megacake1234@gmail.com> | 2024-08-04 22:17:07 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-08-04 22:17:07 +0200 |
commit | efcc544bb36c80efb911390855c0123d5d11f742 (patch) | |
tree | 210f992e56a32a832bc775a5b2c73f032bb3aca0 /src/openvic-dataloader | |
parent | 2addc7763556ff76809f14e2063d1452aa9d6275 (diff) | |
parent | df819d120610b7d3737f8b8e2ad03b7e88fb924c (diff) |
Merge pull request #55 from OpenVicProject/fixup/errors
Add error kind and error message checks to empty tests
Diffstat (limited to 'src/openvic-dataloader')
-rw-r--r-- | src/openvic-dataloader/DiagnosticLogger.hpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/openvic-dataloader/DiagnosticLogger.hpp b/src/openvic-dataloader/DiagnosticLogger.hpp index 8c491ca..479a7a0 100644 --- a/src/openvic-dataloader/DiagnosticLogger.hpp +++ b/src/openvic-dataloader/DiagnosticLogger.hpp @@ -398,8 +398,13 @@ namespace ovdl { [&](auto out, lexy::visualization_options) { return lexy::_detail::write_str(out, fmt::format(fmt, std::forward<Args>(args)...).c_str()); }); - impl.write_path(iter, file().path()); + if constexpr (!std::same_as<T, error::BufferError>) { + if (file().path() != nullptr && file().path()[0] != '\0') { + impl.write_path(iter, file().path()); + } + } + output.pop_back(); auto message = intern(output); error->_set_message(message); if (!error->is_linked_in_tree()) |