From 5a46cc776a609c538795d706a6eee93913debe1f Mon Sep 17 00:00:00 2001
From: Vakho Tsulaia <vakhtang.tsulaia@cern.ch>
Date: Mon, 8 Nov 2021 10:53:06 -0800
Subject: [PATCH] Bug fix in GmxUtil::evaluate()

Fixed wrong declaration of the thread_local variable
---
 GeoModelTools/GeoModelXML/GeoModelXml/src/GmxUtil.cxx | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/GeoModelTools/GeoModelXML/GeoModelXml/src/GmxUtil.cxx b/GeoModelTools/GeoModelXML/GeoModelXml/src/GmxUtil.cxx
index 3e2ca1780..6b9b86a75 100644
--- a/GeoModelTools/GeoModelXML/GeoModelXml/src/GmxUtil.cxx
+++ b/GeoModelTools/GeoModelXML/GeoModelXml/src/GmxUtil.cxx
@@ -81,8 +81,8 @@ GmxInterface * GmxUtil::gmxInterface() {
 }
 
 double GmxUtil::evaluate(char const *expression) {
-    static string lastGoodExpression("none"); // It is helpful for debugging to get some idea of where we had got to...
-    string thread_local strExpression(expression);
+    static thread_local string lastGoodExpression("none"); // It is helpful for debugging to get some idea of where we had got to...
+    string strExpression(expression);
 
     bool isWhiteSpace = true;
     for(unsigned int i = 0; i < strExpression.length(); ++i){
-- 
GitLab