Commit d593a276 authored by Christian Stenger's avatar Christian Stenger Committed by Nikolai Kosjar
Browse files

C++: Fix compile for MSVC2010

Change-Id: I3049efa29b80fecc6c9daa9e1eb967428d331bb2
Reviewed-by: default avatarPrzemyslaw Gorszkowski <>
Reviewed-by: default avatarNikolai Kosjar <>
parent c980acc7
...@@ -499,7 +499,8 @@ void calculateConstantValue(const Symbol *symbol, EnumeratorDeclaration *e, Cont ...@@ -499,7 +499,8 @@ void calculateConstantValue(const Symbol *symbol, EnumeratorDeclaration *e, Cont
int constantValueAsInt = 0; int constantValueAsInt = 0;
if (stringLiteralToInt(constantValue, &constantValueAsInt)) { if (stringLiteralToInt(constantValue, &constantValueAsInt)) {
++constantValueAsInt; ++constantValueAsInt;
const std::string buffer = std::to_string(constantValueAsInt); const std::string buffer
= std::to_string(static_cast<long long>(constantValueAsInt));
e->setConstantValue(control->stringLiteral(buffer.c_str(), e->setConstantValue(control->stringLiteral(buffer.c_str(),
unsigned(buffer.size()))); unsigned(buffer.size())));
} }
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment