changeset 2926:0bcf46cea4e4

fix for older versions of boost::regex
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 09 Nov 2018 11:55:16 +0100
parents a80ba85d89e6
children 9f48722e8508
files Core/Toolbox.cpp
diffstat 1 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/Core/Toolbox.cpp	Fri Nov 09 09:46:21 2018 +0100
+++ b/Core/Toolbox.cpp	Fri Nov 09 11:55:16 2018 +0100
@@ -1573,10 +1573,10 @@
   std::string Toolbox::SubstituteVariables(const std::string& source,
                                            const std::map<std::string, std::string>& dictionary)
   {
-    const boost::regex pattern("\\${([^:]*?)}|"                 // ${what[1]}
-                               "\\${([^:]*?):-([^'\"]*?)}|"     // ${what[2]:-what[3]}
-                               "\\${([^:]*?):-\"([^\"]*?)\"}|"  // ${what[4]:-"what[5]"}
-                               "\\${([^:]*?):-'([^']*?)'}");    // ${what[6]:-'what[7]'}
+    const boost::regex pattern("\\$\\{([^:]*?)\\}|"                 // ${what[1]}
+                               "\\$\\{([^:]*?):-([^'\"]*?)\\}|"     // ${what[2]:-what[3]}
+                               "\\$\\{([^:]*?):-\"([^\"]*?)\"\\}|"  // ${what[4]:-"what[5]"}
+                               "\\$\\{([^:]*?):-'([^']*?)'\\}");    // ${what[6]:-'what[7]'}
 
     VariableFormatter formatter(dictionary);