From fc620d941a5ffdb3baa7f8399ecaf5b8c03b5c03 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Sat, 25 Jul 2015 00:32:49 +0200 Subject: Get rid of warnings --- bpkg/manifest.cxx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/bpkg/manifest.cxx b/bpkg/manifest.cxx index 44a5eff..0393f6f 100644 --- a/bpkg/manifest.cxx +++ b/bpkg/manifest.cxx @@ -53,7 +53,7 @@ namespace bpkg inline static bool alpha (char c) noexcept { - return c >= 'A' && c <= 'Z' || c >= 'a' && c <= 'z'; + return (c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z'); } // Replace std::tolower to keep things locale independent. @@ -281,7 +281,7 @@ namespace bpkg case '.': { - if (mode != epoch && mode != upstream || p == cb) + if ((mode != epoch && mode != upstream) || p == cb) bad_arg (string ("unexpected '") + c + "' character position"); if (add_canonical_component (cb, p, lnn < cb)) @@ -595,7 +595,7 @@ namespace bpkg } if (i == e) - da.push_back (dependency {lv}); + da.push_back (dependency {lv, optional ()}); else { string nm (b, ne); @@ -816,8 +816,8 @@ namespace bpkg // Validate char. // bool valid (alpha (c) || - digit (c) && !flc || - (c == '-' || c == '.') && !flc && !llc); + (digit (c) && !flc) || + ((c == '-' || c == '.') && !flc && !llc)); // Validate length. // -- cgit v1.1