Skip to content

Commit

Permalink
remove underscores in vlaues
Browse files Browse the repository at this point in the history
  • Loading branch information
alaindargelas committed Feb 22, 2024
1 parent c2af9ac commit 4bce12b
Show file tree
Hide file tree
Showing 19 changed files with 783 additions and 781 deletions.
4 changes: 3 additions & 1 deletion src/DesignCompile/CompileExpression.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
#include <Surelog/Utils/NumUtils.h>
#include <Surelog/Utils/StringUtils.h>

#include <algorithm>
#include <cmath>
#include <cstring>

Expand Down Expand Up @@ -432,7 +433,8 @@ constant *compileConst(const FileContent *fC, NodeId child, Serializer &s) {
// Do not evaluate the constant, keep it as in the source text:
UHDM::constant *c = s.MakeConstant();
fC->populateCoreMembers(child, child, c);
const std::string_view value = fC->SymName(child);
std::string value = std::string(fC->SymName(child));
value.erase(std::remove(value.begin(), value.end(), '_'), value.end());
std::string v;
c->VpiDecompile(value);
bool tickNumber = (value.find('\'') != std::string::npos);
Expand Down
Loading

0 comments on commit 4bce12b

Please sign in to comment.