aboutsummaryrefslogtreecommitdiff
path: root/libbutl/path-io.mxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2019-11-08 00:17:11 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2019-11-11 17:39:25 +0300
commitfa313152767ae60941987450268f9562e1d59d42 (patch)
treebebc5c315c8c394f064f47067915812b177e4d7d /libbutl/path-io.mxx
parent23d4deb111bfff9c282c20989573c4b0775e4c16 (diff)
Add path_name_value struct
Diffstat (limited to 'libbutl/path-io.mxx')
-rw-r--r--libbutl/path-io.mxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/libbutl/path-io.mxx b/libbutl/path-io.mxx
index 54d884b..5a91dac 100644
--- a/libbutl/path-io.mxx
+++ b/libbutl/path-io.mxx
@@ -8,6 +8,8 @@
// C includes.
+#include <cassert>
+
#ifndef __cpp_lib_modules_ts
#include <ostream>
#endif
@@ -45,6 +47,8 @@ LIBBUTL_MODEXPORT namespace butl
inline std::basic_ostream<C>&
operator<< (std::basic_ostream<C>& os, const basic_path_name<P>& pn)
{
+ assert (!pn.empty ());
+
return os << (pn.name ? *pn.name : pn.path->string ());
}
}