From a061301ab789d00027f29f389627792dccbe1748 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Thu, 10 Mar 2022 17:31:47 +0300 Subject: Allow effective quoting for names that need curly braces in their representations --- libbuild2/name.cxx | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'libbuild2/name.cxx') diff --git a/libbuild2/name.cxx b/libbuild2/name.cxx index a285459..6c48bb3 100644 --- a/libbuild2/name.cxx +++ b/libbuild2/name.cxx @@ -90,10 +90,9 @@ namespace build2 bool curly = false) { // We don't expect the effective quoting mode to be specified for the - // name patterns or names that need curly braces in their - // representations. + // name patterns. // - assert (q != quote_mode::effective || (!pat && !curly)); + assert (q != quote_mode::effective || !pat); // Special characters, path pattern characters, and regex pattern // characters. The latter only need to be quoted in the first position @@ -121,7 +120,7 @@ namespace build2 }; char esc[] = { - '$', '(', // Token endings. + '{', '}', '$', '(', // Token endings. ' ', '\t', '\n', '#', // Spaces. '"', // Quoting. pair, // Pair separator, if any. -- cgit v1.1