Skip to content

Commit

Permalink
asset(error, msg) does not work in cray if msg has + operator. Modifi…
Browse files Browse the repository at this point in the history
…ed this to make it work.
  • Loading branch information
Avirup Sircar committed Sep 10, 2024
1 parent 67201d1 commit 6bf7925
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 9 deletions.
22 changes: 13 additions & 9 deletions src/atoms/AtomSphericalData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -624,8 +624,9 @@ namespace dftefe
{
auto it = d_sphericalData.find(fieldName);
DFTEFE_AssertWithMsg(it != d_sphericalData.end(),
"FieldName " + fieldName +
" not while parsing the XML file:" + d_fileName);
("FieldName " + fieldName +
" not while parsing the XML file:" + d_fileName)
.c_str());
return it->second;
}

Expand All @@ -636,12 +637,14 @@ namespace dftefe
{
auto it = d_sphericalData.find(fieldName);
DFTEFE_AssertWithMsg(it != d_sphericalData.end(),
"Unable to find the field " + fieldName +
" while parsing the XML file " + d_fileName);
("Unable to find the field " + fieldName +
" while parsing the XML file " + d_fileName)
.c_str());
auto iter = d_qNumbersToIdMap.find(fieldName);
DFTEFE_AssertWithMsg(iter != d_qNumbersToIdMap.end(),
"Unable to find the field " + fieldName +
" while parsing the XML file " + d_fileName);
("Unable to find the field " + fieldName +
" while parsing the XML file " + d_fileName)
.c_str());
auto iterQNumberToId = (iter->second).find(qNumbers);
if (iterQNumberToId != (iter->second).end())
return *((it->second).begin() + iterQNumberToId->second);
Expand All @@ -652,9 +655,10 @@ namespace dftefe
s += std::to_string(qNumbers[i]) + " ";

DFTEFE_AssertWithMsg(false,
"Unable to find the qNumbers " + s + " for " +
" the field " + fieldName +
" while parsing the XML file " + d_fileName);
("Unable to find the qNumbers " + s + " for " +
" the field " + fieldName +
" while parsing the XML file " + d_fileName)
.c_str());
return *((it->second).begin() + iterQNumberToId->second);
}
}
Expand Down
1 change: 1 addition & 0 deletions src/atoms/AtomSphericalData.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
#include <atoms/SphericalData.h>
#include <atoms/SphericalDataNumerical.h>
#include <memory>
#include <unordered_map>
#include <map>
#include <vector>
#include <string>
Expand Down
1 change: 1 addition & 0 deletions src/atoms/AtomSphericalDataContainer.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
#define dftefeAtomSphericalDataContainer_h

#include <utils/TypeConfig.h>
#include <unordered_map>
#include <map>
#include <string>
#include <atoms/AtomSphericalData.h>
Expand Down

0 comments on commit 6bf7925

Please sign in to comment.