From 34e42b9aa2d2c35a0b0a894ba279f53034d66051 Mon Sep 17 00:00:00 2001 From: "Harry T. Vennik" Date: Sat, 4 Nov 2017 10:59:41 +0100 Subject: [PATCH] Improved code formatting --- source/ddbus/thin.d | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/source/ddbus/thin.d b/source/ddbus/thin.d index bd3c3df..3cd9411 100644 --- a/source/ddbus/thin.d +++ b/source/ddbus/thin.d @@ -27,7 +27,9 @@ struct ObjectPath { return _value; } - /// Returns the string representation of this ObjectPath. + /++ + Returns the string representation of this ObjectPath. + +/ string value() const pure @nogc nothrow @safe { return _value; } @@ -71,7 +73,10 @@ struct ObjectPath { _value = opBinary!"~"(rhs)._value; } - /// Returns: false for empty strings or strings that don't match the pattern `(/[0-9A-Za-z_]+)+|/` + /++ + Returns: `false` for empty strings or strings that don't match the + pattern `(/[0-9A-Za-z_]+)+|/`. + +/ static bool isValid(string objPath) pure @nogc nothrow @safe { import std.ascii : isAlphaNum; @@ -83,12 +88,12 @@ struct ObjectPath { return false; // .representation to avoid unicode exceptions -> @nogc & nothrow return objPath.representation.splitter('/').drop(1) - .all!(a => - a.length && - a.all!(c => - c.isAlphaNum || c == '_' - ) - ); + .all!(a => + a.length && + a.all!(c => + c.isAlphaNum || c == '_' + ) + ); } }