From 59db6ff22d090f8b47e278e9ecbeaa049ba3ba55 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Sat, 28 Sep 2019 20:48:35 +0300 Subject: Adapt to swapping of entry and pattern parameters in butl::path_match() --- libbuild2/parser.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'libbuild2/parser.cxx') diff --git a/libbuild2/parser.cxx b/libbuild2/parser.cxx index 0a5142f..33da1b5 100644 --- a/libbuild2/parser.cxx +++ b/libbuild2/parser.cxx @@ -3691,10 +3691,10 @@ namespace build2 // Compare name to pattern as paths and according to dir. // - auto match = [&dir, sp] (const path& pattern, const name& n) -> bool + auto match = [&dir, sp] (const name& n, const path& pattern) -> bool { const path& p (dir ? path_cast (n.dir) : path (n.value)); - return path_match (pattern, p, *sp); + return path_match (p, pattern, *sp); }; // Append name/extension to result according to dir. Store an indication @@ -3810,7 +3810,7 @@ namespace build2 { for (auto i (r.begin ()); i != r.end (); ) { - if (match (p, *i)) + if (match (*i, p)) i = r.erase (i); else ++i; -- cgit v1.1