aboutsummaryrefslogtreecommitdiff
path: root/libbutl/path.ixx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2017-08-05 18:19:28 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2017-08-05 18:19:28 +0200
commit07f657754b0af656ee48c38540805fcec7cee27d (patch)
tree46ee0de36bb9005a6bfc9a53624ad7444e1a0c62 /libbutl/path.ixx
parentc291ac321aa9863c515f84ba0b8b1599c5da2c9a (diff)
Implement path::normalized() predicate
Diffstat (limited to 'libbutl/path.ixx')
-rw-r--r--libbutl/path.ixx8
1 files changed, 8 insertions, 0 deletions
diff --git a/libbutl/path.ixx b/libbutl/path.ixx
index c140d1e..7227b72 100644
--- a/libbutl/path.ixx
+++ b/libbutl/path.ixx
@@ -102,6 +102,14 @@ namespace butl
template <typename C, typename K>
inline bool basic_path<C, K>::
+ normalized (bool sep) const
+ {
+ return (!sep || this->tsep_ <= 1) &&
+ traits::normalized (this->path_, sep);
+ }
+
+ template <typename C, typename K>
+ inline bool basic_path<C, K>::
root () const
{
return traits::root (this->path_);