From fe3724d0ccf7610e01a971e015f01baafcba94eb Mon Sep 17 00:00:00 2001
From: Franck Dary <franck.dary@lis-lab.fr>
Date: Thu, 13 Feb 2020 18:23:38 +0100
Subject: [PATCH] Rempalced litteral id by constexpr

---
 reading_machine/src/Config.cpp | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/reading_machine/src/Config.cpp b/reading_machine/src/Config.cpp
index 6043cea..3b6041b 100644
--- a/reading_machine/src/Config.cpp
+++ b/reading_machine/src/Config.cpp
@@ -135,8 +135,8 @@ void Config::printForDebug(FILE * dest) const
   std::string stackStr = "";
   for (auto & s : stack)
   {
-    if (hasColIndex("ID"))
-      stackStr += getLastNotEmptyConst("ID", s);
+    if (hasColIndex(idColName))
+      stackStr += getLastNotEmptyConst(idColName, s);
     else
       stackStr += std::to_string(s);
     stackStr += ",";
@@ -285,12 +285,12 @@ bool Config::isComment(std::size_t lineIndex) const
 
 bool Config::isMultiword(std::size_t lineIndex) const
 {
-  return hasColIndex("ID") && getConst("ID", lineIndex, 0).get().find('-') != std::string::npos;
+  return hasColIndex(idColName) && getConst(idColName, lineIndex, 0).get().find('-') != std::string::npos;
 }
 
 bool Config::isEmptyNode(std::size_t lineIndex) const
 {
-  return hasColIndex("ID") && getConst("ID", lineIndex, 0).get().find('.') != std::string::npos;
+  return hasColIndex(idColName) && getConst(idColName, lineIndex, 0).get().find('.') != std::string::npos;
 }
 
 bool Config::isToken(std::size_t lineIndex) const
-- 
GitLab